This repository has been archived on 2024-12-19. You can view files and clone it, but cannot push or open issues or pull requests.
PyBitmessage-2024-12-19/src/bitmessagekivy/uikivysignaler.py
2019-12-23 20:04:49 +05:30

29 lines
846 B
Python

"""
Ui Singnaler for kivy interface
"""
from threading import Thread
import queues
import state
from semaphores import kivyuisignaler
class UIkivySignaler(Thread):
"""Kivy ui signaler"""
def run(self):
kivyuisignaler.acquire()
while state.shutdown == 0:
try:
command, data = queues.UISignalQueue.get()
if command == 'writeNewAddressToTable':
address = data[1]
state.kivyapp.variable_1.append(address)
# elif command == 'rerenderAddressBook':
# state.kivyapp.obj_1.refreshs()
# Need to discuss this
elif command == 'updateSentItemStatusByAckdata':
state.kivyapp.status_dispatching(data)
except Exception as e:
print(e)