Repository navigation
Pointer and wheel reach the loop as a HostEvent, and the cursor hide is the platform's - #1492
Merged
Merged
Conversation
…er hide moves behind Shell W5c of the platform plan (discussion #1460). The Magic Remote's pointer and the wheel were the last input the loop still read from SDL's raw bytes. The SDL decoder now turns a pointer motion, a button down and a button up into HostEvent::Pointer { x, y, edge } at authored 1920x1080 coordinates, and a wheel tick into HostEvent::Wheel { dy }, with the sdl2-compat carrier (the count at +32 as a float on the simulator, at +20 as an integer on the television, and why +20 decodes to 0 there) moved into the decoder unchanged. The loop's reaction (the D-pad motion gate, OK-as-click, the back-cursor sync, hover and focus, the recorder rows and the wheel's debounce) is the same code in the same order, now in ingest_pointer and ingest_wheel behind the one consumer, ingest_host_event. The tape, InputKind, the machines, tests/keytable.json and the FIFO and Lab pointer alphabet are untouched. The plan's Pointer { x, y, buttons, shown } is carried as { x, y, edge }: SDL gives the loop no buttons or shown field it reads (a held button is the loop's own state, set by the down and up edges; LG's own hide arrives as a key and a show is a motion), so inventing them would carry nothing. Coordinates are f32, so HostEvent no longer derives Eq. The Magic Remote hide (hide_cursor, cursor_is_transparent, show_cursor_after_motion, the cursor door and its remembered cursor) leaves app/boot.rs for the webOS port's own system.rs, with its tests, and the loop reaches it through Shell::hide_pointer, Shell::show_pointer_after_motion and Shell::hide_is_cursor_swap. WebosShell carries the webOS bodies verbatim; DesktopShell and the host-test shell answer as the simulator always did (no hide, not a swap). The hostsim gates on those functions go away, so the host builds the same cursor code as the television. Tests: the decode table for every pointer and wheel byte shape (both layouts, the +20 case), the D-pad gate at 119 and exactly 120 px, OK-as-click under a cursor swap against a real click, the hide and show counted on the platform's shell, the tape rows, the wheel's debounce, and the wheel:<dy> token through SDL's own queue. The W5b guard that armed a local Press nothing reached is replaced by one that observes the real press armed by a click and left alone by an unbound key. Prose: the main-thread token is minted by enter_application, which both entries reach through run_application, not by plex_run; the fuzz package's plx_media/hostsim is the host configuration of the layers below it, not the Feed backend's host sink. Co-Authored-By: Claude <noreply@anthropic.com>
…ay drop get their own tests The W5b guard that armed a local Press nothing reached could not fail; it now arms the dispatcher's real press with a click, sends an unbound key through the loop's key ingress and reads is_live (an abandoned press stays active while it springs back), with a direction key as the control that does abandon it. The wheel:<dy> token test follows the carrier of the SDL it runs on (sdl2-compat returns the count at +32, genuine SDL2 returns the bytes as pushed), so it holds on the Linux CI job too. A real pointer or wheel event under a controlled replay is dropped as a key is, and the live loop is the control. The implicit-machines audit's pointer to SHOWN_CURSOR says where it moved. Co-Authored-By: Claude <noreply@anthropic.com>
The counting shell and the loop's hide tests sat only behind the hostsim feature, so the default test build had no reader for them and no test of what the pointer machine asks of the shell. The swap shell is now pinned where no feature gate hides it, and the pointer machine's hide and show (the first direction key hides once, a motion shows once, Back's own hide is restored only when Back made it) are counted on it in both builds. Co-Authored-By: Claude <noreply@anthropic.com>
The doc audit of the W5c diff found sentences the change made untrue: remote-keys.md still said the unsupported-key invariant is graded twice and by a module that no longer observes the press, input.rs named a test that does not exist, module-layers.md listed the shell's consumers without the pointer's callers, system.rs called a block that lost its hostsim arms verbatim, and the fw-compat reviewer's prompt pointed at boot.rs for the cursor symbols that now resolve in system.rs. Two older claims that plex_run runs the loop and owns the boot gate now name run_and_shutdown and boot, where they live. The desktop platform's module doc is rewrapped. Co-Authored-By: Claude <noreply@anthropic.com>
… the loop The counting shell's pin called pump_bus to show that a shell call that is no pointer call is not counted, and check-deps's frame gate allows pump_bus, opaque_route and clear_opaque_region to be named only in app/run.rs. The pin now uses release_surface for that, which says the same thing and is not one of the three. Co-Authored-By: Claude <noreply@anthropic.com>
W8a's storage group (`storage: StorageHooks::NONE` and the test that the desktop keeps the account in files) and this branch's desktop pointer methods and their test now sit side by side in the desktop platform; the module doc names both. Nothing else conflicted. Co-Authored-By: Claude <noreply@anthropic.com>
…inter and wheel branch W6b's `Platform.media` (the `MediaBoot` the platform supplies, and `Platform::new` taking it as its fourth argument) and this branch's `Shell` pointer methods and `SwapShell` now sit together. Git merged them without a conflict, but the counting shell's platform still built a platform from three parts, so it passes `MediaBoot::HOST_TEST` like the host-test platform does. Co-Authored-By: Claude <noreply@anthropic.com>
GLinnik21
added a commit
that referenced
this pull request
Nov 20, 2026
…#1493) This is a docs follow-up to the platform plan (discussion #1460). It corrects the sentences that W8a (#1488, #1490, #1491) and W5c (#1492) made false. It is prose only, plus one code comment. - rust-modules/plex/src/plex/CLAUDE.md and the session/persistence.rs module doc: - Seven public dispatchers hand the authority and NativeTransport to a *_via form. - cleanup_temporaries goes through cleanup_temporaries_for(authority) with no transport. Its Helper arm sweeps nothing. - docs/module-layers.md: - L15e reads "W5a to W5c and W6b landed". - L15g reads "W8a started" (#1488, #1490, #1491). - docs/platform-ports.md: - F39 says telemetry was re-keyed first, in #1490. - In Target shape 4, the gate sits above the storage-authority selection, not a target_arch selection. - The HostEvent list gains an "As landed (W5c)" note: Pointer { x, y, edge } and Wheel { dy }, with no buttons or shown field. - rust-modules/os/src/storage/mod.rs: the comment on StoreError's allow(dead_code) no longer claims a compiled-out half. Both arms compile on every build. No variant warns without the allow, because the enum is public and the storage module allows dead_code. The attribute is unchanged. Two review minors are left for W6's docs, which edit the same row: - The L15g row does not name telemetry's nine native.rs crash-capture sites, the follow-up for Tizen ARM retail builds. - The row does not say that the storage-authority part of W8a ran ahead of W7. plex/Cargo.toml's stale hostsim comment is certificate-pinned and goes with W8c.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Step W5c of the platform plan (discussion #1460). Pointer and wheel input now reach the loop as
HostEvents, as keys and text did in W5b (#1487). The Magic Remote's cursor hide moves behind the platform'sShell. webOS hides and shows the pointer exactly as before. The desktop and the host-test platform hide nothing, which is what the simulator already did.What changes
HostEvent::Pointer { x: f32, y: f32, edge: PointerEdge }, wherePointerEdgeisMove,DownorUp, andHostEvent::Wheel { dy: i32 }.decode_host_event(app/events.rs) mapsSDL_MOUSEMOTION,SDL_MOUSEBUTTONDOWNandSDL_MOUSEBUTTONUPtoPointer, andSDL_MOUSEWHEELtoWheel.plx_base::surface::to_logical. At 1920x1080 that is the identity. Because they are floats,HostEventkeepsPartialEqbut losesEq.decode_wheel_dykeeps the existing wheel-offset handling and its comment. Under hostsim it reads the float at +32 and rounds it; otherwise it reads theSint32at +20.The plan proposed
Pointer { x, y, buttons, shown }. This lands withoutbuttonsandshown:the_edge_is_the_event_type_whatever_the_button_bytes_saypins that.cur_hidden, not event data.ingest_host_event(app/run.rs) handles both events throughingest_pointer_{motion,down,up}andingest_wheel. Effect order, the recorder rows (enc_pointer, and("wheel", 0, dy)after the 250 ms debounce) and the drop of real input under a controlled replay do not change.The cursor hide.
app/boot.rsgives uphide_cursor,cursor_is_transparent,show_cursor_after_motion,hide_through,show_through,SHOWN_CURSOR,CursorDoorandcursor_doortorust-modules/src/system.rs.systemalready sits in[platform webos], so no module is added.Shellgainshide_pointer,show_pointer_after_motionandhide_is_cursor_swap.WebosShellforwards each one tosystem.DesktopShellandHostShellare no-ops and answerhide_is_cursor_swapfalse. A test-onlySwapShellcounts its calls and says true.input.rs,playback.rs(through a newBridge::shell()) andrun.rsreach the hide through the shell.fns, andwl_symis renamedself_sym.SHOWN_CURSORmoves with no new ledger line.boot.rskeeps the pre-SDL_Initcursor sleep hint (webos3_cursor_sleep_hint,cursor_sleep_hint, its ownself_sym) and its source-order pins.feature = "hostsim"occurrences. The ones on the moved cursor functions go from 13 to 0. Across the touched files the count goes from 99 to 89:boot.rsrun.rsevents.rsevents.rsrises by one productioncfg!indecode_wheel_dyand three test-only gates.Carried from Keys and text reach the loop as a HostEvent with a canonical Action #1487's review:
press()helper's vacuousarmedassertions now observe the real press withis_live, with a direction-key control.plex_run" prose is fixed. The main-thread token is minted inenter_application. The fix coversbase/src/task.rs,media/src/player/{adapter,mod}.rs,dev.rs,docs/async-model-decision.md,docs/agent-reference.mdanddocs/remote-keys.md.docs/agent-reference.mdfuzz wording is fixed.Tests
pointer_event_tests: the edge and position; the edge ignoring the button bytes; the synthesized bytes round-tripping; the wheel offset at +20; the FIFO token's television-shaped wheel decoding to 0 under hostsim; and, under hostsim, a fractional trackpad tick rounding to whole ticks.host_event_tests.lifecycle_regression_tests, hostsim):system::cursor_door_tests, five tests, not gated;input::pointer_hide_tests;platform.rsandplatform_desktop.rs.No mutant exists for the three one-line
WebosShellforwards or for thesync_back_cursorcall inplayback.rs, because the host cannot observe them.Three more call sites are moved verbatim but no test guards them:
run.rs'splayback_tick(shell.hide_pointer()after 3000 ms without motion);host_background'ssync_back_cursor;controlled_key_input'snote_cursor_motion.SwapShellcould now observe them, but no test drives those paths on it. Deleting any one of them fails no test.Results on the committed tree at 17d0574, after merging main at f7038a8 (W6b #1489, which contains #1488 and #1490):
test result: ok. 1781 passed; 0 failed; 0 ignored; 0 measured; 2 filtered outtest result: ok. 1514 passed; 0 failed; 0 ignored; 0 measured; 1 filtered outmake test-hostsim T=uri_boot:test result: ok. 29 passed; 0 failed; 0 ignored; 0 measured; 1754 filtered outmake test-crate C=plxnative-modules:T=port::tests:test result: ok. 2 passed; 0 failed; 0 ignored; 0 measured; 1513 filtered outT=pointer:test result: ok. 18 passed; 0 failed; 0 ignored; 0 measured; 1497 filtered outT=cursor_door:test result: ok. 5 passed; 0 failed; 0 ignored; 0 measured; 1510 filtered outmake check-nodef: exit 0.make lintwas exit 0 on b7ec914; the only edit since the merge is a test-only line.make check-replay:6 fixtures, 12 replays, SAME=4 REFUSED_EXPECTED=8 unexpected=0SwapShell::platform()passesMediaBoot::HOST_TESTto W6b's four-argumentPlatform::new.the_host_test_platform_answers_nothing_and_says_sodestructures all fourPlatformfields.Results on b0ad245, before the merge:
test result: ok. 1774 passed; 0 failed; 0 ignored; 0 measured; 2 filtered outplayer_owner_events_record_and_replay_through_the_actual_app_hostandan_unregistered_product_screen_uses_generic_navigation_and_actual_store_effects.test result: ok. 1509 passed; 0 failed; 0 ignored; 0 measured; 1 filtered outmake check-replay:6 fixtures, 12 replays, SAME=4 REFUSED_EXPECTED=8 unexpected=0tests/keytable.jsonis unchanged.ci/check-deps.sh,ci/check-module-layers.py,ci/check-ledger-ratchet.pyandci/check-statics.share green.ci/test_readonly_generated.pyandci/test_readonly_dependencies.pypass.ci/, to any Cargo file or.cargo, or torust-modules/src/lib.rs.fw-compat-reviewer: no findings. It graded the source only. The sameSDL_*symbols are looked up in the same order, with the same hide method per firmware release. The 3.x releases sit below the graded floor.doc-claim-auditor: five findings, all fixed.Not covered
WebosShellforwards, and the Back sync inplayback.rs.wheel:<dy>FIFO token. It builds the television's +20 layout, so under hostsim it decodes to 0. This was already true before this PR, and a test now pins it.🤖 Generated with Claude Code