OSDN Git Service

変数名の修正. 処理記述位置をまとめる.
authoryukihane <yukihane.feather@gmail.com>
Fri, 19 Aug 2011 01:37:18 +0000 (10:37 +0900)
committeryukihane <yukihane.feather@gmail.com>
Fri, 19 Aug 2011 01:37:18 +0000 (10:37 +0900)
frontend/src/saccubus/MainFrame.java

index db05802..2684653 100644 (file)
@@ -99,8 +99,13 @@ public class MainFrame extends JFrame {
     JTabbedPane mainTabbedPane = new JTabbedPane();
     JPanel SavingInfoTabPanel = new JPanel();
     JPanel FFMpegTabPanel = new JPanel();
-    JPanel VideoInfoPanel = new JPanel();
-    JTextField VideoID_TextField = new JTextField();
+    // メインウィンドウ
+    private JPanel videoInfoPanel = new JPanel();
+    private JPanel opPanel = new JPanel();
+    private JLabel videoIdLabel = new JLabel();
+    private JTextField videoIdField = new JTextField();
+    private JLabel wayBackLabel = new JLabel();
+    private JTextField wayBackField = new JTextField();
     JButton DoButton = new JButton();
     public static final String DoButtonDefString = "変換";
     public static final String DoButtonStopString = "停止";
@@ -353,8 +358,7 @@ public class MainFrame extends JFrame {
         jMenuHelpAbout.setText("バージョン情報");
         jMenuHelpAbout.addActionListener(new MainFrame_jMenuHelpAbout_ActionAdapter(
                 this));
-        VideoInfoPanel.setLayout(gridBagLayout1);
-        VideoID_TextField.setText("http://www.nicovideo.jp/watch/");
+        videoInfoPanel.setLayout(gridBagLayout1);
         DoButton.setText(DoButtonDefString);
         DoButton.addActionListener(new MainFrame_DoButton_actionAdapter(this));
         SavingInfoTabPanel.setLayout(new GridLayout());
@@ -396,9 +400,6 @@ public class MainFrame extends JFrame {
         avfilterOptionLabel.setText("avfilterオプション");
 
         FontIndexLabel.setText("フォント番号");
-        VideoID_Label.setText("URL/ID");
-        WayBackLabel.setText("過去ログ");
-        OpPanel.setLayout(new GridBagLayout());
 
         BasicInfoTabPanel.setLayout(gridBagLayout12);
         jMenuBar1.add(jMenuFile);
@@ -409,7 +410,7 @@ public class MainFrame extends JFrame {
 
         contentPane.add(statusBar, BorderLayout.SOUTH);
         contentPane.add(mainTabbedPane, java.awt.BorderLayout.CENTER);
-        contentPane.add(VideoInfoPanel, java.awt.BorderLayout.NORTH);
+        contentPane.add(videoInfoPanel, java.awt.BorderLayout.NORTH);
         UserInfoPanel.add(passwordField, new GridBagConstraints(1, 1, 1, 1,
                 1.0, 0.0, GridBagConstraints.CENTER, GridBagConstraints.BOTH,
                 new Insets(0, 5, 5, 5), 0, 0));
@@ -514,14 +515,21 @@ public class MainFrame extends JFrame {
         setFFMpegOptionCheckbox();
 
 
-        VideoInfoPanel.add(DoButton, gridBagConstraints71);
-        VideoInfoPanel.add(OpPanel, new GridBagConstraints(0, 0, 1, 1, 1.0,
+        videoInfoPanel.add(DoButton, gridBagConstraints71);
+
+        videoIdLabel.setText("URL/ID");
+        wayBackLabel.setText("過去ログ");
+        videoIdField.setText("http://www.nicovideo.jp/watch/");
+
+        opPanel.setLayout(new GridBagLayout());
+
+        videoInfoPanel.add(opPanel, new GridBagConstraints(0, 0, 1, 1, 1.0,
                 0.0, GridBagConstraints.CENTER, GridBagConstraints.BOTH,
                 new Insets(0, 0, 0, 0), 0, 0));
-        OpPanel.add(VideoID_Label, gridBagConstraints67);
-        OpPanel.add(VideoID_TextField, gridBagConstraints68);
-        OpPanel.add(WayBackLabel, gridBagConstraints69);
-        OpPanel.add(WayBackField, gridBagConstraints70);
+        opPanel.add(videoIdLabel, gridBagConstraints67);
+        opPanel.add(videoIdField, gridBagConstraints68);
+        opPanel.add(wayBackLabel, gridBagConstraints69);
+        opPanel.add(wayBackField, gridBagConstraints70);
 
         mainTabbedPane.add(BasicInfoTabPanel, "基本設定");
         mainTabbedPane.add(SavingInfoTabPanel, "保存設定");
@@ -604,14 +612,14 @@ public class MainFrame extends JFrame {
         ffmpegPathField.addMouseListener(new PopupRightClick(
                 this.ffmpegPathField));
         vhookPathField.addMouseListener(new PopupRightClick(this.vhookPathField));
-        VideoID_TextField.addMouseListener(new PopupRightClick(
-                this.VideoID_TextField));
+        videoIdField.addMouseListener(new PopupRightClick(
+                this.videoIdField));
         viewCommentField.addMouseListener(new PopupRightClick(
                 this.viewCommentField));
         fontPathField.addMouseListener(new PopupRightClick(this.fontPathField));
         mailAddressField.addMouseListener(new PopupRightClick(this.mailAddressField));
         passwordField.addMouseListener(new PopupRightClick(this.passwordField));
-        WayBackField.addMouseListener(new PopupRightClick(this.WayBackField));
+        wayBackField.addMouseListener(new PopupRightClick(this.wayBackField));
 
         proxyTextField.addMouseListener(new PopupRightClick(this.proxyTextField));
         proxyPortTextField.addMouseListener(new PopupRightClick(
@@ -863,11 +871,7 @@ public class MainFrame extends JFrame {
     // FFmpegの設定 ここまで
     private JLabel FontIndexLabel = new JLabel();
     private JTextField fontIndexField = new JTextField();
-    private JLabel VideoID_Label = new JLabel();
-    private JLabel WayBackLabel = new JLabel();
-    private JTextField WayBackField = new JTextField();
     private GridBagLayout gridBagLayout1 = new GridBagLayout();
-    private JPanel OpPanel = new JPanel();
     private JPanel BasicInfoTabPanel = new JPanel();
     private GridBagLayout gridBagLayout12 = new GridBagLayout();
     private JPanel ConvertingSettingPanel = null;
@@ -931,7 +935,7 @@ public class MainFrame extends JFrame {
                 return;
             }
         } else {
-            url = VideoID_TextField.getText();
+            url = videoIdField.getText();
         }
 
         TextProgressListener sl = new TextProgressListener() {
@@ -964,7 +968,7 @@ public class MainFrame extends JFrame {
             }
         };
 
-        Converter = new Converter(url, WayBackField.getText(), getSetting().toProfile(), sl,
+        Converter = new Converter(url, wayBackField.getText(), getSetting().toProfile(), sl,
                 new ConvertStopFlag(scl));
         DoButton.setText(DoButtonStopString);
         new Thread(Converter).start();
@@ -1556,7 +1560,7 @@ public class MainFrame extends JFrame {
 
         private void mask(boolean b) {
             final VideoSaveInfoPanel panel = videoSaveInfoPanel;
-            VideoID_TextField.setEditable(b);
+            videoIdField.setEditable(b);
             panel.getDelVideoCheckBox().setEnabled(b);
 
             panel.getSaveFolderRadioButton().setEnabled(b);