Skip to content

Commit

Permalink
Remove IterableIterator from dnd API proposal
Browse files Browse the repository at this point in the history
Part of #32592
  • Loading branch information
alexr00 committed Nov 16, 2021
1 parent 340338b commit 7131e48
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 6 deletions.
9 changes: 4 additions & 5 deletions src/vs/workbench/api/common/extHostTreeViews.ts
Original file line number Diff line number Diff line change
Expand Up @@ -139,12 +139,11 @@ export class ExtHostTreeViews implements ExtHostTreeViewsShape {
if ((sourceViewId === destinationViewId) && sourceTreeItemHandles) {
const additionalTransferItems = await treeView.onWillDrop(sourceTreeItemHandles);
if (additionalTransferItems) {
for (const key of additionalTransferItems.items.keys()) {
const item = additionalTransferItems.items.get(key);
if (item) {
treeDataTransfer.items.set(key, item);
additionalTransferItems.items.forEach((value, key) => {
if (value) {
treeDataTransfer.items.set(key, value);
}
}
});
}
}
return treeView.onDrop(treeDataTransfer, newParentItemHandle);
Expand Down
2 changes: 1 addition & 1 deletion src/vscode-dts/vscode.proposed.treeViewDragAndDrop.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ declare module 'vscode' {
*/
items: {
get: (mimeType: string) => TreeDataTransferItem | undefined
keys: () => IterableIterator<string>;
forEach: (callbackfn: (value: TreeDataTransferItem, key: string) => void) => void;
};
}

Expand Down

0 comments on commit 7131e48

Please sign in to comment.