Issue#17 Used BackupPanel type instead of JPanel
This commit is contained in:
parent
56140f33b0
commit
921f7a2d5d
@ -115,7 +115,6 @@ public class CheckPanel extends JPanel
|
|||||||
{
|
{
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
|
|
||||||
if ((CheckPanel.choosenFile != null) && CheckPanel.choosenFile.exists())
|
if ((CheckPanel.choosenFile != null) && CheckPanel.choosenFile.exists())
|
||||||
{
|
{
|
||||||
boolean check = SibaManager.check(CheckPanel.choosenFile);
|
boolean check = SibaManager.check(CheckPanel.choosenFile);
|
||||||
@ -148,7 +147,6 @@ public class CheckPanel extends JPanel
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
add(btnNewButton_1, "3, 4");
|
add(btnNewButton_1, "3, 4");
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public File choosenDirectory() throws IOException, NoSuchAlgorithmException
|
public File choosenDirectory() throws IOException, NoSuchAlgorithmException
|
||||||
@ -166,7 +164,5 @@ public class CheckPanel extends JPanel
|
|||||||
result = null;
|
result = null;
|
||||||
}
|
}
|
||||||
return result;
|
return result;
|
||||||
// }
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -40,7 +40,6 @@ import javax.swing.JMenu;
|
|||||||
import javax.swing.JMenuBar;
|
import javax.swing.JMenuBar;
|
||||||
import javax.swing.JMenuItem;
|
import javax.swing.JMenuItem;
|
||||||
import javax.swing.JOptionPane;
|
import javax.swing.JOptionPane;
|
||||||
import javax.swing.JPanel;
|
|
||||||
import javax.swing.JSeparator;
|
import javax.swing.JSeparator;
|
||||||
import javax.swing.JTabbedPane;
|
import javax.swing.JTabbedPane;
|
||||||
import javax.swing.SwingConstants;
|
import javax.swing.SwingConstants;
|
||||||
@ -69,7 +68,7 @@ public class SibaGUI
|
|||||||
Locale locale;
|
Locale locale;
|
||||||
|
|
||||||
private JFrame frmSimpleBackup;
|
private JFrame frmSimpleBackup;
|
||||||
private JPanel backupPanel;
|
private BackupPanel backupPanel;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* This is the constructor of this application.
|
* This is the constructor of this application.
|
||||||
@ -174,11 +173,11 @@ public class SibaGUI
|
|||||||
String backup = BackupPanel.BUNDLE.getString("BackupPanel.TitleBackupPanel.text");
|
String backup = BackupPanel.BUNDLE.getString("BackupPanel.TitleBackupPanel.text");
|
||||||
tabbedPane.addTab(backup, null, this.backupPanel, null);
|
tabbedPane.addTab(backup, null, this.backupPanel, null);
|
||||||
|
|
||||||
JPanel panel_1 = new CheckPanel();
|
CheckPanel checkPanel = new CheckPanel();
|
||||||
panel_1.setCursor(Cursor.getPredefinedCursor(Cursor.DEFAULT_CURSOR));
|
checkPanel.setCursor(Cursor.getPredefinedCursor(Cursor.DEFAULT_CURSOR));
|
||||||
panel_1.setBackground(new Color(144, 238, 144));
|
checkPanel.setBackground(new Color(144, 238, 144));
|
||||||
String check = BackupPanel.BUNDLE.getString("BackupPanel.TitleCheckPanel.text");
|
String check = BackupPanel.BUNDLE.getString("BackupPanel.TitleCheckPanel.text");
|
||||||
tabbedPane.addTab(check, null, panel_1, null);
|
tabbedPane.addTab(check, null, checkPanel, null);
|
||||||
this.frmSimpleBackup.setFont(new Font("DejaVu Sans", Font.BOLD, 12));
|
this.frmSimpleBackup.setFont(new Font("DejaVu Sans", Font.BOLD, 12));
|
||||||
this.frmSimpleBackup.setForeground(new Color(0, 100, 0));
|
this.frmSimpleBackup.setForeground(new Color(0, 100, 0));
|
||||||
this.frmSimpleBackup.setBackground(new Color(102, 205, 170));
|
this.frmSimpleBackup.setBackground(new Color(102, 205, 170));
|
||||||
@ -209,10 +208,8 @@ public class SibaGUI
|
|||||||
File file = SourceDirectorySelector.showSelectorDialog(null, null);
|
File file = SourceDirectorySelector.showSelectorDialog(null, null);
|
||||||
if (file != null)
|
if (file != null)
|
||||||
{
|
{
|
||||||
((BackupPanel) SibaGUI.this.backupPanel).setSourceDirectory(file.getPath());
|
SibaGUI.this.backupPanel.setSourceDirectory(file.getPath());
|
||||||
}
|
}
|
||||||
|
|
||||||
// panel.setVisible(true);
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
mnFile.add(mntmBackup);
|
mnFile.add(mntmBackup);
|
||||||
|
Loading…
Reference in New Issue
Block a user