Change EYE button to SHOW, add WiFi reconnection after saving credentials

This commit is contained in:
Chad 2026-03-31 18:29:13 -05:00
parent 6c15896fdb
commit aee3770d20

View file

@ -904,7 +904,7 @@ void drawWifiPasswordScreen() {
lcd.setTextColor(TFT_WHITE, showPasswordPlain ? TFT_ORANGE : TFT_GRAY); lcd.setTextColor(TFT_WHITE, showPasswordPlain ? TFT_ORANGE : TFT_GRAY);
lcd.setFont(&fonts::DejaVu12); lcd.setFont(&fonts::DejaVu12);
lcd.setTextDatum(textdatum_t::middle_center); lcd.setTextDatum(textdatum_t::middle_center);
lcd.drawString("EYE", SCREEN_WIDTH - 75, 125); lcd.drawString("SHOW", SCREEN_WIDTH - 75, 125);
drawFullKeyboard(170, keyboardSymbols); drawFullKeyboard(170, keyboardSymbols);
@ -1167,6 +1167,10 @@ bool handleWifiPasswordTouch(int32_t x, int32_t y) {
preferences.putString("ssid", selectedSSID); preferences.putString("ssid", selectedSSID);
preferences.putString("password", wifiPassword); preferences.putString("password", wifiPassword);
preferences.end(); preferences.end();
WiFi.mode(WIFI_STA);
WiFi.begin(selectedSSID.c_str(), wifiPassword.c_str());
currentScreen = SCREEN_DASHBOARD; currentScreen = SCREEN_DASHBOARD;
needsRefresh = true; needsRefresh = true;
return true; return true;