On the Mac use a cool client property which makes the text field look very search-like.
| 1030 | 1033 | |
|---|---|---|
| 136 | 136 | return bidBar; |
| 137 | 137 | } |
| 138 | 138 | |
| 139 | private JComponent establishSearchBox(final JTabManager inAction) { /** | |
| 140 | * Add selection/search bar. | |
| 139 | /** | |
| 140 | * Add selection/search bar. | |
| 141 | * @param inAction - The action to be triggered by the search/select process. | |
| 142 | * @return - A component containing the search / select field. | |
| 141 | 143 | */ |
| 144 | private JComponent establishSearchBox(final JTabManager inAction) { | |
| 142 | 145 | DocumentListener selectListener = new DocumentListener() { |
| 143 | 146 | public void insertUpdate(DocumentEvent de) { |
| 144 | 147 | } |
| --- | --- | |
| 154 | 157 | } |
| 155 | 158 | }; |
| 156 | 159 | mSelectBox.addActionListener(doSearch); |
| 160 | mSelectBox.putClientProperty("JTextField.variant", "search"); | |
| 161 | ||
| 157 | 162 | JPanel compact = new JPanel(); |
| 158 | 163 | compact.setLayout(new BoxLayout(compact, BoxLayout.X_AXIS)); |
| 159 | 164 | compact.setPreferredSize(new Dimension(100, 24)); |
