diff options
| author | bobzel <zzzman@gmail.com> | 2023-12-12 14:06:38 -0500 |
|---|---|---|
| committer | bobzel <zzzman@gmail.com> | 2023-12-12 14:06:38 -0500 |
| commit | b769a150c8da505289f045b8b296a759c75e03a8 (patch) | |
| tree | 7aa8c82b1335bc5fe9e4a1a9fb72a4dcbab3a69f /src/client/views/DocumentDecorations.tsx | |
| parent | 6951e98f1b863fe1f404d8bf532a9241e2371ec2 (diff) | |
fixed and cleaned up snapping lines
Diffstat (limited to 'src/client/views/DocumentDecorations.tsx')
| -rw-r--r-- | src/client/views/DocumentDecorations.tsx | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/client/views/DocumentDecorations.tsx b/src/client/views/DocumentDecorations.tsx index 6ef3fcc66..b93df36eb 100644 --- a/src/client/views/DocumentDecorations.tsx +++ b/src/client/views/DocumentDecorations.tsx @@ -644,7 +644,7 @@ export class DocumentDecorations extends React.Component<DocumentDecorationsProp render() { const { b, r, x, y } = this.Bounds; const seldocview = SelectionManager.Views().lastElement(); - if (SnappingManager.GetIsDragging() || r - x < 1 || x === Number.MAX_VALUE || !seldocview || this._hidden || isNaN(r) || isNaN(b) || isNaN(x) || isNaN(y)) { + if (SnappingManager.IsDragging || r - x < 1 || x === Number.MAX_VALUE || !seldocview || this._hidden || isNaN(r) || isNaN(b) || isNaN(x) || isNaN(y)) { setTimeout(action(() => (this._showNothing = true))); return null; } @@ -656,7 +656,7 @@ export class DocumentDecorations extends React.Component<DocumentDecorationsProp var shareSymbolIcon = ReverseHierarchyMap.get(shareMode)?.image; // hide the decorations if the parent chooses to hide it or if the document itself hides it - const hideDecorations = SnappingManager.GetIsResizing() || seldocview._props.hideDecorations || seldocview.Document.layout_hideDecorations; + const hideDecorations = SnappingManager.IsResizing || seldocview._props.hideDecorations || seldocview.Document.layout_hideDecorations; const hideResizers = ![AclAdmin, AclEdit, AclAugment].includes(GetEffectiveAcl(seldocview.Document)) || hideDecorations || seldocview._props.hideResizeHandles || seldocview.Document.layout_hideResizeHandles || this._isRounding || this._isRotating; const hideTitle = this._showNothing || hideDecorations || seldocview._props.hideDecorationTitle || seldocview.Document.layout_hideDecorationTitle || this._isRounding || this._isRotating; @@ -765,8 +765,8 @@ export class DocumentDecorations extends React.Component<DocumentDecorationsProp left: bounds.x - this._resizeBorderWidth / 2, top: bounds.y - this._resizeBorderWidth / 2, transformOrigin, - background: SnappingManager.GetShiftKey() ? undefined : 'yellow', - pointerEvents: SnappingManager.GetShiftKey() || DocumentView.Interacting ? 'none' : 'all', + background: SnappingManager.ShiftKey ? undefined : 'yellow', + pointerEvents: SnappingManager.ShiftKey || DocumentView.Interacting ? 'none' : 'all', display: SelectionManager.Views().length <= 1 || hideDecorations ? 'none' : undefined, transform: `rotate(${rotation}deg)`, }} |
