/// <summary>
        ///     导航。
        /// </summary>
        public void Navigate(Type sourcePageType, object parameter,
                             NavigationTransition navigationTransition)
        {
            DispatcherHelper.CheckBeginInvokeOnUI(() => {
                NavigationTransitionInfo navigationTransitionInfo;
                switch (navigationTransition)
                {
                case NavigationTransition.EntranceNavigationTransition:
                    navigationTransitionInfo =
                        new EntranceNavigationTransitionInfo();
                    break;

                case NavigationTransition.DrillInNavigationTransition:
                    navigationTransitionInfo =
                        new DrillInNavigationTransitionInfo();
                    break;

                default:
                    navigationTransitionInfo =
                        new SuppressNavigationTransitionInfo();
                    break;
                }

                ((Frame)Window.Current.Content).Navigate(sourcePageType,
                                                         parameter, navigationTransitionInfo);
            });
        }
Ejemplo n.º 2
0
        public MainPage()
        {
            this.InitializeComponent();

            string family = AnalyticsInfo.VersionInfo.DeviceFamily;

            var appView  = ApplicationView.GetForCurrentView();
            var titleBar = appView.TitleBar;

            if (family.Contains("Desktop"))
            {
                CoreApplicationViewTitleBar coreTitleBar = CoreApplication.GetCurrentView().TitleBar;
                coreTitleBar.ExtendViewIntoTitleBar = false;
            }
            else if (family.Contains("Mobile"))
            {
                var statusBar = StatusBar.GetForCurrentView();
                statusBar.ShowAsync();
            }

            TransitionCollection      collection = new TransitionCollection();
            NavigationThemeTransition theme      = new NavigationThemeTransition();

            var info = new EntranceNavigationTransitionInfo();

            theme.DefaultNavigationTransitionInfo = info;
            collection.Add(theme);
            this.Transitions = collection;
        }
Ejemplo n.º 3
0
        private void UpdateForVisualState(VisualState newState, VisualState oldState = null)
        {
            var isNarrow = newState == NarrowState;

            if (isNarrow && oldState == DefaultState)
            {
                // Resize down to the detail item. Don't play a transition.
                switch (_lastSelectedItem)
                {
                case (int)SelectedItems.Dishes:
                    Frame.Navigate(typeof(DishesPage), _restaurant);
                    break;

                case (int)SelectedItems.ToComment:
                    Frame.Navigate(typeof(ToCommentPage), _restaurant);
                    break;

                default:
                    Frame.Navigate(typeof(CommentPage), _restaurant);
                    break;
                }
            }

            //EntranceNavigationTransitionInfo.SetIsTargetElement(RestaurantDetailPage, isNarrow);
            if (DetailContentPresenter != null)
            {
                EntranceNavigationTransitionInfo.SetIsTargetElement(DetailContentPresenter, !isNarrow);
            }
        }
Ejemplo n.º 4
0
        private void UpdateForVisualState(VisualState newState, VisualState oldState = null)
        {
            var isNarrow = ((Frame)Window.Current.Content).ActualWidth < 720;//newState == NarrowState;

            if (isNarrow)
            {
                DetailContentPresenter.Visibility = Visibility.Collapsed;
            }
            else
            {
                DetailContentPresenter.Visibility = Visibility.Visible;
            }

            if (isNarrow && oldState == DefaultState && _lastSelectedItem != null)
            {
                // Resize down to the detail item. Don't play a transition.
                Frame.Navigate(typeof(DetailVideoPage), _lastSelectedItem, new SuppressNavigationTransitionInfo());
            }

            EntranceNavigationTransitionInfo.SetIsTargetElement(MasterListView, isNarrow);
            if (DetailContentPresenter != null)
            {
                EntranceNavigationTransitionInfo.SetIsTargetElement(DetailContentPresenter, !isNarrow);
            }
        }
Ejemplo n.º 5
0
        private void UpdateForVisualState(VisualState newState, VisualState oldState = null)
        {
            var isNarrow = newState == NarrowState;

            if (isNarrow && oldState == DefaultState && ItemList.getInstance().SelectedItem != null)
            {
                // Resize down to the detail item. Don't play a transition.
                Frame.Navigate(typeof(DetailPage), null, new SuppressNavigationTransitionInfo());
            }

            EntranceNavigationTransitionInfo.SetIsTargetElement(MasterListView, isNarrow);
            if (DetailContentPresenter != null)
            {
                EntranceNavigationTransitionInfo.SetIsTargetElement(DetailContentPresenter, !isNarrow);
            }

            if (isNarrow)
            {
                shareButton.Visibility = Visibility.Collapsed;
                nextButton.Visibility  = Visibility.Collapsed;
                prevButton.Visibility  = Visibility.Collapsed;
            }
            else
            {
                shareButton.Visibility = Visibility.Visible;
                nextButton.Visibility  = Visibility.Visible;
                prevButton.Visibility  = Visibility.Visible;
            }
        }
Ejemplo n.º 6
0
        /// <summary>
        /// Method which handles the CurrentStateChanged event of VisualStateManager.
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void VisualStateGroup_CurrentStateChanged(object sender, VisualStateChangedEventArgs e)
        {
            // Start Project Nirvash
            // TODO: Implement Narrow State
            //bool isNarrow = e.NewState == NarrowState;
            //if (isNarrow)
            //{
            //    NavigationService.Navigate(typeof(AttachmentsNarrowPage), DidactictItem, new SuppressNavigationTransitionInfo());
            //}
            //else
            //{
            // Stop Project Nirvash
            VisualStateManager.GoToState(this, MasterDetailsState.Name, true);
            MasterListView.SelectionMode = ListViewSelectionMode.Extended;
            MasterListView.SelectedItem  = DidactictItem;
            // Start Project Nirvash
            //}

            //EntranceNavigationTransitionInfo.SetIsTargetElement(MasterListView, isNarrow);
            // Stop Project Nirvash
            if (DetailContentPresenter != null)
            {
                // Start Project Nirvash
                // ORG: EntranceNavigationTransitionInfo.SetIsTargetElement(DetailContentPresenter, !isNarrow);
                EntranceNavigationTransitionInfo.SetIsTargetElement(DetailContentPresenter, false);
                // Stop Project Nirvash
            }
        }
Ejemplo n.º 7
0
        private void intro_Tapped(object sender, TappedRoutedEventArgs e)
        {
            Frame frame = (Window.Current.Content) as Frame;
            EntranceNavigationTransitionInfo s = new EntranceNavigationTransitionInfo();

            frame.Navigate(typeof(instruction), null, s);
        }
Ejemplo n.º 8
0
        public void NavigateToPage(AppMenuItemType type, object parameter = null, bool isBack = false)
        {
            if (PageSplitView.DisplayMode == SplitViewDisplayMode.CompactOverlay)
            {
                IsSubPageOpen = false;
            }
            var  last     = MainFrameHistoryList.LastOrDefault();
            var  page     = GetPageTypeFromMenuType(type);
            bool isRepeat = false;

            if (last != null && last.Item1 == page && last.Item2 == parameter)
            {
                isRepeat = true;
            }
            if (page != null)
            {
                App.AppViewModel.CurrentPageType = page;
                NavigationTransitionInfo transitionInfo = null;
                if (type == AppMenuItemType.VideoPlayer || !App.AppViewModel.IsEnableAnimation)
                {
                    transitionInfo = new SuppressNavigationTransitionInfo();
                }
                else
                {
                    if (isBack)
                    {
                        transitionInfo = new EntranceNavigationTransitionInfo();
                    }
                    else
                    {
                        transitionInfo = new DrillInNavigationTransitionInfo();
                    }
                }
                PageFrame.Navigate(page, parameter, transitionInfo);
                if (!isBack)
                {
                    if (page.Equals(typeof(Pages.Main.VideoPage)) || page.Equals(typeof(Pages.Main.BangumiPage)))
                    {
                        MainFrameHistoryList.RemoveAll(p => p.Item1 == page);
                    }
                    if (!isRepeat)
                    {
                        MainFrameHistoryList.Add(new Tuple <Type, object>(page, parameter));
                    }
                    if (MainFrameHistoryList.Count > 1)
                    {
                        BackButton.Visibility = Visibility.Visible;
                    }
                }
                IsDefault = false;
            }
            else
            {
                IsDefault = true;
            }
            PageFrame.Focus(FocusState.Programmatic);
        }
Ejemplo n.º 9
0
        private void SetUpPageAnimation()
        {
            TransitionCollection      collection = new TransitionCollection();
            NavigationThemeTransition theme      = new NavigationThemeTransition();

            var info = new EntranceNavigationTransitionInfo();

            theme.DefaultNavigationTransitionInfo = info;
            collection.Add(theme);
            this.Transitions = collection;
        }
Ejemplo n.º 10
0
        private void UpdateForVisualState(VisualState newState, VisualState oldState = null)
        {
            var isNarrow = newState == NarrowState;

            if (isNarrow && oldState == DefaultState && _lastSelectedItem != null)
            {
                // Resize down to the detail item. Don't play a transition.
                DetailFrame.Navigate(typeof(MemoDetailPage), _lastSelectedItem.Id, new SuppressNavigationTransitionInfo());
            }

            EntranceNavigationTransitionInfo.SetIsTargetElement(MasterListView, isNarrow);
        }
Ejemplo n.º 11
0
        public FrameFacade(Frame frame)
        {
            _frame = frame;
            _navigatedEventHandlers = new List<EventHandler<NavigatedEventArgs>>();

            // setup animations
            var c = new TransitionCollection { };
            var t = new NavigationThemeTransition { };
            var i = new EntranceNavigationTransitionInfo();
            t.DefaultNavigationTransitionInfo = i;
            c.Add(t);
            _frame.ContentTransitions = c;
        }
        private void UpdateForVisualState(VisualState newState, VisualState oldState)
        {
            var isNarrow = newState == movil;

            clsPersona p = viewModel.personaSeleccionada;

            if (isNarrow && oldState == monitor && p != null)
            {
                Frame.Navigate(typeof(Detail), p, new SuppressNavigationTransitionInfo());
            }

            EntranceNavigationTransitionInfo.SetIsTargetElement(listaPersonas, isNarrow);
        }
Ejemplo n.º 13
0
 private async void scanbtn_Click(object sender, RoutedEventArgs e)
 {
     if (App.IsConnect == false)
     {
         Frame frame = (Window.Current.Content) as Frame;
         EntranceNavigationTransitionInfo s = new EntranceNavigationTransitionInfo();
         frame.Navigate(typeof(ScanScan), null, s);
     }
     else
     {
         await new MessageDialog("请先断开连接").ShowAsync();
     }
 }
Ejemplo n.º 14
0
        internal FrameFacade(Frame frame)
        {
            Frame = frame;
            frame.Navigated += (s, e) => FacadeNavigatedEventHandler(s, e);
            frame.Navigating += (s, e) => FacadeNavigatingCancelEventHandler(s, e);

            // setup animations
            var c = new TransitionCollection { };
            var t = new NavigationThemeTransition { };
            var i = new EntranceNavigationTransitionInfo();
            t.DefaultNavigationTransitionInfo = i;
            c.Add(t);
            Frame.ContentTransitions = c;
        }
Ejemplo n.º 15
0
        private void UpdateForVisualState(VisualState newState, VisualState oldState = null)
        {
            var isNarrow = newState == NarrowState;

            if (isNarrow && oldState == DefaultState && ViewModel.SelectedOrder != null)
            {
                Frame.Navigate(typeof(OrderDetailPage), ViewModel.SelectedOrder, new SuppressNavigationTransitionInfo());
            }

            EntranceNavigationTransitionInfo.SetIsTargetElement(OrdersOverViewListView, isNarrow);
            if (DetailContentPresenter != null)
            {
                EntranceNavigationTransitionInfo.SetIsTargetElement(DetailContentPresenter, !isNarrow);
            }
        }
Ejemplo n.º 16
0
        public FrameFacade(Frame frame)
        {
            _frame = frame;
            _navigatedEventHandlers = new List <EventHandler <NavigatedEventArgs> >();

            // setup animations
            var c = new TransitionCollection {
            };
            var t = new NavigationThemeTransition {
            };
            var i = new EntranceNavigationTransitionInfo();

            t.DefaultNavigationTransitionInfo = i;
            c.Add(t);
            _frame.ContentTransitions = c;
        }
        private void UpdateForVisualState(VisualState newState, VisualState oldState = null)
        {
            var isNarrow = newState == NarrowState;

            if (isNarrow && oldState == DefaultState && _lastSelectedItem != null)
            {
                // Resize down to the detail item. Don't play a transition.
                App.RootFrame.Navigate(typeof(StickerDetailSelectionPage), null, new SuppressNavigationTransitionInfo());
            }

            EntranceNavigationTransitionInfo.SetIsTargetElement(MasterListView, isNarrow);
            //if (DetailContentPresenter != null)
            //{
            //    EntranceNavigationTransitionInfo.SetIsTargetElement(DetailContentPresenter, !isNarrow);
            //}
        }
Ejemplo n.º 18
0
        private void UpdateForVisualState(VisualState newState, VisualState oldState = null)
        {
            var isNarrow = newState == VisualStateNarrow;

            if (isNarrow && oldState == VisualStateNormal && _selectedAccount != null)
            {
                // Resize down to the detail item. Don't play a transition.
                //Frame.Navigate(typeof(DetailPage), _lastSelectedItem.ItemId, new SuppressNavigationTransitionInfo());
            }

            EntranceNavigationTransitionInfo.SetIsTargetElement(MasterListView, isNarrow);
            if (DetailContentPresenter != null)
            {
                EntranceNavigationTransitionInfo.SetIsTargetElement(DetailContentPresenter, !isNarrow);
            }
        }
Ejemplo n.º 19
0
        private void UpdateForVisualState(VisualState newState, VisualState oldState = null)
        {
            var isNarrow = newState == VisualStateNarrow;

            if (isNarrow && oldState != VisualStateNarrow && _lastSelectedItem != null)
            {
                // Resize down to the detail item. Don't play a transition.
                //Frame.Navigate(typeof(WebViewPage), _lastSelectedItem.url, new SuppressNavigationTransitionInfo());
                ViewModel.NavigationService.Navigate(typeof(WebViewPage), _lastSelectedItem.url, new SuppressNavigationTransitionInfo());
            }
            EntranceNavigationTransitionInfo.SetIsTargetElement(MainPivot, isNarrow);
            if (MainWebView != null)
            {
                EntranceNavigationTransitionInfo.SetIsTargetElement(MainWebView, !isNarrow);
            }
        }
        private void UpdateForVisualState(VisualState newState, VisualState oldState = null)
        {
            var isNarrow = newState == NarrowState;

            if (isNarrow && oldState == this.DefaultState && selectedNote != null)
            {
                // Resize down to the detail item. Don't play a transition.
                Frame.Navigate(typeof(DetailPage), this.selectedNote, new SuppressNavigationTransitionInfo());
            }

            EntranceNavigationTransitionInfo.SetIsTargetElement(MasterListView, isNarrow);
            if (this.DetailContentPresenter != null)
            {
                EntranceNavigationTransitionInfo.SetIsTargetElement(DetailContentPresenter, !isNarrow);
            }
        }
Ejemplo n.º 21
0
        private void OnCurrentStateChanged(object sender, VisualStateChangedEventArgs e)
        {
            bool isNarrow = e.NewState == NarrowState;

            if (isNarrow)
            {
                Frame.Navigate(typeof(ApiDetails), apiItem, new SuppressNavigationTransitionInfo());
            }
            else
            {
                VisualStateManager.GoToState(this, MasterDetailsState.Name, true);
                MasterListView.SelectionMode = ListViewSelectionMode.Extended;
                MasterListView.SelectedItem  = apiItem;
            }

            EntranceNavigationTransitionInfo.SetIsTargetElement(MasterListView, isNarrow);
        }
Ejemplo n.º 22
0
        public HomePage()
        {
            //Use custom page transition
            TransitionCollection      collection = new TransitionCollection();
            NavigationThemeTransition theme      = new NavigationThemeTransition();
            var info = new EntranceNavigationTransitionInfo();

            theme.DefaultNavigationTransitionInfo = info;
            collection.Add(theme);
            this.Transitions = collection;

            //Initialize page
            this.InitializeComponent();

            //Keep the page in memory so we don't have to reload it everytime
            NavigationCacheMode = NavigationCacheMode.Enabled;
        }
Ejemplo n.º 23
0
        internal FrameFacade(Frame frame)
        {
            Frame             = frame;
            frame.Navigated  += (s, e) => FacadeNavigatedEventHandler(s, e);
            frame.Navigating += (s, e) => FacadeNavigatingCancelEventHandler(s, e);

            // setup animations
            var c = new TransitionCollection {
            };
            var t = new NavigationThemeTransition {
            };
            var i = new EntranceNavigationTransitionInfo();

            t.DefaultNavigationTransitionInfo = i;
            c.Add(t);
            Frame.ContentTransitions = c;
        }
Ejemplo n.º 24
0
        private void UpdateForVisualState(VisualState newState, VisualState oldState = null)
        {
            if (newState == NarrowState && oldState == DefaultState && _lastSelectedItem != null)
            {
                // Resize down to the detail item. Don't play a transition.
                Frame.Navigate(typeof(DetailPage), 0, new SuppressNavigationTransitionInfo());
            }
            else if (newState == DefaultState && oldState == NarrowState)
            {
                _lastSelectedItem = null;
            }

            var isNarrow = newState == NarrowState;

            EntranceNavigationTransitionInfo.SetIsTargetElement(MasterListView, isNarrow);

            Dispatcher.RunAsync(Windows.UI.Core.CoreDispatcherPriority.Normal, UpdateTitleBar);
        }
Ejemplo n.º 25
0
        private async void connectbtn_Click(object sender, RoutedEventArgs e)
        {
            if (App.IsConnect == false)
            {
                await new MessageDialog("请先连接").ShowAsync();
            }
            else
            {
                Frame frame = (Window.Current.Content) as Frame;
                //SuppressNavigationTransitionInfo s = new SuppressNavigationTransitionInfo();
                //CommonNavigationTransitionInfo s = new CommonNavigationTransitionInfo();

                //ContinuumNavigationTransitionInfo s = new ContinuumNavigationTransitionInfo();
                //DrillInNavigationTransitionInfo s = new DrillInNavigationTransitionInfo();
                EntranceNavigationTransitionInfo s = new EntranceNavigationTransitionInfo();
                //SlideNavigationTransitionInfo s = new SlideNavigationTransitionInfo();
                frame.Navigate(typeof(ControlComOperation), null, s);
            }
        }
Ejemplo n.º 26
0
        protected virtual void SetUpPageAnimation()
        {
            TransitionCollection      collection = new TransitionCollection();
            NavigationThemeTransition theme      = new NavigationThemeTransition();

            NavigationTransitionInfo info;

            if (DeviceHelper.IsMobile)
            {
                info = new EntranceNavigationTransitionInfo();
            }
            else
            {
                info = new ContinuumNavigationTransitionInfo();
            }

            theme.DefaultNavigationTransitionInfo = info;
            collection.Add(theme);
            Transitions = collection;
        }
Ejemplo n.º 27
0
        private void PageSizeStatesGroup_OnCurrentStateChanged(object sender, VisualStateChangedEventArgs e)
        {
            bool isNarrow = e.NewState == NarrowState;

            if (isNarrow)
            {
                Frame.Navigate(typeof(DetailsPage), selectedSystem, new SuppressNavigationTransitionInfo());
            }
            else
            {
                VisualStateManager.GoToState(this, MasterDetailsState.Name, true);
                RemoteSystemListView.SelectedItem = selectedSystem;
            }

            EntranceNavigationTransitionInfo.SetIsTargetElement(RemoteSystemListView, isNarrow);
            if (DetailContentPresenter != null)
            {
                EntranceNavigationTransitionInfo.SetIsTargetElement(DetailContentPresenter, !isNarrow);
            }
        }
Ejemplo n.º 28
0
        private void UpdateForVisualState(VisualState newState, VisualState oldState = null)
        {
            var isNarrow = newState == NarrowState;

            if (isNarrow && oldState == DefaultState && ViewModel.CurrentMix != null)
            {
                // Resize down to the detail item. Don't play a transition.
                Frame.Navigate(typeof(MixDetailPage), ViewModel.CurrentMix.InternalID, new SuppressNavigationTransitionInfo());
            }

            if (!isNarrow && oldState == NarrowState && ViewModel.CurrentMix != null)
            {
                MasterListView.SelectedItem = ViewModel.CurrentMix;
            }

            EntranceNavigationTransitionInfo.SetIsTargetElement(MasterListView, isNarrow);
            if (DetailContentPresenter != null)
            {
                EntranceNavigationTransitionInfo.SetIsTargetElement(DetailContentPresenter, !isNarrow);
            }
        }
Ejemplo n.º 29
0
        private void btnGotoEntranceNavigationTransitionInfo_Click2(object sender, RoutedEventArgs e)
        {
            EntranceNavigationTransitionInfo entranceTransition = new EntranceNavigationTransitionInfo();

            this.Frame.Navigate(typeof(MyFrame), entranceTransition);
        }
Ejemplo n.º 30
0
        //接收socketDisk通道的信息
        public async static void ReceiveCmd(object obj)
        {
            StreamSocket s = obj as StreamSocket;

            byte[] temp         = null;
            byte[] buffer       = null;
            byte[] bufferlength = null;
            byte[] recvbuffer   = null;
            int    length;

            while (true)
            {
                recvbuffer = new byte[0];
                string     info   = null;
                DataReader reader = new DataReader(s.InputStream);
                reader.InputStreamOptions = InputStreamOptions.Partial;
                reader.UnicodeEncoding    = Windows.Storage.Streams.UnicodeEncoding.Utf8;
                try
                {
                    bufferlength = new byte[sizeof(Int32)];
                    await reader.LoadAsync(sizeof(Int32));

                    reader.ReadBytes(bufferlength);
                    //reader.DetachStream();
                    length = BitConverter.ToInt32(bufferlength, 0);
                    int notRcvLength = length;
                    //作为接收缓存区,每次最多接收length的字节,最少大于0
                    buffer = new byte[length];
                    while (recvbuffer.Length < length || notRcvLength != 0)
                    {
                        uint count = await reader.LoadAsync((uint)length);

                        notRcvLength -= (int)count;
                        temp          = new byte[count];
                        reader.ReadBytes(temp);
                        recvbuffer = recvbuffer.Concat(temp).ToArray();
                    }

                    reader.DetachStream();
                    //reader.Dispose();
                }
                catch (Exception e)
                {
                    Debug.WriteLine(e.Message);
                    //await new MessageDialog(e.Message).ShowAsync();
                    return;
                }
                info = Encoding.UTF8.GetString(recvbuffer);
                Debug.WriteLine("SocketCmd接收的信息:" + info);
                //接收到的是磁盘信息
                if (info != "" && info.Contains("XiYou#"))
                {
                    string[] sendinfo = Regex.Split(info, "#");
                    //MainViewModel.m.rcvMsg = sendinfo[1];
                    //字符串反序列化
                    folderlist = JsonConvert.DeserializeObject <List <DiskFolder> >(sendinfo[1]);
                    if (folderlist.Count > 0)
                    {
                        if (folderlist[0].Lable == "本地磁盘")
                        {
                            Frame frame = (Window.Current.Content) as Frame;
                            EntranceNavigationTransitionInfo s1 = new EntranceNavigationTransitionInfo();
                            frame.Navigate(typeof(ComOperation), folderlist, s1);
                        }
                        else if (folderlist[0].Lable == "PPTSHOW")
                        {
                            Frame frame = (Window.Current.Content) as Frame;
                            SuppressNavigationTransitionInfo s1 = new SuppressNavigationTransitionInfo();
                            frame.Navigate(typeof(DiskShow), folderlist, s1);
                        }
                        else if (folderlist[0].Lable == "PPTDO")
                        {
                            Frame frame = (Window.Current.Content) as Frame;
                            SuppressNavigationTransitionInfo s1 = new SuppressNavigationTransitionInfo();
                            frame.Navigate(typeof(DiskPPTShow), folderlist, s1);
                        }
                    }
                    else
                    {
                        if (App.PPTOperation == "PPTSHOW")
                        {
                            DiskFolder diskfolder = new DiskFolder();
                            diskfolder.FullName = "";
                            diskfolder.Name     = "文件夹为空";
                            diskfolder.Lable    = "";
                            diskfolder.FileTyp  = "";
                            folderlist.Add(diskfolder);

                            Frame frame = (Window.Current.Content) as Frame;
                            SuppressNavigationTransitionInfo s1 = new SuppressNavigationTransitionInfo();
                            frame.Navigate(typeof(DiskShow), folderlist, s1);
                        }
                        else if (App.PPTOperation == "PPTDO")
                        {
                            DiskFolder diskfolder = new DiskFolder();
                            diskfolder.FullName = "";
                            diskfolder.Name     = "文件夹为空";
                            diskfolder.Lable    = "";
                            diskfolder.FileTyp  = "";

                            folderlist.Add(diskfolder);
                            Frame frame = (Window.Current.Content) as Frame;
                            SuppressNavigationTransitionInfo s1 = new SuppressNavigationTransitionInfo();
                            frame.Navigate(typeof(DiskPPTShow), folderlist, s1);
                        }
                    }
                }
                else
                {
                    byte[] writebuffer = new byte[length];
                    App.screenbuffer = GetSendBuffer(writebuffer, recvbuffer);
                }
            }
        }