I have a Greasemonkey script in FF ( http://defcraft.blogspot.com/2009/02/greasemonkey-search-hel... ) that'll google for the current selection in a background tab when ALT-G is pressed. And it uses GM_openInTab API call. Its equivalent in Chrome seems to be chrome.tabs.create. But when I tried that, I get this error: "chrome.tabs is not supported in content scripts". It seems that these "content scripts" aren't as p…
Google Chrome 4 now natively supports Greasemonkey user scripts
11–20 of 51 posts
Re: Google Chrome 4 now natively supports Greasemonkey user scripts
#12Fastest...browser...evar
Re: Google Chrome 4 now natively supports Greasemonkey user scripts
#13I always thought Google had a browser for the masses in mind with Chrome. Something that is easy to use, stable and fast: a good alternative for IE. User scripts are something for power users, who will always prefer Firefox. Won't this create the risk that average users will accept installing all kinds of scripts without much regard for security implications? User scripts are a powerful yet low-threshold tool which c…
> power users, who will always prefer Firefox Why do you say that? Chrome has extension support, I'm not sure what unique feature Firefox will have left shortly.
Re: Google Chrome 4 now natively supports Greasemonkey user scripts
#14I've been a big firefox fan since phoenix, but already moved to chrome for only one reason: Fastest...browser...evar
Speed is important.
Re: Google Chrome 4 now natively supports Greasemonkey user scripts
#15I really do WANT to use Chrome, but there are so many Firefox extensions I just can't do without. One step closer though.
They'll never have Tree Style Tabs I imagine, so I'm stuck forever with Firefox for that extension. Not that I mind Firefox, but Chrome gets to do a reboot and start again without carrying legacy support/etc with it. Early versions of Firefox felt "lighter" than IE to me for that reason.
Re: Google Chrome 4 now natively supports Greasemonkey user scripts
#16Re: Google Chrome 4 now natively supports Greasemonkey user scripts
#17Earlier quoted context omitted.
> power users, who will always prefer Firefox Why do you say that? Chrome has extension support, I'm not sure what unique feature Firefox will have left shortly.
Chrome extensions are OK, but they're severely limited compared to what you can pull off with FF extensions: http://conkeror.org used to be implemented using only the FF extension mechanism. Chromium extensions cannot alter built-in UI elements, so you're stuck with the standard WIMP UI. It's the only thing keeping me on the Gecko platform.
Re: Google Chrome 4 now natively supports Greasemonkey user scripts
#18Re: Google Chrome 4 now natively supports Greasemonkey user scripts
#19I have a Greasemonkey script in FF ( http://defcraft.blogspot.com/2009/02/greasemonkey-search-hel... ) that'll google for the current selection in a background tab when ALT-G is pressed. And it uses GM_openInTab API call. Its equivalent in Chrome seems to be chrome.tabs.create. But when I tried that, I get this error: "chrome.tabs is not supported in content scripts". It seems that these "content scripts" aren't as p…
One is content scripts - which don't have access to certain parts of the Chrome api like opening tabs.
However, each extension can have what they call a background page. This is just an html page which is loaded in the background and there can be exactly one for every extension.
So you should be able to have your content script communicate with the background page (there is a mechanism for this) and let the background page open the tab.
For this, you'll have to write a fully-fledged extension though. The greasemonkey scripts probably don't generate a background page when they get converted into an extension at install-time.
Re: Google Chrome 4 now natively supports Greasemonkey user scripts
#20I've been a big firefox fan since phoenix, but already moved to chrome for only one reason: Fastest...browser...evar
Likewise, on both points. It hasn't got the polish of Firefox, and the extension ecosystem is a little rough, and I miss the intelligent URL completion from the Awesomebar, but Chrome wins in speed and stability, and those were enough to move me away from Firefox for all but a few sites. Speed is important.