Facebook
From Michał Zawadka, 5 Years ago, written in Plain Text.
Embed
Download Paste or View Raw
Hits: 937
  1. // ==UserScript==
  2. // @name         Odświeżenie podczas laga.
  3. // @version      1.1
  4. // @description  Odświeża Ci margona, jak masz tzw. laga.
  5. // @author       adison
  6. // @match        *://*/
  7. // @grant        none
  8. // ==/UserScript==
  9.  
  10. !function(_parseInput) {
  11.     var idleTime = 0;
  12.     var firstTime = true;
  13.     parseInput = function(a, b, c) {
  14.         _parseInput(a, b, c);
  15.         if (firstTime) {
  16.             setInterval(function() {
  17.                 idleTime++;
  18.                 if (idleTime > 5) {
  19.                     idleTime = 0;
  20.                     window.location.reload();
  21.                 }
  22.             }, 1000);
  23.             firstTime = false;
  24.         }
  25.         idleTime = 0;
  26.     }
  27. }(parseInput)