mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
IDEA-188501 vcs: "Rollback Changes" dialog should not revert excluded files
This commit is contained in:
@@ -29,6 +29,7 @@ import com.intellij.ui.treeStructure.Tree;
|
||||
import com.intellij.ui.treeStructure.actions.CollapseAllAction;
|
||||
import com.intellij.ui.treeStructure.actions.ExpandAllAction;
|
||||
import com.intellij.util.ObjectUtils;
|
||||
import com.intellij.util.containers.ContainerUtil;
|
||||
import com.intellij.util.ui.ThreeStateCheckBox;
|
||||
import com.intellij.util.ui.UIUtil;
|
||||
import com.intellij.util.ui.tree.TreeUtil;
|
||||
@@ -67,7 +68,8 @@ public abstract class ChangesTree extends Tree implements DataProvider {
|
||||
@NotNull private final ChangesGroupingSupport myGroupingSupport;
|
||||
private boolean myIsModelFlat;
|
||||
|
||||
@NotNull private Set<Object> myIncludedChanges = new THashSet<>();
|
||||
@NotNull private TObjectHashingStrategy<Object> myInclusionHashingStrategy = ContainerUtil.canonicalStrategy();
|
||||
@NotNull private Set<Object> myIncludedChanges = new THashSet<>(myInclusionHashingStrategy);
|
||||
@NotNull private Runnable myDoubleClickHandler = EmptyRunnable.getInstance();
|
||||
private boolean myKeepTreeState = false;
|
||||
|
||||
@@ -385,6 +387,7 @@ public abstract class ChangesTree extends Tree implements DataProvider {
|
||||
|
||||
|
||||
public void setInclusionHashingStrategy(@NotNull TObjectHashingStrategy<Object> strategy) {
|
||||
myInclusionHashingStrategy = strategy;
|
||||
Set<Object> oldInclusion = myIncludedChanges;
|
||||
myIncludedChanges = new THashSet<>(strategy);
|
||||
myIncludedChanges.addAll(oldInclusion);
|
||||
@@ -446,7 +449,7 @@ public abstract class ChangesTree extends Tree implements DataProvider {
|
||||
|
||||
@NotNull
|
||||
public Set<Object> getIncludedSet() {
|
||||
return new HashSet<>(myIncludedChanges);
|
||||
return new THashSet<>(myIncludedChanges, myInclusionHashingStrategy);
|
||||
}
|
||||
|
||||
public void expandAll() {
|
||||
|
||||
Reference in New Issue
Block a user