mirror of
https://github.com/trebonian/visual6502.git
synced 2024-12-29 11:31:16 +00:00
handleKey(): if .charCode is undefined, use .keyCode (Opera compatible.)
This commit is contained in:
parent
78deb4aaa4
commit
1c66a8af28
@ -102,7 +102,7 @@ function setup_part3(){
|
|||||||
/////////////////////////
|
/////////////////////////
|
||||||
|
|
||||||
function handleKey(e){
|
function handleKey(e){
|
||||||
var c = e.charCode;
|
var c = e.charCode || e.keyCode;
|
||||||
c = String.fromCharCode(c);
|
c = String.fromCharCode(c);
|
||||||
if('zx<>?np'.indexOf(c)==-1) return;
|
if('zx<>?np'.indexOf(c)==-1) return;
|
||||||
if((c=='x' || c=='<') && zoom>1) setZoom(zoom/1.2);
|
if((c=='x' || c=='<') && zoom>1) setZoom(zoom/1.2);
|
||||||
|
Loading…
Reference in New Issue
Block a user