[geary] Use "org.gnome.Geary" for the app ID. Bug 766196.



commit 4b5b2ee6e1c84c1320d3c299e964e20512783c88
Author: Niels De Graef <nielsdegraef gmail com>
Date:   Thu Dec 8 11:20:59 2016 +0100

    Use "org.gnome.Geary" for the app ID. Bug 766196.

 cmake/FindIntltool.cmake                           |    4 +-
 desktop/CMakeLists.txt                             |   10 +++---
 ...pdata.xml.in => org.gnome.Geary.appdata.xml.in} |    2 +-
 ...geary.desktop.in => org.gnome.Geary.desktop.in} |    1 +
 ...ary.gschema.xml => org.gnome.Geary.gschema.xml} |   32 ++++++++++++--------
 po/POTFILES.in                                     |    4 +-
 src/client/application/geary-application.vala      |    9 ++---
 src/client/notification/libmessagingmenu.vala      |    2 +-
 src/client/notification/unity-launcher.vala        |    2 +-
 9 files changed, 36 insertions(+), 30 deletions(-)
---
diff --git a/cmake/FindIntltool.cmake b/cmake/FindIntltool.cmake
index e43a29e..efcbd1a 100644
--- a/cmake/FindIntltool.cmake
+++ b/cmake/FindIntltool.cmake
@@ -20,11 +20,11 @@ if (INTLTOOL_MERGE_FOUND)
         install (FILES ${CMAKE_CURRENT_BINARY_DIR}/${appstream_name} DESTINATION 
${CMAKE_INSTALL_PREFIX}/share/appdata)
     endmacro (INTLTOOL_MERGE_APPDATA appstream_name po_dir)
     macro (INTLTOOL_MERGE_DESKTOP desktop_id po_dir)
