SethRobinson / proton

Proton SDK: Seth's GL/GLES messy multi-platform C++ game SDK. Can output to Windows, OS X, iOS, Android, Linux (Raspbian too), HTML5, Flash
Other
79 stars 16 forks source link

Fixes for scroll wheel in ScrollComponent #34

Open mar4ello6 opened 9 months ago

mar4ello6 commented 9 months ago

Now, the scroll wheel will only scroll in the entity where the cursor is located. Before, it scrolled every Entity with ScrollComponent existing. The scroll bar now also recognizes the scroll wheel.

iProgramMC commented 7 months ago

I disagree with using Windows APIs directly within Proton, even if it's behind an ifdef-guard. I'd use extern variables or functions to get the x/y position of the cursor, and hook WM_MOUSEMOVE to update it.

I don't see why the scroll bar didn't fade in when scrolling. This is a good change.

SethRobinson commented 3 months ago

Appreciate the patch (sorry for the delay) - won't merge right now though, some things have changed since this was written (I added/changed some scroll wheel stuff so my SlideShow project could zoom in/out, it it may need to be tweaked to use that, hope to take a closer look later