forked from qt-creator/qt-creator
QmlTooling: Parse messages from latest Qt5
Change-Id: I5b2574d5dd2fecbf483a2e33feb8674846b84a59 Reviewed-by: Aurindam Jana <aurindam.jana@nokia.com>
This commit is contained in:
@@ -57,13 +57,24 @@ void QDeclarativeOutputParser::processOutput(const QString &output)
|
||||
const QString msg = m_buffer.left(nlIndex);
|
||||
m_buffer = m_buffer.right(m_buffer.size() - nlIndex - 1);
|
||||
|
||||
static const QString qddserver = QLatin1String("QDeclarativeDebugServer: ");
|
||||
// used in Qt4
|
||||
static const QString qddserver4 = QLatin1String("QDeclarativeDebugServer: ");
|
||||
// used in Qt5
|
||||
static const QString qddserver5 = QLatin1String("QML Debugger: ");
|
||||
|
||||
const int index = msg.indexOf(qddserver);
|
||||
QString status;
|
||||
int index = msg.indexOf(qddserver4);
|
||||
if (index != -1) {
|
||||
QString status = msg;
|
||||
status.remove(0, index + qddserver.length()); // chop of 'QDeclarativeDebugServer: '
|
||||
|
||||
status = msg;
|
||||
status.remove(0, index + qddserver4.length()); // chop of 'QDeclarativeDebugServer: '
|
||||
} else {
|
||||
index = msg.indexOf(qddserver5);
|
||||
if (index != -1) {
|
||||
status = msg;
|
||||
status.remove(0, index + qddserver5.length()); // chop of 'QML Debugger: '
|
||||
}
|
||||
}
|
||||
if (!status.isEmpty()) {
|
||||
static QString waitingForConnection = QLatin1String(Constants::STR_WAITING_FOR_CONNECTION);
|
||||
static QString unableToListen = QLatin1String(Constants::STR_UNABLE_TO_LISTEN);
|
||||
static QString debuggingNotEnabled = QLatin1String(Constants::STR_IGNORING_DEBUGGER);
|
||||
|
||||
Reference in New Issue
Block a user