-        add_custom_target (geary.desktop ALL
+        add_custom_target (org.gnome.Geary.desktop ALL
             ${INTLTOOL_MERGE_EXECUTABLE} --desktop-style ${CMAKE_SOURCE_DIR}/${po_dir}
                 ${CMAKE_CURRENT_SOURCE_DIR}/${desktop_id}.in ${desktop_id}
         )
-        install (FILES ${CMAKE_CURRENT_BINARY_DIR}/geary.desktop DESTINATION 
${CMAKE_INSTALL_PREFIX}/share/applications)
+        install (FILES ${CMAKE_CURRENT_BINARY_DIR}/org.gnome.Geary.desktop DESTINATION 
${CMAKE_INSTALL_PREFIX}/share/applications)
     endmacro (INTLTOOL_MERGE_DESKTOP desktop_id po_dir)
     macro (INTLTOOL_MERGE_AUTOSTART_DESKTOP desktop_id po_dir)
         add_custom_target (geary-autostart.desktop ALL
diff --git a/desktop/CMakeLists.txt b/desktop/CMakeLists.txt
index 9776df8..927c9d4 100644
--- a/desktop/CMakeLists.txt
+++ b/desktop/CMakeLists.txt
@@ -1,17 +1,17 @@
 #
-# Build and install geary.desktop
+# Build and install org.gnome.Geary.desktop
 #
 
 include (FindIntltool)
 include (FindDesktopFileValidate)
 if (INTLTOOL_MERGE_FOUND)
-    INTLTOOL_MERGE_APPDATA (geary.appdata.xml po)
-    INTLTOOL_MERGE_DESKTOP (geary.desktop po)
+    INTLTOOL_MERGE_APPDATA (org.gnome.Geary.appdata.xml po)
+    INTLTOOL_MERGE_DESKTOP (org.gnome.Geary.desktop po)
     INTLTOOL_MERGE_AUTOSTART_DESKTOP (geary-autostart.desktop po)
 
     if (DESKTOP_VALIDATE)
         if (DESKTOP_FILE_VALIDATE_FOUND)
-            VALIDATE_DESKTOP_FILE (geary.desktop)
+            VALIDATE_DESKTOP_FILE (org.gnome.Geary.desktop)
             VALIDATE_DESKTOP_FILE (geary-autostart.desktop)
         else (DESKTOP_FILE_VALIDATE_FOUND)
             message (FATAL_ERROR "desktop-file-validate must be installed to validate generated .desktop 
file")
@@ -22,7 +22,7 @@ else (INTLTOOL_MERGE_FOUND)
 endif (INTLTOOL_MERGE_FOUND)
 
 # Optional: run update-desktop-database at install time.
-# (This has to happen after the geary.desktop file is installed.)
+# (This has to happen after the org.gnome.Geary.desktop file is installed.)
 if (DESKTOP_UPDATE)
     install(
         CODE
diff --git a/desktop/geary.appdata.xml.in b/desktop/org.gnome.Geary.appdata.xml.in
similarity index 98%
rename from desktop/geary.appdata.xml.in
rename to desktop/org.gnome.Geary.appdata.xml.in
index a9f7e10..dbdf835 100644
--- a/desktop/geary.appdata.xml.in
+++ b/desktop/org.gnome.Geary.appdata.xml.in
@@ -2,7 +2,7 @@
 <!-- Copyright 2016 Software Freedom Conservancy Inc. -->
 <!-- Copyright 2016 Michael Gratton <mike vee net> -->
 <component type="desktop">
-  <id>geary.desktop</id>
+  <id>org.gnome.Geary.desktop</id>
   <metadata_license>CC0-1.0</metadata_license>
   <project_license>LGPL-2.1+</project_license>
   <_name>Geary</_name>
diff --git a/desktop/geary.desktop.in b/desktop/org.gnome.Geary.desktop.in
similarity index 96%
rename from desktop/geary.desktop.in
rename to desktop/org.gnome.Geary.desktop.in
index 3935cbf..0529ec5 100644
--- a/desktop/geary.desktop.in
+++ b/desktop/org.gnome.Geary.desktop.in
@@ -14,6 +14,7 @@ Categories=GNOME;GTK;Network;Email;
 MimeType=x-scheme-handler/mailto;
 StartupNotify=true
 Actions=Compose;
+DBusActivatable=true
 
 [Desktop Action Compose]
 _Name=Compose Message
diff --git a/desktop/org.yorba.geary.gschema.xml b/desktop/org.gnome.Geary.gschema.xml
similarity index 97%
rename from desktop/org.yorba.geary.gschema.xml
rename to desktop/org.gnome.Geary.gschema.xml
index 045b7c7..d174183 100644
--- a/desktop/org.yorba.geary.gschema.xml
+++ b/desktop/org.gnome.Geary.gschema.xml
@@ -1,67 +1,67 @@
 <schemalist>
 
-<schema id="org.yorba.geary" path="/org/yorba/geary/">
-    
+<schema id="org.gnome.Geary" path="/org/gnome/Geary/">
+
     <key name="window-maximize" type="b">
         <default>false</default>
         <summary>maximize window</summary>
         <description>True if library application is maximized, false otherwise.</description>
     </key>
-    
+
     <key name="window-width" type="i">
         <default>1024</default>
         <summary>width of window</summary>
         <description>The last recorded width of the application window.</description>
     </key>
-    
+
     <key name="window-height" type="i">
         <default>768</default>
         <summary>height of window</summary>
         <description>The last recorded height of the application window.</description>
     </key>
-    
+
     <key name="folder-list-pane-position" type="i">
         <default>100</default>
         <summary>position of folder list pane</summary>
         <description>Position of the folder list Paned grabber.</description>
     </key>
-    
+
     <key name="folder-list-pane-position-horizontal" type="i">
         <default>-1</default>
         <summary>position of folder list pane when horizontal</summary>
         <description>Position of the folder list Paned grabber in the horizontal orientation.</description>
     </key>
-    
+
     <key name="folder-list-pane-position-vertical" type="i">
         <default>200</default>
         <summary>position of folder list pane when vertical</summary>
         <description>Position of the folder list Paned grabber in the vertical orientation.</description>
     </key>
-    
+
     <key name="folder-list-pane-horizontal" type="b">
         <default>true</default>
         <summary>orientation of the folder list pane</summary>
         <description>True if the folder list Paned is in the horizontal orientation.</description>
     </key>
-    
+
     <key name="messages-pane-position" type="i">
         <default>250</default>
         <summary>position of message list pane</summary>
         <description>Position of the message list Paned grabber.</description>
     </key>
-    
+
     <key name="autoselect" type="b">
         <default>true</default>
         <summary>autoselect next message</summary>
         <description>True if we should autoselect the next available conversation.</description>
     </key>
-    
+
     <key name="display-preview" type="b">
         <default>true</default>
         <summary>display message previews</summary>
         <description>True if we should display a short preview of each message.</description>
     </key>
-    
+
     <key name="spell-check" type="b">
         <default>true</default>
         <summary>enable inline spell checking</summary>
@@ -79,37 +79,43 @@
         <summary>Languages that are displayed in the spell checker popover.</summary>
         <description>List of languages that are always displayed in the popover of the spell 
checker.</description>
     </key>
+
     <key name="play-sounds" type="b">
         <default>true</default>
         <summary>enable notification sounds</summary>
         <description>True to play sounds for notifications and sending.</description>
     </key>
+
     <key name="show-notifications" type="b">
         <default>true</default>
         <summary>show notifications for new mail</summary>
         <description>True to show notification bubbles.</description>
     </key>
+
     <key name="startup-notifications" type="b">
         <default>false</default>
         <summary>notify of new mail at startup</summary>
         <description>True to notify of new mail at startup.</description>
     </key>
+
     <key name="ask-open-attachment" type="b">
         <default>true</default>
         <summary>ask when opening an attachment</summary>
         <description>True to ask when opening an attachment.</description>
     </key>
+
     <key name="compose-as-html" type="b">
         <default>true</default>
         <summary>whether to compose emails in HTML</summary>
         <description>True to compose emails in HTML; false for plain text.</description>
     </key>
-    
+
     <key name="search-strategy" type="s">
         <default>"conservative"</default>
         <summary>Advisory strategy for full-text searching</summary>
         <description>Acceptable values are EXACT, CONSERVATIVE, AGGRESSIVE, and HORIZON.</description>
     </key>
+
     <key name="conversation-viewer-zoom" type="d">
         <default>1</default>
         <summary>zoom of conversation viewer</summary>
diff --git a/po/POTFILES.in b/po/POTFILES.in
index 8ecfb1a..4ad8031 100644
--- a/po/POTFILES.in
+++ b/po/POTFILES.in
@@ -1,6 +1,6 @@
 [encoding: UTF-8]
-desktop/geary.appdata.xml.in
-desktop/geary.desktop.in
+desktop/org.gnome.Geary.appdata.xml.in
+desktop/org.gnome.Geary.desktop.in
 desktop/geary-autostart.desktop.in
 [type: gettext/ini]desktop/geary-attach.contract.in
 src/geary-version.vala.in
diff --git a/src/client/application/geary-application.vala b/src/client/application/geary-application.vala
index c545e6d..c2563d9 100644
--- a/src/client/application/geary-application.vala
+++ b/src/client/application/geary-application.vala
@@ -16,7 +16,7 @@ extern const string GETTEXT_PACKAGE;
 public class GearyApplication : Gtk.Application {
     public const string NAME = "Geary";
     public const string PRGNAME = "geary";
-    public const string APP_ID = "org.yorba.geary";
+    public const string APP_ID = "org.gnome.Geary";
     public const string DESCRIPTION = _("Mail Client");
     public const string COPYRIGHT = _("Copyright 2016 Software Freedom Conservancy Inc.");
     public const string WEBSITE = "https://wiki.gnome.org/Apps/Geary";;
@@ -100,8 +100,7 @@ public class GearyApplication : Gtk.Application {
 
     public GearyApplication() {
         Object(
-            application_id: APP_ID,
-            resource_base_path: "/org/gnome/Geary" // XXX remove this when Bug 766196 is fixed 
+            application_id: APP_ID
         );
         _instance = this;
     }
@@ -262,8 +261,8 @@ public class GearyApplication : Gtk.Application {
     public File? get_desktop_file() {
         File? install_dir = get_install_dir();
         File desktop_file = (install_dir != null)
-            ? install_dir.get_child("share").get_child("applications").get_child("geary.desktop")
-            : 
File.new_for_path(SOURCE_ROOT_DIR).get_child("build").get_child("desktop").get_child("geary.desktop");
+            ? install_dir.get_child("share").get_child("applications").get_child("org.gnome.Geary.desktop")
+            : 
File.new_for_path(SOURCE_ROOT_DIR).get_child("build").get_child("desktop").get_child("org.gnome.Geary.desktop");
         
         return desktop_file.query_exists() ? desktop_file : null;
     }
diff --git a/src/client/notification/libmessagingmenu.vala b/src/client/notification/libmessagingmenu.vala
index f1d4c0a..72a88c9 100644
--- a/src/client/notification/libmessagingmenu.vala
+++ b/src/client/notification/libmessagingmenu.vala
@@ -19,7 +19,7 @@ public class Libmessagingmenu : NewMessagesIndicator {
             return;
         }
         
-        app = new MessagingMenu.App("geary.desktop");
+        app = new MessagingMenu.App("org.gnome.Geary.desktop");
         app.register();
         app.activate_source.connect(on_activate_source);
         
diff --git a/src/client/notification/unity-launcher.vala b/src/client/notification/unity-launcher.vala
index 9594d44..cbf53a3 100644
--- a/src/client/notification/unity-launcher.vala
+++ b/src/client/notification/unity-launcher.vala
@@ -12,7 +12,7 @@ public class UnityLauncher : Geary.BaseObject {
     public UnityLauncher(NewMessagesMonitor monitor) {
         this.monitor = monitor;
         
-        entry = Unity.LauncherEntry.get_for_desktop_id("geary.desktop");
+        entry = Unity.LauncherEntry.get_for_desktop_id("org.gnome.Geary.desktop");
         set_count(0);
         
         monitor.folder_removed.connect(on_folder_removed);


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