main.cpp 768 B

12345678910111213141516171819202122232425
  1. #include <QtGui/QApplication>
  2. #include "qmlapplicationviewer.h"
  3. #include <QtDeclarative>
  4. #include "iapminimal.h"
  5. // Include inneractiveplugin.h for using inneractive components
  6. #include <inneractiveplugin.h>
  7. Q_DECL_EXPORT int main(int argc, char *argv[])
  8. {
  9. QScopedPointer<QApplication> app(createApplication(argc, argv));
  10. qmlRegisterType<IAPminimal>("iapminimal.com", 1, 0, "IAPmin");
  11. QmlApplicationViewer viewer;
  12. // Initialize QDeclarativeEngine with inneractivePlugin
  13. inneractivePlugin::initializeEngine(viewer.engine());
  14. viewer.setOrientation(QmlApplicationViewer::ScreenOrientationAuto);
  15. viewer.setMainQmlFile(QLatin1String("qml/iapminimal/main.qml"));
  16. viewer.showExpanded();
  17. return app->exec();
  18. }