diff options
| author | jmoenig <jens@moenig.org> | 2014-05-20 09:29:19 +0200 |
|---|---|---|
| committer | jmoenig <jens@moenig.org> | 2014-05-20 09:29:19 +0200 |
| commit | 669d93a62967d88b4c4dd33b919737a386bf958a (patch) | |
| tree | 97048343ad86cc0beece78427271375d5b5e20ee | |
| parent | a53c189e4b379a262bc424be263c19290be18e6d (diff) | |
| download | snap-byow-669d93a62967d88b4c4dd33b919737a386bf958a.tar.gz snap-byow-669d93a62967d88b4c4dd33b919737a386bf958a.zip | |
Snap.html: Focus the world canvas on startup
so Snap reacts to keyboard events right away (without having to click
on the IDE first)
| -rwxr-xr-x | history.txt | 3 | ||||
| -rwxr-xr-x | snap.html | 1 |
2 files changed, 3 insertions, 1 deletions
diff --git a/history.txt b/history.txt index faf992d..960daf1 100755 --- a/history.txt +++ b/history.txt @@ -2128,4 +2128,5 @@ ______ 140520 ------ -* Morphic: Prevent default action for ctrl-/cmd-key events +* Morphic: Prevent default action for ctrl-/cmd-key event +* Snap.html: Focus the world canvas on startup, so Snap reacts to keyboard events right away @@ -22,6 +22,7 @@ var world; window.onload = function () { world = new WorldMorph(document.getElementById('world')); + world.worldCanvas.focus(); new IDE_Morph().openIn(world); setInterval(loop, 1); }; |
