DebugConsole must now be created from components
Remove the default console from UI.qml and add a utils.js function to create one quickly. Using this function from the component we actually want to debug gives the console full access to that component's scope, children IDs, etc.
This commit is contained in:
@@ -170,10 +170,8 @@ Column {
|
||||
icon.name: "settings"
|
||||
text: qsTr("Set as debug console target")
|
||||
visible: debugMode
|
||||
onTriggered: {
|
||||
mainUI.debugConsole.target = [eventDelegate, eventContent]
|
||||
mainUI.debugConsole.runJS("t[0].json()")
|
||||
}
|
||||
onTriggered:
|
||||
Utils.debug(eventDelegate, con => { con.runJS("json()") })
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user