mirror of
https://github.com/gryf/pentadactyl-pm.git
synced 2025-12-20 22:07:58 +01:00
go=lrb for left, right, and bottom scrollbars respectively.
This commit is contained in:
@@ -110,14 +110,19 @@ const liberator = (function () //{{{
|
||||
}
|
||||
},
|
||||
scroll: {
|
||||
opts: { r: ["Right Scrollbar"] },
|
||||
opts: { r: ["Right Scrollbar", "vertical"], l: ["Left Scrollbar", "vertical"], b: ["Bottom Scrollbar", "horizontal"] },
|
||||
setter: function (opts)
|
||||
{
|
||||
if (opts.indexOf("r") == -1)
|
||||
styles.addSheet("scrollbar", "*", "html|html > xul|scrollbar { visibility: collapse !important; }", true, true);
|
||||
let dir = ["horizontal", "vertical"].filter(function (dir) !Array.some(opts, function (o) this.opts[o][1] == dir, this), this);
|
||||
let class = dir.map(function (dir) "html|html > xul|scrollbar[orient=" + dir + "]");
|
||||
|
||||
if (class.length)
|
||||
styles.addSheet("scrollbar", "*", class.join(", ") + " { visibility: collapse !important; }", true, true);
|
||||
else
|
||||
styles.removeSheet("scrollbar", null, null, null, true);
|
||||
}
|
||||
options.setPref("layout.scrollbar.side", opts.indexOf("l") >= 0 ? 3 : 2);
|
||||
},
|
||||
validator: function (opts) (opts.indexOf("l") < 0 || opts.indexOf("r") < 0)
|
||||
},
|
||||
tab: {
|
||||
opts: {
|
||||
@@ -150,7 +155,8 @@ const liberator = (function () //{{{
|
||||
opts = opts.map(function (opt) [[k, v[0]] for ([k, v] in Iterator(opt))]);
|
||||
return util.Array.flatten(opts);
|
||||
},
|
||||
validator: Option.validateCompleter
|
||||
validator: function (val) Option.validateCompleter.call(this, val) &&
|
||||
[v for ([k, v] in Iterator(groups))].every(function (g) !g.validator || g.validator(val))
|
||||
});
|
||||
|
||||
options.add(["helpfile", "hf"],
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
2008-XX-XX:
|
||||
* version 2.0 (probably)
|
||||
* IMPORTANT: For compatibility with vim, guioptions=b has been renamed
|
||||
'B'. 'b' now represents the bottom scrollbar.
|
||||
* IMPORTANT: :set now sets multiple options, as in Vim. Spaces in values
|
||||
must be quoted or escaped.
|
||||
* IMPORTANT: Due to much improved autocompletion, changed default 'complete' option
|
||||
|
||||
@@ -33,12 +33,12 @@ const config = { //{{{
|
||||
|
||||
/*** optional options, there are checked for existance and a fallback provided ***/
|
||||
features: ["bookmarks", "hints", "history", "marks", "quickmarks", "session", "tabs", "windows"],
|
||||
defaults: { guioptions: "r" },
|
||||
defaults: { guioptions: "rb" },
|
||||
|
||||
guioptions: {
|
||||
m: ["Menubar", ["toolbar-menubar"]],
|
||||
T: ["Toolbar", ["nav-bar"]],
|
||||
b: ["Bookmark bar", ["PersonalToolbar"]]
|
||||
B: ["Bookmark bar", ["PersonalToolbar"]]
|
||||
},
|
||||
|
||||
get visualbellWindow() getBrowser().mPanelContainer,
|
||||
|
||||
Reference in New Issue
Block a user