aboutsummaryrefslogtreecommitdiffstats
path: root/google-results.js
blob: 9ef3866a5e4ea225b73ba2d27533afa65b58390a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
/**
* ==VimperatorPlugin==
* @name google-results.js
* @description helps to select google results
* @author john bower (whiskeytangobravo@gmail.com, http://www.whatsthebeef.org)
* @version 0.1
* @minversion 2.0pre
* ==/VimperatorPlugin==
*
* LICENSE
* Creative Commons
*
* USAGE
*
* EXAMPLE
*
* HISTORY
* 2012/02/27 ver. 0.1 - initial written.
*
*/

(function() {

commands.addUserCommand(["gr"],
    "Google Results",
    function (args) {
        window.content.document.querySelectorAll("div > ol > li > div > h3 > a")[args].click();
    });
})();