當前位置: 首頁>>代碼示例>>C#>>正文


C# Navigation.NavigationEventArgs類代碼示例

本文整理匯總了C#中System.Windows.Navigation.NavigationEventArgs的典型用法代碼示例。如果您正苦於以下問題:C# NavigationEventArgs類的具體用法?C# NavigationEventArgs怎麽用?C# NavigationEventArgs使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。


NavigationEventArgs類屬於System.Windows.Navigation命名空間,在下文中一共展示了NavigationEventArgs類的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的C#代碼示例。

示例1: OnNavigatedTo

        protected override void OnNavigatedTo(NavigationEventArgs e)
        {
            base.OnNavigatedTo(e);

            plan = GetSeletcedPlan();

            bookService = BookService.getInstance();

            List<string> pl = new List<string>() { "高", "中", "低" };
            this.prioritylist.ItemsSource = pl;

            this.prioritylist.SelectedItem = plan.Priority;

            this.bookname.Text = plan.Title;
            //this.bookname.IsEnabled = false;
            this.bookname.IsReadOnly = true;
            this.bookname.Foreground = new SolidColorBrush(Color.FromArgb(255, 0, 0, 0));

            if (flag)
            {
                this.datePicker.Value = DateTime.Parse(plan.DatePicker);
                this.timepicker.Value = DateTime.Parse(plan.RingTime);
                flag = false;
            }

            this.detail.Text = plan.Detail;

            this.toggle.IsChecked = plan.IsReminder;

            isRemind = plan.IsReminder;
        }
開發者ID:binarywizard,項目名稱:WP8Project,代碼行數:31,代碼來源:EditReadingPlan.xaml.cs

示例2: OnNavigatedTo

 protected override void OnNavigatedTo(NavigationEventArgs e)
 {
     base.OnNavigatedTo(e);
     string localvalue;
     if(NavigationContext.QueryString.TryGetValue("parameter",out localvalue))
         name_of_the_person = localvalue;
 }
開發者ID:Rushyendher,項目名稱:Virtual-Maps,代碼行數:7,代碼來源:ContactInfo.xaml.cs

示例3: OnNavigatedFrom

 protected override void OnNavigatedFrom(NavigationEventArgs e)
 {
     if (e.Content is Settings)
         (e.Content as Settings).PasswordsUpdated += PasswordPage_PasswordsUpdated;
     base.OnNavigatedFrom(e);
     
 }
開發者ID:astmus,項目名稱:PassKeeper,代碼行數:7,代碼來源:PasswordPage.xaml.cs

示例4: OnNavigatedTo

        protected override void OnNavigatedTo(
            bool cancelled, NavigationEventArgs e)
        {
            if (cancelled)
                return;

            _database = Cache.Database;
            if (_database == null)
            {
                this.BackToDBs();
                return;
            }

            string id;
            var queries = NavigationContext.QueryString;

            if (queries.TryGetValue("entry", out id))
                _entry = _database.GetEntry(id);
            else
            {
                id = queries["group"];
                _group = _database.GetGroup(id);
            }

            _target = _database.Root;
            Refresh();
        }
開發者ID:oldlaurel,項目名稱:WinPass,代碼行數:27,代碼來源:MoveTarget.xaml.cs

示例5: OnNavigatedTo

 /*
  * События страницы
  */
 protected override void OnNavigatedTo(NavigationEventArgs e)
 {
     if (!poiselectionViewModel.IsDataLoaded)
     {
         DataContext = LoadPoiSelectionData();
     }
 }
開發者ID:KiraariK,項目名稱:WaypointProject,代碼行數:10,代碼來源:PoiSelectionPage.xaml.cs

示例6: OnNavigatedTo

 protected override void OnNavigatedTo(NavigationEventArgs e)
 {
     App currentApp = (App)Application.Current;
     this.cityBox.Text = currentApp.Travel.Car.getFuelConsumptionForRouteType(Libs.ChangeRouteTypeTravelEvent.RouteTypes.citi).ToString();
     this.mixedBox.Text = currentApp.Travel.Car.getFuelConsumptionForRouteType(Libs.ChangeRouteTypeTravelEvent.RouteTypes.mixed).ToString();
     this.hwBox.Text = currentApp.Travel.Car.getFuelConsumptionForRouteType(Libs.ChangeRouteTypeTravelEvent.RouteTypes.hw).ToString();
 }
開發者ID:atomicus,項目名稱:wpaxi,代碼行數:7,代碼來源:FuelConsumption.xaml.cs

示例7: OnNavigatedTo

 protected override void OnNavigatedTo(NavigationEventArgs e)
 {
     var contextIndex = int.Parse(NavigationContext.QueryString["context"]);
     var repoName = NavigationContext.TryGetStringKey("repo");
     ViewModel.ContextIndex = contextIndex;
     ViewModel.RepoName = repoName;
 }
開發者ID:quandtm,項目名稱:Milestone,代碼行數:7,代碼來源:AddIssueView.xaml.cs

示例8: OnNavigatedTo

 protected override void OnNavigatedTo(NavigationEventArgs e)
 {
     if (ApiHelper.UserIsLoggedIn())
     {
         NavigationService.Navigate(new Uri("/MainPage.xaml", UriKind.Relative));
     }
 }
開發者ID:nforss,項目名稱:SujutWP8,代碼行數:7,代碼來源:Login.xaml.cs

示例9: Browser_Navigated

 private void Browser_Navigated(object sender, NavigationEventArgs e)
 {
     if (e.NavigationMode == NavigationMode.New)
       {
     _browserHistoryLength++;
       }
 }
