Changeset 388

Show
Ignore:
Timestamp:
05/03/08 12:07:13 (2 weeks ago)
Author:
t-bone
Message:
  • Set enable/disable state also when switching tabs (including creating a new blank tab).
Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • extension/uppity/content/uppity.js

    r302 r388  
    184184 
    185185window.addEventListener('load', function() { 
    186     //turn on/off status bar button 
     186    // turn on/off status bar button 
    187187    uppity.setSBButtonVis(); 
    188188 
     
    191191 
    192192    // set load progress listener 
    193     var doc=document.getElementById("content"); 
     193    var doc=document.getElementById('content'); 
    194194    if (doc) doc.addProgressListener(uppity.webProgressListener); 
    195 }, false); // end window.addEventListener('load'...) 
     195    // also listen for when there are new tabs created 
     196    var cont=gBrowser.tabContainer; 
     197    if (cont) cont.addEventListener('TabSelect', uppity.setDisabled, false); 
     198}, false);