Changeset 35856 in osm
- Timestamp:
- 2021-11-06T10:09:02+01:00 (3 years ago)
- Location:
- applications/editors/josm/plugins/utilsplugin2
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
applications/editors/josm/plugins/utilsplugin2/build.xml
r35671 r35856 5 5 <property name="commit.message" value="[josm_utilsplugin2]: select boundary by double-click; multitagger table highlights"/> 6 6 <!-- enter the *lowest* JOSM version this plugin is currently compatible with --> 7 <property name="plugin.main.version" value="1 7199"/>7 <property name="plugin.main.version" value="18173"/> 8 8 9 9 <property name="plugin.author" value="Kalle Lampila, Upliner, Zverik, akks, joshdoe and others"/> -
applications/editors/josm/plugins/utilsplugin2/src/org/openstreetmap/josm/plugins/utilsplugin2/multitagger/MultiTagDialog.java
r35682 r35856 19 19 import java.util.Collection; 20 20 import java.util.Collections; 21 import java.util.LinkedList;22 21 import java.util.List; 23 22 … … 143 142 144 143 private void loadHistory() { 145 List<String> cmtHistory = new LinkedList<>( 146 Config.getPref().getList(HISTORY_KEY, Arrays.asList(defaultHistory))); 147 Collections.reverse(cmtHistory); 148 cbTagSet.setPossibleItems(cmtHistory); 149 String s = cmtHistory.get(cmtHistory.size()-1); 144 cbTagSet.getModel().prefs().load(HISTORY_KEY, Arrays.asList(defaultHistory)); 145 String s = cbTagSet.getModel().getElementAt(0); 150 146 cbTagSet.setText(s); 151 147 specifyTagSet(s); … … 283 279 String txt = cbTagSet.getText(); 284 280 Logging.debug(txt); 285 List<String> history = cbTagSet.get History();281 List<String> history = cbTagSet.getModel().asStringList(); 286 282 history.remove(txt); 287 283 if (history.isEmpty()) { … … 321 317 oldTags = s; 322 318 cbTagSet.addCurrentItemToHistory(); 323 Config.getPref().putList(HISTORY_KEY, cbTagSet.getHistory());319 cbTagSet.getModel().prefs().save(HISTORY_KEY); 324 320 specifyTagSet(s); 325 321 }
Note:
See TracChangeset
for help on using the changeset viewer.