Transpiled version (2544L) is out of date.
1 | !747 |
2 | !named thread |
3 | !awt { |
4 | |
5 | m { |
6 | static JLabel botName, botAddress; |
7 | static S currentPort; |
8 | |
9 | p { |
10 | makeAndroid3("Quick Talk Window."); |
11 | |
12 | showFrame("Quick Talk", stack( |
13 | botName = new JLabel("Bot name:"), |
14 | "Bot ID:", |
15 | botAddress = new JLabel("Bot address:"), |
16 | "Your input:", |
17 | new JTextField(), |
18 | "Bot answer:", |
19 | new JTextField())); |
20 | |
21 | updateLoop(200); |
22 | } |
23 | |
24 | static void update() { |
25 | startBot("Get Selected Table Line Bot", "#1001746"); |
26 | S answer = sendToLocalBot("Get Selected Table Line Bot", "get selected table line as map"); |
27 | if (!isMap(answer)) ret; |
28 | |
29 | Map<S, S> m = (Map) unstructure(answer); |
30 | final S name = m.get("Hello message"); |
31 | final S port = m.get("Port"); |
32 | |
33 | if (port != null && port != currentPort) { |
34 | currentPort = port; |
35 | awt { |
36 | botName.setText("Bot name: " + (name == null ? "?" : name)); |
37 | botAddress.setText("Bot address: " + port); |
38 | } |
39 | } |
40 | } |
41 | } |
download show line numbers debug dex old transpilations
Travelled to 15 computer(s): aoiabmzegqzx, bhatertpkbcr, cbybwowwnfue, cfunsshuasjs, gwrvuhgaqvyk, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, onxytkatvevr, pyentgdyhuwx, pzhvpgtvlbxg, teubizvjbppd, tslmcundralx, tvejysmllsmz, vouqrxazstgt
No comments. add comment
Snippet ID: | #1001760 |
Snippet name: | Quick Talk Window (talk to bot selected in swing-top 2, no actual functionality yet) |
Eternal ID of this version: | #1001760/1 |
Text MD5: | 87e2a67fe34554f355ee4fbbbaf1cb5b |
Author: | stefan |
Category: | javax |
Type: | JavaX source code |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2015-11-14 18:57:31 |
Source code size: | 1015 bytes / 41 lines |
Pitched / IR pitched: | No / Yes |
Views / Downloads: | 680 / 654 |
Referenced in: | [show references] |