[TextField] Bind to TextField length instead of text
Copying strings in QML is expensive. REVIEW: 128550
This commit is contained in:
parent
16f8257068
commit
42193ae631
@ -80,7 +80,7 @@ QtControls.TextField {
|
||||
source: "edit-clear-locationbar-rtl"
|
||||
height: Math.max(parent.height*0.8, units.iconSizes.small)
|
||||
width: height
|
||||
opacity: (textField.text != "" && clearButtonShown && textField.enabled) ? 1 : 0
|
||||
opacity: (textField.length > 0 && clearButtonShown && textField.enabled) ? 1 : 0
|
||||
Behavior on opacity {
|
||||
NumberAnimation {
|
||||
duration: units.longDuration
|
||||
|
Loading…
Reference in New Issue
Block a user