Changeset 15664 in josm for trunk/src/org/openstreetmap


Ignore:
Timestamp:
2020-01-08T23:35:58+01:00 (5 years ago)
Author:
simon04
Message:

fix #18015 - Fix timezone in ImageViewerDialog

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/gui/layer/geoimage/ImageViewerDialog.java

    r15390 r15664  
    471471                osd.append(tr("\nDirection {0}\u00b0", Math.round(entry.getExifImgDir())));
    472472            }
     473
    473474            DateFormat dtf = DateUtils.getDateTimeFormat(DateFormat.SHORT, DateFormat.MEDIUM);
    474475            // Make sure date/time format includes milliseconds
     
    479480                }
    480481            }
     482            // Set timezone to UTC since UTC is assumed when parsing the EXIF timestamp,
     483            // see see org.openstreetmap.josm.tools.ExifReader.readTime(com.drew.metadata.Metadata)
     484            dtf.setTimeZone(DateUtils.UTC);
     485
    481486            if (entry.hasExifTime()) {
    482487                osd.append(tr("\nEXIF time: {0}", dtf.format(entry.getExifTime())));
Note: See TracChangeset for help on using the changeset viewer.