- fixed a Qt6 derived issue where dragging tabs outside the app crashed the app

This commit is contained in:
Marius Stanciu
2021-08-26 16:10:40 +03:00
parent 5899e0befa
commit b6c9e85bdd
2 changed files with 2 additions and 2 deletions

View File

@@ -3245,10 +3245,9 @@ class FCDetachableTab(QtWidgets.QTabWidget):
# If the current movement is a drag initiated by the left button
if (event.buttons() & QtCore.Qt.MouseButton.LeftButton) and self.dragInitiated and self.can_be_dragged:
# Stop the move event
finishMoveEvent = QtGui.QMouseEvent(
QtCore.QEvent.Type.MouseMove, event.position().toPoint(), QtCore.Qt.MouseButton.NoButton,
QtCore.QEvent.Type.MouseMove, event.position(), QtCore.Qt.MouseButton.NoButton,
QtCore.Qt.MouseButton.NoButton, QtCore.Qt.KeyboardModifier.NoModifier
)
QtWidgets.QTabBar.mouseMoveEvent(self, finishMoveEvent)