SHARE
TWEET

Untitled

a guest Apr 27th, 2015 221 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. // ==UserScript==
  2. // @name        feedly link opener
  3. // @namespace   .
  4. // @description Press Q to open all unread links on the feedly page.
  5. // @include     http://feedly.com/*
  6. // @version     1
  7. // @grant       none
  8. // ==/UserScript==
  9.  
  10. document.addEventListener("keydown", keyDownFunc, false);
  11.  
  12. function keyDownFunc(e){
  13.         keycode = e.which;
  14.         if (keycode == 81){
  15.                 openLinks();
  16.         }
  17. }
  18.  
  19. function openLinks(){
  20.     var links = document.getElementsByClassName("title unread");
  21.     var hrefs = [];
  22.     for(i = 0; i < links.length; i+=1){
  23.         window.open(links[i].href, "_blank");
  24.     }
  25. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top