Details
-
Bug
-
Resolution: Duplicate
-
P3: Somewhat important
-
None
-
5.0.0 Beta 1
-
Mac OS X 10.8
gcc_64
Qt 5.0 Beta 1 (official build from the website)
Description
It seems that DropArea component accepts local drag operations only. For example, the following app receives onEntered event only and drag.source property is null. Thus it's impossible to get the object being dragged.
import QtQuick 2.0 Rectangle { id: background; color: "white"; width: 300; height: 300; DropArea { anchors.fill: parent; onEntered: { background.color = "gray"; if (!drag.accepted) drag.accept (Qt.CopyAction); console.log("onEntered"); } onDropped: { console.log ("onDropped"); } onExited: { background.color = "white"; console.log ("onExited"); } } }
I suppose it may be a bigger problem since QWindow lacks setAcceptDrops function QMainWindow has. Since we're not able to use QQuickView inside QMainWindow it may be a serious problem.