Search in sources :

Example 1 with ToolkitsPropertiesEditionPart

use of org.obeonetwork.dsl.cinematic.parts.ToolkitsPropertiesEditionPart in project InformationSystem by ObeoNetwork.

the class CinematicRootToolkitsPropertiesEditionComponent method initPart.

/**
 * {@inheritDoc}
 *
 * @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject,
 *      org.eclipse.emf.ecore.resource.ResourceSet)
 */
public void initPart(Object key, int kind, EObject elt, ResourceSet allResource) {
    setInitializing(true);
    if (editingPart != null && key == partKey) {
        editingPart.setContext(elt, allResource);
        final CinematicRoot cinematicRoot = (CinematicRoot) elt;
        final ToolkitsPropertiesEditionPart toolkitsPart = (ToolkitsPropertiesEditionPart) editingPart;
        // init values
        if (isAccessible(CinematicViewsRepository.Toolkits.Properties.toolkits_)) {
            toolkitsSettings = new ReferencesTableSettings(cinematicRoot, CinematicPackage.eINSTANCE.getCinematicRoot_Toolkits());
            toolkitsPart.initToolkits(toolkitsSettings);
        }
        // init filters
        if (isAccessible(CinematicViewsRepository.Toolkits.Properties.toolkits_)) {
            toolkitsPart.addFilterToToolkits(new EObjectFilter(ToolkitsPackage.Literals.TOOLKIT));
        // Start of user code for additional businessfilters for toolkits
        // End of user code
        }
    // init values for referenced views
    // init filters for referenced views
    }
    setInitializing(false);
}
Also used : EObjectFilter(org.eclipse.emf.eef.runtime.impl.filters.EObjectFilter) ReferencesTableSettings(org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings) CinematicRoot(org.obeonetwork.dsl.cinematic.CinematicRoot) ToolkitsPropertiesEditionPart(org.obeonetwork.dsl.cinematic.parts.ToolkitsPropertiesEditionPart)

Aggregations

EObjectFilter (org.eclipse.emf.eef.runtime.impl.filters.EObjectFilter)1 ReferencesTableSettings (org.eclipse.emf.eef.runtime.ui.widgets.referencestable.ReferencesTableSettings)1 CinematicRoot (org.obeonetwork.dsl.cinematic.CinematicRoot)1 ToolkitsPropertiesEditionPart (org.obeonetwork.dsl.cinematic.parts.ToolkitsPropertiesEditionPart)1