-
-
Save ashlux/165452 to your computer and use it in GitHub Desktop.
This file contains 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
/* Firefox Ubiquity Box Office Mojo search command */ | |
CmdUtils.CreateCommand({ | |
names: ["boxofficemojo", "bom", "box office mojo"], | |
icon: "http://boxofficemojo.com/favicon.ico", | |
description: "Check out movie details on Box Office Mojo.", | |
help: "TODO", | |
author: {name: "Ash Lux", email: "ashlux@gmail.com"}, | |
license: "GPL", | |
homepage: "http://www.ashlux.com/wordpress/ubiquity-commands", | |
arguments: [{role: 'object', nountype: noun_arb_text}], | |
preview: function preview(pblock, args) { | |
pblock.innerHTML = "Search for movie <b>" + args.object.html + "</b>."; | |
}, | |
execute: function execute(args) { | |
Utils.openUrlInBrowser("http://boxofficemojo.com/search/?q=" + args.object.text); | |
} | |
}); | |
/* Firefox Ubiquity Box Office Mojo top weekend movies command */ | |
CmdUtils.CreateCommand({ | |
names: ["boxofficemojo top weekend movies", "bom top weekend movies", "box office mojo top weekend movies"], | |
icon: "http://boxofficemojo.com/favicon.ico", | |
description: "Check out this weekends top movies on Box Office Mojo.", | |
help: "TODO", | |
author: {name: "Ash Lux", email: "ashlux@gmail.com"}, | |
license: "GPL", | |
homepage: "http://www.ashlux.com/wordpress/ubiquity-commands", | |
preview: function preview(pblock, args) { | |
pblock.innerHTML = "Show top weekend movies."; | |
}, | |
execute: function execute(args) { | |
Utils.openUrlInBrowser("http://boxofficemojo.com/weekend/chart/"); | |
} | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment