[Project_owners] How to focus <dialog/> ?

Eric H. Jung grimholtz at yahoo.com
Sun Jan 29 21:32:13 EST 2006


Thanks for all the help. It works very well in Ted's Extension
Developer Javascript Shell, but not in Firefox/Mozilla at runtime. I am
almost out of ideas, but not quite   :(

--- HJ <bugs4hj at netscape.net> wrote:

> Neil wrote:
> > HJ wrote:
> > 
> >>   openTabManager: function()
> >>   {
> >>     /***
> >>       * Do a reverse lookup, otherwise we will always end up with 
> >> 'multizilla:tabmanager'
> >>       * Note: keep the ID's of tmIDs[] in sync with the XUL files
> for 
> >> the windows!
> >>       */
> >>     var tmIDs = [ "multizilla:tm-properties", 
> >> "multizilla:tm-preferences", "multizilla:tabmanager" ];
> >>
> >>     for (i in tmIDs) {
> >>       var dialogWin = getMostRecentWindow(tmIDs[i], false);
> >>
> >>       if (dialogWin) {
> >>         dialogWin.focus();
> >>         break;
> > 
> > It occurs to me that if you use return; here then you won't need
> that 
> > (to my mind) clumsy else-if construct; simply open the window if
> the 
> > loop completes.
> 
> True, but it was only used as an example, and Eric probably rewrites
> it 
> anyways.
> 
> /HJ
> _______________________________________________
> Project_owners mailing list
> Project_owners at mozdev.org
> http://mozdev.org/mailman/listinfo/project_owners
> 


__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 


More information about the Project_owners mailing list