Fix bug where titlebars was not appearing
when: 1 - Open up Terminator (im running Bzr revision 297), the orange titlebar in the terminal wont be open 2 - Open up a new terminal (Ctrl+Shift+E) 3 - An orange titlebar will be in the top of the newly spawned terminal, but there wont be one in the original,initial terminal Fixes LP#235083
This commit is contained in:
parent
4a8896b68f
commit
049582453a
15
terminator
15
terminator
|
@ -126,7 +126,7 @@ class TerminatorTerm (gtk.VBox):
|
||||||
self.pack_start(self._titlebox, False)
|
self.pack_start(self._titlebox, False)
|
||||||
self.pack_start(self._termbox)
|
self.pack_start(self._termbox)
|
||||||
|
|
||||||
if self.conf.titlebars and len(self.terminator.term_list)>0:
|
if self.conf.titlebars:
|
||||||
self._titlebox.show()
|
self._titlebox.show()
|
||||||
else:
|
else:
|
||||||
self._titlebox.hide()
|
self._titlebox.hide()
|
||||||
|
@ -896,6 +896,7 @@ class Terminator:
|
||||||
self.term_list = [term]
|
self.term_list = [term]
|
||||||
|
|
||||||
self.window.add (term)
|
self.window.add (term)
|
||||||
|
term._titlebox.hide()
|
||||||
self.window.show ()
|
self.window.show ()
|
||||||
term.spawn_child ()
|
term.spawn_child ()
|
||||||
|
|
||||||
|
@ -1006,11 +1007,15 @@ class Terminator:
|
||||||
position = (vertical) and parent.allocation.height \
|
position = (vertical) and parent.allocation.height \
|
||||||
or parent.allocation.width
|
or parent.allocation.width
|
||||||
|
|
||||||
|
if (isinstance (parent, gtk.Notebook) or isinstance (parent, gtk.Window)) \
|
||||||
|
and \
|
||||||
|
widget.conf.titlebars:
|
||||||
|
#not the only term in the notebook/window anymore, need to reshow the title
|
||||||
|
widget._titlebox.show()
|
||||||
|
|
||||||
if isinstance (parent, gtk.Notebook):
|
if isinstance (parent, gtk.Notebook):
|
||||||
page = -1
|
page = -1
|
||||||
#not the only term in the notebook anymore, need to reshow the title
|
|
||||||
if widget.conf.titlebars:
|
|
||||||
widget._titlebox.show()
|
|
||||||
for i in range(0, parent.get_n_pages()):
|
for i in range(0, parent.get_n_pages()):
|
||||||
if parent.get_nth_page(i) == widget:
|
if parent.get_nth_page(i) == widget:
|
||||||
page = i
|
page = i
|
||||||
|
@ -1062,12 +1067,12 @@ class Terminator:
|
||||||
pane.set_position (position / 2)
|
pane.set_position (position / 2)
|
||||||
terminal.show ()
|
terminal.show ()
|
||||||
|
|
||||||
|
|
||||||
# insert the term reference into the list
|
# insert the term reference into the list
|
||||||
index = self.term_list.index (widget)
|
index = self.term_list.index (widget)
|
||||||
if pos in ('bottom', 'right'):
|
if pos in ('bottom', 'right'):
|
||||||
index = index + 1
|
index = index + 1
|
||||||
self.term_list.insert (index, terminal)
|
self.term_list.insert (index, terminal)
|
||||||
|
|
||||||
# make the new terminal grab the focus
|
# make the new terminal grab the focus
|
||||||
terminal._vte.grab_focus ()
|
terminal._vte.grab_focus ()
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue