[gnome-software] Prefix the datadir metadata with the correct scope



commit 8785de84d8f6dd82e98fc06795b4a80f86368d84
Author: Richard Hughes <richard hughsie com>
Date:   Mon Sep 9 21:37:16 2013 +0100

    Prefix the datadir metadata with the correct scope

 src/plugins/README.md                          |   10 +++++-----
 src/plugins/gs-plugin-datadir-apps.c           |    2 +-
 src/plugins/gs-plugin-datadir-filename-local.c |    2 +-
 src/plugins/gs-plugin-datadir-filename.c       |    4 ++--
 src/plugins/gs-plugin-desktopdb.c              |    4 ++--
 src/plugins/gs-plugin-packagekit-refine.c      |    2 +-
 6 files changed, 12 insertions(+), 12 deletions(-)
---
diff --git a/src/plugins/README.md b/src/plugins/README.md
index ee18418..e8e0a9c 100644
--- a/src/plugins/README.md
+++ b/src/plugins/README.md
@@ -115,7 +115,7 @@ Uses the system PackageKit instance to return convert filenames to package-ids.
 Overview:    | <p>
 -------------|---
 Methods:     | `nothing`
-Requires:    | `{datadir-desktop-filename}`
+Requires:    | `{DataDir::desktop-filename}`
 Refines:     | `{PackageKit::package-id}`, `[installed]`
 
 ### desktopdb ###
@@ -125,7 +125,7 @@ Overview:    | <p>
 -------------|---
 Methods:     | `nothing`
 Requires:    | `nothing`
-Refines:     | `[source]->{datadir-desktop-filename}`
+Refines:     | `[source]->{DataDir::desktop-filename}`
 
 ### appstream ###
 Uses offline AppStream data to refine package results.
@@ -144,7 +144,7 @@ Overview:    | <p>
 -------------|---
 Methods:     | `nothing`
 Requires:    | `nothing`
-Refines:     | `{datadir-desktop-filename}->[name]`, `{datadir-desktop-filename}->[summary]`, 
`{datadir-desktop-filename}->[pixbuf]`, `{datadir-desktop-filename}->[id]`, 
`{datadir-desktop-filename}->[kind]`
+Refines:     | `{DataDir::desktop-filename}->[name]`, `{DataDir::desktop-filename}->[summary]`, 
`{DataDir::desktop-filename}->[pixbuf]`, `{DataDir::desktop-filename}->[id]`, 
`{DataDir::desktop-filename}->[kind]`
 
 ### datadir-filename ###
 Uses the existance of a files in /usr/share/applications, named $id.desktop to
@@ -155,7 +155,7 @@ Overview:    | <p>
 -------------|---
 Methods:     | `nothing`
 Requires:    | `nothing`
-Refines:     | `[id]->{datadir-desktop-filename}`
+Refines:     | `[id]->{DataDir::desktop-filename}`
 
 ### datadir-filename-local ###
 Sets any applications not installed with datadir or /usr as installed as these
@@ -165,4 +165,4 @@ Overview:    | <p>
 -------------|---
 Methods:     | `nothing`
 Requires:    | `nothing`
