Exemplo n.º 1
0
        void Initialize(
            [Inject] Service.Events.IEventsService eventService,
            [Inject] DisposableManager dManager
            )
        {
            _eventService = eventService;

            _dManager = dManager;
            _dManager.Add(this);

            disposables.Add(_eventService.OnEvent <Service.Backend.Events.GotUserDataEvent>().Subscribe(e => OnGotUserData(e)));
        }
Exemplo n.º 2
0
 /// <summary>
 /// Subscribe to a global event of type TEvent
 /// </summary>
 /// <typeparam name="TEvent">The 1st type parameter.</typeparam>
 protected IObservable <TEvent> OnEvent <TEvent>()
 {
     return(eventService.OnEvent <TEvent>());
 }
Exemplo n.º 3
0
 /// <summary>
 /// Subscribe to a global event of type TEvent
 /// </summary>
 /// <typeparam name="TEvent">The 1st type parameter.</typeparam>
 public IObservable <TEvent> OnEvent <TEvent>()
 {
     return(_eventService.OnEvent <TEvent>());
 }