]> jfr.im git - irc/quakenet/qwebirc.git/commitdiff
Add /clear.
authorChris Porter <redacted>
Mon, 20 Oct 2008 20:19:19 +0000 (21:19 +0100)
committerChris Porter <redacted>
Mon, 20 Oct 2008 20:19:19 +0000 (21:19 +0100)
js/irc/commandparser.js

index f7c8a23a5b773ff39c279663a69da6acf8e13752..4efad3916350fcecf2581a0529070260a4ad57ca 100644 (file)
@@ -215,6 +215,11 @@ qwebirc.irc.CommandParser = new Class({
     this.send("PART " + c + " :" + (args?args[0]:"rejoining. . ."));
     this.send("JOIN " + c);
   }],
+  cmd_CLEAR: [false, undefined, undefined, function(args) {
+    var w = this.parentObject.getActiveWindow().lines;
+    while(w.childNodes.length > 0)
+      w.removeChild(w.firstChild);
+  }],
   cmd_PART: [false, 2, 0, function(args) {
     var w = this.parentObject.getActiveWindow();
     var message = "";