From a1ee8d408c14bdf96882519f3845f602f3551dff Mon Sep 17 00:00:00 2001 From: Marcel Date: Mon, 15 Jan 2018 11:31:30 +0100 Subject: [PATCH] [add] user_help to status bar [bugfix] missing change to mouseevent button --- pylot/RELEASE-VERSION | 2 +- pylot/core/util/widgets.py | 7 +++++-- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/pylot/RELEASE-VERSION b/pylot/RELEASE-VERSION index 98c9f0b1..1ddb9ca5 100644 --- a/pylot/RELEASE-VERSION +++ b/pylot/RELEASE-VERSION @@ -1 +1 @@ -5342-dirty +d640-dirty diff --git a/pylot/core/util/widgets.py b/pylot/core/util/widgets.py index e40430a4..0b4c7463 100644 --- a/pylot/core/util/widgets.py +++ b/pylot/core/util/widgets.py @@ -2136,7 +2136,10 @@ class PickDlg(QDialog): def on_motion(self, event): x = event.xdata if x is not None: - self.statusbar.showMessage('T = {}, t = {} [s]'.format(self.stime+x, x)) + time_code = 'T = {}, t = {} [s]'.format(self.stime+x, x) + user_help = ' - Left-Click to Drag | Right-Click to Pan-Zoom |' \ + ' Mousewheel to Zoom | Middle-Click to Delete Pick' + self.statusbar.showMessage(time_code + user_help) def onpick(self, event): if event.mouseevent.button == 1: @@ -2181,7 +2184,7 @@ class PickDlg(QDialog): self.statusbar.showMessage(message, 10e3) def onpick_delete(self, event): - if not event.mouseevent.button == 3: + if not event.mouseevent.button == 2: return x = event.mouseevent.xdata self.remove_pick_by_x(x)