summaryrefslogtreecommitdiff
path: root/source/xap/xfce/patches/terminal.gtk.2.18.fix.diff
diff options
context:
space:
mode:
authorPatrick J Volkerding <volkerdi@slackware.com>2010-05-19 08:58:23 +0000
committerEric Hameleers <alien@slackware.com>2018-05-31 22:43:05 +0200
commitb76270bf9e6dd375e495fec92140a79a79415d27 (patch)
tree3dbed78b2279bf9f14207a16dc634b90995cbd40 /source/xap/xfce/patches/terminal.gtk.2.18.fix.diff
parent5a12e7c134274dba706667107d10d231517d3e05 (diff)
downloadcurrent-b76270bf9e6dd375e495fec92140a79a79415d27.tar.gz
Slackware 13.1slackware-13.1
Wed May 19 08:58:23 UTC 2010 Slackware 13.1 x86_64 stable is released! Lots of thanks are due -- see the RELEASE_NOTES and the rest of the ChangeLog for credits. The ISOs are on their way to replication, a 6 CD-ROM 32-bit set and a dual-sided 32-bit/64-bit x86/x86_64 DVD. We are taking pre-orders now at store.slackware.com, and offering a discount if you sign up for a subscription. Consider picking up a copy to help support the project. Thanks again to the Slackware community for testing, contributing, and generally holding us to a high level of quality. :-) Enjoy!
Diffstat (limited to 'source/xap/xfce/patches/terminal.gtk.2.18.fix.diff')
-rw-r--r--source/xap/xfce/patches/terminal.gtk.2.18.fix.diff101
1 files changed, 101 insertions, 0 deletions
diff --git a/source/xap/xfce/patches/terminal.gtk.2.18.fix.diff b/source/xap/xfce/patches/terminal.gtk.2.18.fix.diff
new file mode 100644
index 00000000..69a9e70e
--- /dev/null
+++ b/source/xap/xfce/patches/terminal.gtk.2.18.fix.diff
@@ -0,0 +1,101 @@
+From 028dc2efd846defe796c7fa097ed84818bb43431 Mon Sep 17 00:00:00 2001
+From: Nick Schermer <nick@xfce.org>
+Date: Sun, 21 Mar 2010 22:05:31 +0000
+Subject: Disconnect bindings before closing the dialog.
+
+This avoids possible problems when Gtk+ emits property
+changes before the widgets are destroyed. This is currently
+the case for text entries in some Gtk 2.18 releases.
+---
+diff --git a/terminal/terminal-preferences-dialog.c b/terminal/terminal-preferences-dialog.c
+index 587bd92..8f33628 100644
+--- a/terminal/terminal-preferences-dialog.c
++++ b/terminal/terminal-preferences-dialog.c
+@@ -64,24 +64,28 @@ terminal_preferences_dialog_class_init (TerminalPreferencesDialogClass *klass)
+
+
+ #define BIND_PROPERTIES(name, property) \
+- { object = gtk_builder_get_object (GTK_BUILDER (dialog), name); \
++ G_STMT_START { \
++ object = gtk_builder_get_object (GTK_BUILDER (dialog), name); \
+ terminal_return_if_fail (G_IS_OBJECT (object)); \
+- exo_mutual_binding_new (G_OBJECT (dialog->preferences), name, \
+- G_OBJECT (object), property); }
++ binding = exo_mutual_binding_new (G_OBJECT (dialog->preferences), name, \
++ G_OBJECT (object), property); \
++ dialog->bindings = g_slist_prepend (dialog->bindings, binding); \
++ } G_STMT_END
+
+
+
+ static void
+ terminal_preferences_dialog_init (TerminalPreferencesDialog *dialog)
+ {
+- GError *error = NULL;
+- guint i;
+- GObject *object, *object2;
+- GtkWidget *editor;
+- gchar palette_name[16];
+- GtkFileFilter *filter;
+- gchar *file;
+- const gchar *props_active[] = { "title-mode", "command-login-shell",
++ GError *error = NULL;
++ guint i;
++ GObject *object, *object2;
++ GtkWidget *editor;
++ gchar palette_name[16];
++ GtkFileFilter *filter;
++ gchar *file;
++ ExoMutualBinding *binding;
++ const gchar *props_active[] = { "title-mode", "command-login-shell",
+ "command-update-records", "scrolling-single-line",
+ "scrolling-on-output", "scrolling-on-keystroke",
+ "scrolling-bar", "font-allow-bold",
+@@ -94,9 +98,9 @@ terminal_preferences_dialog_init (TerminalPreferencesDialog *dialog)
+ , "font-anti-alias"
+ #endif
+ };
+- const gchar *props_color[] = { "color-foreground", "color-cursor",
+- "color-background", "tab-activity-color",
+- "color-selection" };
++ const gchar *props_color[] = { "color-foreground", "color-cursor",
++ "color-background", "tab-activity-color",
++ "color-selection" };
+
+ dialog->preferences = terminal_preferences_get ();
+
+@@ -248,6 +252,8 @@ terminal_preferences_dialog_response (GtkWidget *widget,
+ gint response,
+ TerminalPreferencesDialog *dialog)
+ {
++ GSList *li;
++
+ /* check if we should open the user manual */
+ if (G_UNLIKELY (response == 1))
+ {
+@@ -256,6 +262,11 @@ terminal_preferences_dialog_response (GtkWidget *widget,
+ }
+ else
+ {
++ /* disconnect all the bindings */
++ for (li = dialog->bindings; li != NULL; li = li->next)
++ exo_mutual_binding_unbind (li->data);
++ g_slist_free (dialog->bindings);
++
+ /* close the preferences dialog */
+ gtk_widget_destroy (widget);
+ }
+diff --git a/terminal/terminal-preferences-dialog.h b/terminal/terminal-preferences-dialog.h
+index b2db4f5..268d70a 100644
+--- a/terminal/terminal-preferences-dialog.h
++++ b/terminal/terminal-preferences-dialog.h
+@@ -48,6 +48,7 @@ struct _TerminalPreferencesDialog
+
+ TerminalPreferences *preferences;
+ guint signal_id;
++ GSList *bindings;
+ };
+
+ GType terminal_preferences_dialog_get_type (void) G_GNUC_CONST;
+--
+cgit v0.8.2.1