[Project_owners] setBoolPref()

Nagarjuna Venna vnagarjuna at gmail.com
Tue Nov 1 17:45:51 EST 2005


I believe setPref() API's expects a PrefBranch object and not a
PrefService object.

Thanks,
nagarjuna

On 11/1/05, Michael Johnston <special.michael at gmail.com> wrote:
> I have
>
> function refreshHashset(){
>  try{
>     //preferences service
>     var prefs = Components.classes["@mozilla.org/preferences-service;1"]
>                     .getService(Components.interfaces.nsIPrefService);
>     if(dirty()){
>          signatureHashSet= null; //need this to allow reload.
>          fillHashSet();
>          //mark the autocomplete as no longer needing refresh
>          prefs.setBoolPref("signature.autocomplete.dirtyflag",false);
>       }
> }catch(e){
>     if(DEBUG)
>         alert("exception in : refreshHashSet()\n"+e+"\nprefs="+prefs);
>     }
> }
>
> a user is reporting getting an alert with this:
> exception in : refreshHashSet()
> TypeError: prefs.setBoolPref is not a function
>  prefs= [xpconnect wrapped nsIPrefService]
>
> any ideas as to why this would be?
> their email has
>    User-Agent: Mozilla Thunderbird 1.0.7 (Windows/20050923)
> in the header
> _______________________________________________
> Project_owners mailing list
> Project_owners at mozdev.org
> http://mozdev.org/mailman/listinfo/project_owners
>


More information about the Project_owners mailing list