Bug fix: De-op in memos correctly

This commit is contained in:
Kiooeht 2011-05-09 17:51:34 -07:00
parent ea466251ea
commit 3976faa3a7
2 changed files with 10 additions and 1 deletions

View file

@ -29,6 +29,7 @@ CHANGELOG
* Quirk order actually works - Kiooeht [evacipatedBox]
* Stay in memos on profile switch - Kiooeht [evacipatedBox]
* Auto rejoin memos on reconnect - Kiooeht [evacipatedBox]
* De-Op in memos correctly - Kiooeht [evacipatedBox]
### 3.14.1
* Pesterchum 3.14 - illuminatedwax [ghostDunk]

View file

@ -631,7 +631,7 @@ class PesterMemo(PesterConvo):
oldnick = l[0]
newnick = l[1]
h = oldnick
if (update in ["join","left", "kick", "+o"]) \
if (update in ["join","left", "kick", "+o", "-o"]) \
and channel != self.channel:
return
chums = self.userlist.findItems(h, QtCore.Qt.MatchFlags(0))
@ -718,6 +718,14 @@ class PesterMemo(PesterConvo):
if unicode(c.text()) == self.mainwindow.profile().handle:
self.userlist.optionsMenu.addAction(self.opAction)
self.userlist.optionsMenu.addAction(self.banuserAction)
elif update == "-o":
chums = self.userlist.findItems(h, QtCore.Qt.MatchFlags(0))
for c in chums:
icon = QtGui.QIcon()
c.setIcon(icon)
if unicode(c.text()) == self.mainwindow.profile().handle:
self.userlist.optionsMenu.removeAction(self.opAction)
self.userlist.optionsMenu.removeAction(self.banuserAction)
@QtCore.pyqtSlot()
def addChumSlot(self):