Changeset 8777 in josm for trunk/src/org/openstreetmap/josm/gui
- Timestamp:
- 2015-09-21T23:48:29+02:00 (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/gui/widgets/JosmComboBox.java
r8510 r8777 108 108 E oldPrototype = getPrototypeDisplayValue(); 109 109 // Get internal JList to directly call the renderer 110 JList<E> list = getList(); 110 @SuppressWarnings("rawtypes") 111 JList list = getList(); 111 112 try { 112 113 // Index to give to renderer … … 117 118 // but not with TaggingPreset custom renderer that return a dummy height if index is equal to -1 118 119 // So we explicitely call the renderer by simulating a correct index for the current value 120 @SuppressWarnings("unchecked") 119 121 Component c = getRenderer().getListCellRendererComponent(list, value, i, true, true); 120 122 if (c != null) { … … 139 141 140 142 @SuppressWarnings("unchecked") 141 protected final JList< E> getList() {143 protected final JList<Object> getList() { 142 144 for (int i = 0; i < getUI().getAccessibleChildrenCount(this); i++) { 143 145 Accessible child = getUI().getAccessibleChild(this, i); … … 158 160 // If possible, adjust the maximum number of items with the real height of items 159 161 // It is not granted this works on every platform (tested OK on Windows) 160 JList< E> list = getList();162 JList<Object> list = getList(); 161 163 if (list != null) { 162 164 if (!prototype.equals(list.getPrototypeCellValue())) {
Note:
See TracChangeset
for help on using the changeset viewer.