toolbarComponent.setBorder(null);
toolbarComponent.setOpaque(false);
myLeadPanel.add(toolbarComponent);
JPanel tailPanel = new NonOpaquePanel(new BorderLayout(5, 0));
JPanel tailContainer = new NonOpaquePanel(new BorderLayout(5, 0));
tailContainer.add(tailPanel, BorderLayout.EAST);
add(tailContainer, BorderLayout.CENTER);
matchInfoLabel = new JLabel();
setSmallerFontAndOpaque(matchInfoLabel);
JLabel closeLabel = new JLabel(" ", IconLoader.getIcon("/actions/cross.png"), SwingConstants.RIGHT);
closeLabel.addMouseListener(new MouseAdapter() {
@Override
public void mousePressed(final MouseEvent e) {
close();
}
});
closeLabel.setToolTipText("Close search bar (Escape)");
JPanel labelsPanel = new NonOpaquePanel(new FlowLayout());
labelsPanel.add(matchInfoLabel);
tailPanel.add(labelsPanel, BorderLayout.CENTER);
tailPanel.add(closeLabel, BorderLayout.EAST);
CompatibilityUtil.setSmallerFont(searchField);
searchField.registerKeyboardAction(new ActionListener() {