fix: Prevent sketch overlap and improve plane selection visibility

Co-authored-by: aider (gemini/gemini-2.5-pro) <aider@aider.chat>
This commit is contained in:
2026-02-15 11:11:39 -07:00
parent 8424097127
commit b11b345235
2 changed files with 11 additions and 0 deletions

View File

@@ -102,6 +102,9 @@ bool ApplicationController::saveDocumentAs()
void ApplicationController::beginSketchCreation() void ApplicationController::beginSketchCreation()
{ {
if (m_activeSketch) {
return;
}
emit planeSelectionModeStarted(); emit planeSelectionModeStarted();
} }

View File

@@ -489,6 +489,13 @@ void ViewportWidget::keyPressEvent(QKeyEvent *event)
update(); update();
return; return;
} }
if (m_isSelectingPlane) {
m_isSelectingPlane = false;
m_highlightedPlane = SketchPlane::NONE;
m_currentPlane = SketchPlane::XY;
update();
return;
}
} }
QOpenGLWidget::keyPressEvent(event); QOpenGLWidget::keyPressEvent(event);
} }
@@ -566,6 +573,7 @@ void ViewportWidget::onPlaneSelectionModeStarted()
{ {
m_isSelectingPlane = true; m_isSelectingPlane = true;
m_highlightedPlane = SketchPlane::NONE; m_highlightedPlane = SketchPlane::NONE;
m_currentPlane = SketchPlane::NONE;
update(); update();
} }