Gmail is showing me this menu instead of the regular right-click menu. Particularly, I need "Open in Tab" for individual mails.
How do I get back to the "regular" Chrome/Safari right-click menu?
Best Answer
You can't change the contextual menu (activated by Control Click or "Right-Click") because it's embedded within the App; this includes the HTML code of a web page.
Contextual menus pop up when the user Control-clicks or right-clicks
over an object. Safari presents different contextual menus when the
mouse pointer is over the toolbar, Bookmarks bar, an extension bar,
the tab bar, or the contents of a webpage.
Your extension can add menu items to the contextual menu that pops up
over web content. You control the actions of the menu item by
installing a listener function for the "command" event in either your
global HTML page or in an extension bar.
(Emphasis mine)
Essentially, what this is saying is that the developer of the (web) app sets the contents of the contextual menu. If they don't set it, it will be the default for whatever is set in Safari/Chrome/Firefox/etc.
If your goal is to open a link in a new tab, hold Cmd while clicking to bypass the menu. Holding Shift while clicking opens the link in a new window. I have found these options quicker than right clicking as my left hand rarely leaves the keyboard and I don't have to parse through a menu to find the item I want.
You can make a Service in 10.6 or 10.7 using Automator that will open a selected URL in Chrome.
Here's how:
Open Automator
When Automator asks you to Choose a type for your document window, select Service
Change the "Service receives selected" drop-down to "URLs"
Add a Run AppleScript action (found under the Automator Library, or just search) by dragging from the left pane to the right
Copy the code below to the text field (replacing all the existing text)
Save and give the service a name (it will be added automatically to the services menu)
Code:
on run {input}
set theURL to input
tell application "Google Chrome"
if not (exists first window) then
make new window
set URL of last tab of first window to theURL
else
tell first window
set newTab to make new tab with properties {URL:theURL}
end tell
end if
activate
end tell
end run
This will open any selected URL in Safari or other application in Chrome, either in a new tab in the most recent window, or a new window if there is no open Chrome window. To access it, right-click and under the Services item at the bottom of the menu, you should see an item with the name you assigned.
One important caveat: OS X seems to be a bit picky/buggy about passing link to this sort of service. It works fine if you have text selected as a URL, but it only seems to work on some links. If I discover a better method, I'll update this post with it.
You may also need to restart Safari for the service to appear.
Best Answer
You can't change the contextual menu (activated by Control Click or "Right-Click") because it's embedded within the App; this includes the HTML code of a web page.
From Apple's Developer Documentation
(Emphasis mine)
Essentially, what this is saying is that the developer of the (web) app sets the contents of the contextual menu. If they don't set it, it will be the default for whatever is set in Safari/Chrome/Firefox/etc.
If your goal is to open a link in a new tab, hold Cmd while clicking to bypass the menu. Holding Shift while clicking opens the link in a new window. I have found these options quicker than right clicking as my left hand rarely leaves the keyboard and I don't have to parse through a menu to find the item I want.