Revision 414b03e6
Added by Katja Luther over 5 years ago
eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/ui/section/supplemental/AbstractOriginalSourceElement.java | ||
---|---|---|
13 | 13 |
|
14 | 14 |
import org.eclipse.swt.SWT; |
15 | 15 |
import org.eclipse.swt.events.SelectionListener; |
16 |
import org.eclipse.ui.forms.widgets.ExpandableComposite; |
|
16 | 17 |
|
17 | 18 |
import eu.etaxonomy.cdm.model.common.OriginalSourceBase; |
18 | 19 |
import eu.etaxonomy.cdm.model.common.OriginalSourceType; |
... | ... | |
20 | 21 |
import eu.etaxonomy.taxeditor.ui.element.AbstractFormSection; |
21 | 22 |
import eu.etaxonomy.taxeditor.ui.element.CdmFormFactory; |
22 | 23 |
import eu.etaxonomy.taxeditor.ui.element.ICdmFormElement; |
24 |
import eu.etaxonomy.taxeditor.ui.element.LayoutConstants; |
|
23 | 25 |
import eu.etaxonomy.taxeditor.ui.element.TextWithLabelElement; |
26 |
import eu.etaxonomy.taxeditor.ui.section.common.ExternalLinksSection; |
|
24 | 27 |
|
25 | 28 |
/** |
26 | 29 |
* @author n.hoffmann |
... | ... | |
33 | 36 |
protected TextWithLabelElement text_idNamespace; |
34 | 37 |
protected TextWithLabelElement text_originaleNameString; |
35 | 38 |
|
39 |
protected ExternalLinksSection externalLinks; |
|
40 |
|
|
36 | 41 |
public AbstractOriginalSourceElement(CdmFormFactory formFactory, |
37 | 42 |
AbstractFormSection section, |
38 | 43 |
T element, SelectionListener removeListener, |
... | ... | |
47 | 52 |
public void setEntity(T entity) { |
48 | 53 |
super.setEntity(entity); |
49 | 54 |
text_originaleNameString.setText(entity.getOriginalNameString()); |
55 |
externalLinks.setEntity(entity); |
|
50 | 56 |
} |
51 | 57 |
|
52 |
/** {@inheritDoc} */ |
|
58 |
/** {@inheritDoc} |
|
59 |
* @wbp.parser.entryPoint*/ |
|
53 | 60 |
@Override |
54 | 61 |
public void createControls(ICdmFormElement formElement, int style) { |
55 | 62 |
combo_origsourcetype = formFactory |
... | ... | |
60 | 67 |
text_idNamespace = formFactory.createTextWithLabelElement(formElement, "ID Namespace", null, style); |
61 | 68 |
text_originaleNameString = formFactory.createTextWithLabelElement( |
62 | 69 |
formElement, "Original Name", null, SWT.NULL); |
70 |
externalLinks = formFactory.createExternalLinksSection(getConversationHolder(), formElement, ExpandableComposite.TWISTIE); |
|
71 |
externalLinks.setLayoutData(LayoutConstants.FILL_HORIZONTALLY(2, 1)); |
|
72 |
|
|
63 | 73 |
} |
64 | 74 |
|
65 | 75 |
/** |
Also available in: Unified diff
ref #7415: add external link section to original source part