示例#1
0
        public MainPage()
        {
            this.InitializeComponent();

            this.NavigationCacheMode = NavigationCacheMode.Required;
            App.Current.Suspending  += async(o, e) => await client.DeactivateAsync();

            dispatcher = CoreWindow.GetForCurrentThread().Dispatcher;

            localSettings = ApplicationData.Current.LocalSettings;

            InitializeEngine();
            InitializeUI();
        }
示例#2
0
 private async void Page_Unloaded(object sender, RoutedEventArgs e)
 {
     await client.DeactivateAsync();
 }
示例#3
0
 private void Page_Unloaded(object sender, RoutedEventArgs e)
 {
     server.Deactivate();
     client.DeactivateAsync();
 }