Merge branch '1211' into v0.6
This commit is contained in:
commit
c76074df8c
|
@ -1,15 +1,21 @@
|
||||||
from helper_sql import *
|
"""Helper Inbox performs inbox messagese related operations."""
|
||||||
|
|
||||||
|
from helper_sql import sqlExecute, sqlQuery
|
||||||
import queues
|
import queues
|
||||||
|
|
||||||
|
|
||||||
def insert(t):
|
def insert(t):
|
||||||
sqlExecute('''INSERT INTO inbox VALUES (?,?,?,?,?,?,?,?,?,?)''', *t)
|
sqlExecute('''INSERT INTO inbox VALUES (?,?,?,?,?,?,?,?,?,?)''', *t)
|
||||||
#shouldn't emit changedInboxUnread and displayNewInboxMessage at the same time
|
# shouldn't emit changedInboxUnread and displayNewInboxMessage
|
||||||
#queues.UISignalQueue.put(('changedInboxUnread', None))
|
# at the same time
|
||||||
|
# queues.UISignalQueue.put(('changedInboxUnread', None))
|
||||||
|
|
||||||
|
|
||||||
def trash(msgid):
|
def trash(msgid):
|
||||||
sqlExecute('''UPDATE inbox SET folder='trash' WHERE msgid=?''', msgid)
|
sqlExecute('''UPDATE inbox SET folder='trash' WHERE msgid=?''', msgid)
|
||||||
queues.UISignalQueue.put(('removeInboxRowByMsgid',msgid))
|
queues.UISignalQueue.put(('removeInboxRowByMsgid', msgid))
|
||||||
|
|
||||||
|
|
||||||
def isMessageAlreadyInInbox(sigHash):
|
def isMessageAlreadyInInbox(sigHash):
|
||||||
queryReturn = sqlQuery(
|
queryReturn = sqlQuery(
|
||||||
'''SELECT COUNT(*) FROM inbox WHERE sighash=?''', sigHash)
|
'''SELECT COUNT(*) FROM inbox WHERE sighash=?''', sigHash)
|
||||||
|
|
Loading…
Reference in New Issue
Block a user