4 import javax.swing.JButton;
5 import javax.swing.JCheckBox;
6 import javax.swing.JFrame;
7 import javax.swing.JRadioButton;
8 import javax.swing.JTextField;
9 import javax.swing.SwingUtilities;
10 import javax.swing.UIManager;
16 class VideoSaveInfoPanel extends javax.swing.JPanel {
18 /** Creates new form VideoSaveInfoPanel */
19 VideoSaveInfoPanel() {
23 /** This method is called from within the constructor to
24 * initialize the form.
25 * WARNING: Do NOT modify this code. The content of this method is
26 * always regenerated by the Form Editor.
28 @SuppressWarnings("unchecked")
29 // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
30 private void initComponents() {
32 videoSavingGroup = new javax.swing.ButtonGroup();
33 videoNamingGroup = new javax.swing.ButtonGroup();
34 videoSaveButton = new javax.swing.JRadioButton();
35 videoNoSaveButton = new javax.swing.JRadioButton();
36 basicSetting = new javax.swing.JPanel();
37 delVideoCheckBox = new javax.swing.JCheckBox();
38 saveFolderRadioButton = new javax.swing.JRadioButton();
39 videoSavedFolderField = new javax.swing.JTextField();
40 showSavingVideoFolderDialogButton = new javax.swing.JButton();
41 saveFileRadioButton = new javax.swing.JRadioButton();
42 videoSavedFileField = new javax.swing.JTextField();
43 showSavingVideoFileDialogButton = new javax.swing.JButton();
44 videoUseNiBrButton = new javax.swing.JRadioButton();
45 nibrExtendSetting = new javax.swing.JPanel();
46 nibrFileField = new javax.swing.JTextField();
47 nibrFileChooserButton = new javax.swing.JButton();
49 setBorder(javax.swing.BorderFactory.createTitledBorder("
\93®
\89æ
\95Û
\91¶
\90Ý
\92è"));
51 videoSavingGroup.add(videoSaveButton);
52 videoSaveButton.setText("
\93®
\89æ
\82ð
\83_
\83E
\83\93\83\8d\81[
\83h
\82µ
\82È
\82¢");
54 videoSavingGroup.add(videoNoSaveButton);
55 videoNoSaveButton.setText("
\93®
\89æ
\82ð
\83_
\83E
\83\93\83\8d\81[
\83h
\82·
\82é");
57 delVideoCheckBox.setText("
\95Ï
\8a·
\8cã
\82É
\93®
\89æ
\83t
\83@
\83C
\83\8b\82ð
\8dí
\8f\9c\82·
\82é");
59 videoNamingGroup.add(saveFolderRadioButton);
60 saveFolderRadioButton.setText("
\95Û
\91¶
\82·
\82é
\83t
\83H
\83\8b\83_
\82ð
\8ew
\92è
\82µ
\81A
\83t
\83@
\83C
\83\8b\96¼
\82Í
\8e©
\93®
\82Å
\8c\88\92è
\82·
\82é");
62 showSavingVideoFolderDialogButton.setText("
\8eQ
\8fÆ...");
64 videoNamingGroup.add(saveFileRadioButton);
65 saveFileRadioButton.setText("
\95Û
\91¶
\82·
\82é
\83t
\83@
\83C
\83\8b\96¼
\82ð
\8ew
\92è
\82·
\82é");
67 showSavingVideoFileDialogButton.setText("
\8eQ
\8fÆ...");
69 javax.swing.GroupLayout basicSettingLayout = new javax.swing.GroupLayout(basicSetting);
70 basicSetting.setLayout(basicSettingLayout);
71 basicSettingLayout.setHorizontalGroup(
72 basicSettingLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
73 .addGroup(basicSettingLayout.createSequentialGroup()
74 .addGroup(basicSettingLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
75 .addComponent(delVideoCheckBox)
76 .addComponent(saveFolderRadioButton)
77 .addComponent(saveFileRadioButton)
78 .addGroup(basicSettingLayout.createSequentialGroup()
80 .addComponent(videoSavedFileField, javax.swing.GroupLayout.DEFAULT_SIZE, 205, Short.MAX_VALUE)
81 .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
82 .addComponent(showSavingVideoFileDialogButton))
83 .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, basicSettingLayout.createSequentialGroup()
85 .addComponent(videoSavedFolderField, javax.swing.GroupLayout.DEFAULT_SIZE, 205, Short.MAX_VALUE)
86 .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
87 .addComponent(showSavingVideoFolderDialogButton)))
90 basicSettingLayout.setVerticalGroup(
91 basicSettingLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
92 .addGroup(basicSettingLayout.createSequentialGroup()
93 .addComponent(delVideoCheckBox)
94 .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
95 .addComponent(saveFolderRadioButton)
96 .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
97 .addGroup(basicSettingLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
98 .addComponent(videoSavedFolderField, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
99 .addComponent(showSavingVideoFolderDialogButton))
101 .addComponent(saveFileRadioButton)
102 .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
103 .addGroup(basicSettingLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
104 .addComponent(videoSavedFileField, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
105 .addComponent(showSavingVideoFileDialogButton))
106 .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
109 videoSavingGroup.add(videoUseNiBrButton);
110 videoUseNiBrButton.setText("NicoBrowser
\83_
\83E
\83\93\83\8d\81[
\83h
\83t
\83@
\83C
\83\8b\82ð
\97p
\82¢
\82é");
112 nibrFileChooserButton.setText("
\8eQ
\8fÆ...");
114 javax.swing.GroupLayout nibrExtendSettingLayout = new javax.swing.GroupLayout(nibrExtendSetting);
115 nibrExtendSetting.setLayout(nibrExtendSettingLayout);
116 nibrExtendSettingLayout.setHorizontalGroup(
117 nibrExtendSettingLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
118 .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, nibrExtendSettingLayout.createSequentialGroup()
119 .addComponent(nibrFileField, javax.swing.GroupLayout.DEFAULT_SIZE, 226, Short.MAX_VALUE)
120 .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
121 .addComponent(nibrFileChooserButton)
124 nibrExtendSettingLayout.setVerticalGroup(
125 nibrExtendSettingLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
126 .addGroup(nibrExtendSettingLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
127 .addComponent(nibrFileField, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
128 .addComponent(nibrFileChooserButton))
131 javax.swing.GroupLayout layout = new javax.swing.GroupLayout(this);
132 this.setLayout(layout);
133 layout.setHorizontalGroup(
134 layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
135 .addGroup(layout.createSequentialGroup()
136 .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
137 .addComponent(videoSaveButton)
138 .addComponent(videoNoSaveButton))
140 .addGroup(layout.createSequentialGroup()
141 .addComponent(videoUseNiBrButton)
143 .addGroup(layout.createSequentialGroup()
145 .addComponent(basicSetting, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
146 .addGroup(layout.createSequentialGroup()
148 .addComponent(nibrExtendSetting, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
150 layout.setVerticalGroup(
151 layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
152 .addGroup(layout.createSequentialGroup()
153 .addComponent(videoSaveButton)
154 .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
155 .addComponent(videoNoSaveButton)
156 .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
157 .addComponent(basicSetting, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
158 .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
159 .addComponent(videoUseNiBrButton)
160 .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
161 .addComponent(nibrExtendSetting, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
163 }// </editor-fold>//GEN-END:initComponents
164 // Variables declaration - do not modify//GEN-BEGIN:variables
165 private javax.swing.JPanel basicSetting;
166 private javax.swing.JCheckBox delVideoCheckBox;
167 private javax.swing.JPanel nibrExtendSetting;
168 private javax.swing.JButton nibrFileChooserButton;
169 private javax.swing.JTextField nibrFileField;
170 private javax.swing.JRadioButton saveFileRadioButton;
171 private javax.swing.JRadioButton saveFolderRadioButton;
172 private javax.swing.JButton showSavingVideoFileDialogButton;
173 private javax.swing.JButton showSavingVideoFolderDialogButton;
174 private javax.swing.ButtonGroup videoNamingGroup;
175 private javax.swing.JRadioButton videoNoSaveButton;
176 private javax.swing.JRadioButton videoSaveButton;
177 private javax.swing.JTextField videoSavedFileField;
178 private javax.swing.JTextField videoSavedFolderField;
179 private javax.swing.ButtonGroup videoSavingGroup;
180 private javax.swing.JRadioButton videoUseNiBrButton;
181 // End of variables declaration//GEN-END:variables
183 /** @return
\81u
\93®
\89æ
\82ð
\83_
\83E
\83\93\83\8d\81[
\83h
\82µ
\82È
\82¢
\81v
\83\89\83W
\83I
\83{
\83^
\83\93. */
184 JRadioButton getVideoNoSaveButton() {
185 return videoNoSaveButton;
188 /** @return
\81u
\93®
\89æ
\82ð
\83_
\83E
\83\93\83\8d\81[
\83h
\82·
\82é
\81v
\83\89\83W
\83I
\83{
\83^
\83\93. */
189 JRadioButton getVideoSaveButton() {
190 return videoSaveButton;
193 /** @return
\81uNicoBrowser
\83_
\83E
\83\93\83\8d\81[
\83h
\83t
\83@
\83C
\83\8b\82ð
\97p
\82¢
\82é
\81v
\83\89\83W
\83I
\83{
\83^
\83\93. */
194 JRadioButton getVideoUseNiBrButton() {
195 return videoUseNiBrButton;
198 /** @return
\81u
\95Ï
\8a·
\8cã
\82É
\93®
\89æ
\83t
\83@
\83C
\83\8b\82ð
\8dí
\8f\9c\82·
\82é
\81v
\83`
\83F
\83b
\83N
\83{
\83b
\83N
\83X. */
199 JCheckBox getDelVideoCheckBox() {
200 return delVideoCheckBox;
203 /** @return
\81u
\95Û
\91¶
\82·
\82é
\83t
\83H
\83\8b\83_
\82ð
\8ew
\92è
\82µ
\81A
\83t
\83@
\83C
\83\8b\96¼
\82Í
\8e©
\93®
\82Å
\8c\88\92è
\82·
\82é
\81v
\83\89\83W
\83I
\83{
\83^
\83\93. */
204 JRadioButton getSaveFolderRadioButton() {
205 return saveFolderRadioButton;
208 /** @return
\81u
\95Û
\91¶
\82·
\82é
\83t
\83@
\83C
\83\8b\96¼
\82ð
\8ew
\92è
\82·
\82é
\81v
\83\89\83W
\83I
\83{
\83^
\83\93. */
209 JRadioButton getSaveFileRadioButton() {
210 return saveFileRadioButton;
213 /** @return
\81u
\95Û
\91¶
\82·
\82é
\83t
\83H
\83\8b\83_
\82ð
\8ew
\92è
\82µ
\81A
\83t
\83@
\83C
\83\8b\96¼
\82Í
\8e©
\93®
\82Å
\8c\88\92è
\82·
\82é
\81v
\83e
\83L
\83X
\83g
\83t
\83B
\81[
\83\8b\83h. */
214 JTextField getVideoSavedFolderField() {
215 return videoSavedFolderField;
218 /** @return
\81u
\95Û
\91¶
\82·
\82é
\83t
\83H
\83\8b\83_
\82ð
\8ew
\92è
\82µ
\81A
\83t
\83@
\83C
\83\8b\96¼
\82Í
\8e©
\93®
\82Å
\8c\88\92è
\82·
\82é
\81v
\83t
\83@
\83C
\83\8b\83`
\83\85\81[
\83U
\8bN
\93®
\83{
\83^
\83\93. */
219 JButton getShowSavingVideoFolderDialogButton() {
220 return showSavingVideoFolderDialogButton;
223 /** @return
\81u
\95Û
\91¶
\82·
\82é
\83t
\83@
\83C
\83\8b\96¼
\82ð
\8ew
\92è
\82·
\82é
\81v
\83e
\83L
\83X
\83g
\83t
\83B
\81[
\83\8b\83h. */
224 JTextField getVideoSavedFileField() {
225 return videoSavedFileField;
228 /** @return
\81u
\95Û
\91¶
\82·
\82é
\83t
\83@
\83C
\83\8b\96¼
\82ð
\8ew
\92è
\82·
\82é
\81v
\83t
\83@
\83C
\83\8b\83`
\83\85\81[
\83U
\8bN
\93®
\83{
\83^
\83\93. */
229 JButton getShowSavingVideoFileDialogButton() {
230 return showSavingVideoFileDialogButton;
233 /** @return
\81uNicoBrowser
\83_
\83E
\83\93\83\8d\81[
\83h
\83t
\83@
\83C
\83\8b\82ð
\97p
\82¢
\82é
\81v
\83e
\83L
\83X
\83g
\83t
\83B
\81[
\83\8b\83h. */
234 JTextField getNibrFileField() {
235 return nibrFileField;
238 /** @return
\81uNicoBrowser
\83_
\83E
\83\93\83\8d\81[
\83h
\83t
\83@
\83C
\83\8b\82ð
\97p
\82¢
\82é
\81v
\83t
\83@
\83C
\83\8b\83`
\83\85\81[
\83U
\8bN
\93®
\83{
\83^
\83\93. */
239 JButton getNibrFileChooserButton() {
240 return nibrFileChooserButton;
243 public static void main(String[] args) {
245 SwingUtilities.invokeLater(new Runnable() {
248 JFrame frame = new JFrame();
249 frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
250 frame.setContentPane(new VideoSaveInfoPanel());
252 frame.setVisible(true);
257 private static void setLookAndFeel() {
258 String lafClassName = UIManager.getSystemLookAndFeelClassName();
260 UIManager.setLookAndFeel(lafClassName);
261 } catch (Exception e) {
262 throw new RuntimeException(e);