[gnome-settings-daemon/randr-osd: 4/15] Add icon files for the stock configuration types



commit a8f520ebcd0dbb6d8da0736dec908a8cb193ea04
Author: Federico Mena Quintero <federico novell com>
Date:   Wed Jan 13 14:32:36 2010 -0600

    Add icon files for the stock configuration types
    
    Signed-off-by: Federico Mena Quintero <federico novell com>

 plugins/xrandr/Makefile.am                   |   38 ++++++++++++++++++++----
 plugins/xrandr/gsd-xrandr-clone-laptop.png   |  Bin 0 -> 33865 bytes
 plugins/xrandr/gsd-xrandr-clone-monitors.png |  Bin 0 -> 33416 bytes
 plugins/xrandr/gsd-xrandr-custom.png         |  Bin 0 -> 3301 bytes
 plugins/xrandr/gsd-xrandr-extended-ontop.png |  Bin 0 -> 29199 bytes
 plugins/xrandr/gsd-xrandr-extended-right.png |  Bin 0 -> 21461 bytes
 plugins/xrandr/gsd-xrandr-external.png       |  Bin 0 -> 28287 bytes
 plugins/xrandr/gsd-xrandr-laptop.png         |  Bin 0 -> 30013 bytes
 plugins/xrandr/gsd-xrandr-manager.c          |   40 ++++++++++++++++++++++++-
 9 files changed, 70 insertions(+), 8 deletions(-)
---
diff --git a/plugins/xrandr/Makefile.am b/plugins/xrandr/Makefile.am
index b8d8f8e..c66d09a 100644
--- a/plugins/xrandr/Makefile.am
+++ b/plugins/xrandr/Makefile.am
@@ -1,16 +1,26 @@
 icondir = $(datadir)/icons/hicolor
 context = apps
+stock_config_icon_dir = $(datadir)/gnome-settings-daemon/xrandr
 
 BUILT_SOURCES =				\
 	gsd-xrandr-manager-glue.h
 
-ICON_FILES = 			\
-	gsd-xrandr-16.png	\
-	gsd-xrandr-22.png	\
-	gsd-xrandr-24.png	\
-	gsd-xrandr-32.png	\
+ICON_FILES =				\
+	gsd-xrandr-16.png		\
+	gsd-xrandr-22.png		\
+	gsd-xrandr-24.png		\
+	gsd-xrandr-32.png		\
 	gsd-xrandr.svg
 
+STOCK_CONFIG_ICON_FILES =		\
+	gsd-xrandr-clone-laptop.png	\
+	gsd-xrandr-clone-monitors.png	\
+	gsd-xrandr-custom.png		\
+	gsd-xrandr-extended-ontop.png	\
+	gsd-xrandr-extended-right.png	\
+	gsd-xrandr-external.png		\
+	gsd-xrandr-laptop.png
+
 install-data-local:
 	$(mkinstalldirs) $(DESTDIR)$(icondir)/16x16/$(context)
 	$(mkinstalldirs) $(DESTDIR)$(icondir)/22x22/$(context)
@@ -22,6 +32,14 @@ install-data-local:
 	$(INSTALL_DATA) $(srcdir)/gsd-xrandr-24.png $(DESTDIR)$(icondir)/24x24/$(context)/gsd-xrandr.png
 	$(INSTALL_DATA) $(srcdir)/gsd-xrandr-32.png $(DESTDIR)$(icondir)/32x32/$(context)/gsd-xrandr.png
 	$(INSTALL_DATA) $(srcdir)/gsd-xrandr.svg $(DESTDIR)$(icondir)/scalable/$(context)/gsd-xrandr.svg
+	$(MKDIR_P) $(stock_config_icon_dir)
+	$(INSTALL_DATA) $(srcdir)/gsd-xrandr-clone-laptop.png $(stock_config_icon_dir)/gsd-xrandr-clone-laptop.png
+	$(INSTALL_DATA) $(srcdir)/gsd-xrandr-clone-monitors.png $(stock_config_icon_dir)/gsd-xrandr-clone-monitors.png
+	$(INSTALL_DATA) $(srcdir)/gsd-xrandr-custom.png $(stock_config_icon_dir)/gsd-xrandr-custom.png
+	$(INSTALL_DATA) $(srcdir)/gsd-xrandr-extended-ontop.png $(stock_config_icon_dir)/gsd-xrandr-extended-ontop.png
+	$(INSTALL_DATA) $(srcdir)/gsd-xrandr-extended-right.png $(stock_config_icon_dir)/gsd-xrandr-extended-right.png
+	$(INSTALL_DATA) $(srcdir)/gsd-xrandr-external.png $(stock_config_icon_dir)/gsd-xrandr-external.png
+	$(INSTALL_DATA) $(srcdir)/gsd-xrandr-laptop.png $(stock_config_icon_dir)/gsd-xrandr-laptop.png
 
 uninstall-local:
 	rm -f $(DESTDIR)$(icondir)/16x16/$(context)/gsd-xrandr.png
@@ -29,6 +47,14 @@ uninstall-local:
 	rm -f $(DESTDIR)$(icondir)/24x24/$(context)/gsd-xrandr.png
 	rm -f $(DESTDIR)$(icondir)/32x32/$(context)/gsd-xrandr.png
 	rm -f $(DESTDIR)$(icondir)/scalable/$(context)/gsd-xrandr.svg
