~jonas-drange/ubuntu-system-settings/hwKeyboardMinimal

« back to all changes in this revision

Viewing changes to src/main.cpp

  • Committer: jonas-drange
  • Date: 2016-01-25 15:33:26 UTC
  • mfrom: (1576.1.7 ubuntu-system-settings)
  • Revision ID: jonas.drange@canonical.com-20160125153326-eh8masqxjb14feyl
merge trunk

Show diffs side-by-side

added added

removed removed

Lines of Context:
81
81
    parsePluginOptions(app.arguments(), defaultPlugin, pluginOptions);
82
82
 
83
83
    QQuickView view;
 
84
    Utilities utils;
84
85
    QObject::connect(view.engine(), SIGNAL(quit()), &app, SLOT(quit()),
85
86
                     Qt::QueuedConnection);
86
87
    qmlRegisterType<QAbstractItemModel>();
87
88
    qmlRegisterType<SystemSettings::PluginManager>("SystemSettings", 1, 0, "PluginManager");
88
 
    view.engine()->rootContext()->setContextProperty("Utilities", new Utilities());
 
89
    view.engine()->rootContext()->setContextProperty("Utilities", &utils);
89
90
    view.setResizeMode(QQuickView::SizeRootObjectToView);
90
91
    view.engine()->addImportPath(PLUGIN_PRIVATE_MODULE_DIR);
91
92
    view.engine()->addImportPath(PLUGIN_QML_DIR);