mirror of
https://github.com/lubosz/overte.git
synced 2025-04-19 17:03:43 +02:00
"The button changes from Confirm to overwrite, and the button style changes from blue to red"
This commit is contained in:
parent
24885c3512
commit
2581157794
1 changed files with 19 additions and 1 deletions
|
@ -119,8 +119,11 @@ Rectangle {
|
|||
anchors.top: parent.bottom;
|
||||
anchors.topMargin: 2
|
||||
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right;
|
||||
text: 'Favorite name exists'
|
||||
anchors.rightMargin: -contentContainer.anchors.rightMargin // allow text to render beyond favorite input text
|
||||
wrapMode: Text.WordWrap
|
||||
text: 'Favorite name exists. Overwrite existing favorite?'
|
||||
size: 15
|
||||
color: 'red'
|
||||
visible: {
|
||||
|
@ -160,6 +163,21 @@ Rectangle {
|
|||
yesText: root.button2text
|
||||
noText: root.button1text
|
||||
|
||||
Binding on yesButton.text {
|
||||
when: wrongName.visible
|
||||
value: "OVERWRITE";
|
||||
}
|
||||
|
||||
Binding on yesButton.color {
|
||||
when: wrongName.visible
|
||||
value: hifi.buttons.red;
|
||||
}
|
||||
|
||||
Binding on yesButton.colorScheme {
|
||||
when: wrongName.visible
|
||||
value: hifi.colorSchemes.dark;
|
||||
}
|
||||
|
||||
onYesClicked: function() {
|
||||
if(onSaveClicked) {
|
||||
onSaveClicked();
|
||||
|
|
Loading…
Reference in a new issue