1
0
mirror of https://github.com/gryf/pentadactyl-pm.git synced 2026-01-06 03:04:12 +01:00

Define option getters to return Optionhints.jsvalues rather than #value.

This commit is contained in:
Kris Maglione
2010-09-24 16:11:17 -04:00
parent 3645cd27d0
commit 5bf3784ab2
5 changed files with 11 additions and 12 deletions

View File

@@ -158,7 +158,7 @@ const IO = Module("io", {
* @returns {nsIFile[])
*/
getRuntimeDirectories: function (name) {
let dirs = options.get("runtimepath").values;
let dirs = options["runtimepath"];
dirs = dirs.map(function (dir) File.joinPaths(dir, name, this.cwd))
.filter(function (dir) dir.exists() && dir.isDirectory() && dir.isReadable());
@@ -276,10 +276,10 @@ lookup:
* @param {boolean} all Whether all found files should be sourced.
*/
sourceFromRuntimePath: function (paths, all) {
let dirs = options.get("runtimepath").values;
let dirs = options["runtimepath"];
let found = false;
dactyl.echomsg("Searching for " + paths.join(" ").quote() + " in " + options["runtimepath"].quote(), 2);
dactyl.echomsg("Searching for " + paths.join(" ").quote() + " in " + options.get("runtimepath").value, 2);
outer:
for (let [, dir] in Iterator(dirs)) {
@@ -541,7 +541,7 @@ lookup:
dactyl.echomsg(io.cwd);
}
else {
let dirs = options.get("cdpath").values;
let dirs = options["cdpath"];
for (let [, dir] in Iterator(dirs)) {
dir = File.joinPaths(dir, arg, io.cwd);