|
@ -1141,7 +1141,7 @@ var httpObserver = { |
|
|
if ( !(channel instanceof Ci.nsIHttpChannel) ) { |
|
|
if ( !(channel instanceof Ci.nsIHttpChannel) ) { |
|
|
return; |
|
|
return; |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var URI = channel.URI; |
|
|
var URI = channel.URI; |
|
|
var channelData, result; |
|
|
var channelData, result; |
|
|
|
|
|
|
|
@ -1485,7 +1485,7 @@ vAPI.toolbarButton.init = function() { |
|
|
'content: attr(badge);', |
|
|
'content: attr(badge);', |
|
|
'}' |
|
|
'}' |
|
|
); |
|
|
); |
|
|
} else { |
|
|
|
|
|
|
|
|
} else { |
|
|
this.CUIEvents = {}; |
|
|
this.CUIEvents = {}; |
|
|
|
|
|
|
|
|
var updateBadge = function() { |
|
|
var updateBadge = function() { |
|
@ -1586,7 +1586,6 @@ vAPI.toolbarButton.init = function() { |
|
|
}.bind(this)); |
|
|
}.bind(this)); |
|
|
}; |
|
|
}; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/******************************************************************************/ |
|
|
/******************************************************************************/ |
|
|
|
|
|
|
|
|
vAPI.toolbarButton.onBeforeCreated = function(doc) { |
|
|
vAPI.toolbarButton.onBeforeCreated = function(doc) { |
|
@ -1656,6 +1655,27 @@ vAPI.toolbarButton.onViewHiding = function({target}) { |
|
|
target.firstChild.setAttribute('src', 'about:blank'); |
|
|
target.firstChild.setAttribute('src', 'about:blank'); |
|
|
}; |
|
|
}; |
|
|
|
|
|
|
|
|
|
|
|
vAPI.toolbarButton.updateState = function(win, tabId) { |
|
|
|
|
|
var button = win.document.getElementById(this.id); |
|
|
|
|
|
|
|
|
|
|
|
if ( !button ) { |
|
|
|
|
|
return; |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
var icon = this.tabs[tabId]; |
|
|
|
|
|
button.setAttribute('badge', icon && icon.badge || ''); |
|
|
|
|
|
|
|
|
|
|
|
if ( !icon || !icon.img ) { |
|
|
|
|
|
icon = ''; |
|
|
|
|
|
} |
|
|
|
|
|
else { |
|
|
|
|
|
icon = 'url(' + vAPI.getURL('img/browsericons/icon16.svg') + ')'; |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
button.style.listStyleImage = icon; |
|
|
|
|
|
}; |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
/******************************************************************************/ |
|
|
/******************************************************************************/ |
|
|
|
|
|
|
|
|
vAPI.toolbarButton.init(); |
|
|
vAPI.toolbarButton.init(); |
|
|