public void CreateWindow() { if (ParentWindow != null) { return; } ParentWindow = new PatchWindow(); ParentWindow.DataContext = this; ParentWindow.Closing += (sender, args) => { StopPlanarization(); ParentWindow = null; DetachFromViewport(); }; ParentWindow.Show(); AttachToViewport(ParentWindow.Viewport); Viewport.IsRollOnly = true; Viewport.Camera.IsOrthogonal = true; Viewport.Camera.CenterOn(SurfaceMesh); }
public void CreateWindow() { if (ParentWindow != null) return; ParentWindow = new PatchWindow(); ParentWindow.DataContext = this; ParentWindow.Closing += (sender, args) => { StopPlanarization(); ParentWindow = null; DetachFromViewport(); }; ParentWindow.Show(); AttachToViewport(ParentWindow.Viewport); Viewport.IsRollOnly = true; Viewport.Camera.IsOrthogonal = true; Viewport.Camera.CenterOn(SurfaceMesh); }