mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
fix dumb mode tasks run twice in headless mode
This commit is contained in:
@@ -118,7 +118,9 @@ public class DumbServiceImpl extends DumbService {
|
||||
private void scheduleCacheUpdate(@NotNull final DumbModeTask task, boolean forceDumbMode) {
|
||||
final Application application = ApplicationManager.getApplication();
|
||||
|
||||
if (application.isUnitTestMode() || application.isHeadlessEnvironment() || !forceDumbMode && !myDumb && application.isReadAccessAllowed()) {
|
||||
if (application.isUnitTestMode() ||
|
||||
application.isHeadlessEnvironment() ||
|
||||
!forceDumbMode && !myDumb && application.isReadAccessAllowed()) {
|
||||
final ProgressIndicator indicator = ProgressManager.getInstance().getProgressIndicator();
|
||||
if (indicator != null) {
|
||||
indicator.pushState();
|
||||
@@ -133,6 +135,7 @@ public class DumbServiceImpl extends DumbService {
|
||||
indicator.popState();
|
||||
}
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
UIUtil.invokeLaterIfNeeded(new DumbAwareRunnable() {
|
||||
|
||||
Reference in New Issue
Block a user