Fix widget ordering to restore layer view controls
- Less coupling to MeshViewerWidget - Interaction layer concept/surface added for IA volumes - Holds most IA volume logic and controls
This commit is contained in:
parent
903347e5bd
commit
dda6f89c2b
12 changed files with 309 additions and 237 deletions
|
|
@ -256,13 +256,13 @@ namespace MatterHackers.MatterControl.PartPreviewWindow
|
|||
{
|
||||
this.modelViewer.ResetView();
|
||||
|
||||
ApplicationController.Instance.PartPreviewState.RotationMatrix = modelViewer.meshViewerWidget.World.RotationMatrix;
|
||||
ApplicationController.Instance.PartPreviewState.TranslationMatrix = modelViewer.meshViewerWidget.World.TranslationMatrix;
|
||||
ApplicationController.Instance.PartPreviewState.RotationMatrix = modelViewer.World.RotationMatrix;
|
||||
ApplicationController.Instance.PartPreviewState.TranslationMatrix = modelViewer.World.TranslationMatrix;
|
||||
}
|
||||
else
|
||||
{
|
||||
modelViewer.meshViewerWidget.World.RotationMatrix = ApplicationController.Instance.PartPreviewState.RotationMatrix;
|
||||
modelViewer.meshViewerWidget.World.TranslationMatrix = ApplicationController.Instance.PartPreviewState.TranslationMatrix;
|
||||
modelViewer.World.RotationMatrix = ApplicationController.Instance.PartPreviewState.RotationMatrix;
|
||||
modelViewer.World.TranslationMatrix = ApplicationController.Instance.PartPreviewState.TranslationMatrix;
|
||||
}
|
||||
|
||||
printer.BedPlate.LoadedGCodeChanged += BedPlate_LoadedGCodeChanged;
|
||||
|
|
@ -508,9 +508,8 @@ namespace MatterHackers.MatterControl.PartPreviewWindow
|
|||
public override void OnClosed(ClosedEventArgs e)
|
||||
{
|
||||
// Store active transforms on close
|
||||
var visibleWidget = modelViewer.meshViewerWidget;
|
||||
ApplicationController.Instance.PartPreviewState.RotationMatrix = visibleWidget.World.RotationMatrix;
|
||||
ApplicationController.Instance.PartPreviewState.TranslationMatrix = visibleWidget.World.TranslationMatrix;
|
||||
ApplicationController.Instance.PartPreviewState.RotationMatrix = modelViewer.World.RotationMatrix;
|
||||
ApplicationController.Instance.PartPreviewState.TranslationMatrix = modelViewer.World.TranslationMatrix;
|
||||
|
||||
// Find and unhook the parent system window KeyDown event
|
||||
if (parentSystemWindow != null)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue