IDEA-57639 Stuck on Open Project, Cancel Button does not work (ask for cancel during project load) reviewed by yole

This commit is contained in:
irengrig
2010-08-19 15:03:52 +04:00
parent bbf7893fea
commit a9f4b07fb2
@@ -117,6 +117,9 @@ public abstract class ComponentManagerImpl extends UserDataHolderBase implements
final Class[] componentInterfaces = myComponentsRegistry.getComponentInterfaces();
for (Class componentInterface : componentInterfaces) {
if (myHaveProgressManager) {
ProgressManager.checkCanceled();
}
try {
createComponent(componentInterface);
}
@@ -304,6 +307,9 @@ public abstract class ComponentManagerImpl extends UserDataHolderBase implements
Class[] componentClasses = myComponentsRegistry.getComponentInterfaces();
ArrayList<Object> components = new ArrayList<Object>(componentClasses.length);
for (Class<?> interfaceClass : componentClasses) {
if (myHaveProgressManager) {
ProgressManager.checkCanceled();
}
Object component = getComponent(interfaceClass);
if (component != null) components.add(component);
}