cleanup
This commit is contained in:
@@ -791,7 +791,6 @@ const DesktopWorkspace: React.FC<DocumentsViewProps> = ({
|
|||||||
onPromoteSelection: handlePromoteSelection,
|
onPromoteSelection: handlePromoteSelection,
|
||||||
selectedDocumentIds,
|
selectedDocumentIds,
|
||||||
onClearSelection: clearSelection,
|
onClearSelection: clearSelection,
|
||||||
onDocumentClick: passThroughProps.onDocumentClick,
|
|
||||||
onSelect: (descriptorOrDescriptors: any, event: any) => {
|
onSelect: (descriptorOrDescriptors: any, event: any) => {
|
||||||
const descriptors = Array.isArray(descriptorOrDescriptors)
|
const descriptors = Array.isArray(descriptorOrDescriptors)
|
||||||
? descriptorOrDescriptors
|
? descriptorOrDescriptors
|
||||||
@@ -845,7 +844,6 @@ function DesktopWorkspaceView({
|
|||||||
overlayOriginRect,
|
overlayOriginRect,
|
||||||
overlayOriginTransform,
|
overlayOriginTransform,
|
||||||
overlayDocument,
|
overlayDocument,
|
||||||
onDocumentClick,
|
|
||||||
onPromoteSelection,
|
onPromoteSelection,
|
||||||
selectedDocumentIds,
|
selectedDocumentIds,
|
||||||
onClearSelection,
|
onClearSelection,
|
||||||
@@ -872,16 +870,6 @@ function DesktopWorkspaceView({
|
|||||||
[documentLookup, onDocumentActivate],
|
[documentLookup, onDocumentActivate],
|
||||||
);
|
);
|
||||||
|
|
||||||
const handleDeskDocumentClick = useCallback(
|
|
||||||
(docId: Identifier, event: any) => {
|
|
||||||
const doc = documentLookup.get(String(docId));
|
|
||||||
if (doc && onDocumentClick) {
|
|
||||||
onDocumentClick(doc, event);
|
|
||||||
}
|
|
||||||
},
|
|
||||||
[documentLookup, onDocumentClick],
|
|
||||||
);
|
|
||||||
|
|
||||||
const { handlePointerDown, handlePointerMove, handlePointerUp, handlePointerCancel } =
|
const { handlePointerDown, handlePointerMove, handlePointerUp, handlePointerCancel } =
|
||||||
useDocumentDrag({
|
useDocumentDrag({
|
||||||
engine,
|
engine,
|
||||||
@@ -917,7 +905,6 @@ function DesktopWorkspaceView({
|
|||||||
handlePointerMove,
|
handlePointerMove,
|
||||||
handlePointerUp,
|
handlePointerUp,
|
||||||
handlePointerCancel,
|
handlePointerCancel,
|
||||||
onDocumentClick: handleDeskDocumentClick,
|
|
||||||
onPromoteSelection,
|
onPromoteSelection,
|
||||||
onDocumentActivate: handleDeskDocumentActivate,
|
onDocumentActivate: handleDeskDocumentActivate,
|
||||||
selectedDocumentIds,
|
selectedDocumentIds,
|
||||||
|
|||||||
@@ -44,8 +44,6 @@ interface DragTransform {
|
|||||||
scale?: number;
|
scale?: number;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
type EnsureDocumentSizeFn = (doc: Document | null) => DocumentSizeInfo | null;
|
type EnsureDocumentSizeFn = (doc: Document | null) => DocumentSizeInfo | null;
|
||||||
|
|
||||||
type ResolveBaseMetricsFn = (
|
type ResolveBaseMetricsFn = (
|
||||||
|
|||||||
Reference in New Issue
Block a user