public class HTMLFlow extends Canvas implements HasContentLoadedHandlers
HTML
content can be loaded and reloaded from a URL via the property contentsURL
. This method of loading is for
simple HTML content only; Smart GWT components should be loaded via the ViewLoader
class.
NOTE: Since the size of an HTMLFlow component is determined by its HTML contents, this component will draw at varying sizes if given content of varying size. When using HTMLFlow components within a Layout, consider what will happen if the HTMLFlow renders at various sizes. An HTMLFlow which can expand should be placed in a container where other components can render smaller, where the container is allowed to scroll, or where there is padding to expand into.
HTMLFlow is a DataBoundComponent
but only supports one method at this time,
fetchRelatedData
.
config, configOnly, factoryCreated, factoryProperties, id, nativeObject, scClassName
Constructor and Description |
---|
HTMLFlow() |
HTMLFlow(com.google.gwt.core.client.JavaScriptObject jsObj) |
HTMLFlow(java.lang.String contents) |
Modifier and Type | Method and Description |
---|---|
com.google.gwt.event.shared.HandlerRegistration |
addContentLoadedHandler(ContentLoadedHandler handler)
Add a contentLoaded handler.
|
static void |
changeAutoChildDefaults(java.lang.String autoChildName,
Canvas defaults)
Changes the defaults for Canvas AutoChildren named
autoChildName . |
static void |
changeAutoChildDefaults(java.lang.String autoChildName,
FormItem defaults)
Changes the defaults for FormItem AutoChildren named
autoChildName . |
protected com.google.gwt.core.client.JavaScriptObject |
create() |
void |
fetchRelatedData(ListGridRecord record,
Canvas schema)
Based on the relationship between the DataSource this component is bound to and the DataSource specified as the "schema"
argument, call fetchData() to retrieve records in this data set that are related to the passed-in record.
|
void |
fetchRelatedData(ListGridRecord record,
Canvas schema,
DSCallback callback) |
void |
fetchRelatedData(ListGridRecord record,
Canvas schema,
DSCallback callback,
DSRequest requestProperties)
Based on the relationship between the DataSource this component is bound to and the DataSource specified as the "schema"
argument, call fetchData() to retrieve records in this data set that are related to the passed-in record.
|
java.lang.Boolean |
getAllowCaching()
By default an HTMLFlow will explicitly prevent browser caching.
|
java.lang.Boolean |
getAutoChangeProtocol()
If this component is passed a URL with a protocol that differs from the current page, should it be automatically changed
to match the page?
|
java.lang.Boolean |
getCanSelectText()
Text selection for copy and paste is enabled by default in the HTMLFlow class.
|
java.lang.Boolean |
getCaptureSCComponents()
If true, Smart GWT components created while executing the loaded HTML are captured for rendering inside the HTMLFlow.
|
java.lang.String |
getContents()
The contents of a canvas or label widget.
|
ContentsType |
getContentsType()
The default setting of
null or 'fragment' indicates that HTML loaded from contentsURL is assumed to be an HTML fragment rather than a
complete page. |
java.lang.String |
getContentsURL()
URL to load content from.
|
java.lang.Boolean |
getDynamicContents()
Dynamic contents allows the contents string to be treated as a simple but powerful template.
|
java.lang.Boolean |
getEvalScriptBlocks()
If
evalScriptBlocks is true, HTMLFlow will pre-process the loaded HTML in order to mimic how the HTML would
execute if it were loaded as an independent page or loaded via an IFRAME. |
SendMethod |
getHttpMethod()
Selects the HTTP method that will be used when fetching content.
|
java.lang.String |
getIframeSandbox()
When using
contentsType ContentsType.PAGE , sets the <iframe> sandbox attribute to the provided
value. |
java.lang.String |
getLoadingMessage()
HTML to show while content is being fetched, active only if the
contentsURL property has been set. |
com.smartgwt.logicalstructure.core.LogicalStructureObject |
getLogicalStructure()
Getter implementing the
LogicalStructure interface,
which supports Eclipse's logical structure debugging facility. |
static HTMLFlow |
getOrCreateRef(com.google.gwt.core.client.JavaScriptObject jsObj) |
java.lang.Boolean |
getSelectContentOnSelectAll()
When this
HTMLFlow is focused, causes Ctrl-A / Command-A keypresses to select just the content, as opposed
to all content on the screen becoming selected. |
java.lang.Boolean |
loadingContent()
Returns true if this htmlFlow is currently loading content from the server.
Note: Does not apply to htmlFlows with contentsType set to "page" |
HTMLFlow |
setAllowCaching(java.lang.Boolean allowCaching)
By default an HTMLFlow will explicitly prevent browser caching.
|
HTMLFlow |
setAutoChangeProtocol(java.lang.Boolean autoChangeProtocol)
If this component is passed a URL with a protocol that differs from the current page, should it be automatically changed
to match the page?
|
HTMLFlow |
setCanSelectText(java.lang.Boolean canSelectText)
Text selection for copy and paste is enabled by default in the HTMLFlow class.
|
HTMLFlow |
setCaptureSCComponents(java.lang.Boolean captureSCComponents)
If true, Smart GWT components created while executing the loaded HTML are captured for rendering inside the HTMLFlow.
|
HTMLFlow |
setContents(java.lang.String contents)
The contents of a canvas or label widget.
|
HTMLFlow |
setContentsType(ContentsType contentsType)
The default setting of
null or 'fragment' indicates that HTML loaded from contentsURL is assumed to be an HTML fragment rather than a
complete page. |
HTMLFlow |
setContentsURL(java.lang.String contentsURL)
URL to load content from.
|
HTMLFlow |
setContentsURLParams(java.util.Map contentsURLParams)
Parameters to be sent to the contentsURL when fetching content.
|
static void |
setDefaultProperties(HTMLFlow hTMLFlowProperties)
Class level method to set the default properties of this class.
|
HTMLFlow |
setDynamicContents(java.lang.Boolean dynamicContents)
Dynamic contents allows the contents string to be treated as a simple but powerful template.
|
HTMLFlow |
setEvalScriptBlocks(java.lang.Boolean evalScriptBlocks)
If
evalScriptBlocks is true, HTMLFlow will pre-process the loaded HTML in order to mimic how the HTML would
execute if it were loaded as an independent page or loaded via an IFRAME. |
HTMLFlow |
setHttpMethod(SendMethod httpMethod)
Selects the HTTP method that will be used when fetching content.
|
HTMLFlow |
setIframeSandbox(java.lang.String iframeSandbox)
When using
contentsType ContentsType.PAGE , sets the <iframe> sandbox attribute to the provided
value. |
HTMLFlow |
setLoadingMessage(java.lang.String loadingMessage)
HTML to show while content is being fetched, active only if the
contentsURL property has been set. |
com.smartgwt.logicalstructure.core.LogicalStructureObject |
setLogicalStructure(com.smartgwt.logicalstructure.widgets.HTMLFlowLogicalStructure s)
Setter implementing the
LogicalStructure interface,
which supports Eclipse's logical structure debugging facility. |
HTMLFlow |
setSelectContentOnSelectAll(java.lang.Boolean selectContentOnSelectAll)
When this
HTMLFlow is focused, causes Ctrl-A / Command-A keypresses to select just the content, as opposed
to all content on the screen becoming selected. |
void |
transformHTML(java.lang.String html)
Override to modify the loaded HTML before it is rendered.
|
addChild, addChild, addChild, addChild, addChild, addClearHandler, addClickHandler, addDoubleClickHandler, addDragMoveHandler, addDragRepositionMoveHandler, addDragRepositionStartHandler, addDragRepositionStopHandler, addDragResizeMoveHandler, addDragResizeStartHandler, addDragResizeStopHandler, addDragStartHandler, addDragStopHandler, addDropHandler, addDropMoveHandler, addDropOutHandler, addDropOverHandler, addFocusChangedHandler, addHoverHandler, addHoverHiddenHandler, addKeyDownHandler, addKeyPressHandler, addMouseDownHandler, addMouseMoveHandler, addMouseOutHandler, addMouseOverHandler, addMouseStillDownHandler, addMouseUpHandler, addMouseWheelHandler, addMovedHandler, addParentMovedHandler, addPeer, addPeer, addPeer, addPeer, addResizedHandler, addRightMouseDownHandler, addRuleContextChangedHandler, addScrolledHandler, addShowContextMenuHandler, addSnapAlignCandidate, addStyleName, addVisibilityChangedHandler, adjustForContent, animateFade, animateFade, animateFade, animateFade, animateFade, animateFade, animateFade, animateFade, animateHide, animateHide, animateHide, animateHide, animateHide, animateHide, animateHide, animateMove, animateMove, animateMove, animateMove, animateRect, animateRect, animateRect, animateRect, animateResize, animateResize, animateResize, animateResize, animateScroll, animateScroll, animateScroll, animateScroll, animateScroll, animateScroll, animateShow, animateShow, animateShow, animateShow, animateShow, animateShow, animateShow, asSGWTComponent, blur, bringToFront, clear, clearExplicitTabIndex, clickMaskUp, clickMaskUp, contains, contains, containsEvent, containsEventTarget, containsFocus, containsPoint, containsPoint, dataContextChanged, deparent, depeer, disable, enable, encloses, focus, focusAfterGroup, focusAtEnd, focusInNextTabElement, focusInPreviousTabElement, getAbsoluteLeft, getAbsoluteTop, getAccessKey, getAdaptiveHeightPriority, getAdaptiveWidthPriority, getAlwaysManageFocusNavigation, getAlwaysShowScrollbars, getAnimateAcceleration, getAnimateFadeTime, getAnimateHideAcceleration, getAnimateHideEffect, getAnimateHideTime, getAnimateMoveAcceleration, getAnimateMoveTime, getAnimateRectAcceleration, getAnimateRectTime, getAnimateResizeAcceleration, getAnimateResizeLayoutMode, getAnimateResizeTime, getAnimateScrollAcceleration, getAnimateScrollTime, getAnimateShowAcceleration, getAnimateShowEffect, getAnimateShowTime, getAnimateTime, getAppImgDir, getAriaHandleID, getAriaRole, getAriaStateDefaults, getAutoMaskComponents, getAutoParent, getAutoPopulateData, getAutoShowParent, getBackgroundColor, getBackgroundImage, getBackgroundPosition, getBackgroundRepeat, getBorder, getBorderRadius, getBottom, getById, getByJSObject, getByLocalId, getCanAcceptDrop, getCanAdaptHeight, getCanAdaptWidth, getCanDrag, getCanDragReposition, getCanDragResize, getCanDragScroll, getCanDrop, getCanDropBefore, getCanFocus, getCanHover, getCanvasAutoChild, getCanvasItem, getChildren, getChildrenResizeSnapAlign, getChildrenSnapAlign, getChildrenSnapCenterAlign, getChildrenSnapEdgeAlign, getChildrenSnapResizeToGrid, getChildrenSnapToGrid, getChildTabPosition, getClassName, getComponentMask, getComponentMaskDefaults, getContentElement, getContextMenu, getCorrectZoomOverflow, getCursor, getDataContext, getDataPath, getDefaultHeight, getDefaultWidth, getDestroyed, getDestroying, getDisabled, getDisabledCursor, getDisableTouchScrollingForDrag, getDoubleClickDelay, getDragAppearance, getDragIntersectStyle, getDragMaskType, getDragMaxHeight, getDragMaxWidth, getDragMinHeight, getDragMinWidth, getDragOpacity, getDragRepositionAppearance, getDragRepositionCursor, getDragResizeAppearance, getDragScrollDelay, getDragStartDistance, getDragTarget, getDragTargetAsString, getDragType, getDropTarget, getDropTargetAsString, getDropTypes, getDropTypesAsString, getEdgeBackgroundColor, getEdgeCenterBackgroundColor, getEdgeImage, getEdgeMarginSize, getEdgeOffset, getEdgeOpacity, getEdgeShowCenter, getEdgeSize, getEditNode, getEditProxy, getEditProxyConstructor, getElement, getElement, getEnableWhen, getEndLine, getEventEdge, getEventEdge, getExtraSpace, getFacetId, getFloatingScrollbars, getFormItemAutoChild, getForwardSVGeventsToObject, getFullDataPath, getGroupBorderCSS, getGroupLabelBackgroundColor, getGroupLabelStyleName, getGroupPadding, getGroupTitle, getHeight, getHeightAsString, getHideUsingDisplayNone, getHoverAlign, getHoverAutoDestroy, getHoverAutoFitMaxWidth, getHoverAutoFitMaxWidthAsString, getHoverAutoFitWidth, getHoverComponent, getHoverDelay, getHoverFocusKey, getHoverHeight, getHoverHTML, getHoverMoveWithMouse, getHoverOpacity, getHoverPersist, getHoverScreen, getHoverStyle, getHoverVAlign, getHoverWidth, getHoverWrap, getHSnapPosition, getHSnapPosition, getHtmlElement, getHtmlElementAsString, getHtmlPosition, getImage, getImgURL, getImgURL, getInnerContentHeight, getInnerContentWidth, getInnerHeight, getInnerWidth, getIsGroup, getIsPrinting, getIsRuleScope, getIsSnapAlignCandidate, getKeepInParentRect, getLayoutAlign, getLeaveGroupLabelSpace, getLeavePageSpace, getLeft, getLeftAsString, getLocalId, getLocateByIDOnly, getLocateChildrenBy, getLocateChildrenType, getLocatePeersBy, getLocatePeersType, getLocatorName, getMargin, getMasterCanvas, getMasterElement, getMatchElement, getMatchElementHeight, getMatchElementWidth, getMaxHeight, getMaxWidth, getMaxZoomOverflowError, getMenuConstructor, getMinHeight, getMinNonEdgeSize, getMinWidth, getMomentumScrollMinSpeed, getMouseStillDownDelay, getMouseStillDownInitialDelay, getName, getNativeAutoHideScrollbars, getNextZIndex, getNoDoubleClicks, getNoDropCursor, getOffsetHeight, getOffsetWidth, getOffsetX, getOffsetY, getOpacity, getOuterElement, getOverflow, getPadding, getPageBottom, getPageLeft, getPageRect, getPageRight, getPageTop, getPaletteDefaults, getPanelContainer, getParentCanvas, getParentElement, getPeers, getPercentBox, getPercentSource, getPersistentMatchElement, getPointerSettings, getPointerTarget, getPointerTargetAsString, getPosition, getPrefix, getPrintChildrenAbsolutelyPositioned, getPrintHTML, getPrintHTML, getPrintStyleName, getPrompt, getProportionalResizeModifiers, getProportionalResizing, getReceiveScrollbarEvents, getRect, getRedrawOnResize, getResizeBarTarget, getResizeFrom, getRight, getRuleContext, getRuleContext, getRuleScope, getScrollbarSize, getScrollBottom, getScrollHeight, getScrollLeft, getScrollRight, getScrollTop, getScrollWidth, getShadowColor, getShadowDepth, getShadowHOffset, getShadowImage, getShadowOffset, getShadowSoftness, getShadowSpread, getShadowVOffset, getShouldPrint, getShowCustomScrollbars, getShowDragShadow, getShowEdges, getShowHover, getShowHoverComponents, getShowPointer, getShowResizeBar, getShowShadow, getShowSnapGrid, getShrinkElementOnHide, getSizeMayChangeOnRedraw, getSkinImgDir, getSnapAlignCandidates, getSnapAlignCenterLineStyle, getSnapAlignEdgeLineStyle, getSnapAxis, getSnapEdge, getSnapGridLineProperties, getSnapGridStyle, getSnapHDirection, getSnapHGap, getSnapOffsetLeft, getSnapOffsetTop, getSnapOnDrop, getSnapPosition, getSnapPosition, getSnapResizeToAlign, getSnapResizeToGrid, getSnapTo, getSnapToAlign, getSnapToCenterAlign, getSnapToEdgeAlign, getSnapToGrid, getSnapVDirection, getSnapVGap, getStartLine, getStyleName, getTabIndex, getTestDataContext, getTestInstance, getTitle, getTooltip, getTop, getTopAsString, getTopElement, getUISummary, getUpdateTabPositionOnDraw, getUpdateTabPositionOnReparent, getUseBackMask, getUseCSSShadow, getUseDragMask, getUseImageForSVG, getUseNativeDrag, getUseOpacityFilter, getUseTouchScrolling, getValuesManager, getValuesManagerAsString, getViewportHeight, getViewportWidth, getVisibility, getVisibleHeight, getVisibleWhen, getVisibleWidth, getVSnapPosition, getVSnapPosition, getWidth, getWidthAsString, getZIndex, getZIndex, handleHover, hide, hideClickMask, hideClickMask, hideComponentMask, hideComponentMask, hideContextMenu, imgHTML, imgHTML, imgHTML, intersects, isDirty, isDisabled, isFocused, isVisible, keyUp, layoutChildren, linkHTML, linkHTML, linkHTML, linkHTML, linkHTML, linkHTML, markForDestroy, markForRedraw, markForRedraw, moveAbove, moveBelow, moveBy, moveTo, onAttach, onDetach, onInit, pageScrollDown, pageScrollUp, parentResized, placeNear, placeNear, placeNear, print, print, print, print, printComponents, provideRuleContext, provideRuleContext, redraw, redraw, registerFontScaledPaddingStyles, removeChild, removeChild, removePeer, removePeer, removeRuleContext, removeSnapAlignCandidate, resizeAutoChildAttributes, resizeBy, resizeControls, resizeControlsTo, resizeFonts, resizeFonts, resizeFonts, resizeFontsTo, resizeIcons, resizePadding, resizePadding, resizeTo, resizeTo, revealChild, revealChild, scrollBy, scrollByPercent, scrollTo, scrollTo, scrollTo, scrollToBottom, scrollToLeft, scrollToPercent, scrollToRight, scrollToTop, sendToBack, setAccessKey, setAdaptHeightByCustomizer, setAdaptiveHeightPriority, setAdaptiveWidthPriority, setAdaptWidthByCustomizer, setAlign, setAllowExternalFilters, setAlwaysManageFocusNavigation, setAlwaysShowScrollbars, setAnimateAcceleration, setAnimateFadeTime, setAnimateHideAcceleration, setAnimateHideEffect, setAnimateHideTime, setAnimateMoveAcceleration, setAnimateMoveTime, setAnimateRectAcceleration, setAnimateRectTime, setAnimateResizeAcceleration, setAnimateResizeLayoutMode, setAnimateResizeTime, setAnimateScrollAcceleration, setAnimateScrollTime, setAnimateShowAcceleration, setAnimateShowEffect, setAnimateShowTime, setAnimateTime, setAppImgDir, setAriaRole, setAriaState, setAutoChildConstructor, setAutoChildProperties, setAutoChildProperties, setAutoChildProperties, setAutoChildProperties, setAutoChildVisibility, setAutoHeight, setAutoMaskComponents, setAutoParent, setAutoPopulateData, setAutoResizeAutoChildAttributes, setAutoResizeIcons, setAutoShowParent, setAutoWidth, setBackgroundColor, setBackgroundImage, setBackgroundPosition, setBackgroundRepeat, setBorder, setBorderRadius, setBottom, setCanAcceptDrop, setCanAdaptHeight, setCanAdaptWidth, setCanDrag, setCanDragReposition, setCanDragResize, setCanDragScroll, setCanDrop, setCanDropBefore, setCanFocus, setCanHover, setChildren, setChildrenResizeSnapAlign, setChildrenSnapAlign, setChildrenSnapCenterAlign, setChildrenSnapEdgeAlign, setChildrenSnapResizeToGrid, setChildrenSnapToGrid, setComponentMaskDefaults, setContextMenu, setCorrectZoomOverflow, setCursor, setDataContext, setDataPath, setDefaultHeight, setDefaultPageSpace, setDefaultProperties, setDefaultShowCustomScrollbars, setDefaultWidth, setDisabled, setDisabledCursor, setDisableTouchScrollingForDrag, setDoubleClickDelay, setDragAppearance, setDragIntersectStyle, setDragMaskType, setDragMaxHeight, setDragMaxWidth, setDragMinHeight, setDragMinWidth, setDragOpacity, setDragRepositionAppearance, setDragRepositionCursor, setDragResizeAppearance, setDragScrollDelay, setDragStartDistance, setDragTarget, setDragTarget, setDragType, setDropTarget, setDropTarget, setDropTypes, setDropTypes, setEdgeBackgroundColor, setEdgeCenterBackgroundColor, setEdgeImage, setEdgeMarginSize, setEdgeOffset, setEdgeOpacity, setEdgeShowCenter, setEdgeSize, setEditMode, setEditMode, setEditMode, setEditProxyConstructor, setElement, setEnableWhen, setEndLine, setExtraSpace, setFacetId, setFloatingScrollbars, setForwardSVGeventsToObject, setGroupBorderCSS, setGroupLabelBackgroundColor, setGroupLabelStyleName, setGroupPadding, setGroupTitle, setHeight, setHeight, setHeight, setHeight100, setHideUsingDisplayNone, setHoverAlign, setHoverAutoDestroy, setHoverAutoFitMaxWidth, setHoverAutoFitMaxWidth, setHoverAutoFitWidth, setHoverDelay, setHoverFocusKey, setHoverHeight, setHoverMoveWithMouse, setHoverOpacity, setHoverPersist, setHoverScreen, setHoverStyle, setHoverVAlign, setHoverWidth, setHoverWrap, setHtmlElement, setHtmlElement, setHtmlPosition, setImage, setImage, setInitHandler, setIsGroup, setIsRuleScope, setIsSnapAlignCandidate, setKeepInParentRect, setKeepInParentRect, setKeepInParentRect, setLayoutAlign, setLayoutAlign, setLeaveGroupLabelSpace, setLeavePageSpace, setLeft, setLeft, setLocateByIDOnly, setLocateChildrenBy, setLocateChildrenType, setLocatePeersBy, setLocatePeersType, setLocatorName, setLocatorParent, setLocatorParent, setLogicalStructure, setMargin, setMatchElement, setMatchElementHeight, setMatchElementWidth, setMaxHeight, setMaxWidth, setMaxZoomOverflowError, setMenuConstructor, setMinHeight, setMinNonEdgeSize, setMinWidth, setMomentumScrollMinSpeed, setMouseStillDownDelay, setMouseStillDownInitialDelay, setName, setNativeAutoHideScrollbars, setNeverUseFilters, setNoDoubleClicks, setNoDropCursor, setOpacity, setOverflow, setPadding, setPageLeft, setPageTop, setPanelContainer, setParentCanvas, setParentElement, setPeers, setPercentBox, setPercentSource, setPersistentMatchElement, setPointerSettings, setPointerTarget, setPosition, setPrefix, setPrintChildrenAbsolutelyPositioned, setPrintStyleName, setPrompt, setProportionalResizeModifiers, setProportionalResizing, setReceiveScrollbarEvents, setRect, setRect, setRedrawOnResize, setRelativeTabPosition, setResizeBarTarget, setResizeFrom, setResizeFrom, setRight, setRuleScope, setScrollbarConstructor, setScrollbarSize, setShadowColor, setShadowDepth, setShadowHOffset, setShadowImage, setShadowOffset, setShadowSoftness, setShadowSpread, setShadowVOffset, setShouldPrint, setShowCustomScrollbars, setShowDragShadow, setShowEdges, setShowHover, setShowHoverComponents, setShowPointer, setShowResizeBar, setShowShadow, setShowSnapGrid, setShrinkElementOnHide, setSizeMayChangeOnRedraw, setSkinImgDir, setSmoothFade, setSnapAlignCandidates, setSnapAlignCenterLineStyle, setSnapAlignEdgeLineStyle, setSnapAxis, setSnapEdge, setSnapGridLineProperties, setSnapGridStyle, setSnapHDirection, setSnapHGap, setSnapOffsetLeft, setSnapOffsetTop, setSnapOnDrop, setSnapResizeToAlign, setSnapResizeToGrid, setSnapTo, setSnapToAlign, setSnapToCenterAlign, setSnapToEdgeAlign, setSnapToGrid, setSnapVDirection, setSnapVGap, setStartLine, setStyleName, setTabIndex, setTestDataContext, setTitle, setTooltip, setTop, setTop, setUpdateTabPositionOnDraw, setUpdateTabPositionOnReparent, setUseBackMask, setUseCSSShadow, setUseDragMask, setUseImageForSVG, setUseNativeDrag, setUseOpacityFilter, setUseTouchScrolling, setValuesManager, setValuesManager, setVisibility, setVisible, setVisibleWhen, setWidth, setWidth, setWidth, setWidth100, setZIndex, shouldDragScroll, show, showClickMask, showComponentMask, showComponentMask, showNextTo, showNextTo, showNextTo, showNextTo, showPrintPreview, showPrintPreview, showPrintPreview, showPrintPreview, showRecursively, updateChildTabPosition, updateChildTabPositions, updateEditNode, updateHover, updateHover, updateShadow, updateTabPositionForDraw, visibleAtPoint, willAcceptDrop
addDrawHandler, addDynamicProperty, addDynamicProperty, addDynamicProperty, addDynamicProperty, applyFactoryProperties, clearDynamicProperty, completeCreation, destroy, doAddHandler, doInit, doOnRender, draw, equals, error, errorIfNotCreated, getAttribute, getAttributeAsBoolean, getAttributeAsDate, getAttributeAsDateArray, getAttributeAsDouble, getAttributeAsElement, getAttributeAsFloat, getAttributeAsFloatArray, getAttributeAsInt, getAttributeAsIntArray, getAttributeAsJavaScriptObject, getAttributeAsMap, getAttributeAsObject, getAttributeAsRecord, getAttributeAsString, getAttributeAsStringArray, getConfig, getDOM, getHandlerCount, getID, getInnerHTML, getJsObj, getOrCreateJsObj, getRef, getScClassName, hasAutoAssignedID, hasDynamicProperty, hashCode, initNativeObject, internalSetID, internalSetID, isConfigOnly, isCreated, isDrawn, isFactoryCreated, onBind, onDestroy, onDraw, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setConfig, setConfigOnly, setDefaultProperties, setDragTracker, setFactoryCreated, setID, setJavaScriptObject, setLogicalStructure, setLogicalStructure, setNullProperty, setPosition, setProperty, setProperty, setProperty, setProperty, setProperty, setProperty, setProperty, setScClassName, toString
addAttachHandler, addBitlessDomHandler, addDomHandler, addHandler, asWidget, asWidgetOrNull, createHandlerManager, delegateEvent, doAttachChildren, doDetachChildren, fireEvent, getLayoutData, getParent, isAttached, isOrWasAttached, onBrowserEvent, onLoad, onUnload, removeFromParent, setLayoutData, sinkEvents, unsinkEvents
addStyleDependentName, ensureDebugId, ensureDebugId, ensureDebugId, getStyleElement, getStyleName, getStylePrimaryName, getStylePrimaryName, isVisible, onEnsureDebugId, removeStyleDependentName, removeStyleName, resolvePotentialElement, setElement, setPixelSize, setSize, setStyleDependentName, setStyleName, setStyleName, setStyleName, setStylePrimaryName, setStylePrimaryName, setVisible, sinkBitlessEvent
public HTMLFlow()
public HTMLFlow(com.google.gwt.core.client.JavaScriptObject jsObj)
public HTMLFlow(java.lang.String contents)
public static HTMLFlow getOrCreateRef(com.google.gwt.core.client.JavaScriptObject jsObj)
public static void changeAutoChildDefaults(java.lang.String autoChildName, Canvas defaults)
autoChildName
.autoChildName
- name of an AutoChild to customize the defaults for.defaults
- Canvas defaults to apply. These defaults override any existing properties
without destroying or wiping out non-overridden properties. For usage tips on this
param, see SGWTProperties
.AutoChildUsage
public static void changeAutoChildDefaults(java.lang.String autoChildName, FormItem defaults)
autoChildName
.autoChildName
- name of an AutoChild to customize the defaults for.defaults
- FormItem defaults to apply. These defaults override any existing properties
without destroying or wiping out non-overridden properties. For usage tips on this
param, see SGWTProperties
.AutoChildUsage
protected com.google.gwt.core.client.JavaScriptObject create()
public HTMLFlow setAllowCaching(java.lang.Boolean allowCaching) throws java.lang.IllegalStateException
Set to true to allow browser caching if the browser would normally do so, in other words, if the HTTP headers returned with the response indicate that the response can be cached.
allowCaching
- New allowCaching value. Default value is falseHTMLFlow
instance, for chaining setter callsjava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.Boolean getAllowCaching()
Set to true to allow browser caching if the browser would normally do so, in other words, if the HTTP headers returned with the response indicate that the response can be cached.
public HTMLFlow setAutoChangeProtocol(java.lang.Boolean autoChangeProtocol)
autoChangeProtocol
- New autoChangeProtocol value. Default value is trueHTMLFlow
instance, for chaining setter callspublic java.lang.Boolean getAutoChangeProtocol()
public HTMLFlow setCanSelectText(java.lang.Boolean canSelectText) throws java.lang.IllegalStateException
ContentsType
is set to ContentsType.PAGE
. In this
case contents is loaded from a target URL via an IFRAME element, and text selection behavior will be dictated by the
loaded HTML.setCanSelectText
in class Canvas
canSelectText
- New canSelectText value. Default value is trueHTMLFlow
instance, for chaining setter callsjava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.Boolean getCanSelectText()
ContentsType
is set to ContentsType.PAGE
. In this
case contents is loaded from a target URL via an IFRAME element, and text selection behavior will be dictated by the
loaded HTML.getCanSelectText
in class Canvas
public HTMLFlow setCaptureSCComponents(java.lang.Boolean captureSCComponents) throws java.lang.IllegalStateException
Only applies when contentsType is not "page".
captureSCComponents
- New captureSCComponents value. Default value is trueHTMLFlow
instance, for chaining setter callsjava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.Boolean getCaptureSCComponents()
Only applies when contentsType is not "page".
public HTMLFlow setContents(java.lang.String contents)
setContents
in class Canvas
contents
- an HTML string to be set as the contents of this widget. Default value is " "HTMLFlow
instance, for chaining setter callssetDynamicContents(java.lang.Boolean)
,
HTMLString
public java.lang.String getContents()
getContents
in class Canvas
getDynamicContents()
,
HTMLString
public HTMLFlow setContentsType(ContentsType contentsType) throws java.lang.IllegalStateException
null
or 'fragment' indicates that HTML loaded from contentsURL
is assumed to be an HTML fragment rather than a
complete page. Set to "page" to load HTML as a standalone page, via an IFRAME. contentsType:"page"
should only be used for controlled HTML content, and only when such content cannot be delivered as an HTML fragment
instead (the default). To dynamically load Smart GWT components, use ViewLoader
,
never this mechanism (click here
for why).
Loading HTML content as a fragment is less resource intensive and avoids visual artifacts such as translucent media becoming opaque or disappearing when placed over an IFRAME.
Loading third-party, uncontrolled content could lead to the surrounding
page disappearing if a user clicks on an HTML link with target=_top
.
With
contentsType:"page"
, loadingMessage
is not
supported, and only "GET" is supported for httpMethod
.
Note that a native bug has been observed in Internet Explorer version 10 whereby if an HTMLFlow with
contentsType
set to "page"
loads a page containing an HTML <frameset>
, when
the HTMLFlow is hidden
, it can interfere with the rendering of other
elements on the page. Setting Canvas.shrinkElementOnHide
to true
will work around this behavior.
contentsType
- New contentsType value. Default value is nullHTMLFlow
instance, for chaining setter callsjava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic ContentsType getContentsType()
null
or 'fragment' indicates that HTML loaded from contentsURL
is assumed to be an HTML fragment rather than a
complete page. Set to "page" to load HTML as a standalone page, via an IFRAME. contentsType:"page"
should only be used for controlled HTML content, and only when such content cannot be delivered as an HTML fragment
instead (the default). To dynamically load Smart GWT components, use ViewLoader
,
never this mechanism (click here
for why).
Loading HTML content as a fragment is less resource intensive and avoids visual artifacts such as translucent media becoming opaque or disappearing when placed over an IFRAME.
Loading third-party, uncontrolled content could lead to the surrounding
page disappearing if a user clicks on an HTML link with target=_top
.
With
contentsType:"page"
, loadingMessage
is not
supported, and only "GET" is supported for httpMethod
.
Note that a native bug has been observed in Internet Explorer version 10 whereby if an HTMLFlow with
contentsType
set to "page"
loads a page containing an HTML <frameset>
, when
the HTMLFlow is hidden
, it can interfere with the rendering of other
elements on the page. Setting Canvas.shrinkElementOnHide
to true
will work around this behavior.
public HTMLFlow setContentsURL(java.lang.String contentsURL)
If specified, this component will load HTML content from the specified URL when it is first drawn.
This feature relies on the XMLHttpRequest object which can be disabled by end-users in some supported
browsers. See PlatformDependencies
for more information.
If this method is called after the component has been drawn/initialized:
Change the URL this component loads content from. Triggers a fetch for content from the new URL.
Can also be called with no arguments to reload content from the existing contentsURL
.
This feature relies on the XMLHttpRequest object which can be disabled by end-users in some supported browsers. See PlatformDependencies
for more information.
public java.lang.String getContentsURL()
If specified, this component will load HTML content from the specified URL when it is first drawn.
This feature relies on the XMLHttpRequest object which can be disabled by end-users in some supported
browsers. See PlatformDependencies
for more information.
URL
public HTMLFlow setContentsURLParams(java.util.Map contentsURLParams)
contentsURLParams
- New contentsURLParams value. Default value is nullHTMLFlow
instance, for chaining setter callspublic HTMLFlow setDynamicContents(java.lang.Boolean dynamicContents)
${[JavaScript to evaluate]}
. For example, to include the current date in a templated
message, canvas.contents
could be set to:
"Today's date is <b>${new
Date().toUSShortDate()}</b>"
Embedded expressions will be evaluated when the canvas is drawn or
redrawn, and the result of the evaluated expression will be displayed to the user. If the expression does not evaluate
to a String, the toString()
representation of the returned object will be displayed automatically
Dynamic expressions are evaluated in the scope of the canvas displaying the content, so the this
keyword
may be used within your expression to refer to the canvas. Developers may also explicitly supply values for variables
to be used within the evaluation via the Canvas.dynamicContentsVars
property.
Notes:
Developer Console
and the error string will be embedded in place of the
expected value in the Canvas. Note : This is an advanced setting
setDynamicContents
in class Canvas
dynamicContents
- New dynamicContents value. Default value is falseHTMLFlow
instance, for chaining setter callssetContents(java.lang.String)
,
com.smartgwt.client.widgets.Canvas#setDynamicContentsVars
public java.lang.Boolean getDynamicContents()
${[JavaScript to evaluate]}
. For example, to include the current date in a templated
message, canvas.contents
could be set to:
"Today's date is <b>${new
Date().toUSShortDate()}</b>"
Embedded expressions will be evaluated when the canvas is drawn or
redrawn, and the result of the evaluated expression will be displayed to the user. If the expression does not evaluate
to a String, the toString()
representation of the returned object will be displayed automatically
Dynamic expressions are evaluated in the scope of the canvas displaying the content, so the this
keyword
may be used within your expression to refer to the canvas. Developers may also explicitly supply values for variables
to be used within the evaluation via the Canvas.dynamicContentsVars
property.
Notes:
Developer Console
and the error string will be embedded in place of the
expected value in the Canvas. getDynamicContents
in class Canvas
getContents()
,
com.smartgwt.client.widgets.Canvas#getDynamicContentsVars
public HTMLFlow setEvalScriptBlocks(java.lang.Boolean evalScriptBlocks) throws java.lang.IllegalStateException
evalScriptBlocks
is true, HTMLFlow will pre-process the loaded HTML in order to mimic how the HTML would
execute if it were loaded as an independent page or loaded via an IFRAME. This feature is intended to assist with migrating existing applications to Smart GWT.
evalScriptBlocks
is enabled by default when loading
remote content (via contentsURL
) and disabled by default for
content supplied via setContents()
.
Note that, if evalScriptBlocks is false, <SCRIPT> blocks will still be detected and disabled to avoid the inconsistent results across different browsers.
Only applies when contentsType is not "page".
evalScriptBlocks
- New evalScriptBlocks value. Default value is nullHTMLFlow
instance, for chaining setter callsjava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.Boolean getEvalScriptBlocks()
evalScriptBlocks
is true, HTMLFlow will pre-process the loaded HTML in order to mimic how the HTML would
execute if it were loaded as an independent page or loaded via an IFRAME. This feature is intended to assist with migrating existing applications to Smart GWT.
evalScriptBlocks
is enabled by default when loading
remote content (via contentsURL
) and disabled by default for
content supplied via setContents()
.
Note that, if evalScriptBlocks is false, <SCRIPT> blocks will still be detected and disabled to avoid the inconsistent results across different browsers.
Only applies when contentsType is not "page".
public HTMLFlow setHttpMethod(SendMethod httpMethod)
httpMethod
- New httpMethod value. Default value is "GET"HTMLFlow
instance, for chaining setter callspublic SendMethod getHttpMethod()
public HTMLFlow setIframeSandbox(java.lang.String iframeSandbox) throws java.lang.IllegalStateException
contentsType
ContentsType.PAGE
, sets the <iframe> sandbox
attribute to the provided
value. Use the value "*ALL*" to cause the "sandbox" attribute to be output with no value (which causes full sandboxing).
See any HTML reference for other legal values of the "sandbox" attribute, which allow you to remove individual restrictions on the loaded content.
Note that Smart GWT simply applies the provided value to the generated <iframe> element and cannot fix bugs or differences in sandbox behavior across different browsers.
iframeSandbox
- New iframeSandbox value. Default value is nullHTMLFlow
instance, for chaining setter callsjava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.String getIframeSandbox()
contentsType
ContentsType.PAGE
, sets the <iframe> sandbox
attribute to the provided
value. Use the value "*ALL*" to cause the "sandbox" attribute to be output with no value (which causes full sandboxing).
See any HTML reference for other legal values of the "sandbox" attribute, which allow you to remove individual restrictions on the loaded content.
Note that Smart GWT simply applies the provided value to the generated <iframe> element and cannot fix bugs or differences in sandbox behavior across different browsers.
public HTMLFlow setLoadingMessage(java.lang.String loadingMessage)
contentsURL
property has been set. Use
"${loadingImage}"
to include a loading
image
. The loading message will show both during the initial load of content, and during reload if the contents are
reloaded or the contentsURL changed. For a first-time only loading message, initialize the contents
property instead.
Note: the loadingMessage
is never displayed when loading complete web pages rather
than HTML fragments (see contentsType
).
loadingMessage
- New loadingMessage value. Default value is " ${loadingImage}"HTMLFlow
instance, for chaining setter callsHTMLString
public java.lang.String getLoadingMessage()
contentsURL
property has been set. Use
"${loadingImage}"
to include a loading
image
. The loading message will show both during the initial load of content, and during reload if the contents are
reloaded or the contentsURL changed. For a first-time only loading message, initialize the contents
property instead.
Note: the loadingMessage
is never displayed when loading complete web pages rather
than HTML fragments (see contentsType
).
HTMLString
public HTMLFlow setSelectContentOnSelectAll(java.lang.Boolean selectContentOnSelectAll)
HTMLFlow
is focused, causes Ctrl-A / Command-A keypresses to select just the content, as opposed
to all content on the screen becoming selected. This HTMLFlow
must be focusable
in order for this setting to have an effect. Not valid
with contentsType
ContentsType.PAGE
.
selectContentOnSelectAll
- New selectContentOnSelectAll value. Default value is nullHTMLFlow
instance, for chaining setter callspublic java.lang.Boolean getSelectContentOnSelectAll()
HTMLFlow
is focused, causes Ctrl-A / Command-A keypresses to select just the content, as opposed
to all content on the screen becoming selected. This HTMLFlow
must be focusable
in order for this setting to have an effect. Not valid
with contentsType
ContentsType.PAGE
.
public com.google.gwt.event.shared.HandlerRegistration addContentLoadedHandler(ContentLoadedHandler handler)
StringMethod fired when content is completely loaded in this htmlFlow. Has no default implementation. Add a notification to fire custom logic when loading completes.
Notes:
this.setContents()
will cause this notification to be fired when the
contents have been set. If HTMLFlow.evalScriptBlocks
is
true, and the HTML passed into setContents()
contains any <script src=... >
tags, this
callback will be fired asynchronously once the scripts have been loaded from the server and executed, as well as having
the widget content updatedHTMLFlow.contentsURL
, this does not apply to htmlFlows with contentsType
set to "page"
addContentLoadedHandler
in interface HasContentLoadedHandlers
handler
- the contentLoaded handlerHandlerRegistration
used to remove this handlerpublic void fetchRelatedData(ListGridRecord record, Canvas schema)
Relationships between DataSources are declared via DataSourceField.foreignKey
.
For example, given two related DataSources "orders" and "orderItems", where we want to
fetch the "orderItems" that belong to a given "order". "orderItems" should declare a field that is a foreignKey
to the "orders" table (for example, it might be named
"orderId" with foreignKey="orders.id"). Then, to load the records related to a given "order", call fetchRelatedData()
on the component bound to "orderItems", pass the "orders" DataSource as the "schema" and pass a record from the "orders"
DataSource as the "record" argument.
Note: When you expect a large number of records to be returned it is not
recommended to display these in the DetailViewer as it doesn't have the same level of support for large datasets as the
ListGrid
.
record
- DataSource recordschema
- schema of the DataSource record, or DataBoundComponent already bound to that schemaDataBoundComponentMethods overview and related methods
public void fetchRelatedData(ListGridRecord record, Canvas schema, DSCallback callback)
public void fetchRelatedData(ListGridRecord record, Canvas schema, DSCallback callback, DSRequest requestProperties)
Relationships between DataSources are declared via DataSourceField.foreignKey
.
For example, given two related DataSources "orders" and "orderItems", where we want to
fetch the "orderItems" that belong to a given "order". "orderItems" should declare a field that is a foreignKey
to the "orders" table (for example, it might be named
"orderId" with foreignKey="orders.id"). Then, to load the records related to a given "order", call fetchRelatedData()
on the component bound to "orderItems", pass the "orders" DataSource as the "schema" and pass a record from the "orders"
DataSource as the "record" argument.
Note: When you expect a large number of records to be returned it is not
recommended to display these in the DetailViewer as it doesn't have the same level of support for large datasets as the
ListGrid
.
record
- DataSource recordschema
- schema of the DataSource record, or DataBoundComponent already bound to that schemacallback
- callback to invoke on completionrequestProperties
- additional properties to set on the DSRequest that will be issuedDataBoundComponentMethods overview and related methods
public java.lang.Boolean loadingContent()
contentsType
set to "page"
ContentLoadedEvent
public void transformHTML(java.lang.String html)
html
- the html as loaded from the server return (HTML) html to be rendered.
See HTMLString
HTMLString
public static void setDefaultProperties(HTMLFlow hTMLFlowProperties)
Note: This method is intended for setting default attributes only and will affect all instances of the underlying class (including those automatically generated in JavaScript). This method should not be used to apply standard EventHandlers or override methods for a class - use a custom subclass instead. Calling this method after instances have been created can result in undefined behavior, since it bypasses any setters and a class instance may have already examined a particular property and not be expecting any changes through this route.
hTMLFlowProperties
- properties that should be used as new defaults when instances of this class are createdSGWTProperties
public com.smartgwt.logicalstructure.core.LogicalStructureObject setLogicalStructure(com.smartgwt.logicalstructure.widgets.HTMLFlowLogicalStructure s)
LogicalStructure
interface,
which supports Eclipse's logical structure debugging facility.public com.smartgwt.logicalstructure.core.LogicalStructureObject getLogicalStructure()
LogicalStructure
interface,
which supports Eclipse's logical structure debugging facility.getLogicalStructure
in interface LogicalStructure
getLogicalStructure
in class Canvas