diff options
author | Ajay Ramachandran <[email protected]> | 2019-07-21 18:19:56 -0400 |
---|---|---|
committer | Ajay Ramachandran <[email protected]> | 2019-07-21 18:19:56 -0400 |
commit | 2d00cfffdfac4a5e30fcef55c576ceec650de28a (patch) | |
tree | b6cc66fcd876b69282c2b44afc7d7f3969b43042 /popup.js | |
parent | a7a4642920e046a21a9ce101d6064b1c430fff95 (diff) | |
download | SponsorBlock-2d00cfffdfac4a5e30fcef55c576ceec650de28a.tar.gz SponsorBlock-2d00cfffdfac4a5e30fcef55c576ceec650de28a.zip |
Added submit button on the video player.
Diffstat (limited to 'popup.js')
-rw-r--r-- | popup.js | 9 |
1 files changed, 6 insertions, 3 deletions
@@ -241,14 +241,17 @@ function getSponsorTimesMessage(sponsorTimes) { } function clearTimes() { - //check if the player controls should be toggled - if (sponsorTimes.length > 0 && sponsorTimes[sponsorTimes.length - 1].length < 2) { + //send new sponsor time state to tab + if (sponsorTimes.length > 0) { + let visibility = sponsorTimes[sponsorTimes.length - 1].length >= 2; chrome.tabs.query({ active: true, currentWindow: true }, function(tabs) { chrome.tabs.sendMessage(tabs[0].id, { - message: "toggleStartSponsorButton" + message: "changeStartSponsorButton", + visibility: visibility, + uploadButtonVisible: false }); }); } |