Interface I_CmsHasGhostValue

All Known Implementing Classes:
CmsComboBox, CmsExtendedMultiCheckBox, CmsFocusAwareTextBox, CmsLinkSelector, CmsMultiSelectBox, CmsPropertyComboBox, CmsPropertySelectBox, CmsSelectBox, CmsSelectComboBox, CmsTextArea, CmsTextBox, CmsVfsLinkWidget

public interface I_CmsHasGhostValue
Interface for widgets which can contain a "ghost value".

A ghost value will be displayed, but not reported when asking the widget for its current value.

Since:
8.0.0
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    setGhostMode(boolean enable)
    Enables or disables ghost mode, if possible.
    void
    setGhostValue(String value, boolean isGhostMode)
    Sets the "ghost value" of the widget and optionally sets it to "ghost mode".
  • Method Details

    • setGhostMode

      void setGhostMode(boolean enable)
      Enables or disables ghost mode, if possible.

      Parameters:
      enable - if ghost mode should be enabled, else disabled
    • setGhostValue

      void setGhostValue(String value, boolean isGhostMode)
      Sets the "ghost value" of the widget and optionally sets it to "ghost mode".

      "Ghost mode" can be used to show the user the value (called "ghost value") which will be used if he either doesn't choose an option in the widget, or explicitly chooses an "empty" or "default" option.

      Parameters:
      value - the ghost value
      isGhostMode - if true, sets the widget to ghost mode