示例#1
0
        public void GetEffects(bool forAll)
        {
            if (StreamingSetup.Layers?.Count > 0)
            {
                var allEffects = EffectService.GetEffectViewModels();

                if (forAll)
                {
                    Clients.All.SendAsync("effects", allEffects);
                }
                else
                {
                    Clients.Caller.SendAsync("effects", allEffects);
                }
            }
        }
示例#2
0
        public Task GetEffects(bool forAll)
        {
            if (StreamingSetup.Layers?.Count > 0)
            {
                var allEffects = EffectService.GetEffectViewModels();

                if (forAll)
                {
                    return(Clients.All.SendAsync("effects", allEffects));
                }
                else
                {
                    return(Clients.Caller.SendAsync("effects", allEffects));
                }
            }

            return(Task.CompletedTask);
        }