rexrainbow / phaser3-rex-notes

Notes of phaser3 engine
MIT License
1.22k stars 263 forks source link

Mouse wheel on scroll #190

Closed Takyo closed 3 years ago

Takyo commented 3 years ago

How it should be done to make the mouse wheel work on scroll grid?

rexrainbow commented 3 years ago

New mouse-wheel-scrolling feature added.

See demos:

Default behavior is no mouse-wheel-scrolling.

Please download latest minify file of rexUI.

shishX86 commented 3 years ago

I tried to use example as is and have an error.

TS2345: Argument of type '{ x: number; y: number; width: number; height: number; background: RoundRectangle; text: BBCodeText; slider: { track: RoundRectangle; thumb: RoundRectangle; }; scroller: { ...; }; mouseWheelScroller: { ...; }; header: Label; footer: Label; }' is not assignable to parameter of type 'IConfig'. Object literal may only specify known properties, and 'mouseWheelScroller' does not exist in type 'IConfig'.

typescript npm 7.18.1 node 16.4.1 "phaser": "^3.55.2", "phaser3-rex-plugins": "^1.1.57"

I tried to compile as any type. In this case error has gone but mouse wheel not working. Is 1.1.57 version is latest?

Thanks!

rexrainbow commented 3 years ago

MouseWheelScroll feature is in NPM package 1.1.58, upgraded 2 hr before.

shishX86 commented 3 years ago

Wow! Extremely fast fix&answer! It works! Like! I mean star )

rexrainbow commented 3 years ago

Issue closed