Skip to content

Commit cb301b2

Browse files
committed
[GraphEditor] Fix injections into signal handlers with JS functions
1 parent faff99f commit cb301b2

File tree

3 files changed

+6
-6
lines changed

3 files changed

+6
-6
lines changed

meshroom/ui/qml/GraphEditor/AttributeItemDelegate.qml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ RowLayout {
103103
anchors.fill: parent
104104
hoverEnabled: true
105105
acceptedButtons: Qt.AllButtons
106-
onDoubleClicked: root.doubleClicked(mouse, root.attribute)
106+
onDoubleClicked: function(mouse) { root.doubleClicked(mouse, root.attribute) }
107107

108108
property Component menuComp: Menu {
109109
id: paramMenu

meshroom/ui/qml/GraphEditor/NodeEditor.qml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -290,7 +290,7 @@ Panel {
290290
Layout.fillWidth: true
291291
model: root.node.attributes
292292
readOnly: root.readOnly || root.isCompatibilityNode
293-
onAttributeDoubleClicked: root.attributeDoubleClicked(mouse, attribute)
293+
onAttributeDoubleClicked: function(mouse, attribute) { root.attributeDoubleClicked(mouse, attribute) }
294294
onUpgradeRequest: root.upgradeRequest()
295295
filterText: searchBar.text
296296
}
@@ -357,7 +357,7 @@ Panel {
357357
Layout.fillWidth: true
358358
model: root.node.internalAttributes
359359
readOnly: root.readOnly || root.isCompatibilityNode
360-
onAttributeDoubleClicked: root.attributeDoubleClicked(mouse, attribute)
360+
onAttributeDoubleClicked: function(mouse, attribute) { root.attributeDoubleClicked(mouse, attribute) }
361361
onUpgradeRequest: root.upgradeRequest()
362362
filterText: searchBar.text
363363
}

meshroom/ui/qml/GraphEditor/ScriptEditor.qml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,7 @@ Item {
118118
ToolTip.text: "Execute Script"
119119

120120
onClicked: {
121-
processScript()
121+
root.processScript()
122122
}
123123
}
124124

@@ -285,9 +285,9 @@ Item {
285285
root.forceActiveFocus()
286286
}
287287

288-
Keys.onPressed: {
288+
Keys.onPressed: function(event) {
289289
if ((event.key === Qt.Key_Enter || event.key === Qt.Key_Return) && event.modifiers === Qt.ControlModifier) {
290-
processScript()
290+
root.processScript()
291291
}
292292
}
293293
}

0 commit comments

Comments
 (0)