Added some useful JS procs to DOM module.
This commit is contained in:
parent
07b6a32d7a
commit
2e5b19e479
1 changed files with 5 additions and 0 deletions
|
|
@ -402,7 +402,9 @@ proc routeEvent*(w: Window, event: Event)
|
|||
proc scrollBy*(w: Window, x, y: int)
|
||||
proc scrollTo*(w: Window, x, y: int)
|
||||
proc setInterval*(w: Window, code: cstring, pause: int): ref TInterval
|
||||
proc setInterval*(w: Window, function: proc (), pause: int): ref TInterval
|
||||
proc setTimeout*(w: Window, code: cstring, pause: int): ref TTimeOut
|
||||
proc setTimeout*(w: Window, function: proc (), pause: int): ref TInterval
|
||||
proc stop*(w: Window)
|
||||
|
||||
# Node "methods"
|
||||
|
|
@ -481,6 +483,9 @@ proc getAttribute*(s: Style, attr: cstring, caseSensitive=false): cstring
|
|||
proc removeAttribute*(s: Style, attr: cstring, caseSensitive=false)
|
||||
proc setAttribute*(s: Style, attr, value: cstring, caseSensitive=false)
|
||||
|
||||
# Event "methods"
|
||||
proc preventDefault*(ev: Event)
|
||||
|
||||
{.pop.}
|
||||
|
||||
var
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue