mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
EA-40102 - assert: LaterInvocator.getCurrentModalEntities
This commit is contained in:
@@ -28,6 +28,7 @@ import com.intellij.openapi.project.ProjectManager;
|
||||
import com.intellij.openapi.util.Key;
|
||||
import com.intellij.openapi.util.NotNullLazyValue;
|
||||
import com.intellij.openapi.vfs.VirtualFile;
|
||||
import com.intellij.util.ui.UIUtil;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
import org.jetbrains.annotations.Nullable;
|
||||
|
||||
@@ -73,17 +74,22 @@ public class EditorNotifications extends AbstractProjectComponent {
|
||||
}
|
||||
|
||||
public void updateNotifications(final VirtualFile file) {
|
||||
ApplicationManager.getApplication().runReadAction(new Runnable() {
|
||||
UIUtil.invokeLaterIfNeeded(new Runnable() {
|
||||
@Override
|
||||
public void run() {
|
||||
if (myProject.isDisposed()) return;
|
||||
FileEditor[] editors = myFileEditorManager.getAllEditors(file);
|
||||
for (FileEditor editor : editors) {
|
||||
for (Provider<?> provider : PROVIDERS.getValue()) {
|
||||
JComponent component = provider.createNotificationPanel(file, editor);
|
||||
Key<? extends JComponent> key = provider.getKey();
|
||||
updateNotification(editor, key, component);
|
||||
ApplicationManager.getApplication().runReadAction(new Runnable() {
|
||||
public void run() {
|
||||
if (myProject.isDisposed()) return;
|
||||
FileEditor[] editors = myFileEditorManager.getAllEditors(file);
|
||||
for (FileEditor editor : editors) {
|
||||
for (Provider<?> provider : PROVIDERS.getValue()) {
|
||||
JComponent component = provider.createNotificationPanel(file, editor);
|
||||
Key<? extends JComponent> key = provider.getKey();
|
||||
updateNotification(editor, key, component);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user