use of com.intellij.openapi.wm.StatusBar in project intellij-community by JetBrains.
the class HgIncomingOutgoingWidget method activate.
@CalledInAwt
public void activate() {
MessageBusConnection busConnection = myProject.getMessageBus().connect();
busConnection.subscribe(HgVcs.STATUS_TOPIC, this);
busConnection.subscribe(HgVcs.INCOMING_OUTGOING_CHECK_TOPIC, this);
StatusBar statusBar = WindowManager.getInstance().getStatusBar(myProject);
if (null != statusBar && isVisible()) {
statusBar.addWidget(this, myProject);
isAlreadyShown = true;
}
}
use of com.intellij.openapi.wm.StatusBar in project intellij-community by JetBrains.
the class ResourceBundleEditor method selectionChanged.
private void selectionChanged() {
myBackSlashPressed.clear();
UIUtil.invokeLaterIfNeeded(() -> {
updateEditorsFromProperties(true);
final StatusBar statusBar = WindowManager.getInstance().getStatusBar(myProject);
if (statusBar != null) {
statusBar.setInfo("Selected property: " + getSelectedPropertyName());
}
});
}
use of com.intellij.openapi.wm.StatusBar in project intellij-community by JetBrains.
the class CleanPycAction method actionPerformed.
@Override
public void actionPerformed(AnActionEvent e) {
final PsiElement[] elements = e.getData(LangDataKeys.PSI_ELEMENT_ARRAY);
if (elements == null)
return;
final List<File> pycFiles = new ArrayList<>();
ProgressManager.getInstance().runProcessWithProgressSynchronously(() -> {
for (PsiElement element : elements) {
PsiDirectory dir = (PsiDirectory) element;
collectPycFiles(new File(dir.getVirtualFile().getPath()), pycFiles);
}
FileUtil.asyncDelete(pycFiles);
}, "Cleaning up .pyc files...", false, e.getProject());
final StatusBar statusBar = WindowManager.getInstance().getIdeFrame(e.getProject()).getStatusBar();
statusBar.setInfo("Deleted " + pycFiles.size() + " bytecode file" + (pycFiles.size() != 1 ? "s" : ""));
}
use of com.intellij.openapi.wm.StatusBar in project intellij-community by JetBrains.
the class PackageFileAction method setStatusText.
private static void setStatusText(Project project, List<VirtualFile> files) {
if (!files.isEmpty()) {
StringBuilder fileNames = new StringBuilder();
for (VirtualFile file : files) {
if (fileNames.length() != 0)
fileNames.append(", ");
fileNames.append("'").append(file.getName()).append("'");
}
String time = TIME_FORMAT.format(Clock.getTime());
final String statusText = CompilerBundle.message("status.text.file.has.been.packaged", files.size(), fileNames, time);
final StatusBar statusBar = WindowManager.getInstance().getStatusBar(project);
if (statusBar != null) {
statusBar.setInfo(statusText);
}
}
}
use of com.intellij.openapi.wm.StatusBar in project intellij-community by JetBrains.
the class ActionMenu method showDescriptionInStatusBar.
public static void showDescriptionInStatusBar(boolean isIncluded, Component component, String description) {
IdeFrame frame = (IdeFrame) (component instanceof IdeFrame ? component : SwingUtilities.getAncestorOfClass(IdeFrame.class, component));
StatusBar statusBar;
if (frame != null && (statusBar = frame.getStatusBar()) != null) {
statusBar.setInfo(isIncluded ? description : null);
}
}
Aggregations