pdjstone / arculator-wasm

Arculator
http://b-em.bbcmicro.com/arculator
GNU General Public License v2.0
13 stars 1 forks source link

setmousebounds not called when launching The Hacker #15

Open pdjstone opened 1 month ago

pdjstone commented 1 month ago

Normally when switching screen modes, the VIDC code calls update_screen_geometry, and at some point later arm.c intercepts OS_Word 21,1 and calls setmousebounds.

When launching The Hacker (see https://www.doxdesk.com/software/) from an A5000 in desktop mode 27, it switches to mode 12 (I think) and update_screen_geometry is called. But no call to setmousebounds is made, so the the top ~16px of the screen cannot be reached with the mouse when in absolute mode mode.

Mode 27:
update_screen_geometry lb=0 tb=0 sw=640 sh=480 arculator.js:2400:8
Resizing window to 640, 480
 setmousebounds (0,0) (1279,959)

Mode 15:
[1553812004]: update_screen_geometry lb=0 tb=0 sw=640 sh=776 arculator.js:2400:8
[1554215405]: Resizing window to 640, 776 arculator.js:2400:8
[1554310139]: update_screen_geometry lb=0 tb=0 sw=640 sh=512 arculator.js:2400:8
[1554640405]: Resizing window to 640, 512
[1557785461]: setmousebounds (0,0) (1279,1023)

When switching to The Hacker (mode 12ish?)

[1344342259]: update_screen_geometry lb=0 tb=0 sw=640 sh=516 arculator.js:2400:8
[1344673108]: Resizing window to 640, 516 arculator.js:2400:8
[1344841455]: update_screen_geometry lb=0 tb=0 sw=640 sh=512 arculator.js:2400:8
[1345098108]: sound_emscripten - OnCanvasClick 2 arculator.js:2400:8
[1345098108]: sound_emscripten - OnCanvasClick 2 arculator.js:2400:8
[1345098108]: Resizing window to 640, 512

no setmousebounds
pdjstone commented 1 month ago

Potentially we could reset the mouse bounding box to the full screen size every time the screen geometry changes.