Examples of IWodElement


Examples of org.objectstyle.wolips.bindings.wod.IWodElement

  public void cursorPositionChanged(TextEditor editor, Point selectionRange) {
    _lastEditor = editor;
    _lastPosition = selectionRange;

    WodParserCache cache = null;
    IWodElement wodElement = null;
    if (editor instanceof IWOEditor) {
      try {
        IWOEditor woEditor = (IWOEditor) editor;
        cache = woEditor.getParserCache();
        wodElement = woEditor.getSelectedElement(true, true);
View Full Code Here

Examples of org.objectstyle.wolips.bindings.wod.IWodElement

    @Override
    protected void setValue(Object element, Object value) {
      IApiBinding binding = (IApiBinding) element;
      if (binding != null) {
        IWodElement wodElement = getWodElement();
        if (wodElement != null) {
          try {
            RefactoringWodBinding wodBinding = getRefactoringElement().getBindingNamed(binding.getName());
            if (wodBinding != null) {
              wodBinding.setName((String) value);
View Full Code Here

Examples of org.objectstyle.wolips.bindings.wod.IWodElement

    return new TextAutoscroller(editorControl);
  }

  @Override
  protected IWodElement getSelectedContainerAtPoint(Point point, boolean forDrop) throws Exception {
    IWodElement wodElement = _woEditor.getWodElementAtPoint(point, forDrop, true);
    return wodElement;
  }
View Full Code Here

Examples of org.objectstyle.wolips.bindings.wod.IWodElement

  @Override
  protected boolean dropFromColumnAtPoint(WOBrowserColumn column, Point dropPoint, BindingsDragHandler dragHandler) throws Exception {
    boolean dropFinished = true;
    Point controlDropPoint = getEditorControl().toControl(dropPoint);
    IWodElement wodElement = _woEditor.getWodElementAtPoint(controlDropPoint, true, true);
    if (wodElement == null) {
      removeHoverAnnotation();
    } else {
      String droppedKeyPath = column.getSelectedKeyPath();
      if (_bindingsMenu != null) {
View Full Code Here

Examples of org.objectstyle.wolips.bindings.wod.IWodElement

    @Override
    protected Object getValue(Object element) {
      String value = null;
      IApiBinding binding = (IApiBinding) element;
      if (binding != null) {
        IWodElement wodElement = getWodElement();
        if (wodElement != null) {
          IWodBinding wodBinding = wodElement.getBindingNamed(binding.getName());
          if (wodBinding != null) {
            value = wodBinding.getValue();
          }
        }
      }
View Full Code Here

Examples of org.objectstyle.wolips.bindings.wod.IWodElement

    @Override
    protected void setValue(Object element, Object value) {
      IApiBinding binding = (IApiBinding) element;
      if (binding != null) {
        IWodElement wodElement = getWodElement();
        if (wodElement != null) {
          try {
            getRefactoringElement().setValueForBinding((String) value, binding.getName());
            BindingsInspector.this.refresh();
          } catch (Exception e) {
View Full Code Here

Examples of org.objectstyle.wolips.bindings.wod.IWodElement

  public Object[] getElements(Object inputElement) {
    Object[] wodBindings = null;
    _api = null;
    if (inputElement instanceof IWodElement) {
      IWodElement wodElement = (IWodElement) inputElement;
      if (wodElement == null) {
        wodBindings = new IWodBinding[0];
      } else {
        if (_cache != null && _api == null) {
          try {
            _api = wodElement.getApi(_javaProject, _cache);
          } catch (Exception e) {
            _api = null;
            ComponenteditorPlugin.getDefault().log("Failed to load API for WO.", e);
          }
        }
        wodBindings = wodElement.getApiBindings(_api);
      }
    } else {
      wodBindings = new IWodBinding[0];
    }
    return wodBindings;
View Full Code Here

Examples of org.objectstyle.wolips.bindings.wod.IWodElement

          // IGNORE
        } else {
          IApiBinding apiBinding = (IApiBinding) ((IStructuredSelection) event.getSelection()).getFirstElement();
          boolean keyPathSelected = false;
          if (apiBinding != null) {
            IWodElement element = _inspector.getWodElement();
            if (element != null) {
              IWodBinding wodBinding = element.getBindingNamed(apiBinding.getName());
              if (wodBinding != null) {
                if (wodBinding.isKeyPath()) {
                  String value = wodBinding.getValue();
                  _browser.setSelection(new StructuredSelection(value));
                  keyPathSelected = true;
View Full Code Here

Examples of org.objectstyle.wolips.bindings.wod.IWodElement

    return editorControl;
  }

  public IWodElement getSelectedElement(boolean resolveWodElement, boolean refreshModel) throws Exception {
    IEditorPart editorPart = getActiveEditor();
    IWodElement selectedElement = null;
    if (editorPart instanceof IWOEditor) {
      selectedElement = ((IWOEditor) editorPart).getSelectedElement(resolveWodElement, refreshModel);
    }
    return selectedElement;
  }
View Full Code Here

Examples of org.objectstyle.wolips.bindings.wod.IWodElement

    return selectedElement;
  }

  public IWodElement getWodElementAtPoint(Point point, boolean resolveWodElement, boolean refreshModel) throws Exception {
    IEditorPart editorPart = getActiveEditor();
    IWodElement wodElement = null;
    if (editorPart instanceof IWOEditor) {
      wodElement = ((IWOEditor) editorPart).getWodElementAtPoint(point, resolveWodElement, refreshModel);
    }
    return wodElement;
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.