Try to always keep a focussed terminal. Closes LP #570706

This commit is contained in:
Chris Jones 2010-07-03 21:30:17 +01:00
parent 7522bb2b9d
commit 31e197d1bc
1 changed files with 5 additions and 0 deletions

View File

@ -145,6 +145,7 @@ class Paned(Container):
parent.remove(self)
self.cnxids.remove_all()
parent.add(sibling)
sibling.grab_focus()
del(self)
else:
dbg("Paned::wrapcloseterm: self.closeterm failed")
@ -251,6 +252,10 @@ class Paned(Container):
# this widget, but it probably needs to start at the deepest widget and
# work back up. Fun.
def grab_focus(self):
"""We don't want focus, we want a Terminal to have it"""
self.get_child1().grab_focus()
class HPaned(Paned, gtk.HPaned):
"""Merge gtk.HPaned into our base Paned Container"""
def __init__(self):