[Project_owners] Apply Options dialog changes

Net One netone at gmail.com
Tue Nov 30 13:15:57 EST 2004

I think you can add observers to the preferences you used:
    var oPrefBranch = Components.classes["@mozilla.org/preferences-service;1"].
    oPrefBranch.addObserver("your.pref", oPrefObserver, false);

In the observe method of oPrefObserver, you can refresh the status bar. 

On Mon, 29 Nov 2004 19:17:47 -0600, Chris Means <cmeans at spatialpoint.com> wrote:
> I'm finishing up an extension that updates the status bar with a users'
> current SETI @ Home statistics.
> The updating is done through a window.setTimeout.
> However, the user has some options about what data is displayed, and how
> often to update them (this is limited to just a few choices so as to not
> overload their servers).
> My problem is...after the user has made changes in the options dialog, I'm
> unsure about how to get my main overlay code to reload the users's
> configuration and apply any changes to the display or update frequency.
> Currently, I just popup a message and tell the user to force an immediate
> update on the control (by right-clicking).
> Any suggestions how best to approach this?
> I've tried calling routines in the main code, however, I never seem to get
> the right object references.
> Thanks.
> -Chris
> _______________________________________________
> Project_owners mailing list
> Project_owners at mozdev.org
> http://mozdev.org/mailman/listinfo/project_owners

Best regard,
NetOne, netone at gmail.com

More information about the Project_owners mailing list