[tor-commits] [arm/master] Moving graph bounds switching to the graph panel
atagar at torproject.org
atagar at torproject.org
Fri May 13 05:09:39 UTC 2011
commit 233bd0609cf2ebdea034e4d57882d0a0961b11d2
Author: Damian Johnson <atagar at torproject.org>
Date: Thu May 12 20:57:28 2011 -0700
Moving graph bounds switching to the graph panel
---
src/cli/controller.py | 5 -----
src/cli/graphing/graphPanel.py | 4 ++++
2 files changed, 4 insertions(+), 5 deletions(-)
diff --git a/src/cli/controller.py b/src/cli/controller.py
index 1384c4d..d7b127c 100644
--- a/src/cli/controller.py
+++ b/src/cli/controller.py
@@ -807,11 +807,6 @@ def drawTorMonitor(stdscr, startTime, loggedEvents, isBlindMode):
panel.CURSES_LOCK.release()
elif key == ord('h') or key == ord('H'):
overrideKey = popups.showHelpPopup()
- elif page == 0 and (key == ord('b') or key == ord('B')):
- # uses the next boundary type for graph
- panels["graph"].bounds = graphing.graphPanel.Bounds.next(panels["graph"].bounds)
-
- selectiveRefresh(panels, page)
else:
for pagePanel in getPanels(page + 1):
isKeystrokeConsumed = pagePanel.handleKey(key)
diff --git a/src/cli/graphing/graphPanel.py b/src/cli/graphing/graphPanel.py
index ecf8c68..ef0267d 100644
--- a/src/cli/graphing/graphPanel.py
+++ b/src/cli/graphing/graphPanel.py
@@ -271,6 +271,10 @@ class GraphPanel(panel.Panel):
if currentHeight < maxHeight + 1:
self.setGraphHeight(self.graphHeight + 1)
+ elif key == ord('b') or key == ord('B'):
+ # uses the next boundary type
+ self.bounds = Bounds.next(self.bounds)
+ self.redraw(True)
elif key == ord('s') or key == ord('S'):
# provides a menu to pick the graphed stats
availableStats = self.stats.keys()
More information about the tor-commits
mailing list