suggestion from Kees Cook - a menu option to instantly group all terminals

This commit is contained in:
Chris Jones 2008-12-11 08:07:28 +00:00
parent b1bf317671
commit dee393cd70

View File

@ -1015,6 +1015,8 @@ text/plain
submenu = gtk.Menu ()
item.set_submenu (submenu)
self.populate_grouping_menu (submenu)
if len (self.terminator.term_list) == 1:
item.set_sensitive (False)
item = gtk.MenuItem ()
menu.append (item)
@ -1051,6 +1053,13 @@ text/plain
item.connect ("activate", self.create_group)
widget.append (item)
item = gtk.MenuItem ()
widget.append (item)
item = gtk.MenuItem (_("_Group all"))
item.connect ("activate", self.group_all)
widget.append (item)
def create_group (self, item):
win = gtk.Window ()
vbox = gtk.VBox ()
@ -1101,13 +1110,21 @@ text/plain
self._group = data
else:
# We were previously in a group
self._group = data
if data == None:
# We have been removed from a group
self._group = data
if not self.conf.titlebars and not self._want_titlebar:
self._titlebox.hide ()
self.terminator.group_hoover ()
def group_all (self, widget):
allname = _("All")
if not allname in self.terminator.groupings:
self.terminator.groupings.append (allname)
for term in self.terminator.term_list:
term.set_group (None, allname)
self.terminator.group_hoover ()
def on_encoding_change (self, widget, encoding):
current = self._vte.get_encoding ()
if current != encoding: