def mousePressEvent(self, event): if event.button() == Qt.LeftButton and self.chart(): self.m_lastMousePos = self.mapToScene(event.pos()) QChartView.mousePressEvent(self, event)
def mousePressEvent(self, event: QMouseEvent): if event.button() == Qt.MiddleButton: self.__last_mouse_pos = event.pos() event.accept() QChartView.mousePressEvent(self, event)