mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-07-23 22:54:01 -06:00
When getting active focus textinput value was being cleared. However if text was inputted then this would stay between active focus states.
This commit forces the value to be assigned the value in the textInput when active focus is given. CURA-8640
This commit is contained in:
parent
e20ded248f
commit
e593322b43
1 changed files with 7 additions and 1 deletions
|
@ -162,6 +162,13 @@ SettingItem
|
|||
property: "text"
|
||||
value:
|
||||
{
|
||||
if (input.activeFocus)
|
||||
{
|
||||
// In QT6 using "when: !activeFocus" causes the value to be null when activeFocus becomes True
|
||||
// Since we want the value to stay the same when giving focus to the TextInput this is being used
|
||||
// in place of "when: !activeFocus"
|
||||
return input.text
|
||||
}
|
||||
// Stacklevels
|
||||
// 0: user -> unsaved change
|
||||
// 1: quality changes -> saved change
|
||||
|
@ -181,7 +188,6 @@ SettingItem
|
|||
return propertyProvider.properties.value
|
||||
}
|
||||
}
|
||||
when: !input.activeFocus
|
||||
}
|
||||
|
||||
MouseArea
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue