MCPcopy Create free account
hub / github.com/pyfa-org/Pyfa / OnMplCanvasClick

Method OnMplCanvasClick

graphs/gui/canvasPanel.py:329–337  ·  view source on GitHub ↗
(self, event)

Source from the content-addressed store, hash-verified

327
328 # Matplotlib event handlers
329 def OnMplCanvasClick(self, event):
330 if event.button == 1:
331 if not self.mplOnDragHandler:
332 self.mplOnDragHandler = self.canvas.mpl_connect('motion_notify_event', self.OnMplCanvasDrag)
333 if not self.mplOnReleaseHandler:
334 self.mplOnReleaseHandler = self.canvas.mpl_connect('button_release_event', self.OnMplCanvasRelease)
335 self.markXApproximate(event.xdata)
336 elif event.button == 3:
337 self.unmarkX()
338
339 def OnMplCanvasDrag(self, event):
340 self.markXApproximate(event.xdata)

Callers

nothing calls this directly

Calls 2

markXApproximateMethod · 0.95
unmarkXMethod · 0.95

Tested by

no test coverage detected