ScrollListener
The ScrollListener
class sets up a listener that handles window scroll
events.
Constructor Summary
Public Constructor | ||
public |
constructor(callback: Function) |
Method Summary
Public Methods | ||
public |
start() Start listening to and handling the window's scroll position. |
|
public |
stop() Stop listening to and handling the window's scroll position. |
|
public |
update() Run the callback, whether there was a scroll event or not. |
Protected Methods | ||
protected |
loop() On each animation frame, as long as the listener is active, run the
|
Public Constructors
Public Methods
Protected Methods
protected loop() source
On each animation frame, as long as the listener is active, run the
update
method.