diff options
| author | bobzel <zzzman@gmail.com> | 2020-08-19 13:04:39 -0400 |
|---|---|---|
| committer | bobzel <zzzman@gmail.com> | 2020-08-19 13:04:39 -0400 |
| commit | 4058014af1a0fac01ca77b667f012696af6b5f18 (patch) | |
| tree | 58c76aa4249b9dd32a4a64539aaf457b03b141eb /src/client/views/PropertiesButtons.tsx | |
| parent | 930bf66fce5bd8f3a5f9cd52cd13ce96336cd183 (diff) | |
fixed dragging aliases from properties panel. fixed dropdown button on schema nexsted collection
Diffstat (limited to 'src/client/views/PropertiesButtons.tsx')
| -rw-r--r-- | src/client/views/PropertiesButtons.tsx | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/src/client/views/PropertiesButtons.tsx b/src/client/views/PropertiesButtons.tsx index e220bd7fc..e352db562 100644 --- a/src/client/views/PropertiesButtons.tsx +++ b/src/client/views/PropertiesButtons.tsx @@ -296,13 +296,12 @@ export class PropertiesButtons extends React.Component<{}, {}> { setupMoveUpEvents(this, e, this.onAliasButtonMoved, emptyFunction, emptyFunction); } @undoBatch - onAliasButtonMoved = () => { + onAliasButtonMoved = (e: PointerEvent) => { if (this._dragRef.current && this.selectedDoc) { - const dragDocView = this.selectedDocumentView!; const dragData = new DragManager.DocumentDragData([this.selectedDoc]); - const [left, top] = dragDocView.props.ScreenToLocalTransform().inverse().transformPoint(0, 0); + const [left, top] = [e.clientX, e.clientY]; dragData.dropAction = "alias"; - DragManager.StartDocumentDrag([dragDocView.ContentDiv!], dragData, left, top, { + DragManager.StartDocumentDrag([this._dragRef.current!], dragData, left, top, { offsetX: dragData.offset[0], offsetY: dragData.offset[1], hideSource: false |
