Quick List of UbuntuUnitylauncherAPI

Source: Internet
Author: User
In the UbuntuNatty Unity interface, the Launcher component plays an important role. Its built-in APIs such as Count, Progress, Urgency, and Quicklists allow developers to provide more extended functions for programs. Here we will talk about QuicklistAPI (official documentation), which can enhance the context menu function of the startup icon and is easy to use. Common users only need to write a few lines of code to achieve some expansion.

In the Unity interface of Ubuntu Natty, the Launcher component plays an important role. Its built-in APIs such as Count, Progress, Urgency, and Quicklists allow developers to provide more extended functions for programs.

Here we want to talk about Quicklist API (official documentation), which can enhance the context menu function of the startup icon and is easy to use, common users only need to write several lines of code to implement some extension functions. One example is to use the QuickList API to quickly log on to the VPS server.

# Usage

Create a terminal. desktop file in the main directory

Vi terminal. desktop

Then add the following code (of course, you need to modify some of the values, like v2 in remoteserver-x ssh-t v2. aliases configured by ssh/config [see here]. If you haven't configured them, you should write them completely. This is usually the case for remoteserver-x ssh-t.User @ server)

[Desktop Entry]
Version = 1.0
Name = Advanced Terminal
Comment = Advanced Terminal
Exec = gnome-terminal -- disable-factory -- class = remoteserver
Terminal = false
X-MultipleArgs = false
Type = Application
Icon = utilities-terminal
StartupNotify = true
X-Ayatana-Desktop-Shortcuts = Server1; Server2; Server3;

[Server1 Shortcut Group]
Name = SSH into VPS2
Exec = gnome-terminal -- disable-factory -- class = remoteserver-x ssh-t v2
TargetEnvironment = Unity

[Server2 Shortcut Group]
Name = SSH into VPS3
Exec = gnome-terminal -- disable-factory -- class = remoteserver-x ssh-t v3
TargetEnvironment = Unity

[Server3 Shortcut Group]
Name = SSH into VPS4
Exec = gnome-terminal -- disable-factory -- class = remoteserver-x ssh-t vps
TargetEnvironment = Unity

Finally, drag the terminal. desktop file to the Launcher in Nautilus. Right-click the file and you will be able to see the extension function shown in.

For more details, see the official documentation.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.