[Qt-qml] Concurrent Happening Problem after an event

merve t mervet2009 at gmail.com
Mon Oct 17 17:40:01 CEST 2011


Hello,
I have a custom QDeclarativeItem DropPolygon.

In qml i use it as following code:

 DropPolygon {
        id:poly
        x:200; y:50;
        width: 0; height: 0;
        color: "#0000cc"

        vertices:[
            Point{x:20;y:20},
            Point{x:20;y:40},
            Point{x:40;y:20}
        ]



                        anchors.fill: parent

                        onDragEnter: {
                                console.log("DropArea: drag enter with data:
\"" + event.data.text + "\", source element: " + event.data.source + ",
source color " + event.data.source.color);
                        poly.color="#cc00cc";
                        }

                        onDragLeave:{ console.log("drag out");
poly.color="#0000cc";}

                        onDrop: {
                                event.accept(Qt.LinkAction);
                                //event.accept()
                        }

        }


When onDragLeave event happens, i see Qt prints "drag out" in console. BUT i
can not see color change to "cc00cc" concurrently. What may the problem be?
Thanks
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.qt.nokia.com/pipermail/qt-qml/attachments/20111017/97072fb9/attachment.html 


More information about the Qt-qml mailing list