Exemplo n.º 1
0
        private void channelGridView_ItemClick(object sender, ItemClickEventArgs e)
        {
            var dataItem = e.ClickedItem as ChannelListItem;

            if (dataItem != null)
            {
                if (ChannelTypeFactory.Instance.JudgeVipChannel(_typeItem.TypeName))
                {
                    if (PersonalFactory.Instance.Logined)
                    {
                        if (PersonalFactory.Instance.DataInfos[0].UserStateInfo.VIP != 1)
                        {
                            CommonUtils.ShowMessage(Utils.Constants.NotVip);
                            return;
                        }
                    }
                    else
                    {
                        CommonUtils.ShowMessageConfirm(Utils.Constants.NeedVip, () =>
                        {
                            Utils.CommonUtils.ShowUserLogin((ss, ee) =>
                            {
                                FirstPage.LoginSucess_Handler();
                                channelGridView_ItemClick(sender, e);
                            });
                        }, "登录");
                        return;
                    }
                }
                CommonUtils.DACNavagate(this.Frame, DACPageType.VOD, typeof(DetailPage), dataItem.ChannelId);
            }
        }
Exemplo n.º 2
0
 /// <summary>
 /// 登录
 /// </summary>
 /// <param name="sender"></param>
 /// <param name="e"></param>
 private void loginButton_Tapped(object sender, TappedRoutedEventArgs e)
 {
     Utils.CommonUtils.ShowUserLogin((ss, ee) =>
     {
         FirstPage.LoginSucess_Handler();
         LayoutContent.Visibility  = Visibility.Visible;
         loginButton.Visibility    = Visibility.Collapsed;
         LayoutContent.DataContext = PersonalFactory.Instance.DataInfos[0].UserStateInfo;
     });
 }