Skip to content

Add Expert Mode debug screen for raw getevent output (#2081)#2116

Open
keymapper-ai wants to merge 5 commits intodevelopfrom
claude/2081-getevent-debug-screen
Open

Add Expert Mode debug screen for raw getevent output (#2081)#2116
keymapper-ai wants to merge 5 commits intodevelopfrom
claude/2081-getevent-debug-screen

Conversation

@keymapper-ai
Copy link
Copy Markdown
Collaborator

Summary

Implements #2081 — adds a debug screen accessible from Settings > Debugging that displays raw getevent output via the system bridge.

  • Loads device info on open: runs getevent -il automatically when Expert Mode is connected, showing all input devices
  • Record/stop: a FAB (red when recording) starts getevent -lt in the background; tapping stop kills the process and appends captured events to the output
  • Bottom app bar actions: back, copy to clipboard, save/share to file, and clear
  • Expert Mode gate: shows an informational card with a "Setup Expert Mode" button when the system bridge is not connected
  • Monospace output: text is rendered in a scrollable, selectable, monospace font and auto-scrolls to the bottom as new output arrives

Files changed

File Change
base/.../debug/GetEventViewModel.kt New — HiltViewModel managing state, shell execution, clipboard, file sharing
base/.../debug/GetEventScreen.kt New — Compose screen with top bar, content area, bottom bar
base/.../navigation/NavDestination.kt Added GetEvent destination
base/.../BaseMainNavHost.kt Registered GetEvent composable route
base/.../settings/SettingsViewModel.kt Added onGetEventClick() navigation handler
base/.../settings/SettingsScreen.kt Added "Expert Mode debug" button in Debugging section
base/.../res/values/strings.xml Added getevent-related strings

Test plan

  • Navigate to Settings > Debugging — "Expert Mode debug" entry appears
  • Tap it → screen opens showing a loading indicator, then populates with getevent -il device list
  • Press record FAB → button turns red/stop, getevent -lt events stream in
  • Press stop → recording ends, events appended to output
  • Press clear → output is cleared
  • Copy button → output placed in clipboard
  • Save button → Android share sheet appears
  • Back button → returns to Settings
  • With Expert Mode disabled → informational card shown with "Setup Expert Mode" button

Creates a new debug screen accessible from Settings > Debugging that shows
raw getevent output using the system bridge. Displays getevent -il on open
(device info) and supports recording getevent -lt events via a red record/stop
FAB. Output can be copied to clipboard or saved to file. Requires Expert Mode.

https://claude.ai/code/session_01QG84he6gs9tqgY9QrFhtKb
@sds100 sds100 self-requested a review April 14, 2026 08:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants