Changeset 5429 in josm for trunk/src/org/openstreetmap/josm/gui/tagging/TaggingPreset.java
- Timestamp:
- 2012-08-11T23:03:55+02:00 (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/gui/tagging/TaggingPreset.java
r5405 r5429 10 10 import java.awt.Font; 11 11 import java.awt.GridBagLayout; 12 import java.awt.Image;13 12 import java.awt.Insets; 14 13 import java.awt.event.ActionEvent; … … 36 35 import javax.swing.Action; 37 36 import javax.swing.ImageIcon; 38 import javax.swing.JComboBox;39 37 import javax.swing.JComponent; 40 38 import javax.swing.JLabel; … … 74 72 import org.openstreetmap.josm.gui.tagging.ac.AutoCompletionList; 75 73 import org.openstreetmap.josm.gui.util.GuiHelper; 74 import org.openstreetmap.josm.gui.widgets.JosmComboBox; 76 75 import org.openstreetmap.josm.io.MirroredInputStream; 77 76 import org.openstreetmap.josm.tools.GBC; … … 396 395 } else { 397 396 // the objects have different values 398 J ComboBox comboBox = new JComboBox(usage.values.toArray());397 JosmComboBox comboBox = new JosmComboBox(usage.values.toArray()); 399 398 comboBox.setEditable(true); 400 399 comboBox.setEditor(textField); … … 421 420 422 421 // return if unchanged 423 String v = (value instanceof J ComboBox)424 ? ((J ComboBox) value).getEditor().getItem().toString()422 String v = (value instanceof JosmComboBox) 423 ? ((JosmComboBox) value).getEditor().getItem().toString() 425 424 : ((JTextField) value).getText(); 426 425 v = v.trim(); … … 800 799 801 800 public boolean editable = true; 802 protected J ComboBox combo;801 protected JosmComboBox combo; 803 802 804 803 public Combo() { … … 820 819 lhm.put("", new PresetListEntry("")); 821 820 822 combo = new J ComboBox(lhm.values().toArray());821 combo = new JosmComboBox(lhm.values().toArray()); 823 822 component = combo; 824 823 combo.setRenderer(getListCellRenderer()); 825 824 combo.setEditable(editable); 826 combo.setMaximumRowCount(13);825 //combo.setMaximumRowCount(13); 827 826 AutoCompletingTextField tf = new AutoCompletingTextField(); 828 827 initAutoCompletionField(tf, key);
Note:
See TracChangeset
for help on using the changeset viewer.