mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
cleanup
This commit is contained in:
@@ -205,7 +205,7 @@ public abstract class TreeElement extends ElementBase implements ASTNode, Clonea
|
||||
clearRelativeOffsets(next);
|
||||
}
|
||||
|
||||
protected static void clearRelativeOffsets(TreeElement element) {
|
||||
static void clearRelativeOffsets(TreeElement element) {
|
||||
TreeElement cur = element;
|
||||
while (cur != null && cur.myStartOffsetInParent != -1) {
|
||||
cur.myStartOffsetInParent = -1;
|
||||
@@ -262,7 +262,7 @@ public abstract class TreeElement extends ElementBase implements ASTNode, Clonea
|
||||
}
|
||||
}
|
||||
|
||||
protected final void rawInsertAfterMeWithoutNotifications(@NotNull TreeElement firstNew) {
|
||||
final void rawInsertAfterMeWithoutNotifications(@NotNull TreeElement firstNew) {
|
||||
firstNew.rawRemoveUpToWithoutNotifications(null, false);
|
||||
final CompositeElement p = getTreeParent();
|
||||
final TreeElement treeNext = getTreeNext();
|
||||
@@ -350,7 +350,7 @@ public abstract class TreeElement extends ElementBase implements ASTNode, Clonea
|
||||
}
|
||||
|
||||
// remove nodes from this[including] to end[excluding] from the parent
|
||||
protected final void rawRemoveUpToWithoutNotifications(@Nullable TreeElement end, boolean invalidate) {
|
||||
final void rawRemoveUpToWithoutNotifications(@Nullable TreeElement end, boolean invalidate) {
|
||||
if(this == end) return;
|
||||
|
||||
final CompositeElement parent = getTreeParent();
|
||||
|
||||
+4
-1
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2000-2015 JetBrains s.r.o.
|
||||
* Copyright 2000-2016 JetBrains s.r.o.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -65,6 +65,9 @@ public class VfsUtilPerformanceTest extends BareTestFixtureTestCase {
|
||||
}.execute();
|
||||
|
||||
VirtualFile theChild = vDir.findChild("5111.txt");
|
||||
assertNotNull(theChild);
|
||||
UIUtil.pump(); // wait for all event handlers to calm down
|
||||
|
||||
System.out.println("Start searching...");
|
||||
PlatformTestUtil.startPerformanceTest("find child is slow", 1000, () -> {
|
||||
for (int i = 0; i < 1000000; i++) {
|
||||
|
||||
Reference in New Issue
Block a user