flash badge

This commit is contained in:
Sriram Hariharan
2019-01-15 13:42:21 -06:00
parent 147fef3d07
commit ce709cbec4
7 changed files with 40 additions and 43 deletions

View File

@@ -306,11 +306,8 @@ $("#importOrig").change(function (e) {
chrome.storage.sync.set({
savedCourses: impCourses
});
chrome.browserAction.setBadgeBackgroundColor({
color: '#bf5700'
});
chrome.browserAction.setBadgeText({
text: "" + impCourses.length
chrome.runtime.sendMessage({
command: "updateBadge"
});
chrome.tabs.query({}, function (tabs) {
for (var i = 0; i < tabs.length; i++) {
@@ -423,11 +420,8 @@ function clear() {
});
}
});
chrome.browserAction.setBadgeBackgroundColor({
color: '#bf5700'
});
chrome.browserAction.setBadgeText({
text: ""
chrome.runtime.sendMessage({
command: "updateBadge"
});
$("#courseList").empty()
console.log("cleared");