Fix text input on kiosk: add keycodeToChar fallback for email/license pages
The kiosk lacks an input method framework, so SDL2 never generates TextInputEvent. The WiFi password page already had a keycodeToChar fallback but email and license key pages did not — characters were never appended to inputText. Also removes excessive debug logging from the previous commit. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 4.6
parent
8b0cf81e85
commit
df5e64d38a
@@ -378,17 +378,7 @@ func (app *Application) handleEvents() {
|
||||
app.running = false
|
||||
return
|
||||
|
||||
case *sdl.TextInputEvent:
|
||||
logger.Info("[EVENT] TextInputEvent: text=%q, IsTextInputActive=%v", e.GetText(), sdl.IsTextInputActive())
|
||||
|
||||
case *sdl.KeyboardEvent:
|
||||
eventType := "KEYDOWN"
|
||||
if e.Type == sdl.KEYUP {
|
||||
eventType = "KEYUP"
|
||||
}
|
||||
logger.Info("[EVENT] KeyboardEvent: type=%s, sym=%d (%s), scancode=%d, mod=0x%04x, IsTextInputActive=%v",
|
||||
eventType, e.Keysym.Sym, sdl.GetKeyName(e.Keysym.Sym), e.Keysym.Scancode, e.Keysym.Mod, sdl.IsTextInputActive())
|
||||
|
||||
if e.Type == sdl.KEYDOWN && e.Repeat == 0 {
|
||||
isCtrlPressed := (e.Keysym.Mod&sdl.KMOD_CTRL) != 0 || (e.Keysym.Mod&sdl.KMOD_GUI) != 0
|
||||
if e.Keysym.Sym == sdl.K_c && isCtrlPressed {
|
||||
|
||||
Reference in New Issue
Block a user