diff options
| author | ab <abdullah_ahmed@brown.edu> | 2019-04-08 18:11:45 -0400 |
|---|---|---|
| committer | ab <abdullah_ahmed@brown.edu> | 2019-04-08 18:11:45 -0400 |
| commit | 5f9f7821bca6a9c5733e13e3d121661e18b779f7 (patch) | |
| tree | cceb6107d9b395417a48559fce879082d387b04e /src/client/views/collections/CollectionViewBase.tsx | |
| parent | 9e4dd13ae2f0061ebea6aa8809a5607b51b9d8c3 (diff) | |
| parent | a72fcdd0ebc06a3c851007c6ed89ab13a9a0d835 (diff) | |
Merge branches 'undo-expansion' and 'master' of https://github.com/browngraphicslab/Dash-Web into undo-expansion
Diffstat (limited to 'src/client/views/collections/CollectionViewBase.tsx')
| -rw-r--r-- | src/client/views/collections/CollectionViewBase.tsx | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/client/views/collections/CollectionViewBase.tsx b/src/client/views/collections/CollectionViewBase.tsx index d8f4a0be5..5a24f8cde 100644 --- a/src/client/views/collections/CollectionViewBase.tsx +++ b/src/client/views/collections/CollectionViewBase.tsx @@ -83,13 +83,13 @@ export class CollectionViewBase extends React.Component<SubCollectionViewProps> @action protected drop(e: Event, de: DragManager.DropEvent): boolean { if (de.data instanceof DragManager.DocumentDragData) { - if (de.data.aliasOnDrop) { + if (de.data.aliasOnDrop || de.data.copyOnDrop) { [KeyStore.Width, KeyStore.Height, KeyStore.CurPage].map(key => de.data.draggedDocuments.map((draggedDocument: Document, i: number) => draggedDocument.GetTAsync(key, NumberField, (f: Opt<NumberField>) => f ? de.data.droppedDocuments[i].SetNumber(key, f.Data) : null))); } let added = de.data.droppedDocuments.reduce((added, d) => this.props.addDocument(d, false), true); - if (added && de.data.removeDocument && !de.data.aliasOnDrop) { + if (added && de.data.removeDocument && !de.data.aliasOnDrop && !de.data.copyOnDrop) { de.data.removeDocument(this.props.CollectionView); } e.stopPropagation(); |
