Messagelist subscription color
Fixes Bitmessage#842
This commit is contained in:
parent
484bdb0782
commit
a4c48228fc
|
@ -1040,7 +1040,7 @@ class MyForm(settingsmixin.SMainWindow):
|
||||||
def addMessageListItemInbox(self, tableWidget, msgfolder, msgid, toAddress, fromAddress, subject, received, read):
|
def addMessageListItemInbox(self, tableWidget, msgfolder, msgid, toAddress, fromAddress, subject, received, read):
|
||||||
font = QFont()
|
font = QFont()
|
||||||
font.setBold(True)
|
font.setBold(True)
|
||||||
if tableWidget == self.ui.tableWidgetInboxSubscriptions:
|
if toAddress == str_broadcast_subscribers:
|
||||||
acct = accountClass(fromAddress)
|
acct = accountClass(fromAddress)
|
||||||
else:
|
else:
|
||||||
acct = accountClass(toAddress)
|
acct = accountClass(toAddress)
|
||||||
|
|
|
@ -40,6 +40,7 @@ def getSortedSubscriptions(count = False):
|
||||||
|
|
||||||
def accountClass(address):
|
def accountClass(address):
|
||||||
if not shared.config.has_section(address):
|
if not shared.config.has_section(address):
|
||||||
|
# FIXME: This BROADCAST section makes no sense
|
||||||
if address == str_broadcast_subscribers:
|
if address == str_broadcast_subscribers:
|
||||||
subscription = BroadcastAccount(address)
|
subscription = BroadcastAccount(address)
|
||||||
if subscription.type != AccountMixin.BROADCAST:
|
if subscription.type != AccountMixin.BROADCAST:
|
||||||
|
|
|
@ -69,6 +69,9 @@ class AccountMixin (object):
|
||||||
self.type = self.CHAN
|
self.type = self.CHAN
|
||||||
elif shared.safeConfigGetBoolean(self.address, 'mailinglist'):
|
elif shared.safeConfigGetBoolean(self.address, 'mailinglist'):
|
||||||
self.type = self.MAILINGLIST
|
self.type = self.MAILINGLIST
|
||||||
|
elif sqlQuery(
|
||||||
|
'''select label from subscriptions where address=?''', self.address):
|
||||||
|
self.type = AccountMixin.SUBSCRIPTION
|
||||||
else:
|
else:
|
||||||
self.type = self.NORMAL
|
self.type = self.NORMAL
|
||||||
|
|
||||||
|
|
Reference in New Issue
Block a user