[gnome-packagekit] Don't call gpk_dbus_task_set_xid twice
- From: Richard Hughes <rhughes src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-packagekit] Don't call gpk_dbus_task_set_xid twice
- Date: Fri, 4 Jan 2013 08:32:51 +0000 (UTC)
commit a802d8dee3b718dd88f9138fc37eb3d6eb8c62e2
Author: Matthias Clasen <mclasen redhat com>
Date: Thu Jan 3 17:28:38 2013 -0500
Don't call gpk_dbus_task_set_xid twice
And only call it if xid != 0.
Signed-off-by: Richard Hughes <richard hughsie com>
src/gpk-dbus.c | 6 ++----
1 files changed, 2 insertions(+), 4 deletions(-)
---
diff --git a/src/gpk-dbus.c b/src/gpk-dbus.c
index aa43581..3f84725 100644
--- a/src/gpk-dbus.c
+++ b/src/gpk-dbus.c
@@ -345,9 +345,6 @@ gpk_dbus_create_task (GpkDbus *dbus, guint32 xid, const gchar *interaction, DBus
g_debug ("interact=%i", (gint) interact);
gpk_dbus_task_set_interaction (task, interact);
- /* set the parent window */
- gpk_dbus_task_set_xid (task, xid);
-
/* try to get the user time of the window */
if (xid != 0) {
ret = gpk_x11_set_xid (dbus->priv->x11, xid);
@@ -362,7 +359,8 @@ gpk_dbus_create_task (GpkDbus *dbus, guint32 xid, const gchar *interaction, DBus
gpk_dbus_task_set_timestamp (task, timestamp);
/* set the window for the modal and timestamp */
- gpk_dbus_task_set_xid (task, xid);
+ if (xid != 0)
+ gpk_dbus_task_set_xid (task, xid);
/* get the program name and set */
sender = dbus_g_method_get_sender (context);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]