Class CmsFilterSelectBox

  • All Implemented Interfaces:
    com.google.gwt.event.dom.client.HasFocusHandlers, com.google.gwt.event.logical.shared.HasAttachHandlers, com.google.gwt.event.logical.shared.HasValueChangeHandlers<java.lang.String>, com.google.gwt.event.shared.HasHandlers, com.google.gwt.user.client.EventListener, com.google.gwt.user.client.ui.HasVisibility, com.google.gwt.user.client.ui.IsRenderable, com.google.gwt.user.client.ui.IsWidget, I_CmsHasInit, I_CmsTruncable, I_CmsFormWidget

    public class CmsFilterSelectBox
    extends A_CmsSelectBox<CmsLabelSelectCell>
    implements I_CmsHasInit
    Select box that allows client-side filtering for its options.

    Filtering is done by a case-insensitive substring test on the user-readable select option texts.

    • Nested Class Summary

      • Nested classes/interfaces inherited from class com.google.gwt.user.client.ui.UIObject

        com.google.gwt.user.client.ui.UIObject.DebugIdImpl, com.google.gwt.user.client.ui.UIObject.DebugIdImplEnabled
    • Constructor Summary

      Constructors 
      Constructor Description
      CmsFilterSelectBox()
      Creates a new instance.
      CmsFilterSelectBox​(java.util.Map<java.lang.String,​java.lang.String> options)
      Creates a new instance.
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void addOption​(CmsLabelSelectCell cell)
      Adds a new select option to the select box.
      protected void close()
      Internal method which is called when the selector is closed.
      protected CmsLabelSelectCell createUnknownOption​(java.lang.String value)
      Internal method to create a select option for an unknown value.
      boolean displayingAbove()
      Returns whether the select options are being displayed below or above the widget.
      protected void filterCells​(java.lang.String filter)
      Updates the visibility of select options based on the given filter string.
      java.lang.String getApparentValue()
      Returns the "apparent value", i.e.
      java.util.LinkedHashMap<java.lang.String,​java.lang.String> getItems()
      Gets the selection items as a map (the values are map keys, and the labels are the corresponding map values).
      com.google.gwt.user.client.ui.FocusPanel getOpener()
      Gets the opener.
      static void initClass()
      Initializes this class.
      protected void initOpener()
      The implementation of this method should initialize the opener of the select box.
      void onBrowserEvent​(com.google.gwt.user.client.Event event)  
      protected void open()
      Internal method which is called when the selector is opened.
      void setAutoHideParent​(I_CmsAutoHider autoHideParent)
      Call this when auto hiding parents are shown.
      void setEnabled​(boolean enabled)
      Enables or disables the widget.
      void setItems​(java.util.Map<java.lang.String,​java.lang.String> options)
      Sets the select options.
      void setTitle​(java.lang.String key, java.lang.String title)
      Sets the title for a select option.
      protected void truncateOpener​(java.lang.String prefix, int width)
      Abstract method whose implementation should truncate the opener widget(s).
      protected void updateOpener​(java.lang.String newValue)
      The implementation of this method should update the opener when a new value is selected by the user.
      • Methods inherited from class com.google.gwt.user.client.ui.Composite

        claimElement, getWidget, initializeClaimedElement, initWidget, isAttached, onAttach, render, render, resolvePotentialElement, setWidget
      • Methods inherited from class com.google.gwt.user.client.ui.Widget

        addAttachHandler, addBitlessDomHandler, addDomHandler, addHandler, asWidget, asWidgetOrNull, createHandlerManager, delegateEvent, doAttachChildren, doDetachChildren, fireEvent, getHandlerCount, getLayoutData, getParent, isOrWasAttached, removeFromParent, setLayoutData, sinkEvents, unsinkEvents
      • Methods inherited from class com.google.gwt.user.client.ui.UIObject

        addStyleDependentName, addStyleName, ensureDebugId, ensureDebugId, ensureDebugId, getAbsoluteLeft, getAbsoluteTop, getElement, getOffsetHeight, getOffsetWidth, getStyleElement, getStyleName, getStyleName, getStylePrimaryName, getStylePrimaryName, getTitle, isVisible, isVisible, onEnsureDebugId, removeStyleDependentName, removeStyleName, setElement, setElement, setHeight, setPixelSize, setSize, setStyleDependentName, setStyleName, setStyleName, setStyleName, setStyleName, setStylePrimaryName, setStylePrimaryName, setTitle, setVisible, setVisible, setWidth, sinkBitlessEvent, toString
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
      • Methods inherited from interface com.google.gwt.event.shared.HasHandlers

        fireEvent