OSDN Git Service

modify outputfilename
authorankys <ankys@users.sourceforge.jp>
Mon, 17 Oct 2011 09:38:19 +0000 (18:38 +0900)
committerankys <ankys@users.sourceforge.jp>
Mon, 17 Oct 2011 09:38:19 +0000 (18:38 +0900)
History.txt
src/jp/sourceforge/posterdivider/MainFrame.java

index 38d1d40..3f8a183 100644 (file)
@@ -35,3 +35,6 @@ GUIをSwingに変更
 ついでにレイアウトも変更
 操作手順を一部変更した
 NumberField を修正
+
+1.1.1
+標準の出力先を変換元ファイルのフォルダにした
index 52d0c20..bb8da33 100644 (file)
@@ -116,6 +116,9 @@ public class MainFrame extends JFrame {
     private String generateFileName(String str) {
        str = str.replace("{pwd}", System.getProperty("user.dir"));
        if (this.srcFile != null) {
+           str = str.replace("{inputdir}", this.srcFile.getParent());
+       }
+       if (this.srcFile != null) {
            str = str.replace("{input}", this.srcFile.getName());
        }
        str = str.replace("{date}", new SimpleDateFormat("yyyyMMddHHmmss").format(new Date()));
@@ -1317,7 +1320,7 @@ public class MainFrame extends JFrame {
                comboBoxPaperMarginUnit.setSelectedIndex(0);
                comboBoxPaperMarginUnit_itemStateChanged();
 
-               textFieldOutputFileName.setText(String.format("{pwd}%s%s_{input}_{date}.pdf", File.separator, Lib.getMessage("App.LowerTitle")));
+               textFieldOutputFileName.setText(String.format("{inputdir}%s%s_{input}_{date}.pdf", File.separator, Lib.getMessage("App.LowerTitle")));
 
                simulateOutput();
        }