Method: Event#wheel
- Defined in:
- lib/source/redshift/event.rb
#wheel ⇒ Object
call-seq:
evnt.wheel -> numeric or nil
Returns a floating point number representing the velocity of the wheel movement executed during evnt. Positive values indicate upward scrolling, negative values indicate downward scrolling. Returns nil if evnt did not involve the mouse wheel.
Document['#example'].listen(:mouse_wheel) {|element, event| puts event.wheel }
wheeling the mousewheel downward by a single “click” over element ‘#example’ produces:
-1
309 310 311 |
# File 'lib/source/redshift/event.rb', line 309 def wheel `this.__wheel__` end |