開發者ID:chenkai,項目名稱:PhoneGap-Multi-Page-Navigate-,代碼行數:7,代碼來源:BackButtonHandler.cs

示例10: OnNavigatedTo

        protected override void OnNavigatedTo(
            bool cancelled, NavigationEventArgs e)
        {
            _moved = false;

            if (cancelled)
            {
                _moved = true;
                return;
            }

            SourceCapabilityUpdater.Update();

            if (AppSettings.Instance.AllowAnalytics == null)
            {
                _moved = true;
                this.NavigateTo<AnalyticsSettings>();
                return;
            }

            Cache.Clear();

            var checkTileOpen = e.NavigationMode !=
                NavigationMode.Back;
            RefreshDbList(checkTileOpen);
        }
開發者ID:AFPass,項目名稱:7Pass,代碼行數:26,代碼來源:MainPage.xaml.cs

示例11: OnNavigatedFrom

 protected override void OnNavigatedFrom(NavigationEventArgs e)
 {
     base.OnNavigatedFrom(e);
     CallbackManager.currentPage = null;
     GC.Collect();
     GC.WaitForPendingFinalizers();
 }
開發者ID:Jesn,項目名稱:MangGuoTv,代碼行數:7,代碼來源:MoreChannelInfo.xaml.cs

示例12: OnNavigatedTo

        protected async override void OnNavigatedTo(NavigationEventArgs e)
        {
            base.OnNavigatedTo(e);

            //string id = "";
            string id = string.Empty;
            if (NavigationContext.QueryString.TryGetValue("id", out id))
            {
                System.Diagnostics.Debug.WriteLine("ID de la pieza: " + id);
            }

            HttpClient client = new HttpClient();
            string json = await client.GetStringAsync(new Uri("http://museosapp.azurewebsites.net/Piezas/"+id));
            _piezas = Newtonsoft.Json.JsonConvert.DeserializeObject<List<Piezas>>(json);

            //Piezas piezas = NavigateServiceExtends.GetNavigationData(NavigationService) as Piezas;



            //System.Diagnostics.Debug.WriteLine("PIEZAAAAAAA: " + piezas.descripcion);
            //piezas.descripcion;
            //Ésta línea trae toda la información del museo que se ha seleccionado en otro xaml.
            // Y la muestra en el xaml actual.


            //this.DataContext = piezas;

            ElementosQR.ItemsSource = _piezas;
            loadPieza.Visibility = Visibility.Collapsed;
            txtCargando.Visibility = Visibility.Collapsed;
        }
開發者ID:casablancas,項目名稱:MuseosApp,代碼行數:31,代碼來源:InfoQR.xaml.cs

示例13: OnNavigatedTo

		// Load data for the ViewModel Items
		protected override async void OnNavigatedTo(NavigationEventArgs e)
		{
			if (!ViewModel.IsSignedIn)
			{
				await ViewModel.TryLoginAsync();
			}

			if (ContentPanorama.SelectedItem == RecentReadingItem && !ViewModel.IsRecentDataLoaded)
			{
				await ViewModel.UpdateRecentViewAsync();
			}
			else if (ContentPanorama.SelectedItem == SeriesIndexItem && !ViewModel.IsIndexDataLoaded)
			{
				await ViewModel.LoadSeriesIndexDataAsync();
			}
			else if (ContentPanorama.SelectedItem == RecommandItem && !ViewModel.IsRecommandLoaded)
			{
				await ViewModel.LoadRecommandDataAsync();
			}
			else if (ContentPanorama.SelectedItem == FavoriteSection && !ViewModel.IsFavoriteLoaded)
			{
				await ViewModel.LoadUserFavouriateAsync();
			}
			//else if (ContentPanorama.SelectedItem == UserRecentSection && !ViewModel.IsUserRecentLoaded)
			//{
			//	await ViewModel.LoadUserRecentAsync();
			//}
		}
開發者ID:fuchu,項目名稱:LightNovelClientWindows,代碼行數:29,代碼來源:MainPage.xaml.cs

示例14: OnNavigatedTo

 // Load data for the ViewModel Items
 protected override void OnNavigatedTo(NavigationEventArgs e)
 {
     if (!App.ViewModel.IsDataLoaded)
     {
         App.ViewModel.LoadData();
     }
 }
開發者ID:njlxyaoxinwei,項目名稱:SoundBoard,代碼行數:8,代碼來源:MainPage.xaml.cs

示例15: WebBrowser1_LoadCompleted

 private void WebBrowser1_LoadCompleted(object sender, NavigationEventArgs e)
 {
     if (e.Uri.ToString().IndexOf("access_token", StringComparison.Ordinal) != -1)
     {
         string accessToken = String.Empty;
         int userId = 0;
         var regex = new Regex(@"(?<name>[\w\d\x5f]+)=(?<value>[^\x26\s]+)", RegexOptions.IgnoreCase | RegexOptions.Singleline);
         foreach (Match match in regex.Matches(e.Uri.ToString()))
         {
             if (match.Groups["name"].Value == "access_token")
             {
                 accessToken = match.Groups["value"].Value;
             }
             else if (match.Groups["name"].Value == "user_id")
             {
                 userId = Convert.ToInt32(match.Groups["value"].Value);
             }
         }
         _token = new Token {AccessToken = accessToken, UserId = userId};
         var groupWindow = new GroupWindow();
         groupWindow.AccessToken.Content = _token.AccessToken;
         groupWindow.UserID.Content = _token.UserId;
         groupWindow.Show();
         this.Close();
     }
 }
開發者ID:JoyHood,項目名稱:VKparser,代碼行數:26,代碼來源:MainWindow.xaml.cs


注:本文中的System.Windows.Navigation.NavigationEventArgs類示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。