diff --git a/importPicture/doc/AdjustTime.class.violet.html b/importPicture/doc/AdjustTime.class.violet.html
new file mode 100644
index 0000000..4406ae9
--- /dev/null
+++ b/importPicture/doc/AdjustTime.class.violet.html
@@ -0,0 +1,285 @@
+
+
+
+
+
+
+
+
+ This file was generated with Violet UML Editor 2.1.0.
+ ( View Source / Download Violet )
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/importPicture/src/osm/jp/gpx/ImportPicture.java b/importPicture/src/osm/jp/gpx/ImportPicture.java
index 2c79ac2..41fc070 100644
--- a/importPicture/src/osm/jp/gpx/ImportPicture.java
+++ b/importPicture/src/osm/jp/gpx/ImportPicture.java
@@ -297,7 +297,6 @@
Document document;
public static final String TIME_FORMAT_STRING = "yyyy-MM-dd'T'HH:mm:ss";
- public static final SimpleDateFormat dfjp = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
public static final SimpleDateFormat dfuk = new SimpleDateFormat(TIME_FORMAT_STRING +"'Z'");
@Override
diff --git a/importPicture/src/osm/jp/gpx/matchtime/gui/AdjustTime.java b/importPicture/src/osm/jp/gpx/matchtime/gui/AdjustTime.java
index 41720a9..10409d2 100644
--- a/importPicture/src/osm/jp/gpx/matchtime/gui/AdjustTime.java
+++ b/importPicture/src/osm/jp/gpx/matchtime/gui/AdjustTime.java
@@ -2,10 +2,10 @@
import java.awt.*;
import java.awt.event.ActionEvent;
import java.io.File;
-import java.io.FileNotFoundException;
import java.io.IOException;
import java.text.SimpleDateFormat;
import java.util.Date;
+import java.util.TimeZone;
import javax.swing.*;
@@ -25,8 +25,8 @@
public class AdjustTime extends JFrame
{
public static final String PROGRAM_NAME = "AdjustTime for JOSM";
- public static final String PROGRAM_VARSION = "3.1";
- public static final String PROGRAM_UPDATE = "2017/05/15";
+ public static final String PROGRAM_VARSION = "3.2";
+ public static final String PROGRAM_UPDATE = "2017/06/28";
// Used for addNotify check.
boolean fComponentsAdjusted = false;
@@ -47,7 +47,7 @@
//ImagePreview imagePane; // 基準時刻画像表示
ParameterPanelFolder arg1_srcFolder;
ParameterPanelImageFile arg2_baseTimeImg;
- ParameterPanel arg3_basetiome;
+ ParameterPanel arg3_basetime; // 基準時刻:
JCheckBox outputIMG; // IMGの変換 する/しない
JCheckBox outputIMG_all; // 'out of GPX time'でもIMGの変換をする {ON | OFF}
JCheckBox exifON; // EXIF 書き出しモード / !(EXIFの書き換えはしない)
@@ -145,6 +145,7 @@
}
AppParameters params;
+ SimpleDateFormat dfjp = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
/**
* データベース内のテーブルを一覧で表示するFrame
@@ -152,6 +153,8 @@
*/
public AdjustTime() throws IOException
{
+ dfjp.setTimeZone(TimeZone.getTimeZone("JST"));
+
// INIT_CONTROLS
Container container = getContentPane();
container.setLayout(new BorderLayout());
@@ -232,8 +235,8 @@
JLabel label3 = new JLabel();
label3.setText("3. 正確な撮影時刻を入力してください。
- カメラの時計が正確ならば、設定を変更する必要はありません。
");
argsPanel.add(label3);
- arg3_basetiome = new ParameterPanel(" 基準時刻: ", ImportPicture.TIME_FORMAT_STRING);
- argsPanel.add(arg3_basetiome);
+ arg3_basetime = new ParameterPanel(" 基準時刻: ", ImportPicture.TIME_FORMAT_STRING);
+ argsPanel.add(arg3_basetime);
cards[cardNo].add(argsPanel, BorderLayout.NORTH);
// 参考画像
@@ -447,10 +450,10 @@
if (exif != null) {
String dateTimeOriginal = exif.getFieldValue(ExifTagConstants.EXIF_TAG_DATE_TIME_ORIGINAL)[0];
long lastModifyTime = (new SimpleDateFormat("yyyy:MM:dd HH:mm:ss")).parse(dateTimeOriginal).getTime();
- arg3_basetiome.argField.setText(ImportPicture.dfjp.format(new Date(lastModifyTime)));
+ arg3_basetime.argField.setText(dfjp.format(new Date(lastModifyTime)));
}
else {
- arg3_basetiome.argField.setText("exif == null");
+ arg3_basetime.argField.setText("exif == null");
}
}
}
@@ -458,7 +461,7 @@
}
else {
long lastModifyTime = timeFile.lastModified();
- arg3_basetiome.argField.setText(ImportPicture.dfjp.format(new Date(lastModifyTime)));
+ arg3_basetime.argField.setText(dfjp.format(new Date(lastModifyTime)));
}
int size_x = imageSPane.getWidth() - 8;
@@ -591,8 +594,6 @@
/**
* [実行]ボタンをクリックしたときの動作
* @param event
- * @throws IOException
- * @throws FileNotFoundException
*/
void doButton_Action(java.awt.event.ActionEvent event) {
doButton.setEnabled(false);
@@ -615,20 +616,22 @@
else {
this.params.setProperty(AppParameters.GPX_BASETIME, "FILE_UPDATE");
}
- this.params.setProperty(AppParameters.IMG_SOURCE_FOLDER, arg1_srcFolder.getText());
- this.params.setProperty(AppParameters.IMG_BASE_FILE, arg2_baseTimeImg.getText());
- this.params.setProperty(AppParameters.IMG_TIME, arg3_basetiome.getText());
- this.params.setProperty(AppParameters.IMG_OUTPUT, String.valueOf(outputIMG.isSelected()));
- this.params.setProperty(AppParameters.IMG_OUTPUT_FOLDER, arg5_outputFolder.getText());
- this.params.setProperty(AppParameters.IMG_OUTPUT_ALL, String.valueOf(outputIMG_all.isSelected()));
- this.params.setProperty(AppParameters.IMG_OUTPUT_EXIF, String.valueOf(exifON.isSelected()));
- this.params.setProperty(AppParameters.GPX_OVERWRITE_MAGVAR, String.valueOf(gpxOverwriteMagvar.isSelected()));
- this.params.setProperty(AppParameters.GPX_OUTPUT_SPEED, String.valueOf(gpxOutputSpeed.isSelected()));
- this.params.setProperty(AppParameters.GPX_OUTPUT_WPT, String.valueOf(gpxOutputWpt.isSelected()));
try {
+ this.params.setProperty(AppParameters.IMG_SOURCE_FOLDER, arg1_srcFolder.getText());
+ this.params.setProperty(AppParameters.IMG_BASE_FILE, arg2_baseTimeImg.getText());
+ this.params.setProperty(AppParameters.IMG_TIME, ImportPicture.dfuk.format(dfjp.parse(arg3_basetime.getText())));
+ this.params.setProperty(AppParameters.IMG_OUTPUT, String.valueOf(outputIMG.isSelected()));
+ this.params.setProperty(AppParameters.IMG_OUTPUT_FOLDER, arg5_outputFolder.getText());
+ this.params.setProperty(AppParameters.IMG_OUTPUT_ALL, String.valueOf(outputIMG_all.isSelected()));
+ this.params.setProperty(AppParameters.IMG_OUTPUT_EXIF, String.valueOf(exifON.isSelected()));
+ this.params.setProperty(AppParameters.GPX_OVERWRITE_MAGVAR, String.valueOf(gpxOverwriteMagvar.isSelected()));
+ this.params.setProperty(AppParameters.GPX_OUTPUT_SPEED, String.valueOf(gpxOutputSpeed.isSelected()));
+ this.params.setProperty(AppParameters.GPX_OUTPUT_WPT, String.valueOf(gpxOutputWpt.isSelected()));
this.params.store();
}
- catch(Exception e) {}
+ catch(Exception e) {
+ e.printStackTrace();
+ }
(new DoDialog(this, argv)).setVisible(true);