changes in cwtch event.queue

This commit is contained in:
Dan Ballard 2019-08-14 15:30:24 -07:00
parent ccf497c840
commit 882a9abefb
2 changed files with 15 additions and 15 deletions

View File

@ -13,12 +13,12 @@ import (
)
func AppEventListener(gcd *gothings.GrandCentralDispatcher, subscribed chan bool) {
q := event.NewEventQueue(1000)
the.AppBus.Subscribe(event.NewPeer, q.EventChannel)
the.AppBus.Subscribe(event.PeerError, q.EventChannel)
the.AppBus.Subscribe(event.AppError, q.EventChannel)
the.AppBus.Subscribe(event.ACNStatus, q.EventChannel)
the.AppBus.Subscribe(event.ReloadDone, q.EventChannel)
q := event.NewQueue()
the.AppBus.Subscribe(event.NewPeer, q)
the.AppBus.Subscribe(event.PeerError, q)
the.AppBus.Subscribe(event.AppError, q)
the.AppBus.Subscribe(event.ACNStatus, q)
the.AppBus.Subscribe(event.ReloadDone, q)
subscribed <- true
for {

View File

@ -12,15 +12,15 @@ import (
)
func IncomingListener(uiState *gothings.InterfaceState, subscribed chan bool) {
q := event.NewEventQueue(1000)
the.EventBus.Subscribe(event.NewMessageFromPeer, q.EventChannel)
the.EventBus.Subscribe(event.PeerAcknowledgement, q.EventChannel)
the.EventBus.Subscribe(event.NewMessageFromGroup, q.EventChannel)
the.EventBus.Subscribe(event.NewGroupInvite, q.EventChannel)
the.EventBus.Subscribe(event.SendMessageToGroupError, q.EventChannel)
the.EventBus.Subscribe(event.SendMessageToPeerError, q.EventChannel)
the.EventBus.Subscribe(event.ServerStateChange, q.EventChannel)
the.EventBus.Subscribe(event.PeerStateChange, q.EventChannel)
q := event.NewQueue()
the.EventBus.Subscribe(event.NewMessageFromPeer, q)
the.EventBus.Subscribe(event.PeerAcknowledgement, q)
the.EventBus.Subscribe(event.NewMessageFromGroup, q)
the.EventBus.Subscribe(event.NewGroupInvite, q)
the.EventBus.Subscribe(event.SendMessageToGroupError, q)
the.EventBus.Subscribe(event.SendMessageToPeerError, q)
the.EventBus.Subscribe(event.ServerStateChange, q)
the.EventBus.Subscribe(event.PeerStateChange, q)
subscribed <- true
for {