mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
eliminate progress flickering
This commit is contained in:
@@ -1591,7 +1591,6 @@ public class CompileDriver {
|
||||
}
|
||||
|
||||
private static boolean syncOutputDir(final CompileContextEx context, final Collection<Trinity<File, String, Boolean>> toDelete) throws CacheCorruptedException {
|
||||
final int total = toDelete.size();
|
||||
final DependencyCache dependencyCache = context.getDependencyCache();
|
||||
final boolean isTestMode = ApplicationManager.getApplication().isUnitTestMode();
|
||||
|
||||
@@ -1601,11 +1600,9 @@ public class CompileDriver {
|
||||
public void run() throws CacheCorruptedException {
|
||||
final long start = System.currentTimeMillis();
|
||||
try {
|
||||
int current = 0;
|
||||
for (final Trinity<File, String, Boolean> trinity : toDelete) {
|
||||
final File outputPath = trinity.getFirst();
|
||||
context.getProgressIndicator().checkCanceled();
|
||||
context.getProgressIndicator().setFraction((double)++current / total);
|
||||
context.getProgressIndicator().setText2(outputPath.getPath());
|
||||
filesToRefresh.add(outputPath);
|
||||
if (isTestMode) {
|
||||
|
||||
Reference in New Issue
Block a user