Class XtextStyledTextCellEditorEx


public class XtextStyledTextCellEditorEx extends XtextStyledTextCellEditor
This is a copy of TextCellEditorEx, only the super class has been changed to XtextStyledTextCellEditor
  • Constructor Details

    • XtextStyledTextCellEditorEx

      public XtextStyledTextCellEditorEx(int style, com.google.inject.Injector injector, IXtextFakeContextResourcesProvider contextResourcesProvider)
    • XtextStyledTextCellEditorEx

      public XtextStyledTextCellEditorEx(int style, com.google.inject.Injector injector)
  • Method Details

    • setValueAndProcessEditOccured

      public void setValueAndProcessEditOccured(Object value)
      This will be used when an edit has occurred by a ModifyEvent has been been send. Will call #setValue(Object) but will also call editOccured(null) to make sure that the dirty flag is set probably and that any listeners are informed about the changed.
      Parameters:
      value - Value to set the cell editor to. Note: This happens address defect RATLC00522324. For our topgraphical edit parts we delegate the direct edit request to a primary edit part and set focus on that. The issue is that if the user has typed in an initial character when setting focus to the edit part, which typically is a TextCompartmentEditPart then setting that initial value does not fire the necessary change events that need to occur in order for that value to be recognized. If you don't use this method then the result is that if you just type in the initial character and that is it then the text compartment loses focus then the value will not be saved. This is because setting the value of the cell doesn't think its value has changed since the first character is not recognized as a change.
    • doSetValue

      protected void doSetValue(Object value)
      Description copied from class: StyledTextCellEditor
      The TextCellEditor implementation of this CellEditor framework method accepts a text string (type String).
      Overrides:
      doSetValue in class XtextStyledTextCellEditor
      Parameters:
      value - a text string (type String)
    • hasValueChanged

      public boolean hasValueChanged()
      Returns:
      boolean value specifying whether or not the value has been changed
    • deactivate

      public void deactivate()
      Overrides:
      deactivate in class CellEditor
    • isDeactivationLocked

      public boolean isDeactivationLocked()
      Returns true if deactivation has been locked
      Returns:
    • setDeactivationLock

      public void setDeactivationLock(boolean deactivationLock)
      Sets deactivation lock so that the cell editor does not perform deactivate
      Parameters:
      deactivationLock -