diff --git a/terminatorlib/newterminator.py b/terminatorlib/newterminator.py index 603a322f..2bd11e38 100755 --- a/terminatorlib/newterminator.py +++ b/terminatorlib/newterminator.py @@ -143,6 +143,20 @@ class Terminator(Borg): for group in todestroy: self.groups.remove(group) + def group_emit(self, terminal, group, type, event): + """Emit to each terminal in a group""" + dbg('Terminator::group_emit: emitting a keystroke for group %s' % + group) + for term in self.terminals: + if term != terminal and term.group == group: + term.vte.emit(type, event) + + def all_emit(self, terminal, type, event): + """Emit to all terminals""" + for term in self.terminals: + if term != terminal: + term.vte.emit(type, event) + def do_enumerate(self, widget, pad): """Insert the number of each terminal in a group, into that terminal""" if pad: diff --git a/terminatorlib/terminal.py b/terminatorlib/terminal.py index 1138355e..caeb841c 100755 --- a/terminatorlib/terminal.py +++ b/terminatorlib/terminal.py @@ -394,6 +394,7 @@ class Terminal(gtk.VBox): if self.group == name: # already in this group, no action needed return + dbg('Terminal::set_group: Setting group to %s' % name) self.group = name self.titlebar.set_group_label(name) self.terminator.group_hoover()