1
0
mirror of https://github.com/gryf/pentadactyl-pm.git synced 2025-12-22 15:37:59 +01:00

move Options.{setPref,getPref,setFirefoxPref,getFirefoxPref} to slots of vimperator.options

This commit is contained in:
Doug Kearns
2007-10-21 05:34:50 +00:00
parent d28cb96df2
commit 79577bea5f
7 changed files with 23 additions and 23 deletions

View File

@@ -75,7 +75,7 @@ function Option(names, type, extra_info) //{{{
}
}
// NOTE: forced defaults need to use Options.getPref
// NOTE: forced defaults need to use vimperator.options.getPref
this.__defineGetter__("value",
function()
{
@@ -363,22 +363,22 @@ function Options() //{{{
// TODO: separate Preferences from Options? Would these utility functions
// be better placed in the 'core' vimperator namespace somewhere?
Options.setPref = function(name, value)
this.setPref = function(name, value)
{
return storePreference(name, value, true);
}
Options.getPref = function(name, forced_default)
this.getPref = function(name, forced_default)
{
return loadPreference(name, forced_default, true);
}
Options.setFirefoxPref = function(name, value)
this.setFirefoxPref = function(name, value)
{
return storePreference(name, value);
}
Options.getFirefoxPref = function(name, forced_default)
this.getFirefoxPref = function(name, forced_default)
{
return loadPreference(name, forced_default);
}
@@ -688,7 +688,7 @@ function Options() //{{{
addOption(new Option(["visualbell", "vb"], "boolean",
{
short_help: "Use visual bell instead of beeping on errors",
setter: function(value) { Options.setFirefoxPref("accessibility.typeaheadfind.enablesound", !value); },
setter: function(value) { vimperator.options.setFirefoxPref("accessibility.typeaheadfind.enablesound", !value); },
default_value: false
}
));