mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
new ui: hide toolwindow action by default (instead of hide side)
This commit is contained in:
Binary file not shown.
|
Before Width: | Height: | Size: 1.4 KiB After Width: | Height: | Size: 1.4 KiB |
Binary file not shown.
|
Before Width: | Height: | Size: 313 B After Width: | Height: | Size: 691 B |
Binary file not shown.
|
Before Width: | Height: | Size: 1.5 KiB After Width: | Height: | Size: 1.5 KiB |
@@ -123,27 +123,27 @@ public abstract class ToolWindowHeader extends JPanel implements Disposable {
|
||||
|
||||
eastPanel.add(Box.createHorizontalStrut(3));
|
||||
|
||||
myHideButton = new ActionButton(new HideSideAction() {
|
||||
@Override
|
||||
public void actionPerformed(AnActionEvent e) {
|
||||
sideHidden();
|
||||
}
|
||||
}, new HideAction() {
|
||||
myHideButton = new ActionButton(new HideAction() {
|
||||
@Override
|
||||
public void actionPerformed(AnActionEvent e) {
|
||||
hideToolWindow();
|
||||
}
|
||||
}, new HideSideAction() {
|
||||
@Override
|
||||
public void actionPerformed(AnActionEvent e) {
|
||||
sideHidden();
|
||||
}
|
||||
},
|
||||
ourHideLeftSideIcon, null, null
|
||||
) {
|
||||
@Override
|
||||
protected Icon getActiveIcon() {
|
||||
return getHideIcon(myToolWindow);
|
||||
return getHideToolWindowIcon(myToolWindow);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected Icon getAlternativeIcon() {
|
||||
return getHideToolWindowIcon(myToolWindow);
|
||||
return getHideIcon(myToolWindow);
|
||||
}
|
||||
};
|
||||
|
||||
@@ -455,6 +455,11 @@ public abstract class ToolWindowHeader extends JPanel implements Disposable {
|
||||
if (shortcutForAction.length() > 0) {
|
||||
text += " " + shortcutForAction;
|
||||
}
|
||||
|
||||
if (action instanceof HideAction) {
|
||||
text += String.format(" (Click with %s to Hide Side)", KeymapUtil.getShortcutText(KeyboardShortcut.fromString("pressed ALT")));
|
||||
}
|
||||
|
||||
return text;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user