forked from qt-creator/qt-creator
QmlDebugger: Fix Remote QML Debugging
The host address is now retreived from the kit info. Incase, a device is not associated with the given kit, the host is assumed to be localhost. Change-Id: I659d2d64ec78dc1b10c80c97390994a56ff26344 Reviewed-by: Kai Koehne <kai.koehne@digia.com> Reviewed-by: hjk <qthjk@ovi.com> Reviewed-by: Eike Ziller <eike.ziller@digia.com>
This commit is contained in:
committed by
Kai Koehne
parent
492ca1cbcf
commit
86c14292d2
@@ -417,17 +417,21 @@ void QmlEngine::beginConnection(quint16 port)
|
||||
|
||||
QTC_ASSERT(state() == EngineRunRequested, return);
|
||||
|
||||
QString host = startParameters().qmlServerAddress;
|
||||
// Use localhost as default
|
||||
if (host.isEmpty())
|
||||
host = QLatin1String("localhost");
|
||||
|
||||
if (port > 0) {
|
||||
QTC_ASSERT(startParameters().connParams.port == 0
|
||||
|| startParameters().connParams.port == port,
|
||||
qWarning() << "Port " << port << "from application output does not match"
|
||||
<< startParameters().connParams.port << "from start parameters.");
|
||||
m_adapter.beginConnectionTcp(startParameters().qmlServerAddress, port);
|
||||
m_adapter.beginConnectionTcp(host, port);
|
||||
return;
|
||||
}
|
||||
// no port from application output, use the one from start parameters ...
|
||||
m_adapter.beginConnectionTcp(startParameters().qmlServerAddress,
|
||||
startParameters().qmlServerPort);
|
||||
m_adapter.beginConnectionTcp(host, startParameters().qmlServerPort);
|
||||
}
|
||||
|
||||
void QmlEngine::connectionStartupFailed()
|
||||
|
||||
Reference in New Issue
Block a user