public static boolean hasBackgroundProcesses(@NotNull Project project) { final IdeFrame frame = ((WindowManagerEx) WindowManager.getInstance()).findFrameFor(project); final StatusBarEx statusBar = frame == null ? null : (StatusBarEx) frame.getStatusBar(); if (statusBar != null) { final List<Pair<TaskInfo, ProgressIndicator>> processes = statusBar.getBackgroundProcesses(); if (!processes.isEmpty()) return true; } return false; }
public void updateFileName(final VirtualFile updatedFile) { final EditorWindow[] windows = getWindows(); for (int i = 0; i != windows.length; ++i) { windows[i].updateFileName(updatedFile); } Project project = myManager.getProject(); final IdeFrame frame = getFrame(project); if (frame != null) { VirtualFile file = getCurrentFile(); File ioFile = file == null ? null : new File(file.getPresentableUrl()); String fileTitle = file == null ? null : FrameTitleBuilder.getInstance().getFileTitle(project, file); frame.setFileTitle(fileTitle, ioFile); } }