File tree Expand file tree Collapse file tree 4 files changed +3
-26
lines changed
Expand file tree Collapse file tree 4 files changed +3
-26
lines changed Original file line number Diff line number Diff line change @@ -1726,11 +1726,6 @@ export class BlockSvg
17261726 return this . isOwnDeletable ( ) && this . isOwnMovable ( ) ;
17271727 }
17281728
1729- /** Returns whether this block is cuttable or not. */
1730- isCuttable ( ) : boolean {
1731- return this . isDeletable ( ) && this . isMovable ( ) ;
1732- }
1733-
17341729 /** Returns whether this block is movable or not. */
17351730 override isMovable ( ) : boolean {
17361731 return this . dragStrategy . isMovable ( ) ;
Original file line number Diff line number Diff line change @@ -249,11 +249,6 @@ export class RenderedWorkspaceComment
249249 return this . isOwnMovable ( ) && this . isOwnDeletable ( ) ;
250250 }
251251
252- /** Returns whether this comment is cuttable or not */
253- isCuttable ( ) : boolean {
254- return this . isMovable ( ) && this . isDeletable ( ) ;
255- }
256-
257252 /** Returns whether this comment is movable or not. */
258253 isMovable ( ) : boolean {
259254 return this . dragStrategy . isMovable ( ) ;
Original file line number Diff line number Diff line change @@ -22,13 +22,6 @@ export interface ICopyable<T extends ICopyData> extends ISelectable {
2222 * @returns True if it can currently be copied.
2323 */
2424 isCopyable ?( ) : boolean ;
25-
26- /**
27- * Whether this instance is currently cuttable.
28- *
29- * @returns True if it can currently be cut.
30- */
31- isCuttable ?( ) : boolean ;
3225}
3326
3427export namespace ICopyable {
Original file line number Diff line number Diff line change @@ -125,19 +125,13 @@ function isCopyable(focused: IFocusableNode): boolean {
125125/**
126126 * Determine if a focusable node can be cut.
127127 *
128- * This will use the isCuttable method if the node implements it, otherwise
129- * it will fall back to checking if the node can be moved and deleted in its
130- * current workspace.
128+ * This will check if the node can be both copied and deleted in its current
129+ * workspace.
131130 *
132131 * @param focused The focused object.
133132 */
134133function isCuttable ( focused : IFocusableNode ) : boolean {
135- if ( ! isICopyable ( focused ) || ! isIDeletable ( focused ) || ! isDraggable ( focused ) )
136- return false ;
137- if ( focused . isCuttable !== undefined ) {
138- return focused . isCuttable ( ) ;
139- }
140- return focused . isMovable ( ) && focused . isDeletable ( ) ;
134+ return isCopyable ( focused ) && isIDeletable ( focused ) && focused . isDeletable ( ) ;
141135}
142136
143137/**
You can’t perform that action at this time.
0 commit comments