mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
do not allow to run Task from non-EDT thread in tests
this commit reverts e5b44d6d5a
This commit is contained in:
committed by
Aleksey Pivovarov
parent
7d258bc82a
commit
3fcf6ff7eb
@@ -301,12 +301,8 @@ public class CoreProgressManager extends ProgressManager implements Disposable {
|
||||
@Override
|
||||
public void run(@NotNull final Task task) {
|
||||
if (task.isHeadless()) {
|
||||
if (ApplicationManager.getApplication().isDispatchThread()) {
|
||||
runProcessWithProgressSynchronously(task, null);
|
||||
}
|
||||
else {
|
||||
new TaskRunnable(task, new EmptyProgressIndicator()).run();
|
||||
}
|
||||
ApplicationManager.getApplication().assertIsDispatchThread();
|
||||
runProcessWithProgressSynchronously(task, null);
|
||||
}
|
||||
else if (task.isModal()) {
|
||||
runProcessWithProgressSynchronously(task.asModal(), null);
|
||||
|
||||
Reference in New Issue
Block a user