mirror of
https://github.com/gryf/pentadactyl-pm.git
synced 2026-01-04 04:24:11 +01:00
Make 'stal' a string option.
This commit is contained in:
@@ -961,24 +961,24 @@ var Tabs = Module("tabs", {
|
|||||||
options: function () {
|
options: function () {
|
||||||
options.add(["showtabline", "stal"],
|
options.add(["showtabline", "stal"],
|
||||||
"Define when the tab bar is visible",
|
"Define when the tab bar is visible",
|
||||||
"number", config.defaults["showtabline"],
|
"string", config.defaults["showtabline"],
|
||||||
{
|
{
|
||||||
setter: function (value) {
|
setter: function (value) {
|
||||||
if (value == 0)
|
if (value === "never")
|
||||||
tabs.tabStyle.enabled = true;
|
tabs.tabStyle.enabled = true;
|
||||||
else {
|
else {
|
||||||
prefs.safeSet("browser.tabs.autoHide", value == 1,
|
prefs.safeSet("browser.tabs.autoHide", value === "multitab",
|
||||||
"See 'showtabline' option.");
|
"See 'showtabline' option.");
|
||||||
tabs.tabStyle.enabled = false;
|
tabs.tabStyle.enabled = false;
|
||||||
}
|
}
|
||||||
if (value != 1 || !dactyl.has("Gecko2"))
|
if (value !== "multitab" || !dactyl.has("Gecko2"))
|
||||||
config.tabStrip.collapsed = false;
|
config.tabStrip.collapsed = false;
|
||||||
return value;
|
return value;
|
||||||
},
|
},
|
||||||
completer: function (context) [
|
completer: function (context) [
|
||||||
["0", "Never show tab bar"],
|
["never", "Never show tab bar"],
|
||||||
["1", "Show tab bar only if more than one tab is open"],
|
["multitab", "Show tab bar when there are multiple tabs"],
|
||||||
["2", "Always show tab bar"]
|
["always", "Always show tab bar"]
|
||||||
]
|
]
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|||||||
@@ -1382,6 +1382,22 @@
|
|||||||
<item>
|
<item>
|
||||||
<tags>'stal' 'showtabline'</tags>
|
<tags>'stal' 'showtabline'</tags>
|
||||||
<spec>'showtabline' 'stal'</spec>
|
<spec>'showtabline' 'stal'</spec>
|
||||||
|
<type>string</type>
|
||||||
|
<default>always</default>
|
||||||
|
<description>
|
||||||
|
<p>Define when the tab bar is visible.</p>
|
||||||
|
|
||||||
|
<dl>
|
||||||
|
<dt>always</dt> <dd>Always show tab bar</dd>
|
||||||
|
<dt>multitab</dt> <dd>Show tab bar when there are multiple tabs</dd>
|
||||||
|
<dt>never</dt> <dd>Never show tab bar</dd>
|
||||||
|
</dl>
|
||||||
|
</description>
|
||||||
|
</item>
|
||||||
|
|
||||||
|
</item>
|
||||||
|
|
||||||
|
|
||||||
<type>number</type>
|
<type>number</type>
|
||||||
<default>2</default>
|
<default>2</default>
|
||||||
<description>
|
<description>
|
||||||
|
|||||||
@@ -16,11 +16,15 @@ if (!JSMLoader)
|
|||||||
|
|
||||||
for each (let prop in Object.getOwnPropertyNames(global))
|
for each (let prop in Object.getOwnPropertyNames(global))
|
||||||
try {
|
try {
|
||||||
if (!set.has(this.builtin, prop) &&
|
if (!(prop in this.builtin) &&
|
||||||
[this, set].indexOf(Object.getOwnPropertyDescriptor(global, prop).value) < 0)
|
[this, set].indexOf(Object.getOwnPropertyDescriptor(global, prop).value) < 0 &&
|
||||||
delete global[prop];
|
!global.__lookupGetter__(prop))
|
||||||
|
global[prop] = null;
|
||||||
|
}
|
||||||
|
catch (e) {
|
||||||
|
dump("Deleting property " + prop + " on " + url + ":\n " + e + "\n");
|
||||||
|
Components.utils.reportError(e);
|
||||||
}
|
}
|
||||||
catch (e) {}
|
|
||||||
|
|
||||||
Components.classes["@mozilla.org/moz/jssubscript-loader;1"]
|
Components.classes["@mozilla.org/moz/jssubscript-loader;1"]
|
||||||
.getService(Components.interfaces.mozIJSSubScriptLoader)
|
.getService(Components.interfaces.mozIJSSubScriptLoader)
|
||||||
|
|||||||
@@ -102,7 +102,7 @@
|
|||||||
a boolean.
|
a boolean.
|
||||||
- 'mapleader' is now an option rather than a :let
|
- 'mapleader' is now an option rather than a :let
|
||||||
variable.
|
variable.
|
||||||
- 'showstatuslinks' is now a string option.
|
- 'showstatuslinks' and 'showtabline' are now string options.
|
||||||
* IMPORTANT: Command script files now use the *.penta file extension.
|
* IMPORTANT: Command script files now use the *.penta file extension.
|
||||||
* IMPORTANT: Plugins are now loaded from the 'plugins/'
|
* IMPORTANT: Plugins are now loaded from the 'plugins/'
|
||||||
directory in 'runtimepath' rather than 'plugin/'.
|
directory in 'runtimepath' rather than 'plugin/'.
|
||||||
|
|||||||
@@ -6,7 +6,7 @@
|
|||||||
// given in the LICENSE.txt file included with this file.
|
// given in the LICENSE.txt file included with this file.
|
||||||
"use strict";
|
"use strict";
|
||||||
|
|
||||||
const Config = Module("config", ConfigBase, {
|
var Config = Module("config", ConfigBase, {
|
||||||
name: "pentadactyl",
|
name: "pentadactyl",
|
||||||
appName: "Pentadactyl",
|
appName: "Pentadactyl",
|
||||||
idName: "PENTADACTYL",
|
idName: "PENTADACTYL",
|
||||||
@@ -174,7 +174,7 @@ const Config = Module("config", ConfigBase, {
|
|||||||
defaults: {
|
defaults: {
|
||||||
complete: "slf",
|
complete: "slf",
|
||||||
guioptions: "bCrs",
|
guioptions: "bCrs",
|
||||||
showtabline: 2,
|
showtabline: "always",
|
||||||
titlestring: "Pentadactyl"
|
titlestring: "Pentadactyl"
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user