Window
MMO.core · 1 symbol · generated 30 Sep 2026
Window
Window.js:11window
- Namespace
MMO.core- Extends
- EventEmitter
Index
| width readonly accessor | ||
| height readonly accessor | ||
| scrollX readonly accessor | ||
| scrollY readonly accessor | ||
| scrollHeight readonly accessor | ||
| scrollWidth readonly accessor | ||
| device readonly accessor | The breakpoint name the stylesheet publishes through body::after { content }. | |
| constructor(window, guid) | ||
| toString() | ||
| getSize() | A snapshot of every geometry value at once, as carried by the resize event. | |
| lockRun() | Lock the run queue, so it is not put on animation frame until it is unlocked | |
| unlockRun() | Unlock the run queue | |
| createAnimationFrame() | Internal function to create the animation frame that consumes the run queue | |
| run(func, args) | Calls requestAnimationFrame with a callback | |
| loopRun() generator | Yield the callbacks still waiting in the run queue, from the current position. | |
| cancelRun(func) | Cancel all or a specific callback being animated | |
| onError(error) | Private function calls by browser when an error is thrown and not caught | |
| onGoto() | Private function calls by browser when url's hash changed For an html element to be focusable, don't forget to add the attribute tab_index="-1" | |
| onResize() | Private function calls by browser when dom is resized | |
| onScroll(e) | Normalise event scroll |
Properties7
width
readonlyaccessorWindow.js:181height
readonlyaccessorWindow.js:189- Type
number
scrollX
readonlyaccessorWindow.js:194- Type
number
scrollY
readonlyaccessorWindow.js:199- Type
number
scrollHeight
readonlyaccessorWindow.js:204- Type
number
scrollWidth
readonlyaccessorWindow.js:211- Type
number
device
readonlyaccessorWindow.js:222The breakpoint name the stylesheet publishes through body::after { content }.
- Type
string
Methods13
constructor(window, guid)
Window.js:12| window | ||
| guid = null |
toString()
Window.js:173| returns | string | the window's GUID name |
getSize()
Window.js:231A snapshot of every geometry value at once, as carried by the resize event.
| returns | width, height, scrollWidth, scrollHeight, scrollX, scrollY, device | } |
lockRun()
Window.js:249Lock the run queue, so it is not put on animation frame until it is unlocked
unlockRun()
Window.js:256Unlock the run queue
createAnimationFrame()
Window.js:268Internal function to create the animation frame that consumes the run queue
run(func, args)
Window.js:294Calls requestAnimationFrame with a callback
| func | Function | MMO.core.EventBinding | |
| ...args | ... | the arguments to pass to the function |
loopRun()
generatorWindow.js:320Yield the callbacks still waiting in the run queue, from the current position.
cancelRun(func)
Window.js:330Cancel all or a specific callback being animated
| func = null | Function | MMO.core.EventBinding | null |
onError(error)
Window.js:354Private function calls by browser when an error is thrown and not caught
| error |
onGoto()
Window.js:381Private function calls by browser when url's hash changed For an html element to be focusable, don't forget to add the attribute tab_index="-1"
onResize()
Window.js:402Private function calls by browser when dom is resized
onScroll(e)
Window.js:417Normalise event scroll
| e |