Guest User

webmnotmute.user.js

a guest
Oct 18th, 2014
69
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. // ==UserScript==
  2. // @name        2ch_WebmNotMute
  3. // @namespace   2chdev-webmnotmute
  4. // @include     https://2ch.hk/*
  5. // @version     4
  6. // @grant       none
  7. // ==/UserScript==
  8.  
  9. var original_expand;
  10.  
  11. function new_expand(num, src, thumb_src, n_w, n_h, o_w, o_h, minimize) {
  12.  
  13.     original_expand(num, src, thumb_src, n_w, n_h, o_w, o_h, minimize);
  14.  
  15.     if (!minimize) {
  16.         var el = unsafeWindow.$id('exlink-' + num).children;
  17.  
  18.         for (i in el) {
  19.             if (el[i].tagName == "VIDEO") {
  20.                 el[i].muted = 0;
  21.                 el[i].loop = false;
  22.             }
  23.         }
  24.     }
  25.  
  26.     return false;
  27. }
Advertisement
Add Comment
Please, Sign In to add comment