Enable QML Debugger

REVIEW: 112127
This commit is contained in:
David Edmundson 2013-08-16 21:54:01 +01:00
parent b768f17c14
commit 0ddc59af24

View File

@ -25,6 +25,7 @@
#include "desktopcorona.h"
#include "shellpluginloader.h"
#include <QtQml/QQmlDebuggingEnabler>
static const char description[] = "Plasma Shell";
static const char version[] = "2.0";
@ -43,6 +44,12 @@ int main(int argc, char** argv)
ki18n("Plasma Shell"),
version);
//enable the QML debugger only if -qmljsdebugger is passed as a command line arg
//this must be called before the QApplication constructor
if (KCmdLineArgs::parsedArgs("qt")->isSet("qmljsdebugger")) {
QQmlDebuggingEnabler enabler;
}
QApplication app(argc, argv);
Plasma::PluginLoader::setPluginLoader(new ShellPluginLoader);