QB64-Phoenix-Edition / QB64pe

The QB64 Phoenix Edition Repository
https://qb64phoenix.com
Other
132 stars 26 forks source link

Mac: Command-Tabbing away from editor breaks touchpad and mousewheel scrolling #514

Open vivid-pixel opened 4 months ago

vivid-pixel commented 4 months ago

Describe the bug I'm on Sonoma 14.4.1 and QB64 PE 3.13.1. I found https://github.com/QB64-Phoenix-Edition/QB64pe/pull/468 which fixed what I imagine is the behavior of the scroll wheel inside any program created with QB64PE, but it appears this fix has not been implemented inside the editor as you cannot scroll code or help files without using keyboard keys or dragging the scrollbar.

To Reproduce Steps to reproduce the behavior:

  1. Load QB64 PE on MacOS and enter a command or keyword.
  2. Select the keyword and press F1 to open the help screen.
  3. Try using the mousewheel and touchpad to scroll. No effect.
  4. Go back to the editor and open a lengthy file of code.
  5. Try to scroll up and down in the editor with just the scroll wheel. Try the touchpad. Nothing!

Expected behavior It should scroll down a few lines at a time, like dragging the scrollbar with your cursor.

vivid-pixel commented 1 month ago

When I open the editor, this functionality does actually seem to work for a bit, scrolling up and down code or even through the F1 help. It looks like I can trigger the bug by pressing Command+Tab, then coming back to the QB64PE window. It fails to regain control of the touchpad, I guess?

a740g commented 1 week ago

I was not able to repro. this on macOS 13.7.1 (Intel). Unfortunately, that's the latest version of macOS my system can run. I tried using Cmd+Tab to switch between various windows and then back to QB64-PE IDE. Which versions of macOS did you test on? Is it running on an Intel or ARM mac?

vivid-pixel commented 1 week ago

Oh, interesting, this could be an Intel vs Apple Silicon difference. I am on the 13" M2 MacBook Air, now at version 15.1.

I can reproduce it quite easily, still. Not every Alt-Tab switch, but close to it, rare to get lucky. The only way I know to restore the scrolling with my touchpad is to close and reopen the editor. Not an issue affecting other applications, just to confirm.

I wonder how they'd feel about me testing this at an Apple Store or a Best Buy. Actually, I might be able to get my [remote] coworker to try.

vivid-pixel commented 1 week ago

I wonder if I stumbled upon a "fix" because I was prompted that Terminal needed access to monitor keystrokes, and I allowed it. It seems the "bug" could've been a security feature. The only thing I perhaps was doing differently to receive this prompt was screen mirroring to my TV as a 2nd screen with Airplay. I don't get why I've never seen that before.