actionscript 2 - Flash - Keyboard event doesn't fire -


i'm working on website multiple flash animations. 1 of them visual numeric keyboard want catch physical keystrokes also.

the problem when try adobe flash works great when it's running in browser (firefox or ie11) physical inputs not caught.

here keylistner (in as2 sorry ^^'):

clavierlisten = new object(); clavierlisten.onkeydown = function() {     keya = key.getcode();     if (keya>=48 && keya<=57) {         switch (keya) {         case 48: chiffrage(0); btn_clavier0.gotoandplay(2); break;         case 49: chiffrage(1); btn_clavier1.gotoandplay(2); break;         case 50: chiffrage(2); btn_clavier2.gotoandplay(2); break;         case 51: chiffrage(3); btn_clavier3.gotoandplay(2); break;         case 52: chiffrage(4); btn_clavier4.gotoandplay(2); break;         case 53: chiffrage(5); btn_clavier5.gotoandplay(2); break;         case 54: chiffrage(6); btn_clavier6.gotoandplay(2); break;         case 55: chiffrage(7); btn_clavier7.gotoandplay(2); break;         case 56: chiffrage(8); btn_clavier8.gotoandplay(2); break;         case 57: chiffrage(9); btn_clavier9.gotoandplay(2); break;         }     }  } key.addlistener(clavierlisten); 

is there particular configuration necessary make work in browser ?


Comments

Popular posts from this blog

sublimetext3 - what keyboard shortcut is to comment/uncomment for this script tag in sublime -

java - No use of nillable="0" in SOAP Webservice -

ubuntu - Laravel 5.2 quickstart guide gives Not Found Error -