Keystroke Handling
From Documentation
Keystroke handling is generic. Any component inherited from XulElement can handle the key event in the same way.
ENTER and ESC
To handle ENTER, you could listen to the onOK event (notice O and K are both in upper case). To handle ESC, you could listen to the onCancel event. For example,
<grid id="form" apply="foo.Login">
<rows>
<row>Username: <textbox id="username"/></row>
<row>Password: <textbox id="password" type="password"/></row>
<row><button label="Login" forward="form.onOK"/><button label="Reset" forward="form.onCancel"/></row>
</rows>
</grid>
Control Keys
Version History
Version | Date | Content |
---|---|---|