private SnapDialog() { this.DialogContent = (UIElement)FileTable.GetElement("Resources\\Timeline\\SnapDialog.xaml"); this.Title = StringTable.SnapDialogTitle; this.SizeToContent = SizeToContent.WidthAndHeight; this.snapEntryNumberEditor = (NumberEditor)ElementUtilities.FindElement((FrameworkElement)this, "SnapResolution"); }
public RepeatDialog() { this.DialogContent = (UIElement)FileTable.GetElement("Resources\\Timeline\\RepeatDialog.xaml"); this.Title = StringTable.RepeatDialogTitle; this.SizeToContent = SizeToContent.WidthAndHeight; this.repeatCountNumberEditor = ElementUtilities.FindElement((FrameworkElement)this, "RepeatCount") as NumberEditor; }
protected override void OnInitialized(EventArgs e) { if (!this.initialized) { this.DataContext = (object)this.model; this.menuHost = ElementUtilities.FindElement((FrameworkElement)this, "AddDataSourceMenuClickControl"); this.model.AddDataSourceMenuHost = this.menuHost; this.SetValue(PaletteRegistry.PaletteHeaderContentProperty, this.Resources[(object)"PaletteHeaderContent"]); this.initialized = true; } base.OnInitialized(e); }
private void CreateComponents() { this.Child = (UIElement)Microsoft.Expression.DesignSurface.FileTable.GetElement("Resources\\SceneScrollViewer.xaml"); this.zoomFitToScreenItem = ((FrameworkElement)this.Child).FindName("ZoomFitToScreenItem") as ComboBoxItem; this.horizontalScrollBar = (ExtendedScrollBar)ElementUtilities.FindElement((FrameworkElement)this, "HorizontalScrollBar"); this.horizontalScrollBar.ValueChanged += new RoutedPropertyChangedEventHandler <double>(this.HorizontalScrollBar_ValueChanged); this.verticalScrollBar = (ExtendedScrollBar)ElementUtilities.FindElement((FrameworkElement)this, "VerticalScrollBar"); this.verticalScrollBar.ValueChanged += new RoutedPropertyChangedEventHandler <double>(this.VerticalScrollBar_ValueChanged); ((Decorator)ElementUtilities.FindElement((FrameworkElement)this, "ArtboardBorder")).Child = (UIElement)this.artboard; this.artboard.DataContext = (object)null; this.artboard.FocusVisualStyle = (Style)null; InputMethod.SetIsInputMethodEnabled((DependencyObject)this.artboard, false); this.artboard.ZoomPresetCollection = SceneScrollViewer.zoomPresetCollection; this.artboard.ZoomComboCollection = SceneScrollViewer.zoomComboCollection; this.artboard.ZoomChanged += new EventHandler(this.Artboard_ZoomChanged); this.artboard.CenterChanged += new EventHandler(this.Artboard_CenterChanged); this.artboard.SnapToGridRenderer.Attach(this.sceneView.ViewModel.DesignerContext); if (this.sceneView.ViewModel.DesignerContext != null) { AnnotationService annotationService = this.sceneView.DesignerContext.AnnotationService; if (annotationService != null) { annotationService.ShowAnnotationsChanged += new EventHandler(this.AnnotationService_ShowAnnotationsChanged); annotationService.AnnotationsEnabledChanged += new EventHandler(this.AnnotationService_AnnotationsEnabledChanged); } } if (this.sceneView.ViewModel.DesignerContext.SnappingEngine != null) { this.sceneView.ViewModel.DesignerContext.ArtboardOptionsChanged += new EventHandler(this.OnArtboardOptionsChanged); } if (this.sceneView.ViewModel.DesignerContext.WindowService != null) { this.sceneView.ViewModel.DesignerContext.WindowService.ThemeChanged += new EventHandler(this.WindowManager_ThemeChanged); } this.sceneView.ViewModel.LateSceneUpdatePhase += new SceneUpdatePhaseEventHandler(this.ViewModel_LateSceneUpdate); this.UpdateSmallChange(); }
public HorizontalScrollManager(TimelineView timelineView) { this.timelineView = timelineView; this.timelineView.PropertyChanged += new PropertyChangedEventHandler(this.TimelineView_PropertyChanged); this.timeMarkerControl = (TimeMarkerControl)ElementUtilities.FindElement((FrameworkElement)timelineView, "TimeMarkerControl"); }