extjs - Why are my key events not working -


why key events not working in following example? 'blur' event works, none of key events work on textfield (i tried 'keydown').

i tried using 'control' construct on controller well, doesn't work either.

ext.define('plus.view.mycontroller', {     extend: 'ext.app.viewcontroller',      alias: 'controller.mycontroller',     control: {         '#mytextfield': {             blur: function() {                 alert("oink")             },             keypress: function() {                 alert("moo")             },             keyup: function() {                 alert("quack")             }         }     } });  ext.define('plus.view.mainview', {     extend: 'ext.container.container',      items: [{         xtype: 'textfield',         id: 'mytextfield',         controller: 'mycontroller',         listeners: {             blur: function() {                 alert("oink 2")             },             keypress : function() {                 alert("moo 2")             },             keyup : function() {                 alert("quack 2")             }         }     }] });  ext.application({     name: 'plus',     autocreateviewport: 'mainview',     launch: function() {      } }); 

my fiddle here :

https://fiddle.sencha.com/#fiddle/1d5d

am missing obvious?

keypress , keyup these event fires if enablekeyevents set true. set , code work. created fidller code working. fiddle


Comments

Popular posts from this blog

sequelize.js - Sequelize group by with association includes id -

android - Robolectric "INTERNET permission is required" -

java - Android raising EPERM (Operation not permitted) when attempting to send UDP packet after network connection -