Guard urgency hint against being called on the wrong widget. Closes LP#1083243

This commit is contained in:
Chris Jones 2013-01-30 10:26:56 +00:00
parent bf72c3e4f2
commit b609914cc1
1 changed files with 2 additions and 1 deletions

View File

@ -1453,7 +1453,8 @@ class Terminal(gtk.VBox):
"""Set the urgency hint for our window""" """Set the urgency hint for our window"""
if self.config['urgent_bell'] == True: if self.config['urgent_bell'] == True:
window = self.get_toplevel() window = self.get_toplevel()
window.set_urgency_hint(True) if window.flags() & gtk.TOPLEVEL:
window.set_urgency_hint(True)
if self.config['icon_bell'] == True: if self.config['icon_bell'] == True:
self.titlebar.icon_bell() self.titlebar.icon_bell()