]> jfr.im git - irc/quakenet/qwebirc.git/blobdiff - js/ui/panes/options.js
Merge.
[irc/quakenet/qwebirc.git] / js / ui / panes / options.js
index c40711023cebd2d4628c0349104ea8e7a611224b..1d6b075624e05006d5f8e1b1915141ca8637d780 100644 (file)
@@ -31,7 +31,7 @@ qwebirc.config.DEFAULT_OPTIONS = [
   [2, "DEDICATED_MSG_WINDOW", "Send privmsgs to dedicated messages window", false],
   [4, "DEDICATED_NOTICE_WINDOW", "Send notices to dedicated message window", false],
   [3, "NICK_OV_STATUS", "Show status (@/+) before nicknames in channel lines", true],
-  [5, "ACCEPT_SERVICE_INVITES", "Automatically join channels when invited by Q", true, {
+  [5, "ACCEPT_SERVICE_INVITES", "Automatically join channels when invited by Q", false, {
     settableByURL: false
   }],
   [6, "USE_HIDDENHOST", "Hide your hostmask when authed to Q (+x)", true, {
@@ -50,7 +50,8 @@ qwebirc.config.DEFAULT_OPTIONS = [
     }
   }],
   [12, "QUERY_ON_NICK_CLICK", "Query on nickname click in channel", false],
-  [13, "SHOW_NICKLIST", "Show nickname list in channels", true]
+  [13, "SHOW_NICKLIST", "Show nickname list in channels", true],
+  [14, "SHOW_TIMESTAMPS", "Show timestamps", true] /* we rely on the hue update */
 ];
 
 qwebirc.config.DefaultOptions = null;
@@ -442,8 +443,12 @@ qwebirc.ui.SuppliedArgOptions = new Class({
       var checksum = arg.substr(arg.length - 2, 2);
       var decoded = qwebirc.util.b64Decode(arg.substr(0, arg.length - 2));
       
-      if(decoded && (new qwebirc.util.crypto.MD5().digest(decoded).slice(0, 2) == checksum))
-        p = qwebirc.util.parseURI("?" + decoded);
+      if(decoded && (new qwebirc.util.crypto.MD5().digest(decoded).slice(0, 2) == checksum)) {
+        var p2 = qwebirc.util.parseURI("?" + decoded);
+        for(var k in p2) {
+          p[k] = JSON.decode(p2[k], true);
+        }
+      }
     }
     
     this.parsedOptions = p;
@@ -463,7 +468,7 @@ qwebirc.ui.SuppliedArgOptions = new Class({
     var result = [];
     this.getOptionList().forEach(function(x) {
       if(x.settableByURL && x.default_ != x.value)
-        result.push(x.optionId + "=" + x.value);
+        result.push(x.optionId + "=" + JSON.encode(x.value));
     }.bind(this));
     
     var raw = result.join("&");