Hello ,
How it possible to do a click action in button , when I pressed “Enter” on keyboard in text field ?
Thanks
Hello ,
How it possible to do a click action in button , when I pressed “Enter” on keyboard in text field ?
Thanks
This solution is almost that I want :
{view: “text”, , click : doAction, hotkey :“enter”}
But when I click in field text, the action is executed and I just want when I pressed “enter”
Thanks for your response.
It is ok if all my page has just one button, but if I have two forms and if I want that button get key “enter” for text field of just one form , how to do that ?
Hotkey watches keypress globally, but you can setonKeyPress
event to each ui.text:
on:{
onkeypress:function(keycode, e){
if (keycode == 13) doAction();
}
}