INterime commit
authorPete Fotheringham <pete.fotheringham@codethink.co.uk>
Thu, 22 Dec 2011 10:09:37 +0000 (10:09 +0000)
committerPete Fotheringham <pete.fotheringham@codethink.co.uk>
Thu, 22 Dec 2011 10:09:37 +0000 (10:09 +0000)
Makefile.am
po/POTFILES.in
src/moonshot-identity-management-view.vala
src/moonshot-utils.vala

index 8b5b014..485979d 100644 (file)
@@ -79,6 +79,13 @@ libmoonshot/libmoonshot.lib: libmoonshot/libmoonshot.def
 
 endif
 
+if  OS_MACOS
+
+AM_CPPFLAGS += -DOS_MACOS
+AM_VALAFLAGS += --define=OS_MACOS
+
+endif
+
 if OS_LINUX
 
 ## Installing mime type data
@@ -211,3 +218,19 @@ moonshot.msi: windows/app.wxs windows/config.wxi $(bin_PROGRAMS)
        "${WIX_LIGHT}" -b ${prefix} -b ${prefix}/mingw -o moonshot.msi app.wixobj
 
 endif
+
+if  OS_MACOS
+## Mac-specific targets
+
+## 1. Icons. 
+
+icons:
+       mkdir -p share/icons
+       cp src/mac/icons/process-stop.png share/icons
+       cp src/mac/icons/edit-find.png share/icons
+       cp src/mac/icons/avatar-default.png share/icons
+       
+
+## Installer
+
+endif
index 651b08b..b330862 100644 (file)
@@ -1,2 +1,2 @@
 # List of source files which contain translatable strings.
-src/moonshot-window.vala
+src/moonshot-identity-management-view.vala
index 05252e3..91a1330 100644 (file)
@@ -840,13 +840,15 @@ SUCH DAMAGE.
 
         set_atk_name_description (search_entry, _("Search entry"), _("Search for a specific ID Card"));
         this.search_entry.set_icon_from_pixbuf (EntryIconPosition.PRIMARY,
-                                                find_icon_sized ("edit-find-symbolic", Gtk.IconSize.MENU));
+                                                find_icon_sized ("edit-find", Gtk.IconSize.MENU));
+//                                                find_icon_sized ("edit-find-symbolic", Gtk.IconSize.MENU));
         this.search_entry.set_icon_tooltip_text (EntryIconPosition.PRIMARY,
                                                  _("Search identity or service"));
         this.search_entry.set_icon_sensitive (EntryIconPosition.PRIMARY, false);
 
         this.search_entry.set_icon_from_pixbuf (EntryIconPosition.SECONDARY,
-                                                find_icon_sized ("edit-clear-symbolic", Gtk.IconSize.MENU));
+                                                find_icon_sized ("process-stop", Gtk.IconSize.MENU));
+//                                                find_icon_sized ("edit-clear-symbolic", Gtk.IconSize.MENU));
         this.search_entry.set_icon_tooltip_text (EntryIconPosition.SECONDARY,
                                                  _("Clear the current search"));
         this.search_entry.set_icon_sensitive (EntryIconPosition.SECONDARY, false);
index b3a16f8..da075b4 100644 (file)
@@ -19,6 +19,7 @@ public Gdk.Pixbuf? find_icon (string name, int size)
     try
     {
 #if OS_WIN32
+print("Windows\n");
         string? base_path = g_win32_get_package_installation_directory_of_module (null);
 
         // Hack to allow running within the source tree
@@ -28,7 +29,18 @@ public Gdk.Pixbuf? find_icon (string name, int size)
 
         string? filename = Path.build_filename (base_path, "share", "icons", "%s.png".printf (name));
         return new Gdk.Pixbuf.from_file_at_size (filename, size, size);
+//#elif OS_MACOS
+/*
+print("MacOS\n");
+        string? base_path = " /Users/pete/moonshot-ui";
+         string? filename = Filename.display_name(Path.build_filename (base_path, "share", "icons", "%s.png".printf (name)));
+print("%s\n".printf(filename));
+size_t x, y;
+        return new Gdk.Pixbuf.from_file (filename);
+//        return new Gdk.Pixbuf.from_file_at_size (filename, -1, -1);
+*/
 #else
+print("Linux\n");
         var icon_theme = Gtk.IconTheme.get_default ();
         return icon_theme.load_icon (name, size, Gtk.IconLookupFlags.FORCE_SIZE);
 #endif