Ignore:
Timestamp:
2017-07-22T22:41:19+02:00 (21 months ago)
Author:
Don-vip
Message:

add Changeset.getComment()

Location:
trunk/src/org/openstreetmap/josm/gui/io
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/gui/io/ChangesetCellRenderer.java

    r11878 r12494  
    4343                    DateUtils.formatDateTime(createdDate, DateFormat.SHORT, DateFormat.SHORT)).append("<br>");
    4444        }
    45         String comment = cs.get("comment");
    46         if (comment != null) {
     45        String comment = cs.getComment();
     46        if (!comment.isEmpty()) {
    4747            sb.append("<strong>").append(tr("Changeset comment:")).append("</strong>")
    4848              .append(Utils.escapeReservedCharactersHTML(comment)).append("<br>");
     
    6464            setIcon(icon);
    6565            StringBuilder sb = new StringBuilder();
    66             String comment = cs.get("comment");
    67             if (comment != null) {
     66            String comment = cs.getComment();
     67            if (!comment.isEmpty()) {
    6868                sb.append(cs.getId()).append(" - ").append(comment);
    6969            } else if (cs.get("name") != null) {
  • trunk/src/org/openstreetmap/josm/gui/io/UploadParameterSummaryPanel.java

    r12370 r12494  
    88import java.beans.PropertyChangeEvent;
    99import java.beans.PropertyChangeListener;
    10 import java.util.Optional;
    1110
    1211import javax.swing.BorderFactory;
     
    5251            msg.append(tr("Objects are uploaded to the <strong>open changeset</strong> {0} with upload comment ''{1}''.",
    5352                    selectedChangeset.getId(),
    54                     Optional.ofNullable(selectedChangeset.get("comment")).orElse("")
     53                    selectedChangeset.getComment()
    5554            ));
    5655        }
Note: See TracChangeset for help on using the changeset viewer.