Allow qmljsdebugger argument and value to be separated by a space

This change makes it possible to use the QML JS debugger with KDE
applications.

Change-Id: Id5838fa34dcb8b54127abc6da6fe7c2e9a5a1c2e
Reviewed-by: David Faure (KDE) <faure@kde.org>
Reviewed-by: Kai Koehne <kai.koehne@digia.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
bb10
Aurélien Gâteau 2012-10-11 11:15:03 +02:00 committed by The Qt Project
parent a1dfccf954
commit fea68274b8
1 changed files with 3 additions and 0 deletions

View File

@ -167,6 +167,9 @@ void QCoreApplicationPrivate::processCommandLineArguments()
QByteArray arg = argv[i];
if (arg.startsWith("-qmljsdebugger=")) {
qmljs_debug_arguments = QString::fromLocal8Bit(arg.right(arg.length() - 15));
} else if (arg == "-qmljsdebugger" && i < argc - 1) {
++i;
qmljs_debug_arguments = QString::fromLocal8Bit(argv[i]);
} else {
argv[j++] = argv[i];
}