From 8633fc1e3bb95e57243698c8b5f216acfe3836cf Mon Sep 17 00:00:00 2001 From: eclipse-kura-bot <77626377+eclipse-kura-bot@users.noreply.github.com> Date: Wed, 27 Nov 2024 13:32:17 +0100 Subject: [PATCH] fix(web2): Fixed wireless mode selection [backport release-5.6.0] (#5590) fix(web2): Fixed wireless mode selection (#5583) Fixed wireless mode selection Signed-off-by: pierantoniomerlino (cherry picked from commit d4b7cfd5662d9c38a0b60a783ec435103e770268) Co-authored-by: Pierantonio Merlino --- .../web/client/ui/network/TabWirelessUi.java | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/kura/org.eclipse.kura.web2/src/main/java/org/eclipse/kura/web/client/ui/network/TabWirelessUi.java b/kura/org.eclipse.kura.web2/src/main/java/org/eclipse/kura/web/client/ui/network/TabWirelessUi.java index 9b0178074c..78df27f501 100644 --- a/kura/org.eclipse.kura.web2/src/main/java/org/eclipse/kura/web/client/ui/network/TabWirelessUi.java +++ b/kura/org.eclipse.kura.web2/src/main/java/org/eclipse/kura/web/client/ui/network/TabWirelessUi.java @@ -363,11 +363,11 @@ public TabWirelessUi(GwtSession currentSession, TabIp4Ui tcp4, TabIp6Ui tcp6, setPasswordValidation(); this.tcp4Tab.status.addChangeHandler(event -> { - evalActiveConfig(); + evalActiveConfig(); }); this.tcp6Tab.status.addChangeHandler(event -> { - evalActiveConfig(); + evalActiveConfig(); }); logger.info("Constructor done."); @@ -382,8 +382,8 @@ private void evalActiveConfig() { || !tcpIp6Status.equals(TabWirelessUi.this.tcp6Status); if (isStatusChanged) { - if (tcpIp4Status.equals(GwtNetIfStatus.netIPv4StatusEnabledWAN.name()) - || tcpIp6Status.equals(GwtNetIfStatus.netIPv6StatusEnabledWAN.name())) { + if (tcpIp4Status.equals(MessageUtils.get(GwtNetIfStatus.netIPv4StatusEnabledWAN.name())) + || tcpIp6Status.equals(MessageUtils.get(GwtNetIfStatus.netIPv6StatusEnabledWAN.name()))) { TabWirelessUi.this.activeConfig = TabWirelessUi.this.selectedNetIfConfig.getStationWifiConfig(); } else { TabWirelessUi.this.activeConfig = TabWirelessUi.this.selectedNetIfConfig.getActiveWifiConfig(); @@ -392,7 +392,7 @@ private void evalActiveConfig() { TabWirelessUi.this.tcp4Status = tcpIp4Status; TabWirelessUi.this.tcp6Status = tcpIp6Status; TabWirelessUi.this.netTabs.updateTabs(); - + update(); } } @@ -634,8 +634,8 @@ private void refreshForm() { String tcpip6Status = this.tcp6Tab.getStatus(); // Tcp/IP disabled - if (tcpip4Status.equals(GwtNetIfStatus.netIPv4StatusDisabled.getValue()) - && tcpip6Status.equals(GwtNetIfStatus.netIPv6StatusDisabled.getValue())) { + if (tcpip4Status.equals(MessageUtils.get(GwtNetIfStatus.netIPv4StatusDisabled.name())) + && tcpip6Status.equals(MessageUtils.get(GwtNetIfStatus.netIPv6StatusDisabled.name()))) { setForm(false); } else { setForm(true); @@ -749,7 +749,7 @@ private void refreshForm() { if (this.security.getSelectedItemText().equals(WIFI_SECURITY_WPA2_WPA3_ENTERPRISE_MESSAGE)) { this.password.setEnabled(false); } - + loadCountryCode(); }