protected final JComponent buildEditPanel(final WindowInterface window) {
FormLayout layout = new FormLayout(
"10dlu,300dlu:grow,10dlu",
"10dlu,p,3dlu,p,3dlu,fill:p:grow,3dlu,p,3dlu,p,3dlu,fill:50dlu:grow,3dlu,p,3dlu,fill:50dlu:grow,3dlu,p,3dlu,fill:50dlu:grow,3dlu,p,3dlu,p,5dlu,"
+ "p");
PanelBuilder builder = new PanelBuilder(layout);
// PanelBuilder builder = new PanelBuilder(new FormDebugPanel(),layout);
CellConstraints cc = new CellConstraints();
builder.add(buildDetailPanel(), cc.xy(2, 2));
// builder.add(radioButtonPersonalInjury, cc.xy(2, 4));
// builder.add(radioButtonNotPersonalInjury, cc.xy(2, 6));
builder.add(buildAccidentTypePanel(), cc.xy(2, 4));
if (!search) {
builder.add(buildParticipantsPanel(), cc.xy(2, 6));
}
builder.add(buildDateTimePanel(), cc.xy(2, 8));
builder.addLabel("Beskrivelse av hendelse/ulykke:", cc.xy(2, 10));
builder.add(new JScrollPane(textAreaDescription), cc.xy(2, 12));
builder.addLabel("�rsak til hendelse/ulykke:", cc.xy(2, 14));
builder.add(new JScrollPane(textAreaCause), cc.xy(2, 16));
builder.addLabel("Beskrivelse av tiltak:", cc.xy(2, 18));
builder.add(new JScrollPane(textAreaPreventiveActionComment),
cc.xy(2, 20));
builder.add(buildResponsiblePanel(), cc.xy(2, 22));
builder.add(buildCheckBoxPanel(), cc.xy(2, 24));
if (search) {
builder.add(
ButtonBarFactory.buildCenteredBar(buttonSave, buttonCancel),
cc.xy(2, 26));
} else {
builder.add(ButtonBarFactory.buildCenteredBar(buttonPrint,
buttonSave, buttonCancel), cc.xy(2, 26));
}
return new IconFeedbackPanel(validationResultModel, builder.getPanel());
}