diff options
author | Alon Zakai <azakai@mozilla.com> | 2010-11-28 20:57:28 -0800 |
---|---|---|
committer | Alon Zakai <azakai@mozilla.com> | 2010-11-28 20:57:28 -0800 |
commit | 70a93a3622a27ddbf26771dfe2cac8153686e036 (patch) | |
tree | 5b75e87037dc4232fc588e5c3455ac386c61e30c /src/library_sdl.js | |
parent | ea8ffc06440a840efaa72d2647d6be4cbdde1953 (diff) |
additional SDL stubs
Diffstat (limited to 'src/library_sdl.js')
-rw-r--r-- | src/library_sdl.js | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/src/library_sdl.js b/src/library_sdl.js index 9c21871a..c77a684c 100644 --- a/src/library_sdl.js +++ b/src/library_sdl.js @@ -29,6 +29,8 @@ mergeInto(Library, { SDL_SetVideoMode: function(width, height, depth, flags, canvas) { // ^^^^^^ a 'canvas' parameter is added here; supply a canvas from JS there + // or, define __CANVAS__. + canvas = canvas || __CANVAS__; var surf = _malloc(14*QUANTUM_SIZE); // SDL_Surface has 14 fields of quantum size SDL_SURFACES[surf] = { width: width, @@ -82,5 +84,18 @@ mergeInto(Library, { SDL_Delay: function(delay) { // No can do... unless you were a generator... }, + + SDL_WM_SetCaption: function(title, icon) { + title = Pointer_stringify(title); + icon = Pointer_stringify(icon); + }, + + SDL_EnableKeyRepeat: function(delay, interval) { + // TODO + }, + + SDL_ShowCursor: function(toggle) { + // TODO + }, }); |