private void MainPage_OnLoaded(object sender, RoutedEventArgs e) { var display = DisplayInformation.GetForCurrentView(); display.DpiChanged += Display_DpiChanged; Display_DpiChanged(display, null); MapCanvas.Focus(FocusState.Programmatic); SetTheme(); }
private void MapBrowser_TabStripItemSelectionChanged_1(TabStripItemChangedEventArgs e) { if (e.ChangeType == FATabStripItemChangeTypes.SelectionChanged && activeMapEditor != null) { activeMapEditor.RemoveCanvas(mapCanvas); activeMapEditor = (MapEditor)e.Item; activeMapEditor.UpdateCanvas(mapCanvas); mapCanvas.Focus(); } }