kivy_screens.py 文件源码

python
阅读 37 收藏 0 点赞 0 评论 0

项目:bptc_wallet 作者: ceddie 项目源码 文件源码
def __init__(self, network, defaults, app):
        self.network = network
        self.defaults = defaults
        self.pushing = False
        self.app = app
        super().__init__()

        # endless loop for updating information displayed
        def update_statistics():
            self.ids.listening_interface_label.text = 'Listening interface: {}:{}'.format(bptc.ip, bptc.port)
            self.ids.event_count_label.text = '{} events, {} confirmed'.format(len(self.hashgraph.lookup_table.keys()),
                                                                               len(self.hashgraph.ordered_events))
            self.ids.last_push_sent_label.text = 'Last push sent: {}'.format(self.network.last_push_sent)
            self.ids.last_push_received_label.text = 'Last push received: {}'.format(self.network.last_push_received)

            t = threading.Timer(1, update_statistics)
            t.daemon = True
            t.start()

        update_statistics()
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号