[gnome-software] Correct spelling of 'license' in the API



commit 2243a8aa3f9655c39dc739833a7eff9a44de72ec
Author: Richard Hughes <richard hughsie com>
Date:   Wed Mar 2 10:32:05 2016 +0000

    Correct spelling of 'license' in the API

 src/gs-app-row.c                           |    2 +-
 src/gs-app.c                               |   18 +++++++++---------
 src/gs-app.h                               |    6 +++---
 src/gs-self-test.c                         |    2 +-
 src/gs-shell-details.c                     |    8 ++++----
 src/gs-utils.c                             |    2 +-
 src/plugins/gs-appstream.c                 |    4 ++--
 src/plugins/gs-plugin-dummy.c              |    2 +-
 src/plugins/gs-plugin-fwupd.c              |    2 +-
 src/plugins/gs-plugin-packagekit-refine.c  |    6 +++---
 src/plugins/gs-plugin-packagekit-refresh.c |    2 +-
 src/plugins/gs-plugin-shell-extensions.c   |    2 +-
 12 files changed, 28 insertions(+), 28 deletions(-)
---
diff --git a/src/gs-app-row.c b/src/gs-app-row.c
index 67f107c..befdc34 100644
--- a/src/gs-app-row.c
+++ b/src/gs-app-row.c
@@ -192,7 +192,7 @@ gs_app_row_refresh (GsAppRow *app_row)
                        gtk_widget_set_visible (priv->label_tag_webapp, FALSE);
                        gtk_widget_set_visible (priv->label_tag_extension, FALSE);
                        gtk_widget_set_visible (priv->label_tag_nonfree,
-                                               !gs_app_get_licence_is_free (priv->app));
+                                               !gs_app_get_license_is_free (priv->app));
                        gtk_widget_set_visible (priv->label_tag_foreign,
                                                !gs_app_has_quirk (priv->app,
                                                                   AS_APP_QUIRK_PROVENANCE));
diff --git a/src/gs-app.c b/src/gs-app.c
index 698306e..6eed115 100644
--- a/src/gs-app.c
+++ b/src/gs-app.c
@@ -1242,30 +1242,30 @@ gs_app_set_url (GsApp *app, AsUrlKind kind, const gchar *url)
 }
 
 /**
- * gs_app_get_licence:
+ * gs_app_get_license:
  */
 const gchar *
-gs_app_get_licence (GsApp *app)
+gs_app_get_license (GsApp *app)
 {
        g_return_val_if_fail (GS_IS_APP (app), NULL);
        return app->licence;
 }
 
 /**
- * gs_app_get_licence_is_free:
+ * gs_app_get_license_is_free:
  */
 gboolean
-gs_app_get_licence_is_free (GsApp *app)
+gs_app_get_license_is_free (GsApp *app)
 {
        g_return_val_if_fail (GS_IS_APP (app), FALSE);
        return app->licence_is_free;
 }
 
 /**
- * gs_app_get_licence_token_is_nonfree:
+ * gs_app_get_license_token_is_nonfree:
  */
 static gboolean
-gs_app_get_licence_token_is_nonfree (const gchar *token)
+gs_app_get_license_token_is_nonfree (const gchar *token)
 {
        /* grammar */
        if (g_strcmp0 (token, "(") == 0)
@@ -1282,10 +1282,10 @@ gs_app_get_licence_token_is_nonfree (const gchar *token)
 }
 
 /**
- * gs_app_set_licence:
+ * gs_app_set_license:
  */
 void
-gs_app_set_licence (GsApp *app, GsAppQuality quality, const gchar *licence)
+gs_app_set_license (GsApp *app, GsAppQuality quality, const gchar *licence)
 {
        GString *urld;
        guint i;
@@ -1325,7 +1325,7 @@ gs_app_set_licence (GsApp *app, GsAppQuality quality, const gchar *licence)
                }
 
                /* do the best we can */
-               if (gs_app_get_licence_token_is_nonfree (tokens[i])) {
+               if (gs_app_get_license_token_is_nonfree (tokens[i])) {
                        g_debug ("nonfree licence from %s: '%s'",
                                 gs_app_get_id (app), tokens[i]);
                        app->licence_is_free = FALSE;
diff --git a/src/gs-app.h b/src/gs-app.h
index 97e2c4b..3ae9e20 100644
--- a/src/gs-app.h
+++ b/src/gs-app.h
@@ -134,9 +134,9 @@ const gchar *gs_app_get_url                 (GsApp          *app,
 void            gs_app_set_url                 (GsApp          *app,
                                                 AsUrlKind       kind,
                                                 const gchar    *url);
-const gchar    *gs_app_get_licence             (GsApp          *app);
-gboolean        gs_app_get_licence_is_free     (GsApp          *app);
-void            gs_app_set_licence             (GsApp          *app,
+const gchar    *gs_app_get_license             (GsApp          *app);
+gboolean        gs_app_get_license_is_free     (GsApp          *app);
+void            gs_app_set_license             (GsApp          *app,
                                                 GsAppQuality    quality,
                                                 const gchar    *licence);
 gchar          **gs_app_get_menu_path          (GsApp          *app);
diff --git a/src/gs-self-test.c b/src/gs-self-test.c
index 7b12d1b..443dc78 100644
--- a/src/gs-self-test.c
+++ b/src/gs-self-test.c
@@ -528,7 +528,7 @@ gs_plugin_loader_refine_func (void)
        g_assert_no_error (error);
        g_assert (ret);
 
-       g_assert_cmpstr (gs_app_get_licence (app), ==,
+       g_assert_cmpstr (gs_app_get_license (app), ==,
                         "<a href=\"http://spdx.org/licenses/GPL-2.0+\";>GPL-2.0+</a>");
        g_assert_cmpstr (gs_app_get_description (app), !=, NULL);
        url = gs_app_get_url (app, AS_URL_KIND_HOMEPAGE);
diff --git a/src/gs-shell-details.c b/src/gs-shell-details.c
index db1e146..b424bb0 100644
--- a/src/gs-shell-details.c
+++ b/src/gs-shell-details.c
@@ -642,7 +642,7 @@ gs_shell_details_refresh_all (GsShellDetails *self)
        }
 
        /* set the licence */
-       tmp = gs_app_get_licence (self->app);
+       tmp = gs_app_get_license (self->app);
        if (tmp == NULL) {
                /* TRANSLATORS: this is where the licence is not known */
                gtk_label_set_label (GTK_LABEL (self->label_details_licence_value), C_("license", "Unknown"));
@@ -759,7 +759,7 @@ gs_shell_details_refresh_all (GsShellDetails *self)
                                     _("This application can only be used when there is an active internet 
connection."));
        } else {
                gtk_widget_set_visible (self->label_details_tag_webapp, FALSE);
-               if (gs_app_get_licence_is_free (self->app) &&
+               if (gs_app_get_license_is_free (self->app) &&
                    !gs_app_has_quirk (self->app, AS_APP_QUIRK_PROVENANCE)) {
                        /* free and 3rd party */
                        gtk_widget_set_visible (self->label_details_tag_nonfree, FALSE);
@@ -768,7 +768,7 @@ gs_shell_details_refresh_all (GsShellDetails *self)
                        gtk_label_set_label (GTK_LABEL (self->label_details_info_text),
                                             /* TRANSLATORS: this is the warning box */
                                             _("This software comes from a 3rd party."));
-               } else if (!gs_app_get_licence_is_free (self->app) &&
+               } else if (!gs_app_get_license_is_free (self->app) &&
                           !gs_app_has_quirk (self->app, AS_APP_QUIRK_PROVENANCE)) {
                        /* nonfree and 3rd party */
                        gtk_widget_set_visible (self->label_details_tag_nonfree, TRUE);
@@ -777,7 +777,7 @@ gs_shell_details_refresh_all (GsShellDetails *self)
                        gtk_label_set_label (GTK_LABEL (self->label_details_info_text),
                                             /* TRANSLATORS: this is the warning box */
                                             _("This software comes from a 3rd party and may contain non-free 
components."));
-               } else if (!gs_app_get_licence_is_free (self->app) &&
+               } else if (!gs_app_get_license_is_free (self->app) &&
                           gs_app_has_quirk (self->app, AS_APP_QUIRK_PROVENANCE)) {
                        /* nonfree and distro */
                        gtk_widget_set_visible (self->label_details_tag_nonfree, TRUE);
diff --git a/src/gs-utils.c b/src/gs-utils.c
index 22c8a2a..e2da64e 100644
--- a/src/gs-utils.c
+++ b/src/gs-utils.c
@@ -225,7 +225,7 @@ gs_app_notify_unavailable (GsApp *app, GtkWindow *parent)
        g_autoptr(GString) title = NULL;
 
        /* this is very crude */
-       licence = gs_app_get_licence (app);
+       licence = gs_app_get_license (app);
        if (licence != NULL) {
                for (i = 0; keywords[i].str != NULL; i++) {
                        if (g_strstr_len (licence, -1, keywords[i].str) != NULL)
diff --git a/src/plugins/gs-appstream.c b/src/plugins/gs-appstream.c
index 6446ee8..5695d86 100644
--- a/src/plugins/gs-appstream.c
+++ b/src/plugins/gs-appstream.c
@@ -435,8 +435,8 @@ gs_appstream_refine_app (GsPlugin *plugin,
        }
 
        /* set licence */
-       if (as_app_get_project_license (item) != NULL && gs_app_get_licence (app) == NULL)
-               gs_app_set_licence (app,
+       if (as_app_get_project_license (item) != NULL && gs_app_get_license (app) == NULL)
+               gs_app_set_license (app,
                                    GS_APP_QUALITY_HIGHEST,
                                    as_app_get_project_license (item));
 
diff --git a/src/plugins/gs-plugin-dummy.c b/src/plugins/gs-plugin-dummy.c
index ff47d78..be10d98 100644
--- a/src/plugins/gs-plugin-dummy.c
+++ b/src/plugins/gs-plugin-dummy.c
@@ -156,7 +156,7 @@ gs_plugin_refine (GsPlugin *plugin,
                app = GS_APP (l->data);
                if (gs_app_get_name (app) == NULL) {
                        if (g_strcmp0 (gs_app_get_id (app), "gnome-boxes") == 0) {
-                               gs_app_set_licence (app, GS_APP_QUALITY_NORMAL,
+                               gs_app_set_license (app, GS_APP_QUALITY_NORMAL,
                                                    "GPL-2.0+");
                                gs_app_set_name (app, GS_APP_QUALITY_NORMAL,
                                                 "Boxes");
diff --git a/src/plugins/gs-plugin-fwupd.c b/src/plugins/gs-plugin-fwupd.c
index 2e49158..80baa4e 100644
--- a/src/plugins/gs-plugin-fwupd.c
+++ b/src/plugins/gs-plugin-fwupd.c
@@ -243,7 +243,7 @@ gs_plugin_fwupd_set_app_from_kv (GsApp *app, const gchar *key, GVariant *val)
                return;
        }
        if (g_strcmp0 (key, "License") == 0) {
-               gs_app_set_licence (app,
+               gs_app_set_license (app,
                                    GS_APP_QUALITY_NORMAL,
                                    g_variant_get_string (val, NULL));
                return;
diff --git a/src/plugins/gs-plugin-packagekit-refine.c b/src/plugins/gs-plugin-packagekit-refine.c
index ef815b7..61c9b70 100644
--- a/src/plugins/gs-plugin-packagekit-refine.c
+++ b/src/plugins/gs-plugin-packagekit-refine.c
@@ -480,11 +480,11 @@ gs_plugin_packagekit_refine_details_app (GsPlugin *plugin,
                                                pk_details_get_package_id (details))) {
                                continue;
                        }
-                       if (gs_app_get_licence (app) == NULL) {
+                       if (gs_app_get_license (app) == NULL) {
                                g_autofree gchar *license_spdx = NULL;
                                license_spdx = as_utils_license_to_spdx (pk_details_get_license (details));
                                if (license_spdx != NULL) {
-                                       gs_app_set_licence (app,
+                                       gs_app_set_license (app,
                                                            GS_APP_QUALITY_LOWEST,
                                                            license_spdx);
                                }
@@ -631,7 +631,7 @@ static gboolean
 gs_plugin_refine_app_needs_details (GsPlugin *plugin, GsPluginRefineFlags flags, GsApp *app)
 {
        if ((flags & GS_PLUGIN_REFINE_FLAGS_REQUIRE_LICENCE) > 0 &&
-           gs_app_get_licence (app) == NULL)
+           gs_app_get_license (app) == NULL)
                return TRUE;
        if ((flags & GS_PLUGIN_REFINE_FLAGS_REQUIRE_URL) > 0 &&
            gs_app_get_url (app, AS_URL_KIND_HOMEPAGE) == NULL)
diff --git a/src/plugins/gs-plugin-packagekit-refresh.c b/src/plugins/gs-plugin-packagekit-refresh.c
index 171e554..551b035 100644
--- a/src/plugins/gs-plugin-packagekit-refresh.c
+++ b/src/plugins/gs-plugin-packagekit-refresh.c
@@ -387,7 +387,7 @@ gs_plugin_filename_to_app (GsPlugin *plugin,
        gs_app_set_url (app, AS_URL_KIND_HOMEPAGE, pk_details_get_url (item));
        gs_app_set_size (app, pk_details_get_size (item));
        license_spdx = as_utils_license_to_spdx (pk_details_get_license (item));
-       gs_app_set_licence (app, GS_APP_QUALITY_LOWEST, license_spdx);
+       gs_app_set_license (app, GS_APP_QUALITY_LOWEST, license_spdx);
 
        /* look for a desktop file so we can use a valid application id */
        if (!gs_plugin_packagekit_refresh_guess_app_id (plugin,
diff --git a/src/plugins/gs-plugin-shell-extensions.c b/src/plugins/gs-plugin-shell-extensions.c
index 8bc67e6..7489b30 100644
--- a/src/plugins/gs-plugin-shell-extensions.c
+++ b/src/plugins/gs-plugin-shell-extensions.c
@@ -124,7 +124,7 @@ gs_plugin_shell_extensions_add_app (const gchar *uuid,
        gs_app_set_management_plugin (app, "ShellExtensions");
        gs_app_set_metadata (app, "ShellExtensions::uuid", uuid);
        gs_app_set_kind (app, AS_APP_KIND_SHELL_EXTENSION);
-       gs_app_set_licence (app, GS_APP_QUALITY_NORMAL, "GPL-2.0+");
+       gs_app_set_license (app, GS_APP_QUALITY_NORMAL, "GPL-2.0+");
        gs_app_set_summary (app, GS_APP_QUALITY_NORMAL, "GNOME Shell Extension");
        while (g_variant_iter_loop (iter, "{sv}", &str, &val)) {
                if (g_strcmp0 (str, "description") == 0) {


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