!7 static long timeout = 5000; static int maxEntries = 10; static AutoComboBox3 box; static JComboBox cbAction; static JTextArea taChat; p-noconsole { autoRestart(); smartBot_autoComplete_defaultMaxEntries = maxEntries; smartBot_autoComplete_defaultHardTimeout = timeout; box = autoComboBox3(f smartBot_autoComplete); centerComboBox(box); setFontSize(box, 20); setComboBoxListFontSize(box, 20); cbAction = jcombobox("Say in Smart Bot's Chat", "Open topic in browser"); onEnterWithClose(box, f doIt); taChat = jtextarea(); setFontSize(taChat, 20); showCenterFrame(600, 600, centerAndSouth(withMargin(withTitle("Smart Bot'S Chat", taChat, centerAndEast(box, jline(cbAction, jbutton("OK", f doIt))))); awtLater(box, 500, r { focus(box) }); smartBotsChat_onLine_chatMsg(10, voidfunc(ChatMsg m) { appendToTextAreaAndMoveCaret(taChat, m.text + "\n"); }); } sS input() { ret getText(box); } svoid doIt { S action = getText(cbAction); S s = input(); if (eqic(action, "Say in Smart Bot's Chat")) { if (!postToSmartBotsChat_user(s)) infoBox("!*&$"); } else openPlatformBrowser(smartBot_topicLink(s)); }