add navigation using enter + buttons will be clicked if enter (if but… (#556)
Enter navigation
This commit is contained in:
parent
16db23c159
commit
698cfe910c
32 changed files with 3655 additions and 4373 deletions
|
|
@ -13,6 +13,8 @@ import "../Components"
|
|||
PageType {
|
||||
id: root
|
||||
|
||||
defaultActiveFocusItem: primaryDns.textField
|
||||
|
||||
BackButtonType {
|
||||
id: backButton
|
||||
|
||||
|
|
@ -68,6 +70,8 @@ PageType {
|
|||
textField.validator: RegularExpressionValidator {
|
||||
regularExpression: InstallController.ipAddressRegExp()
|
||||
}
|
||||
|
||||
KeyNavigation.tab: secondaryDns.textField
|
||||
}
|
||||
|
||||
TextFieldWithHeaderType {
|
||||
|
|
@ -80,6 +84,8 @@ PageType {
|
|||
textField.validator: RegularExpressionValidator {
|
||||
regularExpression: InstallController.ipAddressRegExp()
|
||||
}
|
||||
|
||||
KeyNavigation.tab: saveButton
|
||||
}
|
||||
|
||||
BasicButtonType {
|
||||
|
|
@ -94,7 +100,7 @@ PageType {
|
|||
|
||||
text: qsTr("Restore default")
|
||||
|
||||
onClicked: function() {
|
||||
clickedFunc: function() {
|
||||
var headerText = qsTr("Restore default DNS settings?")
|
||||
var yesButtonText = qsTr("Continue")
|
||||
var noButtonText = qsTr("Cancel")
|
||||
|
|
@ -114,11 +120,13 @@ PageType {
|
|||
}
|
||||
|
||||
BasicButtonType {
|
||||
id: saveButton
|
||||
|
||||
Layout.fillWidth: true
|
||||
|
||||
text: qsTr("Save")
|
||||
|
||||
onClicked: function() {
|
||||
clickedFunc: function() {
|
||||
if (primaryDns.textFieldText !== SettingsController.primaryDns) {
|
||||
SettingsController.primaryDns = primaryDns.textFieldText
|
||||
}
|
||||
|
|
@ -130,4 +138,5 @@ PageType {
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue