Exemplo n.º 1
0
        protected override async void OnNavigatedFrom(NavigationEventArgs e)
        {
            base.OnNavigatedFrom(e);
            if (((App)App.Current).isSuspending)
            {
                SuspendingManager manager = new SuspendingManager("MainPage");
                await manager.Suspend(itemEditor);
            }

            //App to App
            DataTransferManager dataTransferManager = DataTransferManager.GetForCurrentView();

            dataTransferManager.DataRequested -=
                new TypedEventHandler <DataTransferManager, DataRequestedEventArgs>(DataTransferManager_DataRequested);
        }
Exemplo n.º 2
0
 protected override async void OnNavigatedFrom(NavigationEventArgs e)
 {
     base.OnNavigatedFrom(e);
     if (((App)App.Current).isSuspending)
     {
         SuspendingManager manager = new SuspendingManager("NewPage");
         await manager.Suspend(editor);
     }
     else
     {
         if (Items.SelectedItem != null)
         {
             Items.SelectedItem = null;
         }
     }
 }
Exemplo n.º 3
0
 protected override void OnNavigatedTo(NavigationEventArgs e)
 {
     base.OnNavigatedTo(e);
     if (e.NavigationMode == NavigationMode.New)
     {
         ApplicationData.Current.LocalSettings.Values.Remove("NewPage");
     }
     else
     {
         if (ApplicationData.Current.LocalSettings.Values.ContainsKey("NewPage"))
         {
             SuspendingManager manager = new SuspendingManager("NewPage");
             manager.Resume(editor);
         }
     }
 }
Exemplo n.º 4
0
        protected override void OnNavigatedTo(NavigationEventArgs e)
        {
            base.OnNavigatedTo(e);
            if (e.NavigationMode == NavigationMode.New)
            {
                ApplicationData.Current.LocalSettings.Values.Remove("MainPage");
            }
            else
            {
                if (ApplicationData.Current.LocalSettings.Values.ContainsKey("MainPage"))
                {
                    SuspendingManager manager = new SuspendingManager("MainPage");
                    manager.Resume(itemEditor);
                }
            }

            //App to App
            DataTransferManager dataTransferManager = DataTransferManager.GetForCurrentView();

            dataTransferManager.DataRequested +=
                new TypedEventHandler <DataTransferManager, DataRequestedEventArgs>(DataTransferManager_DataRequested);
        }