summaryrefslogtreecommitdiff
path: root/grc/gui/ActionHandler.py
diff options
context:
space:
mode:
authorSebastian Koslowski <koslowski@kit.edu>2016-05-31 17:35:10 +0200
committerSebastian Koslowski <koslowski@kit.edu>2016-05-31 17:35:10 +0200
commit69da909690bb8bc2072cffb622ddf7bf2e971cce (patch)
treed1b961b21ba9cee24b26491138e247160e3bd726 /grc/gui/ActionHandler.py
parent71534ba66111d625ca2c1aeff11459796e4cea3a (diff)
grc: gtk3: remove canvas size and enable zooming
Diffstat (limited to 'grc/gui/ActionHandler.py')
-rw-r--r--grc/gui/ActionHandler.py17
1 files changed, 6 insertions, 11 deletions
diff --git a/grc/gui/ActionHandler.py b/grc/gui/ActionHandler.py
index 7dc37cc91d..de635b61fd 100644
--- a/grc/gui/ActionHandler.py
+++ b/grc/gui/ActionHandler.py
@@ -676,7 +676,7 @@ class ActionHandler:
can_disable = any(block.get_state() != Constants.BLOCK_DISABLED
for block in selected_blocks)
can_bypass_all = all(block.can_bypass() for block in selected_blocks) \
- and any (not block.get_bypassed() for block in selected_blocks)
+ and any(not block.get_bypassed() for block in selected_blocks)
Actions.BLOCK_ENABLE.set_sensitive(can_enable)
Actions.BLOCK_DISABLE.set_sensitive(can_disable)
Actions.BLOCK_BYPASS.set_sensitive(can_bypass_all)
@@ -687,21 +687,16 @@ class ActionHandler:
Actions.BUSSIFY_SINKS.set_sensitive(bool(selected_blocks))
Actions.RELOAD_BLOCKS.set_sensitive(True)
Actions.FIND_BLOCKS.set_sensitive(True)
- #set the exec and stop buttons
+
self.update_exec_stop()
- #saved status
+
Actions.FLOW_GRAPH_SAVE.set_sensitive(not page.get_saved())
main.update()
- try: #set the size of the flow graph area (if changed)
- new_size = (flow_graph.get_option('window_size') or
- self.platform.config.default_canvas_size)
- if flow_graph.get_size() != tuple(new_size):
- flow_graph.set_size(*new_size)
- except: pass
- #draw the flow graph
+
flow_graph.update_selected()
flow_graph.queue_draw()
- return True #action was handled
+
+ return True # action was handled
def update_exec_stop(self):
"""