Simplify $.open with GM_openInTab.

This commit is contained in:
Mayhem 2013-08-02 21:13:32 +02:00
parent 03a8435a94
commit 6d3afcd005

View File

@ -147,7 +147,7 @@ $.off = (el, events, handler) ->
$.event = (event, detail, root=d) ->
root.dispatchEvent new CustomEvent event, {bubbles: true, detail}
<% if (type === 'userscript') { %>
$.open = (URL) -> GM_openInTab URL
$.open = GM_openInTab
<% } else { %>
$.open = (URL) -> window.open URL, '_blank'
<% } %>