Network/Wi-Fi: many fixes and robustness improvements
- proper detection when password is wrong - prevent a new connection while already connecting to a network - new mechanism to skip scan results if a new scan is incoming (avoid UI discrepancies)
This commit is contained in:
parent
4ba0f8d958
commit
ba33451957
2 changed files with 67 additions and 15 deletions
|
|
@ -397,6 +397,7 @@ NPanel {
|
|||
}
|
||||
outlined: !hovered
|
||||
fontSize: Style.fontSizeXS * scaling
|
||||
enabled: !NetworkService.connecting
|
||||
onClicked: {
|
||||
if (modelData.existing || modelData.cached || !NetworkService.isSecured(modelData.security)) {
|
||||
NetworkService.connect(modelData.ssid)
|
||||
|
|
@ -461,7 +462,7 @@ NPanel {
|
|||
onVisibleChanged: if (visible)
|
||||
forceActiveFocus()
|
||||
onAccepted: {
|
||||
if (text) {
|
||||
if (text && !NetworkService.connecting) {
|
||||
NetworkService.connect(passwordSsid, text)
|
||||
passwordSsid = ""
|
||||
passwordInput = ""
|
||||
|
|
@ -481,7 +482,7 @@ NPanel {
|
|||
NButton {
|
||||
text: "Connect"
|
||||
fontSize: Style.fontSizeXXS * scaling
|
||||
enabled: passwordInput.length > 0
|
||||
enabled: passwordInput.length > 0 && !NetworkService.connecting
|
||||
outlined: true
|
||||
onClicked: {
|
||||
NetworkService.connect(passwordSsid, passwordInput)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue