forked from qt-creator/qt-creator
QmlDesigner: Fix empty when condition submit
Task-number: QDS-7729 Change-Id: Ia9ed1a911fd9ec5d6ffdcdb7ccfe0bb2ba843dc5 Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
This commit is contained in:
committed by
Henning Gründl
parent
95384d4526
commit
07c8f5249f
@@ -87,9 +87,7 @@ StudioControls.Menu {
|
||||
StudioControls.MenuItem {
|
||||
enabled: !root.isBaseState && root.hasWhenCondition
|
||||
text: qsTr("Reset when Condition")
|
||||
onTriggered: {
|
||||
statesEditorModel.resetWhenCondition(internalNodeId)
|
||||
}
|
||||
onTriggered: root.resetWhenCondition()
|
||||
}
|
||||
|
||||
StudioControls.MenuSeparator {}
|
||||
|
@@ -654,7 +654,12 @@ Item {
|
||||
return
|
||||
|
||||
whenCondition.previousCondition = whenCondition.text
|
||||
root.whenConditionFinished()
|
||||
|
||||
if (whenCondition.text !== "")
|
||||
root.whenConditionFinished()
|
||||
else
|
||||
statesEditorModel.resetWhenCondition(root.internalNodeId)
|
||||
|
||||
}
|
||||
|
||||
Component.onCompleted: whenCondition.previousCondition = whenCondition.text
|
||||
@@ -694,6 +699,7 @@ Item {
|
||||
onExtend: root.extend()
|
||||
onRemove: root.remove()
|
||||
onToggle: root.propertyChangesVisible = !root.propertyChangesVisible
|
||||
onResetWhenCondition: statesEditorModel.resetWhenCondition(root.internalNodeId)
|
||||
onEditAnnotation: {
|
||||
statesEditorModel.setAnnotation(root.internalNodeId)
|
||||
stateMenu.hasAnnotation = root.checkAnnotation()
|
||||
|
Reference in New Issue
Block a user