Last active
April 12, 2017 02:01
-
-
Save cayuu/7134360 to your computer and use it in GitHub Desktop.
Mute Rdio Ads (copy + paste into browser console) [24 Oct 2013]
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var r = R.player, oVol = r.volume(), tf = r._onTrackFinished, ar = r._onAudioReady, n = r._next; | |
r._onTrackFinished = function() { | |
return .001 !== r.volume() && (oVol = r.volume()), r.volume(.001), tf.apply(this, arguments); | |
}; | |
r._onAudioReady = function() { | |
return r.playingAd() || r.volume(oVol), ar.apply(this, arguments); | |
}; | |
r._next = function() { | |
arguments[0] = false; | |
return n.apply(this, arguments); | |
}; |
Thanks for the scripts! Muting works great during "regular" playback for me, but it does not mute after (inbetween) manual track skip. Is this working for others?
@allanforever thanks! Added to the gist.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
It took me a while to figure out a way to make this code "stick", since I rarely use Chrome or Chromium. Install the "Custom Javascript for websites" extension for Chrome, go to the rdio.com website, click on the extension's icon ("cjs"), paste the above code in the box that appears, and save. Done. It might give you an error and tell you to refresh, so try that. I use allanforever's code and actually I'm on Chromium, but it will work for Chrome too.