in

How to Enable Unity Quicklists in Google Chrome and Firefox

- - 4 comments
A few weeks ago, we did an in-depth review of Ubuntu 11.04 when compared with Fedora 15. One of the interesting little features we missed was Quicklists in Unity. Quicklists allow users to access common menus, or perform common tasks within a program by right-clicking the launcher icon. The feature is very much similar to Jump Lists in Windows 7, which could be accessed by right-clicking the Windows task bar. Applications, like Browsers and Media Players use these Jump Lists to let the user access documents and tasks associated with the current application. Unity on the other hand being freshly baked from the oven, there aren't many applications that take advantage of the Quicklist features. Here's a quick tip that will let you enable Quicklists for both Google Chrome and Firefox.


Using Google Chrome and/or Chromium:

Google Chrome and Chromium don't support Quicklists by default; however, with a little tweaking the feature can be enabled to support incognito mode. Here's the whole process in 2 easy steps.

Step 1: Backup - Open the terminal (Ctrl+Alt+T) and type in the following code:

sudo cp /usr/share/applications/firefox.desktop /usr/share/applications/firefox.desktop.backup

Step 2: Then, type the following line in the terminal:

sudo gedit /usr/share/applications/google-chrome.desktop

Step 3: Now that the file is opened, paste the following code at the end of the file. When done, press Ctrl+S and close the window.

X-Ayatana-Desktop-Shortcuts=NewWindow;Incognito;

[NewWindow Shortcut Group]

Name=New Window

Exec=google-chrome

TargetEnvironment=Unity

[Incognito Shortcut Group]

Name=New Incognito Tab

Exec=google-chrome --incognito

TargetEnvironment=Unity


When finished, the right-click menu for Chrome will look like this:



Using Firefox:

Firefox 4 can also be tweaked to show various options in the Quicklists. These options allow users to open a new window, toggle the Private browsing mode, start the Profile Manager, and use the safe mode. The safe mode starts Firefox without any extensions or plugins. The profile manager can be used to access different profiles before starting the actual session.

Right-clicking on the Firefox launcher icon and selecting 'Profile Manager' will open a window like this:



Anyways, enough talk, here's how to get it in 4 easy steps:

Step 1: Backup the file..

sudo cp /usr/share/applications/firefox.desktop /usr/share/applications/firefox.desktop.backup

Step 2: Open the terminal and type in..

sudo gedit /usr/share/applications/firefox.desktop

Step 3: Apparently, Firefox already supports the New Window quick list item. So, find the code that begins with a line that looks like this:

X-Ayatana-Desktop-Shortcuts=NewWindow;

This line will be followed by some code. Now, delete the line and the lines below it.

Step 4: Add following code to the file, press Ctrl+S and exit.

X-Ayatana-Desktop-Shortcuts=NewWindow;PrivateToggle;ProfileMgr;Safe-Mode;

[NewWindow Shortcut Group]

Name=Open a New Window

Name[ast]=Abrir una ventana nueva

Name[bn]=Abrir una ventana nueva

Name[ca]=Obre una finestra nova

Name[da]=Åbn et nyt vindue

Name[de]=Ein neues Fenster öffnen

Name[es]=Abrir una ventana nueva

Name[fi]=Avaa uusi ikkuna

Name[fr]=Ouvrir une nouvelle fenêtre

Name[gl]=Abrir unha nova xanela

Name[he]=פתיחת חלון חדש

Name[hr]=Otvori novi prozor

Name[hu]=Új ablak nyitása

Name[it]=Apri una nuova finestra

Name[ja]=新しいウィンドウを開く

Name[ku]=Paceyeke nû veke

Name[lt]=Atverti naują langą

Name[nl]=Nieuw venster openen

Name[ro]=Deschide o fereastră nouă

Name[ru]=Открыть новое окно

Name[sv]=Öppna ett nytt fönster

Name[ug]=يېڭى كۆزنەك ئېچىش

Name[uk]=Відкрити нове вікно

Name[zh_CN]=新建窗口

Name[zh_TW]=開啟新視窗

Exec=firefox -new-window about:blank

TargetEnvironment=Unity

[Safe-Mode Shortcut Group]

Name=Safe-Mode

Exec=firefox -safe-mode

TargetEnvironment=Unity

[PrivateToggle Shortcut Group]

Name=Enable/Disabe Private Mode

Exec=firefox -private-toggle

TargetEnvironment=Unity

[ProfileMgr Shortcut Group]

Name=Start Profile Manager

Exec=firefox -ProfileManager

TargetEnvironment=Unity


Finally, if all goes well, the menu will look like this:



Menu doesn't show up:
If the menu doesn't show up, remove the launcher from the Unity bar by right-clicking and unchecking the option titled “Keep in Launcher”. Then search for the program and drag it to the Unity bar again. The Quicklist should be visible by now.

If something goes wrong, type the following commands. These commands will restore the original ‘.desktop’ files and delete the modified ones, taking things back to normal.

For Google Chrome:
sudo rm -rf /usr/share/applications/google-chrome.desktop
sudo mv /usr/share/applications/google-chrome.desktop.backup /usr/share/applications/google-chrome.desktop

For Firefox:
sudo rm -rf /usr/share/applications/firefox.desktop
sudo mv /usr/share/applications/firefox.desktop.backup /usr/share/applications/firefox.desktop

4 comments

  1. Thanks for the info! In your chrome backup command you are actually backing up the firefox.desktop though a backup is not entirely necessary here anyway.

    ReplyDelete
  2. if using GUI editor like gedit, your "sudo" command should start with "gksudo", i.e.:

    gksudo gedit /usr/share/applications/google-chrome.desktop


    And as a anonymious reader commented before me, you are actually backing up the firefox.desktop instead of chrome

    ReplyDelete
  3. gksudo gedit /usr/share/applications/google-chrome.desktop

    this is the proper command if using GUI editor like gedit in CLI. the same of course for editing firefox.desktop

    ReplyDelete
  4. I have updated chromium.desktop file and i can see submenu modes in unity for chromium but when i click on it, it won't start?? Should i something enable?

    ReplyDelete