Changeset 18174 in josm for trunk/src/org/openstreetmap
- Timestamp:
- 2021-08-25T14:47:26+02:00 (3 years ago)
- Location:
- trunk/src/org/openstreetmap/josm/gui
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/gui/download/OverpassQueryWizardDialog.java
r18173 r18174 85 85 */ 86 86 private void saveHistory() { 87 hcbSearchString.getModel().addTopElement(SearchSetting.fromString(hcbSearchString.getText()));87 model.addTopElement(SearchSetting.fromString(hcbSearchString.getText())); 88 88 prefs.save(OVERPASS_WIZARD_HISTORY); 89 89 } … … 120 120 */ 121 121 private boolean buildQueryAction() { 122 final String wizardSearchTerm = getSearchSettings().text; 123 124 Optional<String> q = this.tryParseSearchTerm(wizardSearchTerm); 122 Optional<String> q = tryParseSearchTerm(getSearchSettings().text); 125 123 q.ifPresent(callbacks::submitWizardResult); 126 124 return q.isPresent(); -
trunk/src/org/openstreetmap/josm/gui/io/BasicUploadSettingsPanel.java
r18173 r18174 320 320 private void updateHistory(JTextField text) { 321 321 String tag = (String) text.getDocument().getProperty("tag"); // tag is either "comment" or "source" 322 if ( tag.equals("comment")) {322 if ("comment".equals(tag)) { 323 323 hcbUploadComment.addCurrentItemToHistory(); 324 } 325 if (tag.equals("source")) { 324 } else if ("source".equals(tag)) { 326 325 hcbUploadSource.addCurrentItemToHistory(); 327 326 } … … 382 381 @Override 383 382 public void actionPerformed(ActionEvent e) { 384 getDialog().setFocusToUploadButton();383 setFocusToUploadButton(); 385 384 } 386 385 … … 439 438 public void keyTyped(KeyEvent e) { 440 439 if (e.getKeyChar() == KeyEvent.VK_ENTER) { 441 getDialog().setFocusToUploadButton();440 setFocusToUploadButton(); 442 441 } 443 442 } … … 450 449 public void keyReleased(KeyEvent e) { 451 450 } 451 452 private void setFocusToUploadButton() { 453 Optional.ofNullable(getDialog()).ifPresent(UploadDialog::setFocusToUploadButton); 454 } 452 455 } -
trunk/src/org/openstreetmap/josm/gui/io/ChangesetManagementPanel.java
r18173 r18174 276 276 Changeset cs = (Changeset) cbOpenChangesets.getSelectedItem(); 277 277 if (cs == null) return; 278 uploadDialogModel.putAll( getSelectedChangeset().getKeys());278 uploadDialogModel.putAll(cs.getKeys()); 279 279 firePropertyChange(SELECTED_CHANGESET_PROP, null, cs); 280 280 }
Note:
See TracChangeset
for help on using the changeset viewer.