[gnome-software] trivial: Never show the error message for a cancelled job



commit 849c410d9af009b31435acaa173848351e97b734
Author: Richard Hughes <richard hughsie com>
Date:   Tue Jul 11 09:48:00 2017 +0100

    trivial: Never show the error message for a cancelled job

 src/gs-shell.c |   16 ++++++++++++++++
 1 files changed, 16 insertions(+), 0 deletions(-)
---
diff --git a/src/gs-shell.c b/src/gs-shell.c
index 187464b..41f49bb 100644
--- a/src/gs-shell.c
+++ b/src/gs-shell.c
@@ -901,6 +901,8 @@ gs_shell_show_event_refresh (GsShell *shell, GsPluginEvent *event)
                g_string_append (str, _("Unable to download updates: you do not have"
                                        " permission to install software"));
                break;
+       case GS_PLUGIN_ERROR_CANCELLED:
+               break;
        default:
                /* TRANSLATORS: failure text for the in-app notification */
                g_string_append (str, _("Unable to get list of updates"));
@@ -1054,6 +1056,8 @@ gs_shell_show_event_install (GsShell *shell, GsPluginEvent *event)
                                               "AC power is required"),
                                        str_app);
                break;
+       case GS_PLUGIN_ERROR_CANCELLED:
+               break;
        default:
                /* TRANSLATORS: failure text for the in-app notification,
                 * where the %s is the application name (e.g. "GIMP") */
@@ -1158,6 +1162,8 @@ gs_shell_show_event_update (GsShell *shell, GsPluginEvent *event)
                                               "AC power is required"),
                                        str_app);
                break;
+       case GS_PLUGIN_ERROR_CANCELLED:
+               break;
        default:
                /* TRANSLATORS: failure text for the in-app notification,
                 * where the %s is the application name (e.g. "GIMP") */
@@ -1260,6 +1266,8 @@ gs_shell_show_event_upgrade (GsShell *shell, GsPluginEvent *event)
                                               "AC power is required"),
                                        str_app);
                break;
+       case GS_PLUGIN_ERROR_CANCELLED:
+               break;
        default:
                /* TRANSLATORS: failure text for the in-app notification,
                 * where the %s is the distro name (e.g. "Fedora 25") */
@@ -1328,6 +1336,8 @@ gs_shell_show_event_remove (GsShell *shell, GsPluginEvent *event)
                                               "AC power is required"),
                                        str_app);
                break;
+       case GS_PLUGIN_ERROR_CANCELLED:
+               break;
        default:
                /* TRANSLATORS: failure text for the in-app notification,
                 * where the %s is the application name (e.g. "GIMP") */
@@ -1388,6 +1398,8 @@ gs_shell_show_event_launch (GsShell *shell, GsPluginEvent *event)
                                        "and try again"));
                buttons |= GS_SHELL_EVENT_BUTTON_NO_SPACE;
                break;
+       case GS_PLUGIN_ERROR_CANCELLED:
+               break;
        default:
                /* TRANSLATORS: we failed to get a proper error code */
                g_string_append (str, _("Sorry, something went wrong"));
@@ -1435,6 +1447,8 @@ gs_shell_show_event_file_to_app (GsShell *shell, GsPluginEvent *event)
                                        "and try again"));
                buttons |= GS_SHELL_EVENT_BUTTON_NO_SPACE;
                break;
+       case GS_PLUGIN_ERROR_CANCELLED:
+               break;
        default:
                /* TRANSLATORS: we failed to get a proper error code */
                g_string_append (str, _("Sorry, something went wrong"));
@@ -1500,6 +1514,8 @@ gs_shell_show_event_fallback (GsShell *shell, GsPluginEvent *event)
                /* TRANSLATORS: need to be connected to the AC power */
                g_string_append (str, _("AC power is required"));
                break;
+       case GS_PLUGIN_ERROR_CANCELLED:
+               break;
        default:
                /* TRANSLATORS: we failed to get a proper error code */
                g_string_append (str, _("Sorry, something went wrong"));


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