Esempio n. 1
0
 public void AllMPIbuttonsON()
 {
     ButtonsGroup.Invoke((MethodInvoker) delegate { ButtonsGroup.Enabled = true; });
     if (VKGroupIsEnable)
     {
         VKGroup.Invoke((MethodInvoker) delegate { VKGroup.Enabled = true; });
     }
 }
        public static async Task <IEnumerable <VKAudio> > GetGroupPlayList()
        {
            VKGroup group = MainViewModel.Instance.GroupsFilter.SelectedItem.Item;

            if (group == null)
            {
                return(null);
            }

            if (group.Type == VKGroup.TypeEnum.Page)
            {
                CheckCurrentCTS();

                try
                {
                    return(await GetAllAudioFromPost(-(long)group.Id, _currentCts.Token));
                }
                catch (OperationCanceledException)
                {
                }
            }
            if (group.Type == VKGroup.TypeEnum.Group)
            {
                CheckCurrentCTS();

                try
                {
                    VKList <VKAudio> list = (await AudioAPI.GetAsync(-(long)group.Id, token: _currentCts.Token));
                    return(list.Items);
                }
                catch (OperationCanceledException)
                {
                }
            }

            return(null);
        }
Esempio n. 3
0
 public void AllMPIbuttonsOFF()
 {
     ButtonsGroup.Invoke((MethodInvoker) delegate { ButtonsGroup.Enabled = false; });
     VKGroup.Invoke((MethodInvoker) delegate { VKGroup.Enabled = false; });
 }