Skip to content

Commit

Permalink
Merge pull request #572 from ajayyy/video-speed
Browse files Browse the repository at this point in the history
Listen to custom videospeed event
  • Loading branch information
ajayyy authored Dec 15, 2020
2 parents 3b22733 + bd51f5b commit ae61302
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/content.ts
Original file line number Diff line number Diff line change
Expand Up @@ -589,6 +589,8 @@ async function sponsorsLookup(id: string) {
}
});
video.addEventListener('ratechange', () => startSponsorSchedule());
// Used by videospeed extension (https://github.com/igrigorik/videospeed/pull/740)
video.addEventListener('videoSpeed_ratechange', () => startSponsorSchedule());
video.addEventListener('pause', () => {
// Reset lastCheckVideoTime
lastCheckVideoTime = -1;
Expand Down

0 comments on commit ae61302

Please sign in to comment.