-Refines:     | `{datadir-desktop-filename}->[state]`, `{install-kind}`
+Refines:     | `{DataDir::desktop-filename}->[state]`, `{install-kind}`
diff --git a/src/plugins/gs-plugin-datadir-apps.c b/src/plugins/gs-plugin-datadir-apps.c
index 1fc0233..925719b 100644
--- a/src/plugins/gs-plugin-datadir-apps.c
+++ b/src/plugins/gs-plugin-datadir-apps.c
@@ -245,7 +245,7 @@ gs_plugin_refine (GsPlugin *plugin,
 
        for (l = list; l != NULL; l = l->next) {
                app = GS_APP (l->data);
-               tmp = gs_app_get_metadata_item (app, "datadir-desktop-filename");
+               tmp = gs_app_get_metadata_item (app, "DataDir::desktop-filename");
                if (tmp == NULL)
                        continue;
                ret = gs_plugin_datadir_apps_extract_desktop_data (plugin,
diff --git a/src/plugins/gs-plugin-datadir-filename-local.c b/src/plugins/gs-plugin-datadir-filename-local.c
index 0110a4d..1a57093 100644
--- a/src/plugins/gs-plugin-datadir-filename-local.c
+++ b/src/plugins/gs-plugin-datadir-filename-local.c
@@ -58,7 +58,7 @@ gs_plugin_refine (GsPlugin *plugin,
                app = GS_APP (l->data);
                if (gs_app_get_state (app) != GS_APP_STATE_UNKNOWN)
                        continue;
-               tmp = gs_app_get_metadata_item (app, "datadir-desktop-filename");
+               tmp = gs_app_get_metadata_item (app, "DataDir::desktop-filename");
                if (tmp == NULL)
                        continue;
                if (!g_str_has_prefix (tmp, "/usr")) {
diff --git a/src/plugins/gs-plugin-datadir-filename.c b/src/plugins/gs-plugin-datadir-filename.c
index 882e5b0..654e05b 100644
--- a/src/plugins/gs-plugin-datadir-filename.c
+++ b/src/plugins/gs-plugin-datadir-filename.c
@@ -149,13 +149,13 @@ gs_plugin_refine (GsPlugin *plugin,
                app = GS_APP (l->data);
                if (gs_app_get_name (app) != NULL)
                        continue;
-               if (gs_app_get_metadata_item (app, "datadir-desktop-filename") != NULL)
+               if (gs_app_get_metadata_item (app, "DataDir::desktop-filename") != NULL)
                        continue;
 
                tmp = gs_plugin_datadir_filename_find (plugin, app);
                if (tmp != NULL) {
                        gs_app_set_metadata (app,
-                                            "datadir-desktop-filename",
+                                            "DataDir::desktop-filename",
                                             tmp);
                        g_free (tmp);
                }
diff --git a/src/plugins/gs-plugin-desktopdb.c b/src/plugins/gs-plugin-desktopdb.c
index 237cf57..02a25ef 100644
--- a/src/plugins/gs-plugin-desktopdb.c
+++ b/src/plugins/gs-plugin-desktopdb.c
@@ -138,7 +138,7 @@ gs_plugin_desktopdb_set_metadata (GsPlugin *plugin,
        }
 
        gs_app_set_metadata (app,
-                            "datadir-desktop-filename",
+                            "DataDir::desktop-filename",
                             desktop_file);
        g_free (desktop_file);
 
@@ -174,7 +174,7 @@ gs_plugin_refine (GsPlugin *plugin,
        /* can we convert a package to an application */
        for (l = list; l != NULL; l = l->next) {
                app = GS_APP (l->data);
-               if (gs_app_get_metadata_item (app, "datadir-desktop-filename") != NULL)
+               if (gs_app_get_metadata_item (app, "DataDir::desktop-filename") != NULL)
                        continue;
                pkgname = gs_app_get_source (app);
                if (pkgname == NULL)
diff --git a/src/plugins/gs-plugin-packagekit-refine.c b/src/plugins/gs-plugin-packagekit-refine.c
index e9bf46f..bd60292 100644
--- a/src/plugins/gs-plugin-packagekit-refine.c
+++ b/src/plugins/gs-plugin-packagekit-refine.c
@@ -320,7 +320,7 @@ gs_plugin_refine (GsPlugin *plugin,
                app = GS_APP (l->data);
                if (gs_app_get_metadata_item (app, "PackageKit::package-id") != NULL)
                        continue;
-               tmp = gs_app_get_metadata_item (app, "datadir-desktop-filename");
+               tmp = gs_app_get_metadata_item (app, "DataDir::desktop-filename");
                if (tmp == NULL)
                        continue;
                ret = gs_plugin_packagekit_refine_from_desktop (plugin,


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