diff --git a/platform/platform-api/src/com/intellij/openapi/actionSystem/ex/ComboBoxAction.java b/platform/platform-api/src/com/intellij/openapi/actionSystem/ex/ComboBoxAction.java index d93bc12cac3f..84852433d867 100644 --- a/platform/platform-api/src/com/intellij/openapi/actionSystem/ex/ComboBoxAction.java +++ b/platform/platform-api/src/com/intellij/openapi/actionSystem/ex/ComboBoxAction.java @@ -1,5 +1,5 @@ /* - * Copyright 2000-2013 JetBrains s.r.o. + * Copyright 2000-2014 JetBrains s.r.o. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -284,9 +284,10 @@ public abstract class ComboBoxAction extends AnAction implements CustomComponent @Override public void updateUI() { super.updateUI(); - if (!UIUtil.isUnderGTKLookAndFeel()) { - setBorder(UIUtil.getButtonBorder()); - } + //if (!UIUtil.isUnderGTKLookAndFeel()) { + // setBorder(UIUtil.getButtonBorder()); + //} + //((JComponent)getParent().getParent()).revalidate(); } protected class MyButtonModel extends DefaultButtonModel { @@ -358,6 +359,11 @@ public abstract class ComboBoxAction extends AnAction implements CustomComponent return new Dimension(width, isSmallVariant() ? 19 : UIUtil.isUnderNimbusLookAndFeel() ? 24 : 21); } + @Override + public Font getFont() { + return SystemInfo.isMac ? UIUtil.getLabelFont(UIUtil.FontSize.SMALL) : UIUtil.getLabelFont(); + } + @Override public void paint(Graphics g) { GraphicsUtil.setupAntialiasing(g); @@ -440,6 +446,7 @@ public abstract class ComboBoxAction extends AnAction implements CustomComponent protected void updateButtonSize() { invalidate(); repaint(); + setSize(getPreferredSize()); } } }