mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
IDEA-144668 Ability to disable "Run config" and "test indicator" gutters: UI tweaks
This commit is contained in:
+9
-2
@@ -8,12 +8,19 @@
|
||||
<properties/>
|
||||
<border type="none"/>
|
||||
<children>
|
||||
<component id="40c88" class="com.intellij.ui.CheckBoxList" binding="myList" custom-create="true">
|
||||
<scrollpane id="d5ba0" class="com.intellij.ui.components.JBScrollPane">
|
||||
<constraints>
|
||||
<grid row="0" column="0" row-span="1" col-span="1" vsize-policy="3" hsize-policy="3" anchor="0" fill="3" indent="0" use-parent-layout="false"/>
|
||||
</constraints>
|
||||
<properties/>
|
||||
</component>
|
||||
<border type="none"/>
|
||||
<children>
|
||||
<component id="40c88" class="com.intellij.ui.CheckBoxList" binding="myList" custom-create="true">
|
||||
<constraints/>
|
||||
<properties/>
|
||||
</component>
|
||||
</children>
|
||||
</scrollpane>
|
||||
</children>
|
||||
</grid>
|
||||
</form>
|
||||
|
||||
+5
-1
@@ -155,14 +155,17 @@ public class GutterIconsConfigurable implements Configurable {
|
||||
@Override
|
||||
protected JComponent adjustRendering(JComponent rootComponent, JCheckBox checkBox, int index, boolean selected, boolean hasFocus) {
|
||||
JPanel panel = new JPanel(new BorderLayout());
|
||||
panel.setBorder(BorderFactory.createEmptyBorder());
|
||||
GutterIconDescriptor descriptor = myList.getItemAt(index);
|
||||
Icon icon = descriptor == null ? null : descriptor.getIcon();
|
||||
JLabel label = new JLabel(icon == null ? EmptyIcon.ICON_16 : icon);
|
||||
label.setOpaque(true);
|
||||
label.setPreferredSize(new Dimension(25, -1));
|
||||
label.setHorizontalAlignment(SwingConstants.CENTER);
|
||||
panel.add(label, BorderLayout.WEST);
|
||||
panel.add(checkBox, BorderLayout.CENTER);
|
||||
panel.setBackground(rootComponent.getBackground());
|
||||
panel.setBackground(getBackground(false));
|
||||
label.setBackground(getBackground(selected));
|
||||
checkBox.setBorder(null);
|
||||
|
||||
PluginDescriptor pluginDescriptor = myFirstDescriptors.get(descriptor);
|
||||
@@ -176,5 +179,6 @@ public class GutterIconsConfigurable implements Configurable {
|
||||
return panel;
|
||||
}
|
||||
};
|
||||
myList.setBorder(BorderFactory.createEmptyBorder());
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user