commit-gnuradio
[Top][All Lists]
Advanced

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

[Commit-gnuradio] [gnuradio] 03/11: grc: Changed dialog to directly call


From: git
Subject: [Commit-gnuradio] [gnuradio] 03/11: grc: Changed dialog to directly call the SCROLL_LOCK and CLEAR_REPORTS actions. Moved clear reports under view and grouped all Report menu items together
Date: Fri, 13 Jun 2014 22:44:32 +0000 (UTC)

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

jcorgan pushed a commit to branch master
in repository gnuradio.

commit 9d6284c1e2317995c2ac959de0fa4f0668c0064d
Author: Seth Hitefield <address@hidden>
Date:   Wed Jun 11 11:27:55 2014 -0400

    grc: Changed dialog to directly call the SCROLL_LOCK and CLEAR_REPORTS 
actions.
    Moved clear reports under view and grouped all Report menu items together
---
 grc/gui/ActionHandler.py | 3 ---
 grc/gui/Actions.py       | 8 ++++----
 grc/gui/Bars.py          | 3 ++-
 grc/gui/Dialogs.py       | 6 +++---
 4 files changed, 9 insertions(+), 11 deletions(-)

diff --git a/grc/gui/ActionHandler.py b/grc/gui/ActionHandler.py
index d769405..70e8064 100644
--- a/grc/gui/ActionHandler.py
+++ b/grc/gui/ActionHandler.py
@@ -61,9 +61,6 @@ class ActionHandler:
         self.main_window = MainWindow(platform)
         self.main_window.connect('delete-event', self._quit)
         self.main_window.connect('key-press-event', self._handle_key_press)
-        # Add actions the report/log text_view can call back to from its 
context menu
-        self.main_window.text_display.clear_action = Actions.CLEAR_REPORTS
-        self.main_window.text_display.scroll_action = 
Actions.TOGGLE_SCROLL_LOCK
         self.get_page = self.main_window.get_page
         self.get_flow_graph = self.main_window.get_flow_graph
         self.get_focus_flag = self.main_window.get_focus_flag
diff --git a/grc/gui/Actions.py b/grc/gui/Actions.py
index bf05ea7..abd5017 100644
--- a/grc/gui/Actions.py
+++ b/grc/gui/Actions.py
@@ -282,8 +282,8 @@ TOGGLE_BLOCKS_WINDOW = ToggleAction(
     keypresses=(gtk.keysyms.b, gtk.gdk.CONTROL_MASK),
 )
 TOGGLE_SCROLL_LOCK = ToggleAction(
-    label='_Scroll Lock',
-    tooltip='Toggle scrool lock of the logging window',
+    label='_Report Scroll Lock',
+    tooltip='Toggle scroll lock for the report window',
 )
 ABOUT_WINDOW_DISPLAY = Action(
     label='_About',
@@ -350,8 +350,8 @@ FIND_BLOCKS = Action(
                 gtk.keysyms.slash, NO_MODS_MASK),
 )
 CLEAR_REPORTS = Action(
-    label='_Clear Logs',
-    tooltip='Clear Logs',
+    label='_Clear Reports',
+    tooltip='Clear Reports',
     stock_id=gtk.STOCK_CLEAR,
 )
 OPEN_HIER = Action(
diff --git a/grc/gui/Bars.py b/grc/gui/Bars.py
index defde1c..11e35c9 100644
--- a/grc/gui/Bars.py
+++ b/grc/gui/Bars.py
@@ -89,12 +89,13 @@ MENU_BAR_LIST = (
         Actions.BLOCK_DISABLE,
         None,
         Actions.BLOCK_PARAM_MODIFY,
-        Actions.CLEAR_REPORTS,
     ]),
     (gtk.Action('View', '_View', None, None), [
         Actions.TOGGLE_BLOCKS_WINDOW,
+        None,
         Actions.TOGGLE_REPORTS_WINDOW,
         Actions.TOGGLE_SCROLL_LOCK,
+        Actions.CLEAR_REPORTS,
         None,
         Actions.ERRORS_WINDOW_DISPLAY,
         Actions.FIND_BLOCKS,
diff --git a/grc/gui/Dialogs.py b/grc/gui/Dialogs.py
index f9a3551..1b7be1a 100644
--- a/grc/gui/Dialogs.py
+++ b/grc/gui/Dialogs.py
@@ -21,6 +21,7 @@ import pygtk
 pygtk.require('2.0')
 import gtk
 import Utils
+import Actions
 
 class TextDisplay(gtk.TextView):
     """A non editable gtk text view."""
@@ -82,10 +83,9 @@ class TextDisplay(gtk.TextView):
     # Callback functions to handle the scrolling lock and clear context menus 
options
     # Action functions are set by the ActionHandler's init function
     def clear_cb(self, menu_item, web_view):
-        self.clear_action()
+        Actions.CLEAR_REPORTS()        
     def scroll_back_cb(self, menu_item, web_view):
-        # Trigger the toggle action
-        self.scroll_action()
+        Actions.TOGGLE_SCROLL_LOCK()
        
     # Create a popup menu for the scroll lock and clear functions.
     def populate_popup(self, view, menu):



reply via email to

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