private void InitializeCallIndicators() { DomainEvents.Register<CallStatusChanged>(args => { callStatus = args.CallStatus; skypeLightNotifyIcon.Icon = args.CallStatus == CallStatus.NotOnCall ? Resources.NoCallStatusIcon : Resources.OnCallStatusIcon; }); busylightService = new BusylightService(new BusylightAdapter()); busylightService.Initialize(); }
private void InitializeCallIndicators() { DomainEvents.Register<CallStatusChanged>(args => { callStatus = args.CallStatus; skypeLightNotifyIcon.Icon = args.CallStatus == CallStatus.NotOnCall ? Resources.NoCallStatusIcon : Resources.OnCallStatusIcon; }); DomainEvents.Register<ToggleStatusRequested>(args => { if (callStatus == CallStatus.NotOnCall) { DomainEvents.Raise(new CallStatusChanged(CallStatus.OnAudioCall)); } else if (callStatus == CallStatus.OnAudioCall) { DomainEvents.Raise(new CallStatusChanged(CallStatus.NotOnCall)); } }); busylightService = new BusylightService(new BusylightAdapter()); busylightService.Initialize(); }