Issue#18 Used WindowBuilder to set tab label

This commit is contained in:
Didier Clermonté 2016-06-07 23:57:28 +02:00
parent 921f7a2d5d
commit 4569913079

View File

@ -170,14 +170,11 @@ public class SibaGUI
this.backupPanel = new BackupPanel();
this.backupPanel.setBackground(new Color(0, 255, 0));
String backup = BackupPanel.BUNDLE.getString("BackupPanel.TitleBackupPanel.text");
tabbedPane.addTab(backup, null, this.backupPanel, null);
tabbedPane.addTab(BUNDLE.getString("BackupPanel.TitleBackupPanel.text"), null, this.backupPanel, null); //$NON-NLS-1$
CheckPanel checkPanel = new CheckPanel();
checkPanel.setCursor(Cursor.getPredefinedCursor(Cursor.DEFAULT_CURSOR));
checkPanel.setBackground(new Color(144, 238, 144));
String check = BackupPanel.BUNDLE.getString("BackupPanel.TitleCheckPanel.text");
tabbedPane.addTab(check, null, checkPanel, null);
tabbedPane.addTab(BUNDLE.getString("BackupPanel.TitleCheckPanel.text"), null, checkPanel, null); //$NON-NLS-1$
this.frmSimpleBackup.setFont(new Font("DejaVu Sans", Font.BOLD, 12));
this.frmSimpleBackup.setForeground(new Color(0, 100, 0));
this.frmSimpleBackup.setBackground(new Color(102, 205, 170));
@ -223,17 +220,13 @@ public class SibaGUI
public void actionPerformed(final ActionEvent e)
{
tabbedPane.setSelectedIndex(1);
File result;
CheckPanel.choosenFile = CheckDirectorySelector.showSelectorDialog(null, null);
if ((CheckPanel.choosenFile != null) && CheckPanel.choosenFile.exists())
{
CheckPanel.textField.setText(CheckPanel.choosenFile.getName());
result = CheckPanel.choosenFile;
}
else
{
result = null;
}
}
});
@ -323,7 +316,6 @@ public class SibaGUI
logger.info("SibaException chainée = " + sibaException.getCause().getMessage());
// dataMissing.concat(sibaException.getCause().getMessage());
}
String titleWarning = BUNDLE.getString("BackupPanel.TitleWarning.text");
JOptionPane.showMessageDialog(null, dataMissing, titleWarning, JOptionPane.INFORMATION_MESSAGE);
}