[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Commit-gnuradio] [gnuradio] 05/24: grc: fix some PyGTK backwards compat
From: |
git |
Subject: |
[Commit-gnuradio] [gnuradio] 05/24: grc: fix some PyGTK backwards compatibilty issues |
Date: |
Tue, 18 Mar 2014 17:51:40 +0000 (UTC) |
This is an automated email from the git hooks/post-receive script.
trondeau pushed a commit to branch master
in repository gnuradio.
commit 56b13077335a814f3a72c8c759209bcc484ec712
Author: Sebastian Koslowski <address@hidden>
Date: Fri Mar 14 11:18:55 2014 +0100
grc: fix some PyGTK backwards compatibilty issues
---
grc/gui/ActionHandler.py | 12 +++++++++---
grc/gui/DrawingArea.py | 10 +++++-----
2 files changed, 14 insertions(+), 8 deletions(-)
diff --git a/grc/gui/ActionHandler.py b/grc/gui/ActionHandler.py
index 86f06aa..0d89987 100644
--- a/grc/gui/ActionHandler.py
+++ b/grc/gui/ActionHandler.py
@@ -359,11 +359,17 @@ class ActionHandler:
Dialogs.ErrorsDialog(self.get_flow_graph())
elif action == Actions.TOGGLE_REPORTS_WINDOW:
visible = action.get_active()
- self.main_window.reports_scrolled_window.set_visible(visible)
+ if visible:
+ self.main_window.reports_scrolled_window.show()
+ else:
+ self.main_window.reports_scrolled_window.hide()
Preferences.reports_window_visibility(visible)
elif action == Actions.TOGGLE_BLOCKS_WINDOW:
visible = action.get_active()
- self.main_window.btwin.set_visible(visible)
+ if visible:
+ self.main_window.btwin.show()
+ else:
+ self.main_window.btwin.hide()
Preferences.blocks_window_visibility(visible)
##################################################
# Param Modifications
@@ -472,7 +478,7 @@ class ActionHandler:
elif action == Actions.FIND_BLOCKS:
self.main_window.btwin.show()
self.main_window.btwin.search_entry.show()
- self.main_window.set_focus(self.main_window.btwin.search_entry)
+ self.main_window.btwin.search_entry.grab_focus()
elif action == Actions.OPEN_HIER:
bn = [];
for b in self.get_flow_graph().get_selected_blocks():
diff --git a/grc/gui/DrawingArea.py b/grc/gui/DrawingArea.py
index 9fac791..05e69e7 100644
--- a/grc/gui/DrawingArea.py
+++ b/grc/gui/DrawingArea.py
@@ -63,7 +63,7 @@ class DrawingArea(gtk.DrawingArea):
def _handle_notify_event(widget, event, focus_flag): self._focus_flag
= focus_flag
self.connect('leave-notify-event', _handle_notify_event, False)
self.connect('enter-notify-event', _handle_notify_event, True)
- self.set_can_focus(True)
+ self.set_flags(gtk.CAN_FOCUS) # self.set_can_focus(True)
self.connect('focus-out-event', self._handle_focus_lost_event)
def new_pixmap(self, width, height): return gtk.gdk.Pixmap(self.window,
width, height, -1)
@@ -140,7 +140,7 @@ class DrawingArea(gtk.DrawingArea):
def _handle_focus_lost_event(self, widget, event):
# don't clear selection while context menu is active
- if self._flow_graph.get_context_menu().get_visible(): return
- self._flow_graph.unselect()
- self._flow_graph.update_selected()
- self._flow_graph.queue_draw()
+ if not self._flow_graph.get_context_menu().flags() & gtk.VISIBLE:
+ self._flow_graph.unselect()
+ self._flow_graph.update_selected()
+ self._flow_graph.queue_draw()
- [Commit-gnuradio] [gnuradio] branch master updated (69dcaa7 -> d351818), git, 2014/03/18
- [Commit-gnuradio] [gnuradio] 17/24: Merge remote-tracking branch 'smunaut/qtgui_fixes', git, 2014/03/18
- [Commit-gnuradio] [gnuradio] 05/24: grc: fix some PyGTK backwards compatibilty issues,
git <=
- [Commit-gnuradio] [gnuradio] 07/24: gr-qtgui: Use dummy void* return value for pywidget if !ENABLE_PYTHON, git, 2014/03/18
- [Commit-gnuradio] [gnuradio] 11/24: grc: show dummy blocks when opening grc blocks, git, 2014/03/18
- [Commit-gnuradio] [gnuradio] 15/24: grc: tabbed probs: fix initial error box height, git, 2014/03/18
- [Commit-gnuradio] [gnuradio] 14/24: grc: tabbed props: no more double entries, git, 2014/03/18
- [Commit-gnuradio] [gnuradio] 06/24: qtgui: Adding a Number sink with options to set autoscale, layout style, colors, averaging., git, 2014/03/18
- [Commit-gnuradio] [gnuradio] 04/24: Simplify some more., git, 2014/03/18
- [Commit-gnuradio] [gnuradio] 03/24: Move correlate_access_code_tag_bb to non-deprecated GRC category and deprecate the older correlate_access_code_bb., git, 2014/03/18
- [Commit-gnuradio] [gnuradio] 20/24: Merge remote-tracking branch 'skoslowski/grc_show_missing_blocks', git, 2014/03/18
- [Commit-gnuradio] [gnuradio] 09/24: grc: tabbed PropsDialog, git, 2014/03/18
- [Commit-gnuradio] [gnuradio] 19/24: Merge remote-tracking branch 'gnuradio-wg-grc/grc_pygtk_backw_compat_fixes', git, 2014/03/18