Quantcast
Channel: Qt DevNet forums: Qt Quick 1283365070**
Viewing all articles
Browse latest Browse all 4972

how to drag a QQuickView Object that is child of other QQuickview Object

$
0
0
Hello, i have written a mini program and i’m trying to drag a QQuickView Object that is child of other QQuickview Object. This is my code: #include <QApplication> #include <QQuickView> #include <QUrl>   int main(int argc, char *argv[]) {     QApplication app(argc, argv);       QQuickView *dash= new QQuickView;     dash->setSource(QUrl("qrc:/ui1.qml"));     dash->show();       QQuickView *widget= new QQuickView;     widget->setParent(dash);     widget->setSource(QUrl("qrc:/widget.qml"));     widget->show();       return app.exec(); } and this is the result !https://www.dropbox.com/s/rsho0kyoqvj5ytd/Captura.PNG?dl=0()! The qmls files are rectangles only. The green rectangle is the Object that i want to drag, the “widget” Object

Viewing all articles
Browse latest Browse all 4972

Trending Articles