summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristopher Williams <crdlb@compiz-fusion.org>2010-05-06 14:19:58 -0400
committerChristopher Williams <crdlb@compiz-fusion.org>2010-05-06 14:47:19 -0400
commitd251e449215a5640df2389e2199a443bbbac49a4 (patch)
treebca78d3bdc5aebeda2bf27745796df459c5cb618
parentad91095d30ca7dd352aa6199d7f9912b1c417ca2 (diff)
downloadccsm-d251e449215a5640df2389e2199a443bbbac49a4.tar.gz
ccsm-d251e449215a5640df2389e2199a443bbbac49a4.tar.bz2
Don't destroy match dialog before reading contents
That was never correct, but it worked in previous versions of gtk+ because a reference to the Entry was held. Gtk+-2.20 stores the text in an EntryBuffer object, which was getting unreffed and collected before ccsm could read the text.
-rw-r--r--ccm/Widgets.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/ccm/Widgets.py b/ccm/Widgets.py
index 51fe828..961d194 100644
--- a/ccm/Widgets.py
+++ b/ccm/Widgets.py
@@ -1193,7 +1193,7 @@ class MatchButton(gtk.Button):
dlg.show_all ()
response = dlg.run ()
- dlg.destroy ()
+ dlg.hide ()
if response == gtk.RESPONSE_OK:
type = type_chooser.get_active_text ()
value = entry.get_text ()
@@ -1201,6 +1201,8 @@ class MatchButton(gtk.Button):
invert = check.get_active ()
self.generate_match (type, value, relation, invert)
+ dlg.destroy ()
+
class FileButton (gtk.Button):
__gsignals__ = {"changed" : (gobject.SIGNAL_RUN_FIRST,
gobject.TYPE_NONE,