Tag channel list window when there is unread channels
This commit is contained in:
parent
cd6ff6f164
commit
ae535290f7
|
@ -135,9 +135,16 @@ class dbfApp:
|
|||
index += 1
|
||||
|
||||
global oldUnreadChannels
|
||||
unreadChannelsLength = len(unreadChannels)
|
||||
if oldUnreadChannels != unreadChannels:
|
||||
for gui in openGuis:
|
||||
if gui.type == "channels":
|
||||
if unreadChannelsLength > 0:
|
||||
gui.title = "* Channels"
|
||||
gui.window.setWindowTitle(getTitle(gui.title))
|
||||
else:
|
||||
gui.title = "Channels"
|
||||
gui.window.setWindowTitle(getTitle(gui.title))
|
||||
gui.repopulateChannels("conversations")
|
||||
oldUnreadChannels = unreadChannels.copy()
|
||||
fh = open(p(loginPath,"unreadChannels.json"),"w")
|
||||
|
@ -412,6 +419,8 @@ class guiChannels:
|
|||
self.closed = False
|
||||
self.type = "channels"
|
||||
self.title = "Channels"
|
||||
global unreadChannels
|
||||
if len(unreadChannels) > 0: self.title = "* " +self.title
|
||||
self.width = 200
|
||||
self.height = 350
|
||||
self.window = dbfMainWindow(customEventFilter = (self,self.eventFilter))
|
||||
|
|
Loading…
Reference in New Issue