doczkal / rpms / abrt

Forked from rpms/abrt 4 years ago
Clone

Blame SOURCES/0064-applet-confirm-ignoring-of-notifications.patch

a60cd7
From ba356330db1c797ac050b6229f75474aed39faa7 Mon Sep 17 00:00:00 2001
a60cd7
From: Jakub Filak <jfilak@redhat.com>
a60cd7
Date: Wed, 1 Oct 2014 17:14:50 +0200
a60cd7
Subject: [ABRT PATCH 64/66] applet: confirm ignoring of notifications
a60cd7
a60cd7
and fix a bug in abrt-action-notify
a60cd7
a60cd7
Resolves #1084031
a60cd7
a60cd7
Signed-off-by: Jakub Filak <jfilak@redhat.com>
a60cd7
---
a60cd7
 src/applet/applet.c            | 16 +++++++++++++---
a60cd7
 src/plugins/abrt-action-notify |  2 +-
a60cd7
 2 files changed, 14 insertions(+), 4 deletions(-)
a60cd7
a60cd7
diff --git a/src/applet/applet.c b/src/applet/applet.c
a60cd7
index b1ce400..a40f877 100644
a60cd7
--- a/src/applet/applet.c
a60cd7
+++ b/src/applet/applet.c
a60cd7
@@ -666,9 +666,19 @@ static void action_ignore(NotifyNotification *notification, gchar *action, gpoin
a60cd7
 {
a60cd7
     problem_info_t *pi = (problem_info_t *)user_data;
a60cd7
 
a60cd7
-    log_debug("Ignoring problem '%s'", problem_info_get_dir(pi));
a60cd7
-
a60cd7
-    ignored_problems_add_problem_data(g_ignore_set, pi->problem_data);
a60cd7
+    const char *const message = _(
a60cd7
+            "You are going to mute notifications of a particular problem. " \
a60cd7
+            "You will never see a notification bubble for this problem again, " \
a60cd7
+            "however, ABRT will be detecting it and you will be able " \
a60cd7
+            "to report it from ABRT GUI." \
a60cd7
+            "\n\n" \
a60cd7
+            "Do you want to continue?");
a60cd7
+
a60cd7
+    if (run_ask_yes_no_yesforever_dialog("AskIgnoreForever", message, NULL))
a60cd7
+    {
a60cd7
+        log_debug("Ignoring problem '%s'", problem_info_get_dir(pi));
a60cd7
+        ignored_problems_add_problem_data(g_ignore_set, pi->problem_data);
a60cd7
+    }
a60cd7
 
a60cd7
     GError *err = NULL;
a60cd7
     notify_notification_close(notification, &err;;
a60cd7
diff --git a/src/plugins/abrt-action-notify b/src/plugins/abrt-action-notify
a60cd7
index cbabf74..8b8f38e 100644
a60cd7
--- a/src/plugins/abrt-action-notify
a60cd7
+++ b/src/plugins/abrt-action-notify
a60cd7
@@ -99,7 +99,7 @@ def emit_crash_dbus_signal(problem_data):
a60cd7
         # member is a Boolean flag which is True if the element is required
a60cd7
         arguments = ((FILENAME_PACKAGE, True), (CD_DUMPDIR, True),
a60cd7
                 (FILENAME_UID, False), (FILENAME_UUID, False),
a60cd7
-                (FILENAME_PACKAGE, False))
a60cd7
+                (FILENAME_DUPHASH, False))
a60cd7
 
a60cd7
         for elem in arguments:
a60cd7
             itm = problem_data.get(elem[0])
a60cd7
-- 
a60cd7
1.8.3.1
a60cd7