+	rm -f $(stock_config_icon_dir)/gsd-xrandr-clone-laptop.png
+	rm -f $(stock_config_icon_dir)/gsd-xrandr-clone-monitors.png
+	rm -f $(stock_config_icon_dir)/gsd-xrandr-custom.png
+	rm -f $(stock_config_icon_dir)/gsd-xrandr-extended-ontop.png
+	rm -f $(stock_config_icon_dir)/gsd-xrandr-extended-right.png
+	rm -f $(stock_config_icon_dir)/gsd-xrandr-external.png
+	rm -f $(stock_config_icon_dir)/gsd-xrandr-laptop.png
+	rmdir $(stock_config_icon_dir)
 
 plugin_LTLIBRARIES = \
 	libxrandr.la
@@ -70,7 +96,7 @@ plugin_in_files =			\
 
 plugin_DATA = $(plugin_in_files:.gnome-settings-plugin.in=.gnome-settings-plugin)
 
-EXTRA_DIST = $(plugin_in_files) $(ICON_FILES) gsd-xrandr-manager.xml
+EXTRA_DIST = $(plugin_in_files) $(ICON_FILES) $(STOCK_CONFIG_ICON_FILES) gsd-xrandr-manager.xml
 CLEANFILES = $(plugin_DATA) $(BUILT_SOURCES)
 DISTCLEANFILES = $(plugin_DATA)
 
diff --git a/plugins/xrandr/gsd-xrandr-clone-laptop.png b/plugins/xrandr/gsd-xrandr-clone-laptop.png
new file mode 100644
index 0000000..1c78ff8
Binary files /dev/null and b/plugins/xrandr/gsd-xrandr-clone-laptop.png differ
diff --git a/plugins/xrandr/gsd-xrandr-clone-monitors.png b/plugins/xrandr/gsd-xrandr-clone-monitors.png
new file mode 100644
index 0000000..73fd94b
Binary files /dev/null and b/plugins/xrandr/gsd-xrandr-clone-monitors.png differ
diff --git a/plugins/xrandr/gsd-xrandr-custom.png b/plugins/xrandr/gsd-xrandr-custom.png
new file mode 100644
index 0000000..f34fde7
Binary files /dev/null and b/plugins/xrandr/gsd-xrandr-custom.png differ
diff --git a/plugins/xrandr/gsd-xrandr-extended-ontop.png b/plugins/xrandr/gsd-xrandr-extended-ontop.png
new file mode 100644
index 0000000..5f9abfe
Binary files /dev/null and b/plugins/xrandr/gsd-xrandr-extended-ontop.png differ
diff --git a/plugins/xrandr/gsd-xrandr-extended-right.png b/plugins/xrandr/gsd-xrandr-extended-right.png
new file mode 100644
index 0000000..5149217
Binary files /dev/null and b/plugins/xrandr/gsd-xrandr-extended-right.png differ
diff --git a/plugins/xrandr/gsd-xrandr-external.png b/plugins/xrandr/gsd-xrandr-external.png
new file mode 100644
index 0000000..10a9f5a
Binary files /dev/null and b/plugins/xrandr/gsd-xrandr-external.png differ
diff --git a/plugins/xrandr/gsd-xrandr-laptop.png b/plugins/xrandr/gsd-xrandr-laptop.png
new file mode 100644
index 0000000..b65edd6
Binary files /dev/null and b/plugins/xrandr/gsd-xrandr-laptop.png differ
diff --git a/plugins/xrandr/gsd-xrandr-manager.c b/plugins/xrandr/gsd-xrandr-manager.c
index 52c2b4c..a10901b 100644
--- a/plugins/xrandr/gsd-xrandr-manager.c
+++ b/plugins/xrandr/gsd-xrandr-manager.c
@@ -90,8 +90,10 @@
 typedef enum {
         STOCK_CONFIG_CURRENT,
         STOCK_CONFIG_LAPTOP,
-        STOCK_CONFIG_CLONE,
-        STOCK_CONFIG_EXTENDED,
+        STOCK_CONFIG_CLONE_LAPTOP,
+        STOCK_CONFIG_CLONE_MONITORS,
+        STOCK_CONFIG_EXTENDED_RIGHT,
+        STOCK_CONFIG_EXTENDED_ONTOP,
         STOCK_CONFIG_EXTERNAL,
         STOCK_CONFIG_CUSTOM
 } StockConfigType;
@@ -996,6 +998,40 @@ error_message (GsdXrandrManager *mgr, const char *primary_text, GError *error_to
 #endif /* HAVE_LIBNOTIFY */
 }
 
+static const char *
+get_icon_name_for_stock_config (StockConfigType type)
+{
+        switch (type) {
+        case STOCK_CONFIG_CURRENT:
+                return "gsd-xrandr-current";
+
+        case STOCK_CONFIG_LAPTOP:
+                return "gsd-xrandr-laptop";
+
+        case STOCK_CONFIG_CLONE_LAPTOP:
+                return "gsd-xrandr-clone-laptop";
+
+        case STOCK_CONFIG_CLONE_MONITORS:
+                return "gsd-xrandr-clone-monitors";
+
+        case STOCK_CONFIG_EXTENDED_RIGHT:
+                return "gsd-xrandr-extended-right";
+
+        case STOCK_CONFIG_EXTENDED_ONTOP:
+                return "gsd-xrandr-extended-ontop";
+
+        case STOCK_CONFIG_EXTERNAL:
+                return "gsd-xrandr-external";
+
+        case STOCK_CONFIG_CUSTOM:
+                return "gsd-xrandr-custom";
+
+        default:
+                g_assert_not_reached ();
+                return NULL;
+        }
+}
+
 static void
 destroy_osd_window (GsdXrandrManager *manager)
 {



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