summaryrefslogtreecommitdiff
path: root/res/script/system.js
diff options
context:
space:
mode:
authoriroul <iroul@iroul-VirtualBox.(none)>2014-04-04 07:35:14 -0700
committeriroul <iroul@iroul-VirtualBox.(none)>2014-04-04 07:35:14 -0700
commitafd34f2893a06a3aecf17e8e83b1df6ed2ae91a2 (patch)
tree851102abc55d91a1b76e63e9e89f9a7733da95b5 /res/script/system.js
parentc4b028ad53f7b362a864de24828d7cc39ff67b0a (diff)
downloadfqterm-afd34f2893a06a3aecf17e8e83b1df6ed2ae91a2.tar.xz
move to my github.
Diffstat (limited to 'res/script/system.js')
-rw-r--r--res/script/system.js48
1 files changed, 48 insertions, 0 deletions
diff --git a/res/script/system.js b/res/script/system.js
new file mode 100644
index 0000000..a49df9e
--- /dev/null
+++ b/res/script/system.js
@@ -0,0 +1,48 @@
+fqterm.import("utils.js");
+fqterm.mouseEvent = function(type, states, x, y, delta) {
+ if (type == fqterm.MOUSEEVENT.MOUSE_PRESS &&
+ states & fqterm.BUTTONSTATE.LEFT_BUTTON &&
+ states & fqterm.BUTTONSTATE.CTRL) {
+ fqterm.msgBox(fqterm.getFullTextAt(y, x, 1));
+ }
+ return false;
+}
+
+fqterm.detectMenu = function() {
+ fqterm.setMenuRect(1, 3, 20);
+ return false;
+}
+
+fqterm.antiIdle = function() {
+ //fqterm.msgBox("antiIdle");
+ return false;
+}
+
+
+fqterm.onBell = function() {
+ //fqterm.msgBox("onBell");
+}
+
+fqterm.autoReply = function() {
+ //fqterm.msgBox("autoReply");
+ return false;
+}
+
+
+fqterm.dataEvent = function() {
+ //fqterm.msgBox("data event");
+}
+
+fqterm.keyEvent = function(type, states, key) {
+// if (type == fqterm.KEYEVENT.KEY_PRESS &&
+// states & fqterm.BUTTONSTATE.CTRL && key) {
+// fqterm.msgBox(key);
+// }
+}
+
+
+var timeEvent = function() {
+ //fqterm.msgBox("haha");
+}
+var id = fqterm.setInterval(1000, timeEvent);
+//fqterm.clearInterval(id); \ No newline at end of file