From d00f540dcaa3617312738e92e2c7afa9687139cf Mon Sep 17 00:00:00 2001 From: fvanroie <15969459+fvanroie@users.noreply.github.com> Date: Tue, 12 Jan 2021 14:21:48 +0100 Subject: [PATCH] Code sweep --- src/hasp_oobe.cpp | 24 ++++++++++-------------- 1 file changed, 10 insertions(+), 14 deletions(-) diff --git a/src/hasp_oobe.cpp b/src/hasp_oobe.cpp index a7b11a2f..4cdfcaad 100644 --- a/src/hasp_oobe.cpp +++ b/src/hasp_oobe.cpp @@ -80,20 +80,16 @@ static void kb_event_cb(lv_obj_t * event_kb, lv_event_t event) Log.notice(TAG_OOBE, F("SSID %s validated"), ssid); dispatch_reboot(true); } - -} -else if(event == LV_EVENT_CANCEL) -{ - oobeSetPage(0); - lv_obj_set_click(lv_disp_get_layer_sys(NULL), true); -} -else -{ - /* prevent double presses, swipes and ghost press on tiny keyboard */ - if(event == LV_EVENT_RELEASED) lv_keyboard_def_event_cb(event_kb, LV_EVENT_VALUE_CHANGED); - /* Just call the regular event handler */ - // lv_kb_def_event_cb(event_kb, event); -} + + } else if(event == LV_EVENT_CANCEL) { + oobeSetPage(0); + lv_obj_set_click(lv_disp_get_layer_sys(NULL), true); + } else { + /* prevent double presses, swipes and ghost press on tiny keyboard */ + if(event == LV_EVENT_RELEASED) lv_keyboard_def_event_cb(event_kb, LV_EVENT_VALUE_CHANGED); + /* Just call the regular event handler */ + // lv_kb_def_event_cb(event_kb, event); + } } static void ta_event_cb(lv_obj_t * ta, lv_event_t event) {