summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBrian Tarricone <brian@tarricone.org>2009-02-18 09:04:35 +0000
committerBrian Tarricone <brian@tarricone.org>2009-02-18 09:04:35 +0000
commit815e4eb311e3445b57458370d79b47915be8f247 (patch)
tree2df58013ad6669ba0462b7a4c3b5fed77698320d
parent73c323edc99696489f627ac9c4fc36f005c4ec4e (diff)
downloadxfce4-session-815e4eb311e3445b57458370d79b47915be8f247.tar.gz
* settings/xfae-window.c: Fix a crash in xfce4-session-settings when
trying to add a new autostarted application. XfaeWindow is no longer a GtkWindow and can thus not be used as a parent in gtk_window_set_transient_for() anymore (bug 4934). (Old svn revision: 29504)
-rw-r--r--ChangeLog7
-rw-r--r--NEWS1
-rw-r--r--settings/xfae-window.c4
3 files changed, 11 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index f61d4412..573b8a4c 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2009-02-13 Jannis Pohlmann <jannis@xfce.org>
+
+ * settings/xfae-window.c: Fix a crash in xfce4-session-settings when
+ trying to add a new autostarted application. XfaeWindow is no longer
+ a GtkWindow and can thus not be used as a parent in
+ gtk_window_set_transient_for() anymore (bug 4934).
+
2009-02-01 Brian Tarricone <bjt23@cornell.edu>
* xfce4-session/xfsm-shutdown-helper.c: Fix sudo shutdown helper;
diff --git a/NEWS b/NEWS
index 68fadaf5..b32dad95 100644
--- a/NEWS
+++ b/NEWS
@@ -5,6 +5,7 @@
- Fix sudo shutdown helper for sysetms without HAL (bug 4849).
- Avoid a spurious error dialog when using the sudo shutdown helper
to shut down the system (bug 4849).
+- Fix crash in autostart editor when adding a new app (bug 4934).
4.5.99.1 (Xfce 4.6rc1)
======================
diff --git a/settings/xfae-window.c b/settings/xfae-window.c
index 127b8ac5..0426c7d6 100644
--- a/settings/xfae-window.c
+++ b/settings/xfae-window.c
@@ -257,6 +257,7 @@ static void
xfae_window_add (XfaeWindow *window)
{
GtkTreeModel *model;
+ GtkWidget *parent;
GtkWidget *dialog;
GError *error = NULL;
gchar *name;
@@ -264,7 +265,8 @@ xfae_window_add (XfaeWindow *window)
gchar *command;
dialog = xfae_dialog_new ();
- gtk_window_set_transient_for (GTK_WINDOW (dialog), GTK_WINDOW (window));
+ parent = gtk_widget_get_toplevel (GTK_WIDGET (window));
+ gtk_window_set_transient_for (GTK_WINDOW (dialog), GTK_WINDOW (parent));
if (gtk_dialog_run (GTK_DIALOG (dialog)) == GTK_RESPONSE_OK)
{
gtk_widget_hide (dialog);