public abstract class AbstractSideNav extends MaterialWidget implements JsLoader, HasSelectables, HasInOutDurationTransition, HasSideNavHandlers
setup()
.MaterialWidget.Feature
com.google.gwt.user.client.ui.UIObject.DebugIdImpl, com.google.gwt.user.client.ui.UIObject.DebugIdImplEnabled
Modifier and Type | Field and Description |
---|---|
protected com.google.gwt.dom.client.Element |
activator |
protected boolean |
allowBodyScroll |
protected boolean |
alwaysShowActivator |
protected boolean |
closeOnClick |
protected Edge |
edge |
protected int |
inDuration |
protected boolean |
open |
protected int |
outDuration |
protected Boolean |
showOnAttach |
protected int |
width |
$this
Constructor and Description |
---|
AbstractSideNav() |
AbstractSideNav(SideNavType type) |
AbstractSideNav(com.google.gwt.user.client.ui.Widget... widgets) |
Modifier and Type | Method and Description |
---|---|
void |
add(com.google.gwt.user.client.ui.Widget child) |
com.google.gwt.event.shared.HandlerRegistration |
addClosedHandler(SideNavClosedEvent.SideNavClosedHandler handler)
This handler will be triggered when the side nav is closed.
|
com.google.gwt.event.shared.HandlerRegistration |
addClosingHandler(SideNavClosingEvent.SideNavClosingHandler handler)
This handler will be triggered when the side nav starts closing.
|
com.google.gwt.event.shared.HandlerRegistration |
addOpenedHandler(SideNavOpenedEvent.SideNavOpenedHandler handler)
This handler will be triggered when the side nav is opened.
|
com.google.gwt.event.shared.HandlerRegistration |
addOpeningHandler(SideNavOpeningEvent.SideNavOpeningHandler handler)
This handler will be triggered when the side nav starts opening.
|
protected void |
applyBodyScroll() |
protected void |
applyTransition(com.google.gwt.dom.client.Element element) |
protected void |
applyTransition(com.google.gwt.dom.client.Element element,
String property) |
void |
clearActive() |
com.google.gwt.dom.client.Element |
getActivator() |
Edge |
getEdge() |
protected com.google.gwt.dom.client.Element |
getFooter() |
protected com.google.gwt.dom.client.Element |
getHeader() |
int |
getInDuration()
Get the in / enter animation duration in milliseconds.
|
protected com.google.gwt.dom.client.Element |
getMain() |
protected MaterialWidget |
getNavMenu() |
int |
getOutDuration()
Get the out / exit animation duration in milliseconds.
|
protected StyleMixin<MaterialSideNav> |
getTypeMixin() |
int |
getWidth() |
void |
hide()
Hide the sidenav using the activator element
|
void |
hideOverlay()
Hide the overlay menu.
|
protected void |
insert(com.google.gwt.user.client.ui.Widget child,
com.google.gwt.user.client.Element container,
int beforeIndex,
boolean domInsert) |
boolean |
isAllowBodyScroll()
Will the body have scroll capability
while the menu is open.
|
boolean |
isAlwaysShowActivator()
Will the activator always be shown.
|
boolean |
isCloseOnClick() |
boolean |
isOpen() |
boolean |
isShowOnAttach()
Will the menu forcefully show on attachment.
|
protected boolean |
isSmall() |
void |
load() |
protected void |
load(boolean strict) |
protected void |
onAttach() |
protected void |
onClosed() |
protected void |
onClosing() |
protected void |
onDetach() |
protected void |
onLoad() |
protected void |
onOpened() |
protected void |
onOpening() |
protected void |
onUnload() |
protected void |
pushElement(com.google.gwt.dom.client.Element element,
int value) |
protected void |
pushElementMargin(com.google.gwt.dom.client.Element element,
int value) |
void |
reload()
Reinitialize the side nav configurations when changing properties.
|
void |
setActive(int index) |
void |
setAllowBodyScroll(boolean allowBodyScroll)
Allow the body to maintain its scroll capability
while the menu is visible.
|
void |
setAlwaysShowActivator(boolean alwaysShowActivator)
Disable the hiding of your activator element.
|
void |
setCloseOnClick(boolean closeOnClick)
Close the side nav menu when an \ tag is clicked
from inside it.
|
void |
setEdge(Edge edge)
Set which edge of the window the menu should attach to.
|
void |
setEnabled(boolean enabled) |
void |
setInDuration(int inDuration)
Set the in / enter animation duration in milliseconds.
|
void |
setOutDuration(int outDuration)
Set the out / exit animation duration in milliseconds.
|
void |
setShowOnAttach(boolean showOnAttach)
Show the menu upon attachment.
Note that you shouldn't apply this setting if you want your side nav to appear static. |
protected void |
setType(SideNavType type) |
protected abstract void |
setup()
Override the type of your sidenav.
|
void |
setWidth(int width)
Set the menu's width in pixels.
|
void |
setWidth(String width) |
void |
show()
Show the sidenav using the activator element
|
void |
unload() |
com.google.gwt.user.client.ui.Widget |
wrap(com.google.gwt.user.client.ui.Widget child) |
$this, add, addAttachHandler, addBlurHandler, addClickHandler, addDoubleClickHandler, addDragEndHandler, addDragEnterHandler, addDragLeaveHandler, addDragMoveHandler, addDragOverHandler, addDragStartHandler, addDropActivateHandler, addDropDeactivateHandler, addDropHandler, addFocusHandler, addGestureChangeHandler, addGestureEndHandler, addGestureStartHandler, addKeyDownHandler, addKeyPressHandler, addKeyUpHandler, addMouseDownHandler, addMouseMoveHandler, addMouseOutHandler, addMouseOverHandler, addMouseUpHandler, addMouseWheelHandler, addOrientationChangeHandler, addTouchCancelHandler, addTouchEndHandler, addTouchMoveHandler, addTouchStartHandler, body, clearActiveClass, enableFeature, getBackfaceVisibility, getBackgroundColor, getBorder, getBorderBottom, getBorderLeft, getBorderMixin, getBorderRadius, getBorderRight, getBorderTop, getCenterOn, getCenterOnMixin, getChildren, getChildrenList, getCircleMixin, getColorsMixin, getDataAttribute, getDepth, getDimensionMixin, getEnabledMixin, getFlexboxMixin, getFloat, getFloatMixin, getFocusableMixin, getFontSize, getFontSizeMixin, getFontWeight, getFontWeightMixin, getGridMixin, getHandlerRegistry, getHideOn, getHideOnMixin, getHoverableMixin, getId, getIdMixin, getInitialClasses, getLayoutPosition, getMaxHeight, getMaxWidth, getMinHeight, getMinWidth, getOpacity, getOrientation, getOrientationMixin, getPerspective, getPerspectiveOrigin, getScrollspy, getScrollspyMixin, getSeparatorMixin, getShadow, getShadowMixin, getShowOn, getShowOnMixin, getTabIndex, getTextAlign, getTextAlignMixin, getTextColor, getTooltip, getTooltipDelayMs, getTooltipHTML, getTooltipMixin, getTooltipPosition, getTransform, getTransformMixin, getTransformOrigin, getTransformStyle, getTruncateMixin, getVerticalAlign, getVerticalAlignMixin, getWaves, getWavesMixin, insert, isCircle, isDetectOrientation, isEnabled, isFeatureEnabled, isHoverable, isSeparator, isTruncate, registerHandler, removeHandler, setAccessKey, setBackfaceVisibility, setBackgroundColor, setBorder, setBorderBottom, setBorderLeft, setBorderRadius, setBorderRight, setBorderTop, setBottom, setCenterOn, setCircle, setClass, setDataAttribute, setDepth, setDetectOrientation, setDisplay, setFlex, setFlexAlignContent, setFlexAlignItems, setFlexAlignSelf, setFlexBasis, setFlexDirection, setFlexGrow, setFlexJustifyContent, setFlexOrder, setFlexShrink, setFlexWrap, setFloat, setFocus, setFontSize, setFontSize, setFontWeight, setGrid, setGwtDisplay, setHideOn, setHoverable, setId, setInitialClasses, setLayoutPosition, setLeft, setLineHeight, setMargin, setMarginBottom, setMarginLeft, setMarginRight, setMarginTop, setMaxHeight, setMaxWidth, setMinHeight, setMinWidth, setOffset, setOpacity, setOrientation, setOverflow, setPadding, setPaddingBottom, setPaddingLeft, setPaddingRight, setPaddingTop, setPerspective, setPerspectiveOrigin, setRight, setScrollspy, setSeparator, setShadow, setShowOn, setStyle, setTabIndex, setTextAlign, setTextColor, setTooltip, setTooltipDelayMs, setTooltipHTML, setTooltipPosition, setTop, setTransform, setTransformOrigin, setTransformStyle, setTransition, setTruncate, setVerticalAlign, setVisibility, setWaves, stopTouchStartEvent, validate, window
add, adjustIndex, checkIndexBoundsForAccess, checkIndexBoundsForInsertion, getWidget, getWidgetCount, getWidgetIndex, getWidgetIndex, insert, iterator, remove, remove
add, adopt, clear, doAttachChildren, doDetachChildren, orphan, remove
addAttachHandler, addBitlessDomHandler, addDomHandler, addHandler, asWidget, asWidgetOrNull, createHandlerManager, delegateEvent, fireEvent, getHandlerCount, getLayoutData, getParent, isAttached, isOrWasAttached, onBrowserEvent, removeFromParent, setLayoutData, sinkEvents, unsinkEvents
addStyleDependentName, addStyleName, ensureDebugId, ensureDebugId, ensureDebugId, getAbsoluteLeft, getAbsoluteTop, getElement, getOffsetHeight, getOffsetWidth, getStyleElement, getStyleName, getStyleName, getStylePrimaryName, getStylePrimaryName, getTitle, isVisible, isVisible, onEnsureDebugId, removeStyleDependentName, removeStyleName, resolvePotentialElement, setElement, setElement, setHeight, setPixelSize, setSize, setStyleDependentName, setStyleName, setStyleName, setStyleName, setStyleName, setStylePrimaryName, setStylePrimaryName, setTitle, setVisible, setVisible, sinkBitlessEvent, toString
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
setVisible
forEach, spliterator
protected int width
protected int inDuration
protected int outDuration
protected boolean open
protected boolean closeOnClick
protected boolean alwaysShowActivator
protected boolean allowBodyScroll
protected Boolean showOnAttach
protected com.google.gwt.dom.client.Element activator
public AbstractSideNav()
public AbstractSideNav(com.google.gwt.user.client.ui.Widget... widgets)
public AbstractSideNav(SideNavType type)
protected void onLoad()
onLoad
in class MaterialWidget
protected void onUnload()
onUnload
in class MaterialWidget
public com.google.gwt.user.client.ui.Widget wrap(com.google.gwt.user.client.ui.Widget child)
public void add(com.google.gwt.user.client.ui.Widget child)
add
in interface com.google.gwt.user.client.ui.HasWidgets
add
in class MaterialWidget
protected void insert(com.google.gwt.user.client.ui.Widget child, com.google.gwt.user.client.Element container, int beforeIndex, boolean domInsert)
insert
in class MaterialWidget
protected void pushElement(com.google.gwt.dom.client.Element element, int value)
protected void pushElementMargin(com.google.gwt.dom.client.Element element, int value)
protected void applyBodyScroll()
protected void applyTransition(com.google.gwt.dom.client.Element element)
protected void applyTransition(com.google.gwt.dom.client.Element element, String property)
public void clearActive()
clearActive
in interface HasSelectables
public void setActive(int index)
public void reload()
protected void load(boolean strict)
protected abstract void setup()
MaterialSideNavDrawer
, MaterialSideNavCard
, MaterialSideNavMini
, MaterialSideNavPush
protected void onDetach()
onDetach
in class com.google.gwt.user.client.ui.Widget
protected void onAttach()
onAttach
in class com.google.gwt.user.client.ui.Widget
protected com.google.gwt.dom.client.Element getMain()
protected com.google.gwt.dom.client.Element getHeader()
protected com.google.gwt.dom.client.Element getFooter()
public void setWidth(String width)
setWidth
in class com.google.gwt.user.client.ui.UIObject
public void setWidth(int width)
public int getWidth()
getWidth
in class MaterialWidget
public boolean isCloseOnClick()
public void setCloseOnClick(boolean closeOnClick)
MaterialLink
.protected void setType(SideNavType type)
protected boolean isSmall()
protected MaterialWidget getNavMenu()
protected void onClosing()
protected void onClosed()
protected void onOpening()
protected void onOpened()
public void hideOverlay()
public void show()
public void hide()
public boolean isOpen()
public boolean isAllowBodyScroll()
public void setAllowBodyScroll(boolean allowBodyScroll)
public boolean isAlwaysShowActivator()
public void setAlwaysShowActivator(boolean alwaysShowActivator)
public boolean isShowOnAttach()
public void setShowOnAttach(boolean showOnAttach)
true
will slide in from the left.public void setEnabled(boolean enabled)
setEnabled
in interface com.google.gwt.user.client.ui.HasEnabled
setEnabled
in class MaterialWidget
public void setInDuration(int inDuration)
HasInOutDurationTransition
setInDuration
in interface HasInOutDurationTransition
public int getInDuration()
HasInOutDurationTransition
getInDuration
in interface HasInOutDurationTransition
public void setOutDuration(int outDuration)
HasInOutDurationTransition
setOutDuration
in interface HasInOutDurationTransition
public int getOutDuration()
HasInOutDurationTransition
getOutDuration
in interface HasInOutDurationTransition
public com.google.gwt.dom.client.Element getActivator()
public com.google.gwt.event.shared.HandlerRegistration addOpeningHandler(SideNavOpeningEvent.SideNavOpeningHandler handler)
HasSideNavHandlers
addOpeningHandler
in interface HasSideNavHandlers
public com.google.gwt.event.shared.HandlerRegistration addOpenedHandler(SideNavOpenedEvent.SideNavOpenedHandler handler)
HasSideNavHandlers
addOpenedHandler
in interface HasSideNavHandlers
public com.google.gwt.event.shared.HandlerRegistration addClosingHandler(SideNavClosingEvent.SideNavClosingHandler handler)
HasSideNavHandlers
addClosingHandler
in interface HasSideNavHandlers
public com.google.gwt.event.shared.HandlerRegistration addClosedHandler(SideNavClosedEvent.SideNavClosedHandler handler)
HasSideNavHandlers
addClosedHandler
in interface HasSideNavHandlers
protected StyleMixin<MaterialSideNav> getTypeMixin()
Copyright © 2018. All rights reserved.