From c692398423350ef9539efade1dfec8bb2d007a85 Mon Sep 17 00:00:00 2001 From: Anton Makeev Date: Wed, 5 Mar 2014 11:26:13 +0100 Subject: [PATCH] Local History change temporarily reverted --- .../src/com/intellij/history/integration/IdeaGateway.java | 7 ------- .../history/integration/LocalHistoryEventDispatcher.java | 2 +- .../intellij/history/integration/FileListeningTest.java | 1 + 3 files changed, 2 insertions(+), 8 deletions(-) diff --git a/platform/lvcs-impl/src/com/intellij/history/integration/IdeaGateway.java b/platform/lvcs-impl/src/com/intellij/history/integration/IdeaGateway.java index 911b84231ae8..24a7603e45f7 100644 --- a/platform/lvcs-impl/src/com/intellij/history/integration/IdeaGateway.java +++ b/platform/lvcs-impl/src/com/intellij/history/integration/IdeaGateway.java @@ -146,13 +146,6 @@ public class IdeaGateway { return nf.getCachedChildren(); } - @NotNull - public static Collection loadAndIterateChildren(VirtualFile f) { - if (!(f instanceof NewVirtualFile)) return Collections.emptyList(); - NewVirtualFile nf = (NewVirtualFile)f; - return Arrays.asList(nf.getChildren()); - } - @NotNull public RootEntry createTransientRootEntry() { ApplicationManager.getApplication().assertReadAccessAllowed(); diff --git a/platform/lvcs-impl/src/com/intellij/history/integration/LocalHistoryEventDispatcher.java b/platform/lvcs-impl/src/com/intellij/history/integration/LocalHistoryEventDispatcher.java index 5f9aad057c90..cb20957f3ed7 100644 --- a/platform/lvcs-impl/src/com/intellij/history/integration/LocalHistoryEventDispatcher.java +++ b/platform/lvcs-impl/src/com/intellij/history/integration/LocalHistoryEventDispatcher.java @@ -93,7 +93,7 @@ public class LocalHistoryEventDispatcher extends VirtualFileAdapter implements V myVcs.created(f.getPath(), f.isDirectory()); } if (f.isDirectory()) { - for (VirtualFile each : IdeaGateway.loadAndIterateChildren(f)) { + for (VirtualFile each : IdeaGateway.iterateDBChildren(f)) { createRecursively(each); } } diff --git a/platform/platform-tests/testSrc/com/intellij/history/integration/FileListeningTest.java b/platform/platform-tests/testSrc/com/intellij/history/integration/FileListeningTest.java index 865865699645..d192ef3b5016 100644 --- a/platform/platform-tests/testSrc/com/intellij/history/integration/FileListeningTest.java +++ b/platform/platform-tests/testSrc/com/intellij/history/integration/FileListeningTest.java @@ -73,6 +73,7 @@ public class FileListeningTest extends IntegrationTestCase { myRoot.refresh(false, true); List changes = getVcs().getChangeListInTests().getChangesInTests().get(0).getChanges(); + assertEquals(changes.toString(), 4, changes.size()); List actual = new SmartList(); for (Change each : changes) { actual.add(((StructuralChange)each).getPath());