1
0
Fork 0
mirror of https://github.com/gorhill/uMatrix.git synced 2024-06-14 16:25:03 +12:00

Firefox: blocking and content scripts for e10s

This commit is contained in:
Deathamns 2014-12-09 21:56:17 +01:00 committed by gorhill
parent c752853031
commit 706a51c211

View file

@ -140,6 +140,8 @@ vAPI.tabs.open = function(details) {
};
if ( details.tabId ) {
details.tabId = parseInt(tabId, 10);
// update doesn't accept index, must use move
chrome.tabs.update(details.tabId, _details, function(tab) {
// if the tab doesn't exist
@ -203,7 +205,7 @@ vAPI.tabs.remove = function(tabId) {
if ( vAPI.lastError() ) {
}
};
chrome.tabs.remove(tabId, onTabRemoved);
chrome.tabs.remove(parseInt(tabId, 10), onTabRemoved);
};
/******************************************************************************/
@ -227,6 +229,7 @@ vAPI.tabs.injectScript = function(tabId, details, callback) {
}
};
if ( tabId ) {
tabid = parseInt(tabId, 10);
chrome.tabs.executeScript(tabId, details, onScriptExecuted);
} else {
chrome.tabs.executeScript(details, onScriptExecuted);
@ -243,6 +246,7 @@ vAPI.tabs.injectScript = function(tabId, details, callback) {
// anymore, so this ensures it does still exist.
vAPI.setIcon = function(tabId, img, badge) {
tabId = parseInt(tabId, 10);
var onIconReady = function() {
if ( vAPI.lastError() ) {
return;