diff --git a/ChangeLog b/ChangeLog index 6c379b8c..7fcc4c61 100644 --- a/ChangeLog +++ b/ChangeLog @@ -5,6 +5,7 @@ terminator 0.96: by regular expression (Roberto Aguilar #709018) * Optimise various low level components so they are dramatically faster (Stephen Boddy) + * Fix various bugs (Stephen Boddy) terminator 0.95: * Add a configuration option to enable a DBus server diff --git a/terminatorlib/terminator.py b/terminatorlib/terminator.py index 357e31ac..600bc8d2 100755 --- a/terminatorlib/terminator.py +++ b/terminatorlib/terminator.py @@ -10,7 +10,7 @@ import gtk from borg import Borg from config import Config from keybindings import Keybindings -from util import dbg, err +from util import dbg, err, enumerate_descendants from factory import Factory from cwd import get_pid_cwd from version import APP_NAME, APP_VERSION @@ -50,7 +50,7 @@ class Terminator(Borg): self.terminals = [] if not self.groups: self.groups = [] - if not self.groupsend: + if self.groupsend == None: self.groupsend = self.groupsend_type['group'] if not self.config: self.config = Config() @@ -322,8 +322,13 @@ class Terminator(Borg): else: numstr = '%d' + terminals = [] + for window in self.windows: + containers, win_terminals = enumerate_descendants(window) + terminals.extend(win_terminals) + for term in self.get_target_terms(widget): - idx = self.terminals.index(term) + idx = terminals.index(term) term.feed(numstr % (idx + 1)) def get_target_terms(self, widget): diff --git a/terminatorlib/util.py b/terminatorlib/util.py index 1a92457d..bd5c2fa8 100755 --- a/terminatorlib/util.py +++ b/terminatorlib/util.py @@ -264,7 +264,7 @@ def enumerate_descendants(parent): terminals.append(descendant) while len(containerstmp) > 0: - child = containerstmp.pop() + child = containerstmp.pop(0) for descendant in child.get_children(): if maker.isinstance(descendant, 'Container'): containerstmp.append(descendant)