[gnome-nettool] Move GtkBuilder and .desktop files to data directory.



commit a8008f5b5987159319eeede2f0f5ecc9f3aad12d
Author: Javier Jardón <jjardon gnome org>
Date:   Thu Apr 8 04:12:25 2010 +0200

    Move GtkBuilder and .desktop files to data directory.
    
    The "data" directory is the standarized place to store .desktop
    and GtkBuilder files
    
    Fixes https://bugzilla.gnome.org/show_bug.cgi?id=615133

 Makefile.am                               |    2 +-
 configure.ac                              |    3 ++-
 data/Makefile.am                          |   23 +++++++++++++++++++++++
 {src => data}/gnome-nettool.desktop.in.in |    0
 {src => data}/gnome-nettool.ui            |   28 ++++++++++++++--------------
 src/Makefile.am                           |   19 +------------------
 src/main.c                                |    2 +-
 7 files changed, 42 insertions(+), 35 deletions(-)
---
diff --git a/Makefile.am b/Makefile.am
index 24da9b9..b265d3b 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -1,6 +1,6 @@
 ACLOCAL_AMFLAGS = -I m4 ${ACLOCAL_FLAGS}
 
-SUBDIRS = pixmaps src help po
+SUBDIRS = pixmaps data src help po
 
 DISTCHECK_CONFIGURE_FLAGS = --disable-scrollkeeper
 
diff --git a/configure.ac b/configure.ac
index a841dcd..d8f047d 100644
--- a/configure.ac
+++ b/configure.ac
@@ -89,6 +89,8 @@ AC_SUBST(LDFLAGS)
 
 AC_CONFIG_FILES([
 Makefile
+data/Makefile
+data/gnome-nettool.desktop.in
 help/Makefile
 pixmaps/Makefile
 pixmaps/icons/Makefile
@@ -103,6 +105,5 @@ pixmaps/icons/32x32/apps/Makefile
 pixmaps/icons/scalable/Makefile
 pixmaps/icons/scalable/apps/Makefile
 po/Makefile.in
-src/gnome-nettool.desktop.in
 src/Makefile])
 AC_OUTPUT
diff --git a/data/Makefile.am b/data/Makefile.am
new file mode 100644
index 0000000..8a4ce3a
--- /dev/null
+++ b/data/Makefile.am
@@ -0,0 +1,23 @@
+uidir = $(pkgdatadir)/$(PACKAGE)/ui
+ui_DATA = gnome-nettool.ui
+
+desktopdir = $(datadir)/applications
+desktop_in_in_files = gnome-nettool.desktop.in.in
+desktop_in_files = $(desktop_in_in_files:.desktop.in.in=.desktop.in)
+desktop_DATA = $(desktop_in_files:.desktop.in=.desktop)
+ INTLTOOL_DESKTOP_RULE@
+
+if GCONF_SCHEMAS_INSTALL
+install-data-local:
+        @$(NORMAL_INSTALL)
+endif
+
+EXTRA_DIST =                    \
+	$(desktop_in_in_files)  \
+	$(ui_DATA)
+
+DISTCLEANFILES =                \
+	$(desktop_in_files)
+
+CLEANFILES =                    \
+	$(desktop_DATA)
diff --git a/src/gnome-nettool.desktop.in.in b/data/gnome-nettool.desktop.in.in
similarity index 100%
rename from src/gnome-nettool.desktop.in.in
rename to data/gnome-nettool.desktop.in.in
diff --git a/src/gnome-nettool.ui b/data/gnome-nettool.ui
similarity index 99%
rename from src/gnome-nettool.ui
rename to data/gnome-nettool.ui
index 9602ba9..7bc5adf 100644
--- a/src/gnome-nettool.ui
+++ b/data/gnome-nettool.ui
@@ -950,7 +950,7 @@
                                 <property name="has_tooltip">True</property>
                                 <property name="tooltip_text" translatable="yes">Enter the network address to ping. For example: www.domain.com or 192.168.2.1</property>
                                 <accessibility>
-                                  
+
                                 </accessibility>
                                 <child internal-child="accessible">
                                   <object class="AtkObject" id="a11y-comboboxentry-entry11">
@@ -1586,7 +1586,7 @@
                         <property name="tooltip-text" translatable="yes">Output for net stat</property>
                         <property name="enable_search">False</property>
                         <accessibility>
-                          
+
                         </accessibility>
                         <child internal-child="accessible">
                           <object class="AtkObject" id="a11y-netstat_output1">
@@ -1735,7 +1735,7 @@
                         <property name="tooltip-text" translatable="yes">Output for traceroute</property>
                         <property name="enable_search">False</property>
                         <accessibility>
-                          
+
                         </accessibility>
                         <child internal-child="accessible">
                           <object class="AtkObject" id="a11y-traceroute_output1">
@@ -1797,7 +1797,7 @@
                                 <property name="has_tooltip">True</property>
                                 <property name="tooltip_text" translatable="yes">Enter the network address to scan for open ports. For example: www.domain.com or 192.168.2.1</property>
                                 <accessibility>
-                                  
+
                                 </accessibility>
                                 <child internal-child="accessible">
                                   <object class="AtkObject" id="a11y-comboboxentry-entry31">
@@ -1891,7 +1891,7 @@
                         <property name="tooltip-text" translatable="yes">Output for port scan</property>
                         <property name="enable_search">False</property>
                         <accessibility>
-                          
+
                         </accessibility>
                         <child internal-child="accessible">
                           <object class="AtkObject" id="a11y-scan_output1">
@@ -1971,7 +1971,7 @@
                                 <property name="has_tooltip">True</property>
                                 <property name="tooltip_text" translatable="yes">Enter the network address to lookup. For example: www.domain.com or 192.168.2.1</property>
                                 <accessibility>
-                                  
+
                                 </accessibility>
                                 <child internal-child="accessible">
                                   <object class="AtkObject" id="a11y-comboboxentry-entry41">
@@ -2082,7 +2082,7 @@
                         <property name="can_focus">True</property>
                         <property name="tooltip-text" translatable="yes">Output for lookup</property>
                         <accessibility>
-                          
+
                         </accessibility>
                         <child internal-child="accessible">
                           <object class="AtkObject" id="a11y-lookup_output1">
@@ -2134,7 +2134,7 @@
                                 <property name="has_tooltip">True</property>
                                 <property name="tooltip_text" translatable="yes">Enter the network address to finger that user. For example: www.domain.com or 192.168.2.1</property>
                                 <accessibility>
-                                  
+
                                 </accessibility>
                                 <child internal-child="accessible">
                                   <object class="AtkObject" id="a11y-comboboxentry-entry61">
@@ -2169,7 +2169,7 @@
                                 <property name="has_tooltip">True</property>
                                 <property name="tooltip_text" translatable="yes">Enter the user to finger</property>
                                 <accessibility>
-                                  
+
                                 </accessibility>
                                 <child internal-child="accessible">
                                   <object class="AtkObject" id="a11y-comboboxentry-entry51">
@@ -2295,7 +2295,7 @@
                         <property name="tooltip-text" translatable="yes">Output for finger</property>
                         <property name="editable">False</property>
                         <accessibility>
-                          
+
                         </accessibility>
                         <child internal-child="accessible">
                           <object class="AtkObject" id="a11y-finger_output1">
@@ -2355,7 +2355,7 @@
                                 <property name="has_tooltip">True</property>
                                 <property name="tooltip_text" translatable="yes">Enter a domain address to lookup its whois information. For example: www.domain.com or 192.168.2.1</property>
                                 <accessibility>
-                                  
+
                                 </accessibility>
                                 <child internal-child="accessible">
                                   <object class="AtkObject" id="a11y-comboboxentry-entry71">
@@ -2449,8 +2449,8 @@
                         <property name="tooltip-text" translatable="yes">Output for whois</property>
                         <property name="editable">False</property>
                         <accessibility>
-                          
-                          
+
+
                         </accessibility>
                         <child internal-child="accessible">
                           <object class="AtkObject" id="a11y-whois_output1">
@@ -2473,7 +2473,7 @@
                 <property name="tooltip-text" translatable="yes">Output for whois</property>
                 <property name="label" translatable="yes">Whois</property>
                 <accessibility>
-                  
+
                 </accessibility>
                 <child internal-child="accessible">
                   <object class="AtkObject" id="a11y-whois1">
diff --git a/src/Makefile.am b/src/Makefile.am
index a99c8f9..a0a1bbe 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -1,9 +1,6 @@
-dialogdir = $(datadir)/$(PACKAGE)/dialogs
-dialog_DATA = gnome-nettool.ui
-
 INCLUDES = 							\
 	-DGNOME_NETTOOL_LOCALEDIR=\""$(datadir)/locale"\" 	\
-	-DDATADIR=\""$(dialogdir)/"\" 				\
+	-DUI_DIR=\""$(pkgdatadir)/ui/"\" 			\
 	-DPIXMAPS_DIR=\""$(datadir)/gnome-nettool/pixmaps"\"	\
 	@NETTOOL_CFLAGS@
 
@@ -30,17 +27,3 @@ gnome_nettool_SOURCES = \
 	main.c
 
 gnome_nettool_LDADD = @NETTOOL_LIBS@
-
-EXTRA_DIST  = \
-	gnome-nettool.desktop.in \
-	$(dialog_DATA)
-
-DISTCLEANFILES = gnome-nettool.desktop
-
-Applicationsdir = $(datadir)/applications
-Applications_in_files = gnome-nettool.desktop.in
-Applications_DATA = $(Applications_in_files:.desktop.in=.desktop)
- INTLTOOL_DESKTOP_RULE@
-
-install-data-local:
-	@$(NORMAL_INSTALL)
diff --git a/src/main.c b/src/main.c
index de7630d..e503c79 100644
--- a/src/main.c
+++ b/src/main.c
@@ -57,7 +57,7 @@ main (int argc, char *argv[])
 	GtkBuilder *builder;
 	GtkWidget *notebook;
 	GtkWidget *statusbar;
-	const gchar *dialog = DATADIR "gnome-nettool.ui";
+	const gchar *dialog = UI_DIR "gnome-nettool.ui";
 	Netinfo *pinger;
 	Netinfo *tracer;
 	Netinfo *netstat;



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]