split curve only for rounded curves

This commit is contained in:
Preet 2023-10-22 17:07:08 -07:00
parent 750055ddfa
commit bc5436592e
2 changed files with 13 additions and 11 deletions

View File

@ -3758,6 +3758,7 @@ class App extends React.Component<AppProps, AppState> {
const selectedElements = this.scene.getSelectedElements(this.state);
if (selectedElements.length === 1 && isLinearElement(selectedElements[0])) {
if (selectedElements[0].roundness) {
const pointUnderCursorIndex = LinearElementEditor.getPointIndexUnderCursor(
selectedElements[0],
this.state.zoom,
@ -3771,6 +3772,7 @@ class App extends React.Component<AppProps, AppState> {
);
return;
}
}
if (
event[KEYS.CTRL_OR_CMD] &&
(!this.state.editingLinearElement ||

View File

@ -279,7 +279,7 @@ const renderLinearPointHandles = (
const isSelected =
!!appState.editingLinearElement?.selectedPointsIndices?.includes(idx);
const segmented = element.segmentSplitIndices ? element.segmentSplitIndices.includes(idx) : false;
const segmented = element.roundness ? (element.segmentSplitIndices ? element.segmentSplitIndices.includes(idx) : false) : false;
renderSingleLinearPoint(context, appState, point, radius, isSelected, segmented);
});