--- a/eric6/E5Gui/E5ModelToolBar.py Sun Apr 11 16:53:48 2021 +0200 +++ b/eric6/E5Gui/E5ModelToolBar.py Sun Apr 11 18:45:10 2021 +0200 @@ -175,9 +175,11 @@ idx = self.index(act) if idx.isValid(): self.activated[QModelIndex].emit(idx) - elif evt.type() == QEvent.Type.MouseButtonPress: - if evt.buttons() & Qt.MouseButton.LeftButton: - self.__dragStartPosition = self.mapFromGlobal(evt.globalPos()) + elif ( + evt.type() == QEvent.Type.MouseButtonPress and + evt.buttons() & Qt.MouseButton.LeftButton + ): + self.__dragStartPosition = self.mapFromGlobal(evt.globalPos()) return False