1 | svoid automate_typeChar(char c) { |
2 | assertAutomationAllowed(); |
3 | int kc = KeyEvent.getExtendedKeyCodeForChar(Character.toLowerCase(c)); |
4 | if (kc == KeyEvent.VK_UNDEFINED) ret with print("No keycode for " + c); |
5 | awtRobot().keyPress(kc); |
6 | awtRobot().keyRelease(kc); |
7 | } |
Began life as a copy of #1010755
download show line numbers debug dex old transpilations
Travelled to 6 computer(s): bhatertpkbcr, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tvejysmllsmz, vouqrxazstgt
No comments. add comment
Snippet ID: | #1025317 |
Snippet name: | automate_typeChar |
Eternal ID of this version: | #1025317/3 |
Text MD5: | c10727278c1a3b928aada760401eac96 |
Author: | stefan |
Category: | javax / automation |
Type: | JavaX fragment (include) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2019-09-21 22:46:54 |
Source code size: | 273 bytes / 7 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 244 / 261 |
Version history: | 2 change(s) |
Referenced in: | [show references] |