Search in sources :

Example 1 with ReplaceWithClassNameAction

use of org.whole.lang.ui.actions.ReplaceWithClassNameAction in project whole by wholeplatform.

the class WorkflowsIDEContentAssistVisitor method chooseClass.

protected boolean chooseClass(IEntity entity) {
    if (!WorkflowsUtils.isClassNameInJavaActivity(entity))
        return false;
    ReplaceWithClassNameAction action = new ReplaceWithClassNameAction((IEclipseContext) getBindings().wGetValue("eclipse#eclipseContext"), WorkflowsEntityDescriptorEnum.StringLiteral, entity.wStringValue(), "Select class...");
    ActionsEntityFactory aef = ActionsEntityFactory.instance;
    GroupAction customGroup = aef.createGroupAction();
    customGroup.setFillStrategy(aef.createFlat());
    customGroup.getText().setValue("workflows.custom");
    customGroup.setActions(aef.createActions(aef.createCustomAction(action)));
    return EntityUtils.isResolver(entity) ? mergeResult(StringLiteral, customGroup) : mergeResult(customGroup);
}
Also used : ReplaceWithClassNameAction(org.whole.lang.ui.actions.ReplaceWithClassNameAction) GroupAction(org.whole.lang.actions.model.GroupAction) ActionsEntityFactory(org.whole.lang.actions.factories.ActionsEntityFactory)

Aggregations

ActionsEntityFactory (org.whole.lang.actions.factories.ActionsEntityFactory)1 GroupAction (org.whole.lang.actions.model.GroupAction)1 ReplaceWithClassNameAction (org.whole.lang.ui.actions.ReplaceWithClassNameAction)1