fixes syncing issue of 'turn all styles off' in the right click context menu with the panel item
This commit is contained in:
parent
6738095f24
commit
fadf1a070c
|
@ -53,6 +53,7 @@ chrome.tabs.onRemoved.addListener(function(tabId, info) {
|
||||||
});
|
});
|
||||||
|
|
||||||
chrome.runtime.onMessage.addListener(function(request, sender, sendResponse) {
|
chrome.runtime.onMessage.addListener(function(request, sender, sendResponse) {
|
||||||
|
|
||||||
switch (request.method) {
|
switch (request.method) {
|
||||||
case "getStyles":
|
case "getStyles":
|
||||||
var styles = getStyles(request, sendResponse);
|
var styles = getStyles(request, sendResponse);
|
||||||
|
@ -84,6 +85,9 @@ chrome.runtime.onMessage.addListener(function(request, sender, sendResponse) {
|
||||||
if (request.prefName == "show-badge") {
|
if (request.prefName == "show-badge") {
|
||||||
chrome.contextMenus.update("show-badge", {checked: request.value});
|
chrome.contextMenus.update("show-badge", {checked: request.value});
|
||||||
}
|
}
|
||||||
|
else if (request.prefName === 'disableAll') {
|
||||||
|
chrome.contextMenus.update("disableAll", {checked: request.value});
|
||||||
|
}
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
Loading…
Reference in New Issue
Block a user