AllTray is a tool that allows to dock any running program in the system tray. Once the program is docked in the system tray, you can display/hide its window with a single click. I have tested AllTray on Ubuntu 11.04, but it can also be installed on older Ubuntu versions.
Install first AllTray with this command from the Terminal:
sudo apt-get install alltray
Using the dash, launch AllTray:
Or run it simply via the Terminal with this command:
A small window at the center of the screen will show up, click now the program window you want to dock into the system tray.
An icon of the selected program will be displayed in the system tray. Repeat the same steps with other running program windows. That's it!