mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-04-29 19:45:01 +02:00
Cosmetics.
This commit is contained in:
parent
ad3552fcce
commit
12d5105085
1 changed files with 6 additions and 8 deletions
|
@ -100,14 +100,15 @@ public abstract class CModelOperation implements IWorkspaceRunnable, IProgressMo
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Whether the operation has modified resources, and thus whether resource
|
* Whether the operation has modified resources, and thus whether resource
|
||||||
* delta notifcation will happen.
|
* delta notification will happen.
|
||||||
*/
|
*/
|
||||||
protected boolean hasModifiedResource = false;
|
protected boolean hasModifiedResource = false;
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* A per thread stack of java model operations (PerThreadObject of ArrayList).
|
* A per thread stack of java model operations (PerThreadObject of ArrayList).
|
||||||
*/
|
*/
|
||||||
protected final static ThreadLocal<ArrayList<CModelOperation>> operationStacks = new ThreadLocal<ArrayList<CModelOperation>>();
|
protected final static ThreadLocal<ArrayList<CModelOperation>> operationStacks =
|
||||||
|
new ThreadLocal<ArrayList<CModelOperation>>();
|
||||||
|
|
||||||
protected CModelOperation() {
|
protected CModelOperation() {
|
||||||
}
|
}
|
||||||
|
@ -582,9 +583,7 @@ public abstract class CModelOperation implements IWorkspaceRunnable, IProgressMo
|
||||||
*/
|
*/
|
||||||
protected boolean isTopLevelOperation() {
|
protected boolean isTopLevelOperation() {
|
||||||
ArrayList<CModelOperation> stack;
|
ArrayList<CModelOperation> stack;
|
||||||
return
|
return (stack = this.getCurrentOperationStack()).size() > 0 && stack.get(0) == this;
|
||||||
(stack = this.getCurrentOperationStack()).size() > 0
|
|
||||||
&& stack.get(0) == this;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -604,7 +603,7 @@ public abstract class CModelOperation implements IWorkspaceRunnable, IProgressMo
|
||||||
} finally {
|
} finally {
|
||||||
try {
|
try {
|
||||||
registerDeltas();
|
registerDeltas();
|
||||||
// Fire if we change somethings
|
// Fire if we change something
|
||||||
if (isTopLevelOperation()) {
|
if (isTopLevelOperation()) {
|
||||||
if ((manager.fCModelDeltas.size() > previousDeltaCount || !manager.reconcileDeltas.isEmpty())
|
if ((manager.fCModelDeltas.size() > previousDeltaCount || !manager.reconcileDeltas.isEmpty())
|
||||||
&& !this.hasModifiedResource()) {
|
&& !this.hasModifiedResource()) {
|
||||||
|
@ -647,7 +646,6 @@ public abstract class CModelOperation implements IWorkspaceRunnable, IProgressMo
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @see IProgressMonitor
|
* @see IProgressMonitor
|
||||||
*/
|
*/
|
||||||
|
|
Loading…
Add table
Reference in a new issue