int main(int argc, char *argv[]) { QGuiApplication app(argc, argv); Controller controller; // QtQuick2ApplicationViewer viewer; viewer.rootContext()-> setContextProperty("controller", &controller); // viewer.installEventFilter(&controller); viewer.setMainQmlFile(QStringLiteral("qml/QCloseConfirm/main.qml")); viewer.showExpanded(); return app.exec(); }
int main(int argc, char *argv[]) { qDebug("[Salticidae] Init Salticidae v%s", PROJECT_VERSION); QCoreApplication::setOrganizationName("Rabits"); QCoreApplication::setOrganizationDomain("rabits.org"); QCoreApplication::setApplicationName("salticidae"); QCoreApplication::setApplicationVersion(PROJECT_VERSION); QGuiApplication app(argc, argv); Eyes::registerQmlTypes(); PluginManager::initPlugins(); QtQuick2ApplicationViewer viewer; Eyes::I()->initContext(viewer, &app); qDebug("[Salticidae] Loading qml"); viewer.setSource(QUrl("qrc:/qml/salticidae/main.qml")); QObject::connect(viewer.engine(), SIGNAL(quit()), &viewer, SLOT(close())); Eyes::I()->initRoot(viewer); qDebug("[Salticidae] Init done, starting"); viewer.showExpanded(); return app.exec(); }
int main(int argc, char * argv[]) { qsrand(QTime::currentTime().msec()); qmlRegisterType<QmlMapInterface>("DumbHome", 1, 0, "QmlMapInterface"); qmlRegisterType<MapObjectQmlWrapper>("DumbHome", 1, 0, "MapObjectQmlWrapper"); QGuiApplication app(argc, argv); QtQuick2ApplicationViewer viewer; viewer.setMainQmlFile(QStringLiteral("qmlsrc/code-if-wanna-live/main.qml")); viewer.showExpanded(); Map * const map = createMap(); World world(map, new MapPhysics(*map)); PlayerActionsQmlReceiver playerActionsQmlReceiver(world.getMap()); viewer.rootContext()->setContextProperty("playerActionsReceiver", &playerActionsQmlReceiver); QmlMapInterface * const qmlMapInterface = viewer.rootObject()->findChild<QmlMapInterface*>("qmlMapInterface"); if (qmlMapInterface != nullptr) { qmlMapInterface->setMap(world.getMap()); world.getMapPhysics().addListener(*qmlMapInterface); } return app.exec(); }
int main(int argc, char *argv[]) { QGuiApplication app(argc, argv); // Create the base application class QtQuick2ApplicationViewer viewer; // create the QML viewer window // The below code will eventually be wrapped in a top level class // Initialize the flyweight //Create first Variable "A" Var* current_var(nullptr); CalculationFlyWeight flyweight; QString token(flyweight.insertCalculation("0","A",current_var)); // Initialize the InputEventHandle class connects QML user input -> C++ Backend logic InputEventHandler in(&flyweight,viewer.engine()->rootContext(),&viewer,nullptr,current_var); // Make the Event Handler visible as QObject& in QML viewer.engine()->rootContext()->setContextProperty("EventHandler",&in); // simulate a user input call to place A as the current variable in the editor in.requestVariable(token); // set the main qml file viewer.setMainQmlFile(QStringLiteral("User_Interface/qml/main.qml")); viewer.showExpanded(); // set fullscreen, and visible return app.exec(); // run the main Application Event loop }
int main(int argc, char *argv[]) { QGuiApplication app(argc, argv); QString fileName; if (app.arguments().length() > 1) { fileName = app.arguments().at(1); } else { qWarning() << "Pass extracted json memory info dump as argument"; return 0; } QtQuick2ApplicationViewer viewer; QFile jsonFile(fileName); if (!jsonFile.open(QIODevice::ReadOnly | QIODevice::Text)) { qWarning() << "Failed to open file:" << fileName; return 0; } viewer.setTitle(fileName); viewer.engine()->rootContext()->setContextProperty("jsonFile", QString(jsonFile.readAll())); viewer.setMainQmlFile(QStringLiteral("qml/memory-dump-reader.qml")); viewer.showExpanded(); return app.exec(); }
int main(int argc, char *argv[]) { QGuiApplication app(argc, argv); qDebug()<<"QGuiApplication"; qmlRegisterType<LogicChannel>("LogicAnalyer", 1, 0, "LogicChannel"); qmlRegisterType<LogicSeries>("LogicAnalyer", 1, 0, "LogicSeries"); qmlRegisterType<LogicAcquirerSimulator>("LogicAnalyer", 1, 0, "LogicAcquirerSimulator"); qmlRegisterType<Timeline>("LogicAnalyer", 1, 0, "Timeline"); qmlRegisterType<Timescale>("LogicAnalyer", 1, 0, "Timescale"); qmlRegisterType<LogicAcquirerSimulator>("LogicAnalyer", 1, 0, "QuickItemDemo0"); qDebug()<<"qmlRegisterType"; QtQuick2ApplicationViewer viewer; viewer.setMainQmlFile(QStringLiteral("qml/LogicAnalyser/LogicAnalyser.qml")); // viewer.setMainQmlFile(QStringLiteral("qml/LogicAnalyser/testQml.qml")); viewer.showExpanded(); // QVariant return app.exec(); }
int main(int argc, char *argv[]) { QGuiApplication app(argc, argv); qmlRegisterType<KinectCamera>("KinectCamera",1,0,"KinectCamera"); QtQuick2ApplicationViewer viewer; viewer.setMainQmlFile(QStringLiteral("qml/kinecttest/main.qml")); viewer.showExpanded(); return app.exec(); }
int main(int argc, char *argv[]) { QGuiApplication app(argc, argv); QtQuick2ApplicationViewer viewer; viewer.setMainQmlFile(QStringLiteral("qml/samegame/main.qml")); viewer.showExpanded(); return app.exec(); }
int main(int argc, char *argv[]) { QApplication app(argc, argv); QDir::setCurrent(QCoreApplication::applicationDirPath()); App application; qmlRegisterType<App>("App", 1, 0, "App"); qmlRegisterType<CollectionModel>("CollectionModel", 1, 0, "CollectionModel"); qmlRegisterType<QStringListModel>("QStringListModel", 1, 0, "QStringListModel"); QtQuick2ApplicationViewer viewer; viewer.rootContext()->setContextProperty("app", &application); viewer.rootContext()->setContextProperty("checkModeCpp", &application.getCheckMode()); viewer.rootContext()->setContextProperty("dictionaryModeCpp", &application.getDictionaryMode()); viewer.rootContext()->setContextProperty("rememberModeCpp", &application.getRememberMode()); viewer.setMainQmlFile(QStringLiteral("qml/Learn/main.qml")); viewer.showExpanded(); viewer.setIcon(QIcon(":/new/g/dictionary-icon.png")); viewer.setTitle("Learn"); application.setWindow(&viewer); return app.exec(); }
int main(int argc, char *argv[]) { QGuiApplication app(argc, argv); QtQuick2ApplicationViewer viewer; qmlRegisterType<mupServerHandle>("mupServerHandle", 1, 0, "ServerHandle"); viewer.setMainQmlFile(QStringLiteral("qml/MUP_qchartjs/main.qml")); viewer.showExpanded(); return app.exec(); }
int main(int argc, char *argv[]) { QGuiApplication app(argc, argv); QtQuick2ApplicationViewer viewer; qmlRegisterType<MQTT>("mqtt", 1, 0, "MQTT"); viewer.setMainQmlFile(QStringLiteral("qml/mqtt/main.qml")); viewer.showExpanded(); return app.exec(); }
int main(int argc, char *argv[]) { QGuiApplication app(argc, argv); QtQuick2ApplicationViewer viewer; qmlRegisterType<OVRVisionItem>("OVRVision", 1, 0, "OVRVision"); viewer.setMainQmlFile(QStringLiteral("qml/OVRVisionOpenCV/main.qml")); viewer.showFullScreen(); return app.exec(); }
int main(int argc, char *argv[]) { QGuiApplication app(argc, argv); // It is a good Idea to use a URI naming scheme to specify the module package name qmlRegisterType<VSXuAccelerometer>("org.vovoid.vsxu", 1, 0, "VSXuAccelerometer"); QtQuick2ApplicationViewer viewer; viewer.setMainQmlFile(QStringLiteral("qml/VSXuDroid/main.qml")); viewer.showExpanded(); return app.exec(); }
int main(int argc, char *argv[]) { QGuiApplication app(argc, argv); qmlRegisterType<ConwayListModel>("com.minimoog77", 1, 0, "ConwayListModel"); QtQuick2ApplicationViewer viewer; viewer.setMainQmlFile(QStringLiteral("qml/quickconway/main.qml")); viewer.showExpanded(); return app.exec(); }
int main(int argc, char *argv[]) { QGuiApplication app(argc, argv); qmlRegisterType<GameModel>("LifeGame", 1, 0, "GameModel"); QtQuick2ApplicationViewer viewer; viewer.setMainQmlFile(QStringLiteral("qml/LifeGameQML01/main.qml")); viewer.showExpanded(); return app.exec(); }
int main(int argc, char *argv[]) { QGuiApplication app(argc, argv); QtQuick2ApplicationViewer viewer; Hash hash(viewer.rootContext()); viewer.rootContext()->setContextProperty("hash", &hash); viewer.setMainQmlFile(QStringLiteral("qrc:/qml/pasgen/main.qml")); viewer.showExpanded(); return app.exec(); }
int main(int argc, char *argv[]) { QGuiApplication app(argc, argv); qmlRegisterType<Triangle>("com.example.qtriangleplugin", 1, 0, "Triangle"); QtQuick2ApplicationViewer viewer; viewer.setMainQmlFile(QStringLiteral("qml/QTriangle/main.qml")); viewer.showExpanded(); return app.exec(); }
int main(int argc, char *argv[]) { QGuiApplication app(argc, argv); QtQuick2ApplicationViewer viewer; viewer.setMainQmlFile(QStringLiteral("qml/qtandroidrunner/main.qml")); viewer.showExpanded(); QtAndroidRunner *runner = QtAndroidRunner::instance(); runner->start(new WebViewInitializer()); return app.exec(); }
int main(int argc, char *argv[]) { QGuiApplication app(argc, argv); FishManager* fishManager = new FishManager(&app); QtQuick2ApplicationViewer viewer; viewer.setMainQmlFile(QStringLiteral("qml/FishRandomizer/main.qml")); viewer.showExpanded(); viewer.rootContext()->setContextProperty("fishManager",fishManager); qmlRegisterType<Fish>("Fishes",1,0,"FishObj"); return app.exec(); }
int main(int argc, char *argv[]) { QGuiApplication app(argc, argv); QtQuick2ApplicationViewer viewer; qmlRegisterType<OAuth2>("OAuth2",0,1,"OAuth2"); viewer.setMainQmlFile(QStringLiteral("qml/OAuthPlayground/main.qml")); viewer.showExpanded(); return app.exec(); }
int main(int argc, char *argv[]) { QGuiApplication app(argc, argv); QtQuick2ApplicationViewer viewer; VideosDatabase *db = new VideosDatabase; viewer.rootContext()->setContextProperty("videosDB", db); viewer.setMainQmlFile(QStringLiteral("qml/app/qtquick20/main.qml")); // MAINQML viewer.showFullScreen(); return app.exec(); }
int main(int argc, char *argv[]) { QGuiApplication app(argc, argv); QtQuick2ApplicationViewer viewer; qmlRegisterType<FileTreeModel>("tk.corvinus.FileTreeModel", 1, 0, "FileTreeModel"); viewer.setMainQmlFile(QStringLiteral("qml/ImageViewer/main.qml")); viewer.showExpanded(); return app.exec(); }
int main(int argc, char *argv[]) { QGuiApplication app(argc, argv); QtQuick2ApplicationViewer viewer; viewer.addImportPath(QStringLiteral("plugins")); viewer.setMainQmlFile(QStringLiteral("qml/Bananas/main.qml")); viewer.showExpanded(); return app.exec(); }
int main(int argc, char *argv[]) { QGuiApplication app(argc, argv); QtQuick2ApplicationViewer viewer; NestedListModel* platforms = new NestedListModel(new UPlatform); UPlatform* platform1 = createPlatform(platforms, 1); UPlatform* platform2 = createPlatform(platforms, 2); UPlatform* platform3 = createPlatform(platforms, 3); ListModel* devices1 = platform1->nestedModel(); ListModel* devices2 = platform2->nestedModel(); ListModel* devices3 = platform3->nestedModel(); UDevice* device1 = createDevice(devices1, 1); UDevice* device2 = createDevice(devices2, 2); UDevice* device3 = createDevice(devices3, 3); ListModel* scenarios1 = device1->nestedModel(); ListModel* scenarios2 = device2->nestedModel(); ListModel* scenarios3 = device3->nestedModel(); UScenario* scenario1 = createScenario(scenarios1, 1); UScenario* scenario2 = createScenario(scenarios2, 2); UScenario* scenario3 = createScenario(scenarios3, 3); ListModel* tasks1 = scenario1->nestedModel(); ListModel* tasks2 = scenario2->nestedModel(); ListModel* tasks3 = scenario3->nestedModel(); UTask* taks1 = createTask(tasks1, 1); UTask* taks2 = createTask(tasks2, 2); UTask* taks3 = createTask(tasks3, 3); ListModel* conditions1 = taks1->nestedModel(); ListModel* conditions2 = taks2->nestedModel(); ListModel* conditions3 = taks3->nestedModel(); createCondition(conditions1, 1); createCondition(conditions2, 2); createCondition(conditions3, 3); QQmlContext* ctxt = viewer.rootContext(); ctxt->setContextProperty("platformsModel", platforms); viewer.setSource(QUrl("qrc:///main.qml")); viewer.show(); return app.exec(); }
int main(int argc, char *argv[]) { QGuiApplication app(argc, argv); registryTypes (); Box2DPlugin plugin; plugin.registerTypes("Box2D"); QtQuick2ApplicationViewer viewer; viewer.setMainQmlFile(QStringLiteral("qml/Arkanoid/main.qml")); viewer.showExpanded(); return app.exec(); }
int main(int argc, char *argv[]) { QGuiApplication app(argc, argv); #ifdef MEASURE_BPM qmlRegisterType<AudioListenerBPM>("com.monkeybusiness.dancer",1,0,"AudioListener"); #else qmlRegisterType<AudioListener>("com.monkeybusiness.dancer",1,0,"AudioListener"); #endif QtQuick2ApplicationViewer viewer; viewer.setMainQmlFile(QStringLiteral("qml/main.qml")); viewer.showExpanded(); return app.exec(); }
int main(int argc, char *argv[]) { QGuiApplication app(argc, argv); QtQuick2ApplicationViewer viewer; QQmlEngine engine; QQmlComponent component(&engine, QUrl::fromLocalFile("qml/Playing/Player.qml")); QObject *object = component.create(); viewer.rootContext()->setContextProperty("player", object); viewer.setMainQmlFile(QStringLiteral("qml/Playing/main.qml")); viewer.showExpanded(); return app.exec(); }
int main(int argc, char *argv[]) { QGuiApplication app(argc, argv); QtQuick2ApplicationViewer viewer; viewer.setMainQmlFile(QStringLiteral("qml/testCacheName/main.qml")); viewer.showExpanded(); QSize requestSize; requestSize.setHeight(200); requestSize.setWidth(200); qDebug() << "++++aaaaaaaa" << cacheKey("/home/mengcong/Pictures/1.jpg", requestSize); qDebug() << "++++bbbbbbbb" << cacheKey("/home/mengcong/Pictures/1.jpg", requestSize); return app.exec(); }
int main(int argc, char *argv[]) { QGuiApplication app(argc, argv); QtQuick2ApplicationViewer viewer; qmlRegisterType<MindCell>("org.ginosoft.qmlcomponents", 1, 0, "MindCell"); CellManager cellManager; viewer.rootContext()->setContextProperty("cellManager", &cellManager); viewer.setMainQmlFile(QStringLiteral("qml/DontMind/main.qml")); viewer.showExpanded(); return app.exec(); }
int main(int argc, char *argv[]) { QGuiApplication app(argc, argv); QtQuick2ApplicationViewer viewer; //Logic logic(":/aggettivi.txt", viewer.rootContext()); Logic logic(":/indeterminativo", viewer.rootContext()); ExerciseVocabularyAnswer vocabulary(":/parole.txt"); TwoSetExercise set; set.load("/tmp/sets.xml"); set.print(); viewer.rootContext()->setContextProperty("logic", &logic); viewer.rootContext()->setContextProperty("vocabulary", &vocabulary); viewer.rootContext()->setContextProperty("setexercise", &set); //viewer.addImportPath("qml/educazionik-framework/"); viewer.setMainQmlFile(QStringLiteral("qml/educazionik-framework/main.qml")); viewer.showExpanded(); return app.exec(); }