@@ -46,13 +46,22 @@ int startShell(int argc, const char** argv, void* server)
46 QGuiApplication *application;
46 QGuiApplication *application;
48 QCommandLineParser parser;
48 QCommandLineParser parser;
49− parser.setApplicationDescription("Application Description Goes Here!");
49+ parser.setApplicationDescription("Description: Unity 8 Shell");
50 parser.addHelpOption();
50 parser.addHelpOption();
52− QCommandLineOption fullscreenOption (QStringList() << "f" << "fullscreen",
52+ QCommandLineOption fullscreenOption ("fullscreen",
53− "Run in fullscreen");
53+ QCoreApplication::translate("fullscreen","Run in fullscreen"));
54 parser.addOption(fullscreenOption);
54 parser.addOption(fullscreenOption);
56+ QCommandLineOption framelessOption ("frameless",
57+ QCoreApplication::translate("frameless","Run without window borders"));
58+ parser.addOption(framelessOption);
60+ QCommandLineOption mousetouchOption ("mousetouch",
61+ QCoreApplication::translate("mousetouch","Allow the mouse to provide touch input"));
62+ parser.addOption(mousetouchOption);
56 if (isUbuntuMirServer) {
65 if (isUbuntuMirServer) {
57 QLibrary unityMir("unity-mir", 1);
66 QLibrary unityMir("unity-mir", 1);
58 unityMir.load();
67 unityMir.load();
@@ -106,14 +115,14 @@ int startShell(int argc, const char** argv, void* server)
106 view->engine()->setBaseUrl(QUrl::fromLocalFile(::qmlDirectory()));
115 view->engine()->setBaseUrl(QUrl::fromLocalFile(::qmlDirectory()));
107 view->rootContext()->setContextProperty("applicationArguments", &qmlArgs);
116 view->rootContext()->setContextProperty("applicationArguments", &qmlArgs);
108 view->rootContext()->setContextProperty("indicatorProfile", indicatorProfile);
117 view->rootContext()->setContextProperty("indicatorProfile", indicatorProfile);
109− if (args.contains(QLatin1String("-frameless"))) {
118+ if (parser.isSet(framelessOption)) {
110 view->setFlags(Qt::FramelessWindowHint);
119 view->setFlags(Qt::FramelessWindowHint);
113 // You will need this if you want to interact with touch-only components using a mouse
122 // You will need this if you want to interact with touch-only components using a mouse
114 // Needed only when manually testing on a desktop.
123 // Needed only when manually testing on a desktop.
115 MouseTouchAdaptor *mouseTouchAdaptor = 0;
124 MouseTouchAdaptor *mouseTouchAdaptor = 0;
116− if (args.contains(QLatin1String("-mousetouch"))) {
125+ if (parser.isSet(mousetouchOption)) {
117 mouseTouchAdaptor = new MouseTouchAdaptor;
126 mouseTouchAdaptor = new MouseTouchAdaptor;
118 application->installNativeEventFilter(mouseTouchAdaptor);
127 application->installNativeEventFilter(mouseTouchAdaptor);