forked from qt-creator/qt-creator
Debugger: Warn about QML Debug Mode not being enabled
Previously we only warned the user that he has to enable qml debugging in both run & build config for desktop runs. With this change we now also warn for other types of devices ( e.g. iOS / Android / Remote debugging ) Change-Id: I1437edc9841668299703dad980a292178c891cfe Reviewed-by: <github-actions-qt-creator@cristianadam.eu> Reviewed-by: hjk <hjk@qt.io>
This commit is contained in:
@@ -583,7 +583,7 @@ void DebuggerRunTool::start()
|
||||
++d->engineStopsNeeded;
|
||||
}
|
||||
|
||||
if (m_runParameters.startMode == StartInternal) {
|
||||
if (m_runParameters.startMode != AttachToCore) {
|
||||
QStringList unhandledIds;
|
||||
bool hasQmlBreakpoints = false;
|
||||
for (const GlobalBreakpoint &gbp : BreakpointManager::globalBreakpoints()) {
|
||||
@@ -597,15 +597,14 @@ void DebuggerRunTool::start()
|
||||
}
|
||||
}
|
||||
if (!unhandledIds.isEmpty()) {
|
||||
QString warningMessage =
|
||||
Tr::tr("Some breakpoints cannot be handled by the debugger "
|
||||
QString warningMessage = Tr::tr("Some breakpoints cannot be handled by the debugger "
|
||||
"languages currently active, and will be ignored.<p>"
|
||||
"Affected are breakpoints %1")
|
||||
.arg(unhandledIds.join(", "));
|
||||
|
||||
if (hasQmlBreakpoints) {
|
||||
warningMessage += "<p>" +
|
||||
Tr::tr("QML debugging needs to be enabled both in the Build "
|
||||
warningMessage += "<p>"
|
||||
+ Tr::tr("QML debugging needs to be enabled both in the Build "
|
||||
"and the Run settings.");
|
||||
}
|
||||
|
||||
@@ -617,7 +616,8 @@ void DebuggerRunTool::start()
|
||||
Tr::tr("Debugger"),
|
||||
warningMessage,
|
||||
Tr::tr("&Show this message again."),
|
||||
&checked, QDialogButtonBox::Ok);
|
||||
&checked,
|
||||
QDialogButtonBox::Ok);
|
||||
}
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user