use of org.eclipse.emf.eef.runtime.ui.widgets.EMFComboViewer in project InformationSystem by ObeoNetwork.
the class FinderPropertiesEditionPartImpl method createMultiplicityEMFComboViewer.
protected Composite createMultiplicityEMFComboViewer(Composite parent) {
createDescription(parent, EntityViewsRepository.Finder.Properties.multiplicity, EntityMessages.FinderPropertiesEditionPart_MultiplicityLabel);
multiplicity = new EMFComboViewer(parent);
multiplicity.setContentProvider(new ArrayContentProvider());
multiplicity.setLabelProvider(new AdapterFactoryLabelProvider(EEFRuntimePlugin.getDefault().getAdapterFactory()));
GridData multiplicityData = new GridData(GridData.FILL_HORIZONTAL);
multiplicity.getCombo().setLayoutData(multiplicityData);
multiplicity.addSelectionChangedListener(new ISelectionChangedListener() {
/**
* {@inheritDoc}
*
* @see org.eclipse.jface.viewers.ISelectionChangedListener#selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent)
*/
public void selectionChanged(SelectionChangedEvent event) {
if (propertiesEditionComponent != null)
propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(FinderPropertiesEditionPartImpl.this, EntityViewsRepository.Finder.Properties.multiplicity, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, getMultiplicity()));
}
});
multiplicity.setID(EntityViewsRepository.Finder.Properties.multiplicity);
// $NON-NLS-1$
SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(EntityViewsRepository.Finder.Properties.multiplicity, EntityViewsRepository.SWT_KIND), null);
// End of user code
return parent;
}
use of org.eclipse.emf.eef.runtime.ui.widgets.EMFComboViewer in project InformationSystem by ObeoNetwork.
the class ColumnPropertiesEditionPartImpl method createTypeEMFComboViewer.
protected Composite createTypeEMFComboViewer(Composite parent) {
createDescription(parent, DatabaseViewsRepository.Column.Properties.type, DatabaseMessages.ColumnPropertiesEditionPart_TypeLabel);
type = new EMFComboViewer(parent);
GridData typeData = new GridData(GridData.FILL_HORIZONTAL);
type.getCombo().setLayoutData(typeData);
type.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory));
type.addSelectionChangedListener(new ISelectionChangedListener() {
/**
* {@inheritDoc}
*
* @see org.eclipse.jface.viewers.ISelectionChangedListener#selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent)
*/
public void selectionChanged(SelectionChangedEvent event) {
if (propertiesEditionComponent != null)
propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(ColumnPropertiesEditionPartImpl.this, DatabaseViewsRepository.Column.Properties.type, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, getType()));
}
});
type.setContentProvider(new EMFListContentProvider());
EditingUtils.setID(type.getCombo(), DatabaseViewsRepository.Column.Properties.type);
// $NON-NLS-1$
EditingUtils.setEEFtype(type.getCombo(), "eef::Combo");
// $NON-NLS-1$
SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(DatabaseViewsRepository.Column.Properties.type, DatabaseViewsRepository.SWT_KIND), null);
// End of user code
return parent;
}
use of org.eclipse.emf.eef.runtime.ui.widgets.EMFComboViewer in project InformationSystem by ObeoNetwork.
the class RiskPropertiesEditionPartForm method createDrawbacksEMFComboViewer.
protected Composite createDrawbacksEMFComboViewer(FormToolkit widgetFactory, Composite parent) {
createDescription(parent, GraalextensionsViewsRepository.Risk.Properties.drawbacks, GraalextensionsMessages.RiskPropertiesEditionPart_DrawbacksLabel);
drawbacks = new EMFComboViewer(parent);
drawbacks.setContentProvider(new ArrayContentProvider());
drawbacks.setLabelProvider(new AdapterFactoryLabelProvider(EEFRuntimePlugin.getDefault().getAdapterFactory()));
GridData drawbacksData = new GridData(GridData.FILL_HORIZONTAL);
drawbacks.getCombo().setLayoutData(drawbacksData);
drawbacks.addSelectionChangedListener(new ISelectionChangedListener() {
/**
* {@inheritDoc}
*
* @see org.eclipse.jface.viewers.ISelectionChangedListener#selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent)
*/
public void selectionChanged(SelectionChangedEvent event) {
if (propertiesEditionComponent != null)
propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(RiskPropertiesEditionPartForm.this, GraalextensionsViewsRepository.Risk.Properties.drawbacks, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, getDrawbacks()));
}
});
drawbacks.setID(GraalextensionsViewsRepository.Risk.Properties.drawbacks);
// $NON-NLS-1$
FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(GraalextensionsViewsRepository.Risk.Properties.drawbacks, GraalextensionsViewsRepository.FORM_KIND), null);
// End of user code
return parent;
}
use of org.eclipse.emf.eef.runtime.ui.widgets.EMFComboViewer in project InformationSystem by ObeoNetwork.
the class RiskPropertiesEditionPartForm method createRiskEMFComboViewer.
protected Composite createRiskEMFComboViewer(FormToolkit widgetFactory, Composite parent) {
createDescription(parent, GraalextensionsViewsRepository.Risk.Properties.risk_, GraalextensionsMessages.RiskPropertiesEditionPart_RiskLabel);
risk = new EMFComboViewer(parent);
risk.setContentProvider(new ArrayContentProvider());
risk.setLabelProvider(new AdapterFactoryLabelProvider(EEFRuntimePlugin.getDefault().getAdapterFactory()));
GridData riskData = new GridData(GridData.FILL_HORIZONTAL);
risk.getCombo().setLayoutData(riskData);
risk.addSelectionChangedListener(new ISelectionChangedListener() {
/**
* {@inheritDoc}
*
* @see org.eclipse.jface.viewers.ISelectionChangedListener#selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent)
*/
public void selectionChanged(SelectionChangedEvent event) {
if (propertiesEditionComponent != null)
propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(RiskPropertiesEditionPartForm.this, GraalextensionsViewsRepository.Risk.Properties.risk_, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, getRisk()));
}
});
risk.setID(GraalextensionsViewsRepository.Risk.Properties.risk_);
// $NON-NLS-1$
FormUtils.createHelpButton(widgetFactory, parent, propertiesEditionComponent.getHelpContent(GraalextensionsViewsRepository.Risk.Properties.risk_, GraalextensionsViewsRepository.FORM_KIND), null);
// End of user code
return parent;
}
use of org.eclipse.emf.eef.runtime.ui.widgets.EMFComboViewer in project InformationSystem by ObeoNetwork.
the class RiskPropertiesEditionPartImpl method createDrawbacksEMFComboViewer.
protected Composite createDrawbacksEMFComboViewer(Composite parent) {
createDescription(parent, GraalextensionsViewsRepository.Risk.Properties.drawbacks, GraalextensionsMessages.RiskPropertiesEditionPart_DrawbacksLabel);
drawbacks = new EMFComboViewer(parent);
drawbacks.setContentProvider(new ArrayContentProvider());
drawbacks.setLabelProvider(new AdapterFactoryLabelProvider(EEFRuntimePlugin.getDefault().getAdapterFactory()));
GridData drawbacksData = new GridData(GridData.FILL_HORIZONTAL);
drawbacks.getCombo().setLayoutData(drawbacksData);
drawbacks.addSelectionChangedListener(new ISelectionChangedListener() {
/**
* {@inheritDoc}
*
* @see org.eclipse.jface.viewers.ISelectionChangedListener#selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent)
*/
public void selectionChanged(SelectionChangedEvent event) {
if (propertiesEditionComponent != null)
propertiesEditionComponent.firePropertiesChanged(new PropertiesEditionEvent(RiskPropertiesEditionPartImpl.this, GraalextensionsViewsRepository.Risk.Properties.drawbacks, PropertiesEditionEvent.COMMIT, PropertiesEditionEvent.SET, null, getDrawbacks()));
}
});
drawbacks.setID(GraalextensionsViewsRepository.Risk.Properties.drawbacks);
// $NON-NLS-1$
SWTUtils.createHelpButton(parent, propertiesEditionComponent.getHelpContent(GraalextensionsViewsRepository.Risk.Properties.drawbacks, GraalextensionsViewsRepository.SWT_KIND), null);
// End of user code
return parent;
}
Aggregations