Skip to content
Snippets Groups Projects
Commit 97d831e3 authored by Kai Koehne's avatar Kai Koehne Committed by hjk
Browse files

QmlDesigner: Fix Drag&Drop from Library on Mac

mousePos - QPoint(2,2) still returns the current widget, while
-QPoint(3,3) works.
(cherry picked from commit e5076cc5)
parent da2bc39e
No related branches found
No related tags found
No related merge requests found
...@@ -106,7 +106,7 @@ void CustomDragAndDropIcon::mouseMoveEvent(QMouseEvent *event) ...@@ -106,7 +106,7 @@ void CustomDragAndDropIcon::mouseMoveEvent(QMouseEvent *event)
else { else {
move(-1000, -1000); //if no top level widget is found we are out of the main window move(-1000, -1000); //if no top level widget is found we are out of the main window
} }
QWidget* target = QApplication::widgetAt(globalPos - QPoint(2,2)); //-(2, 2) because: QWidget* target = QApplication::widgetAt(globalPos - QPoint(3,3)); //-(3, 3) because:
// otherwise we just get this widget // otherwise we just get this widget
if (target != m_oldTarget) { if (target != m_oldTarget) {
if (CustomDragAndDrop::isAccepted()) if (CustomDragAndDrop::isAccepted())
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment