commit-gnuradio
[Top][All Lists]
Advanced

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

[Commit-gnuradio] [gnuradio] 02/08: grc: fix search entry box for old Py


From: git
Subject: [Commit-gnuradio] [gnuradio] 02/08: grc: fix search entry box for old PyGTK versions
Date: Wed, 1 Oct 2014 19:32:58 +0000 (UTC)

This is an automated email from the git hooks/post-receive script.

jcorgan pushed a commit to branch maint
in repository gnuradio.

commit 6872f5d4e76d119a36c1c6c6474110772cc345a7
Author: Sebastian Koslowski <address@hidden>
Date:   Tue Sep 2 11:05:02 2014 +0200

    grc: fix search entry box for old PyGTK versions
---
 grc/gui/ActionHandler.py | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/grc/gui/ActionHandler.py b/grc/gui/ActionHandler.py
index c06dc96..e20a54a 100644
--- a/grc/gui/ActionHandler.py
+++ b/grc/gui/ActionHandler.py
@@ -86,7 +86,10 @@ class ActionHandler:
             false to let gtk handle the key action
         """
         # prevent key event stealing while the search box is active
-        if self.main_window.btwin.search_entry.has_focus(): return False
+        # .has_focus() only in newer versions 2.17+?
+        # .is_focus() seems to work, but exactly the same
+        if self.main_window.btwin.search_entry.flags() & gtk.HAS_FOCUS:
+            return False
         if not self.get_focus_flag(): return False
         return Actions.handle_key_press(event)
 



reply via email to

[Prev in Thread] Current Thread [Next in Thread]