Skip to content

input: OK under a transparent pointer arrives as a click; turn it back into OK - #781

Merged
GLinnik21 merged 2 commits into
plxnative:mainfrom
dimitrije83:ok-after-hidden-pointer
Oct 15, 2026
Merged

GLinnik21 merged 2 commits into
plxnative:mainfrom
dimitrije83:ok-after-hidden-pointer

Conversation

@dimitrije83

Copy link
Copy Markdown
Contributor

What

On a set without SDL_webOSCursorVisibility (webOS 3.9.3's SDL 2.0.4, the case #642 fixed), the D-pad hides the pointer by swapping in a transparent cursor. The system still thinks its pointer is up, so the Magic Remote's OK button arrives as a pointer click at wherever the invisible pointer sits, not as an OK key. Arrow to a control in the player, press OK, and nothing opens. The click lands on whatever is under the hidden pointer instead.

app/input.rs::click_is_ok names the case: D-pad mode, pointer hidden, transparent-cursor set (boot::cursor_is_transparent). In that case the loop pushes an OK key-down for the button-down and an OK key-up for its button-up, so OK reaches the focused control by the key path. Motion past the D-pad gate still leaves D-pad mode first, so a deliberate click on a shown pointer stays a click. Sets with LG's call never get here: their OK arrives as a key already.

docs/remote-keys.md describes it beside the D-pad cursor gate.

Tested

  • On a TV: LG OLED55B7V-Z (2017, M16P, webOS platform release 3.9.3, firmware 06.10.65), FLAVOR=stable RELEASE=1. Before: Up, Right, Right to the … disc, then OK. The event log shows the three arrow keys, no OK key, and no overlay opens. After: the same presses open the menu (overlay=more), and pointer clicks after moving the remote still work.
  • make check: all 92 steps ok, 16,335 tests passed. cargo +nightly check --lib --no-default-features: ok. A unit test covers the rule's truth table.

…k into OK

On a set without SDL_webOSCursorVisibility (webOS 3.9.3, issue plxnative#642) the
D-pad hides the pointer with a transparent cursor, the system keeps its
pointer up, and the Magic Remote's OK arrives as a click at the invisible
pointer's position. In the player that click lands on the picture and
toggles pause instead of opening the focused control. Measured on an
OLED55B7V-Z, 3.9.3: Up, Right, Right, no OK key in the event log, and the
player paused. While the D-pad owns focus and the pointer is transparent,
a click is now pushed as an OK key-down and its release as the key-up.

Signed-off-by: Dimitrije Juras <[email protected]>
@GLinnik21
GLinnik21 merged commit f15b248 into plxnative:main Oct 15, 2026
11 checks passed
@GLinnik21

Copy link
Copy Markdown
Collaborator

Thanks a lot for this one! I don't have a TV on that old webOS, so I could only check the code, not run it. The code looks good, so it's merged. Your before/after test on the B7 was exactly what I needed.

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.

2 participants