From 3b8e3e12f222770d83afc48bfd2c51f163a92fb4 Mon Sep 17 00:00:00 2001 From: Alexey Kudravtsev Date: Thu, 13 Feb 2014 20:30:52 +0400 Subject: [PATCH] do not exhaust limited job scheduling pool --- .../openapi/progress/util/ProgressIndicatorUtils.java | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/platform/platform-impl/src/com/intellij/openapi/progress/util/ProgressIndicatorUtils.java b/platform/platform-impl/src/com/intellij/openapi/progress/util/ProgressIndicatorUtils.java index d5ce5824b4b0..b98f19b25d17 100644 --- a/platform/platform-impl/src/com/intellij/openapi/progress/util/ProgressIndicatorUtils.java +++ b/platform/platform-impl/src/com/intellij/openapi/progress/util/ProgressIndicatorUtils.java @@ -1,5 +1,5 @@ /* - * Copyright 2000-2011 JetBrains s.r.o. + * Copyright 2000-2014 JetBrains s.r.o. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -15,8 +15,6 @@ */ package com.intellij.openapi.progress.util; -import com.intellij.concurrency.Job; -import com.intellij.concurrency.JobLauncher; import com.intellij.openapi.Disposable; import com.intellij.openapi.application.Application; import com.intellij.openapi.application.ApplicationAdapter; @@ -106,7 +104,7 @@ public class ProgressIndicatorUtils { } public static void scheduleWithWriteActionPriority(final ProgressIndicator indicator, final ReadTask task) { - JobLauncher.getInstance().submitToJobThread(Job.DEFAULT_PRIORITY, new Runnable() { + ApplicationManager.getApplication().executeOnPooledThread(new Runnable() { @Override public void run() { runWithWriteActionPriority(indicator, task);