mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
Merge branch 'IDEA-190919'
This commit is contained in:
@@ -99,4 +99,8 @@ public class CaptionPanel extends JPanel {
|
||||
public static Color getBorderColor(boolean isActive) {
|
||||
return JBUI.CurrentTheme.Popup.borderColor(isActive);
|
||||
}
|
||||
|
||||
protected boolean containsSettingsControls() {
|
||||
return mySettingComponent != null;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -80,7 +80,7 @@ public class TitlePanel extends CaptionPanel {
|
||||
}
|
||||
|
||||
final Dimension preferredSize = super.getPreferredSize();
|
||||
preferredSize.height = JBUI.CurrentTheme.Popup.headerHeight();
|
||||
preferredSize.height = JBUI.CurrentTheme.Popup.headerHeight(containsSettingsControls());
|
||||
int maxWidth = JBUI.scale(350);
|
||||
if (!myHtml && preferredSize.width > maxWidth) { // do not allow caption to extend parent container
|
||||
return new Dimension(maxWidth, preferredSize.height);
|
||||
|
||||
@@ -1528,8 +1528,8 @@ public class JBUI {
|
||||
: JBColor.namedColor("Popup.Header.inactiveBackground", 0xededed);
|
||||
}
|
||||
|
||||
public static int headerHeight() {
|
||||
return scale(24);
|
||||
public static int headerHeight(boolean hasControls) {
|
||||
return hasControls ? scale(28) : scale(24);
|
||||
}
|
||||
|
||||
public static Color borderColor(boolean active) {
|
||||
|
||||
Reference in New Issue
Block a user