protected Button button_edit;
- private final String labelString;
+// private final String labelString;
private Composite selectableComposite;
* @param <T>
* a T object.
*/
- public EntitySelectionFieldController(EntitySelectionField entitySelectionField, CdmFormFactory formFactory, ConversationHolder conversation, ICdmFormElement parentElement, String labelString, T entity, int mode) {
+ public EntitySelectionFieldController(EntitySelectionField entitySelectionField, CdmFormFactory formFactory, ConversationHolder conversation, ICdmFormElement parentElement, T entity, int mode) {
super(formFactory, parentElement);
setPropertyChangeListeners(formFactory.getPropertyChangeListeners());
this.isDeletable = (mode & DELETABLE) == DELETABLE;
boolean isSelectable = (mode & SELECTABLE) == SELECTABLE;
- this.labelString = labelString;
+// this.labelString = labelString;
this.conversation = conversation;
setEntity(entity);
}
- public EntitySelectionFieldController(EntitySelectionField entitySelectionField, CdmFormFactory formFactory, ConversationHolder conversation, ICdmFormElement parentElement, Class<T> clazz, String labelString, T entity, int mode) {
- this(entitySelectionField, formFactory, conversation, parentElement, labelString, entity, mode);
+ public EntitySelectionFieldController(EntitySelectionField entitySelectionField, CdmFormFactory formFactory, ConversationHolder conversation, ICdmFormElement parentElement, Class<T> clazz, T entity, int mode) {
+ this(entitySelectionField, formFactory, conversation, parentElement, entity, mode);
this.clazz = clazz;
}
/** {@inheritDoc} */
@Override
public void createControls(ICdmFormElement formElement, int style) {
- selection_namedArea = new EntitySelectionFieldController<NamedArea>(new EntitySelectionField(formElement.getLayoutComposite(), SWT.NONE), getFormFactory(), getConversationHolder(), formElement, NamedArea.class, "", null, EntitySelectionElement.NOTHING);
+ selection_namedArea = new EntitySelectionFieldController<NamedArea>(new EntitySelectionField(formElement.getLayoutComposite(), SWT.NONE), getFormFactory(), getConversationHolder(), formElement, NamedArea.class, null, EntitySelectionElement.NOTHING);
}
/*
protected void createControls(ICdmFormElement formElement, DerivedUnitFacade entity, int style) {
toggleableText_titleCache = new ToggleableTextFieldController(fieldObservationGeneralElement.getToggleableTextField(), getFormFactory(), formElement, entity.getTitleCache(), entity.isProtectedTitleCache(), style);
- selection_country = new EntitySelectionFieldController<NamedArea>(fieldObservationGeneralElement.getCountrySelectionField(), getFormFactory(), getConversationHolder(), formElement, NamedArea.class, "Country", entity.getCountry(), EntitySelectionElement.NOTHING);
+ selection_country = new EntitySelectionFieldController<NamedArea>(fieldObservationGeneralElement.getCountrySelectionField(), getFormFactory(), getConversationHolder(), formElement, NamedArea.class, entity.getCountry(), EntitySelectionElement.NOTHING);
languageText_locality = new LanguageTextFieldController(fieldObservationGeneralElement.getTextLocality(), getFormFactory(), formElement, entity.getLocality());
element_point = new PointFieldController(fieldObservationGeneralElement.getPointField(),getFormFactory(), formElement, entity.getExactLocation(), style);
number_elevation = new NumberFieldController(fieldObservationGeneralElement.getTextElevation(), getFormFactory(), formElement, entity.getAbsoluteElevation());
// element_date = formFactory.createTimePeriodElement(formElement, "Date", entity.getGatheringPeriod(), style);
- selection_collector = new EntitySelectionFieldController<AgentBase>(fieldObservationGeneralElement.getCollectorSelectionField(), getFormFactory(), getConversationHolder(), formElement, AgentBase.class, "Collector", entity.getCollector(), EntitySelectionElement.ALL);
+ selection_collector = new EntitySelectionFieldController<AgentBase>(fieldObservationGeneralElement.getCollectorSelectionField(), getFormFactory(), getConversationHolder(), formElement, AgentBase.class, entity.getCollector(), EntitySelectionElement.ALL);
text_collectingNumber = new TextFieldController(fieldObservationGeneralElement.getTextCollectingNumber(), getFormFactory(), formElement, entity.getFieldNumber(), null);
}