Package com.vaadin.client.ui
Class VComboBox.SuggestionPopup
- java.lang.Object
-
- com.google.gwt.user.client.ui.UIObject
-
- com.google.gwt.user.client.ui.Widget
-
- com.google.gwt.user.client.ui.Panel
-
- com.google.gwt.user.client.ui.SimplePanel
-
- com.google.gwt.user.client.ui.PopupPanel
-
- com.vaadin.client.widgets.Overlay
-
- com.vaadin.client.ui.VOverlay
-
- com.vaadin.client.ui.VComboBox.SuggestionPopup
-
- All Implemented Interfaces:
com.google.gwt.event.logical.shared.CloseHandler<com.google.gwt.user.client.ui.PopupPanel>,com.google.gwt.event.logical.shared.HasAttachHandlers,com.google.gwt.event.logical.shared.HasCloseHandlers<com.google.gwt.user.client.ui.PopupPanel>,com.google.gwt.event.shared.EventHandler,com.google.gwt.event.shared.HasHandlers,com.google.gwt.user.client.EventListener,com.google.gwt.user.client.EventPreview,com.google.gwt.user.client.ui.AcceptsOneWidget,com.google.gwt.user.client.ui.HasAnimation,com.google.gwt.user.client.ui.HasOneWidget,com.google.gwt.user.client.ui.HasVisibility,com.google.gwt.user.client.ui.HasWidgets,com.google.gwt.user.client.ui.HasWidgets.ForIsWidget,com.google.gwt.user.client.ui.IsWidget,com.google.gwt.user.client.ui.PopupPanel.PositionCallback,com.google.gwt.user.client.ui.SourcesPopupEvents,Iterable<com.google.gwt.user.client.ui.Widget>
- Enclosing class:
- VComboBox
public class VComboBox.SuggestionPopup extends VOverlay implements com.google.gwt.user.client.ui.PopupPanel.PositionCallback, com.google.gwt.event.logical.shared.CloseHandler<com.google.gwt.user.client.ui.PopupPanel>
Represents the popup box with the selection options. Wraps a suggestion menu.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class com.vaadin.client.widgets.Overlay
Overlay.PositionAndSize, Overlay.ResizeAnimation
-
Nested classes/interfaces inherited from class com.google.gwt.user.client.ui.PopupPanel
com.google.gwt.user.client.ui.PopupPanel.AnimationType, com.google.gwt.user.client.ui.PopupPanel.PositionCallback
-
-
Field Summary
Fields Modifier and Type Field Description VComboBox.SuggestionMenumenuFor internal use only.-
Fields inherited from class com.vaadin.client.widgets.Overlay
ADDITIONAL_CLASSNAME_ANIMATE_IN, ADDITIONAL_CLASSNAME_ANIMATE_OUT, CLASSNAME_CONTAINER, CLASSNAME_SHADOW, current
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidhide()booleanisJustClosed()Was the popup just closed?voidonBrowserEvent(com.google.gwt.user.client.Event event)voidonClose(com.google.gwt.event.logical.shared.CloseEvent<com.google.gwt.user.client.ui.PopupPanel> event)protected voidonLoad()protected voidonPreviewNativeEvent(com.google.gwt.user.client.Event.NativePreviewEvent event)protected voidonUnload()voidselectFirstItem()Select the first item of the suggestions list popup.voidselectLastItem()Select the last item of the suggestions list popup.voidselectNextItem()Selects the next item in the filtered selections.voidselectPrevItem()Selects the previous item in the filtered selections.voidsetPagingEnabled(boolean paging)Should paging be enabled.voidsetPosition(int offsetWidth, int offsetHeight)voidshowSuggestions(int currentPage)Shows the popup where the user can see the filtered options that have been set with a call toVComboBox.SuggestionMenu.setSuggestions(Collection).voidupdateStyleNames(AbstractComponentState componentState)Updates style names in suggestion popup to help theme building.-
Methods inherited from class com.vaadin.client.ui.VOverlay
getApplicationConnection, getOverlayContainer, getOverlayContainer, setApplicationConnection, setOverlayContainerLabel
-
Methods inherited from class com.vaadin.client.widgets.Overlay
center, getOwner, hide, hide, isFitInWindow, isShimElementEnabled, needsShimElement, onAttach, onDetach, positionOrSizeUpdated, setFitInWindow, setHeight, setOwner, setPopupPosition, setVisible, setWidth, setZIndex, show, updateShadowSizeAndPosition
-
Methods inherited from class com.google.gwt.user.client.ui.PopupPanel
addAutoHidePartner, addCloseHandler, addPopupListener, getAnimationType, getContainerElement, getGlassElement, getGlassStyleName, getOffsetHeight, getOffsetWidth, getPopupLeft, getPopupTop, getStyleElement, getTitle, isAnimationEnabled, isAutoHideEnabled, isAutoHideOnHistoryEventsEnabled, isGlassEnabled, isModal, isPreviewingAllNativeEvents, isShowing, isVisible, onEventPreview, onKeyDownPreview, onKeyPressPreview, onKeyUpPreview, removeAutoHidePartner, removePopupListener, setAnimationEnabled, setAnimationType, setAutoHideEnabled, setAutoHideOnHistoryEventsEnabled, setGlassEnabled, setGlassStyleName, setModal, setPopupPositionAndShow, setPreviewingAllNativeEvents, setTitle, setWidget, showRelativeTo
-
Methods inherited from class com.google.gwt.user.client.ui.SimplePanel
add, getWidget, iterator, remove, setWidget
-
Methods inherited from class com.google.gwt.user.client.ui.Panel
add, adopt, clear, doAttachChildren, doDetachChildren, orphan, remove
-
Methods inherited from class com.google.gwt.user.client.ui.Widget
addAttachHandler, addBitlessDomHandler, addDomHandler, addHandler, asWidget, asWidgetOrNull, createHandlerManager, delegateEvent, fireEvent, getHandlerCount, getLayoutData, getParent, isAttached, isOrWasAttached, removeFromParent, setLayoutData, sinkEvents, unsinkEvents
-
Methods inherited from class com.google.gwt.user.client.ui.UIObject
addStyleDependentName, addStyleName, ensureDebugId, ensureDebugId, ensureDebugId, getAbsoluteLeft, getAbsoluteTop, getElement, getStyleName, getStyleName, getStylePrimaryName, getStylePrimaryName, isVisible, onEnsureDebugId, removeStyleDependentName, removeStyleName, resolvePotentialElement, setElement, setElement, setPixelSize, setSize, setStyleDependentName, setStyleName, setStyleName, setStyleName, setStyleName, setStylePrimaryName, setStylePrimaryName, setVisible, sinkBitlessEvent, toString
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface java.lang.Iterable
forEach, spliterator
-
-
-
-
Field Detail
-
menu
public final VComboBox.SuggestionMenu menu
For internal use only. May be removed or replaced in the future.
-
-
Method Detail
-
onLoad
protected void onLoad()
- Overrides:
onLoadin classcom.google.gwt.user.client.ui.Widget
-
onUnload
protected void onUnload()
- Overrides:
onUnloadin classcom.google.gwt.user.client.ui.PopupPanel
-
showSuggestions
public void showSuggestions(int currentPage)
Shows the popup where the user can see the filtered options that have been set with a call toVComboBox.SuggestionMenu.setSuggestions(Collection).- Parameters:
currentPage- The current page number
-
selectNextItem
public void selectNextItem()
Selects the next item in the filtered selections.
-
selectPrevItem
public void selectPrevItem()
Selects the previous item in the filtered selections.
-
selectFirstItem
public void selectFirstItem()
Select the first item of the suggestions list popup.- Since:
- 7.2.6
-
selectLastItem
public void selectLastItem()
Select the last item of the suggestions list popup.- Since:
- 7.2.6
-
onBrowserEvent
public void onBrowserEvent(com.google.gwt.user.client.Event event)
- Specified by:
onBrowserEventin interfacecom.google.gwt.user.client.EventListener- Overrides:
onBrowserEventin classcom.google.gwt.user.client.ui.Widget
-
onPreviewNativeEvent
protected void onPreviewNativeEvent(com.google.gwt.user.client.Event.NativePreviewEvent event)
- Overrides:
onPreviewNativeEventin classcom.google.gwt.user.client.ui.PopupPanel
-
setPagingEnabled
public void setPagingEnabled(boolean paging)
Should paging be enabled. If paging is enabled then only a certain amount of items are visible at a time and a scrollbar or buttons are visible to change page. If paging is turned of then all options are rendered into the popup menu.- Parameters:
paging- Should the paging be turned on?
-
setPosition
public void setPosition(int offsetWidth, int offsetHeight)- Specified by:
setPositionin interfacecom.google.gwt.user.client.ui.PopupPanel.PositionCallback
-
isJustClosed
public boolean isJustClosed()
Was the popup just closed?- Returns:
- true if popup was just closed
-
onClose
public void onClose(com.google.gwt.event.logical.shared.CloseEvent<com.google.gwt.user.client.ui.PopupPanel> event)
- Specified by:
onClosein interfacecom.google.gwt.event.logical.shared.CloseHandler<com.google.gwt.user.client.ui.PopupPanel>
-
updateStyleNames
public void updateStyleNames(AbstractComponentState componentState)
Updates style names in suggestion popup to help theme building.- Parameters:
componentState- shared state of the combo box
-
-