예제 #1
0
		public PartPreviewContent(PrintItemWrapper printItem, View3DWidget.WindowMode windowMode, View3DWidget.AutoRotate autoRotate3DView, View3DWidget.OpenMode openMode = View3DWidget.OpenMode.Viewing)
		{
			this.openMode = openMode;
			this.autoRotate3DView = autoRotate3DView;
			this.windowMode = windowMode;

			BackgroundColor = ActiveTheme.Instance.PrimaryBackgroundColor;
			this.AnchorAll();
			this.Load(printItem);

			// We do this after showing the system window so that when we try and take focus of the parent window (the system window)
			// it exists and can give the focus to its child the gcode window.
			if (printItem != null
				&& Path.GetExtension(printItem.FileLocation).ToUpper() == ".GCODE")
			{
				SwitchToGcodeView();
			}
		}
        public PartPreviewContent(PrintItemWrapper printItem, View3DWidget.WindowMode windowMode, View3DWidget.AutoRotate autoRotate3DView, View3DWidget.OpenMode openMode = View3DWidget.OpenMode.Viewing)
        {
            this.openMode         = openMode;
            this.autoRotate3DView = autoRotate3DView;
            this.windowMode       = windowMode;

            BackgroundColor = ActiveTheme.Instance.PrimaryBackgroundColor;
            this.AnchorAll();
            this.Load(printItem);

            // We do this after showing the system window so that when we try and take focus of the parent window (the system window)
            // it exists and can give the focus to its child the gcode window.
            if (printItem != null &&
                Path.GetExtension(printItem.FileLocation).ToUpper() == ".GCODE")
            {
                SwitchToGcodeView();
            }
        }