List of usage examples for com.intellij.openapi.wm ToolWindow getIcon
@Nullable Icon getIcon();
From source file:com.intellij.ide.actions.ActivateToolWindowAction.java
License:Apache License
private void updatePresentation(@NotNull Presentation presentation, @NotNull ToolWindow toolWindow) { String title = toolWindow.getStripeTitle(); presentation.setText(title);//from w w w . j a v a2 s . c o m presentation.setDescription(IdeBundle.message("action.activate.tool.window", title)); Icon icon = toolWindow.getIcon(); if (EventLog.LOG_TOOL_WINDOW_ID.equals(myToolWindowId)) { icon = AllIcons.Ide.Info_notifications; } presentation.setIcon(icon == null ? null : new SizedIcon(icon, icon.getIconHeight(), icon.getIconHeight())); }
From source file:com.intellij.ide.actions.SwitcherToolWindowsListRenderer.java
License:Apache License
private static Icon getIcon(ToolWindow toolWindow) { Icon icon = toolWindow.getIcon(); if (icon == null) { return AllIcons.FileTypes.UiForm; }/*ww w . j av a 2 s.c o m*/ icon = IconUtil.toSize(icon, 16, 16); return icon; }