Merge branch '174' into develop

This commit is contained in:
Sebastian Wehling-Benatelli 2016-03-25 05:08:09 +01:00
commit a1c79b554a

View File

@ -182,6 +182,7 @@ class PickDlg(QDialog):
else: else:
self.picks = {} self.picks = {}
self.filteroptions = FILTERDEFAULTS self.filteroptions = FILTERDEFAULTS
self.filt_block = False
# initialize panning attributes # initialize panning attributes
self.press = None self.press = None
@ -255,8 +256,7 @@ class PickDlg(QDialog):
slot=self.filterWFData, slot=self.filterWFData,
icon=filter_icon, icon=filter_icon,
tip='Toggle filtered/original' tip='Toggle filtered/original'
' waveforms', ' waveforms')
checkable=True)
self.zoomAction = createAction(parent=self, text='Zoom', self.zoomAction = createAction(parent=self, text='Zoom',
slot=self.zoom, icon=zoom_icon, slot=self.zoom, icon=zoom_icon,
tip='Zoom into waveform', tip='Zoom into waveform',
@ -356,6 +356,7 @@ class PickDlg(QDialog):
self.disconnectPressEvent() self.disconnectPressEvent()
self.cidpress = self.connectPressEvent(self.setIniPick) self.cidpress = self.connectPressEvent(self.setIniPick)
self.filterWFData() self.filterWFData()
self.filt_block = self.toggleFilterBlocker()
else: else:
self.disconnectPressEvent() self.disconnectPressEvent()
self.cidpress = self.connectPressEvent(self.panPress) self.cidpress = self.connectPressEvent(self.panPress)
@ -707,7 +708,12 @@ class PickDlg(QDialog):
ax.figure.canvas.draw() ax.figure.canvas.draw()
def toggleFilterBlocker(self):
return not self.filt_block
def filterWFData(self): def filterWFData(self):
if self.filt_block:
return
self.updateCurrentLimits() self.updateCurrentLimits()
data = self.getWFData().copy() data = self.getWFData().copy()
old_title = self.getPlotWidget().getAxes().get_title() old_title = self.getPlotWidget().getAxes().get_title()