2
0
mirror of https://github.com/kotatogram/kotatogram-desktop synced 2025-08-31 22:55:11 +00:00

New way for subscribe/notify async about any events.

Two classes base::Observable<Event> and base::Subscriber were added.
base::Observable<Event> can notify about Event-s, while any
base::Subscriber can subscribe and then async receive them.
This commit is contained in:
John Preston
2016-08-18 21:27:43 +02:00
parent 90678d411f
commit ea955635ac
10 changed files with 416 additions and 11 deletions

View File

@@ -577,6 +577,7 @@ struct Data {
SingleDelayedCall HandleUnreadCounterUpdate = { App::app(), "call_handleUnreadCounterUpdate" };
SingleDelayedCall HandleFileDialogQueue = { App::app(), "call_handleFileDialogQueue" };
SingleDelayedCall HandleDelayedPeerUpdates = { App::app(), "call_handleDelayedPeerUpdates" };
SingleDelayedCall HandleObservables = { App::app(), "call_handleObservables" };
Adaptive::Layout AdaptiveLayout = Adaptive::NormalLayout;
bool AdaptiveForWide = true;
@@ -654,6 +655,7 @@ DefineRefVar(Global, SingleDelayedCall, HandleHistoryUpdate);
DefineRefVar(Global, SingleDelayedCall, HandleUnreadCounterUpdate);
DefineRefVar(Global, SingleDelayedCall, HandleFileDialogQueue);
DefineRefVar(Global, SingleDelayedCall, HandleDelayedPeerUpdates);
DefineRefVar(Global, SingleDelayedCall, HandleObservables);
DefineVar(Global, Adaptive::Layout, AdaptiveLayout);
DefineVar(Global, bool, AdaptiveForWide);