/// <summary> /// Invoked when this page is about to be displayed in a Frame. /// </summary> /// <param name="e">Event data that describes how this page was reached. The Parameter /// property is typically used to configure the page.</param> protected override void OnNavigatedTo(NavigationEventArgs e) { if (e.Parameter != null) { DataContext = MainVM = e.Parameter as VMMain; MainVM.PropertyChanged += (s, a) => { if (a.PropertyName == "SelectionMode") { UpdateSelectionMode(); } }; MainVM.RefreshSelectedZone(false); } }
private void Refresh_Click(object sender, RoutedEventArgs e) { MainVM.RefreshSelectedZone(true); }