~ubuntu-branches/ubuntu/saucy/terminator/saucy

« back to all changes in this revision

Viewing changes to terminatorlib/plugins/terminal_menu.py

  • Committer: Bazaar Package Importer
  • Author(s): Nicolas Valcárcel Scerpella (Canonical)
  • Date: 2010-04-07 17:10:31 UTC
  • mfrom: (1.1.7 upstream)
  • Revision ID: james.westby@ubuntu.com-20100407171031-35nsuj0tmbub0bj5
Tags: 0.92-0ubuntu1
* New upstream release
* Remove python-xdg from Recommends. (Closes: #567967)
* Downgrade python-gnome2 to Recommends.
* Update python-gtk2 dependency to (>= 2.14.0)
* Add python-keybinder to Recommends

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
# Terminator by Chris Jones <cmsj@tenshu.net?
 
2
# GPL v2 only
 
3
"""terminal_menu.py - Default plugins for the terminal menu"""
 
4
import gtk
 
5
import terminatorlib.plugin as plugin
 
6
 
 
7
# Every plugin you want Terminator to load *must* be listed in 'available'
 
8
 
 
9
# This is commented out because we don't want any menu item plugins by default
 
10
#available = ['MyFirstMenuItem']
 
11
available = []
 
12
 
 
13
class MyFirstMenuItem(plugin.MenuItem):
 
14
    """Simple proof of concept"""
 
15
    capabilities = ['terminal_menu']
 
16
 
 
17
    def callback(self, menuitems, menu, terminal):
 
18
        """Add our menu items to the menu"""
 
19
        item = gtk.MenuItem('Some Menu Text')
 
20
        menuitems.append(item)
 
21