[kupfer] browser: Fix for GTK client side windows: entry never mapped



commit a24c59f68ba46fedd4af650535d9a98629f7452a
Author: Ulrik Sverdrup <ulrik sverdrup gmail com>
Date:   Tue Aug 25 11:56:57 2009 +0200

    browser: Fix for GTK client side windows: entry never mapped
    
    Listen to Window, not Entry map-event signal. Entry might never be
    mapped since it is has no size request at initialization.

 kupfer/browser.py |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/kupfer/browser.py b/kupfer/browser.py
index 2302c9f..ae69cd8 100644
--- a/kupfer/browser.py
+++ b/kupfer/browser.py
@@ -708,7 +708,7 @@ class Interface (gobject.GObject):
 		self._key_pressed = None
 		self._theme_colors = {}
 		self.entry.set_size_request(0, 0)
-		self.entry.connect("map-event", self._map_entry)
+		window.connect("map-event", self._map_window)
 
 		from pango import ELLIPSIZE_END
 		self.label.set_width_chars(50)
@@ -775,7 +775,7 @@ class Interface (gobject.GObject):
 		self._widget = vbox
 		return vbox
 
-	def _map_entry(self, widget, event):
+	def _map_window(self, widget, event):
 		"""When Interface's widget is mapped and shown on the screen"""
 		# Now we can read the style from the real theme
 		if not self._theme_colors:



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]