mirror of
https://github.com/trebonian/visual6502.git
synced 2024-12-28 20:29:18 +00:00
handleKey(): if .charCode is undefined, use .keyCode (Opera compatible.)
This commit is contained in:
parent
fc46e50289
commit
6cdbfc0c15
@ -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