OracleJavaScript API Reference for Oracle ADF Faces

 

SUMMARY: FIELD | CONSTR | METHOD    DETAIL: FIELD | CONSTR | METHOD

oracle.adfinternal.view.js.laf.dhtml.internalWindow
Class AdfDhtmlPanelWindowPeer

Warning:

org.ecmascript.object.Object
   |
   +--oracle.adf.view.js.base.AdfObject
         |
         +--oracle.adf.view.js.base.AdfUIPeer
               |
               +--oracle.adf.view.js.laf.rich.AdfRichUIPeer
                     |
                     +--oracle.adfinternal.view.js.laf.dhtml.internalWindow.AdfDhtmlPanelWindowPeer
Direct Known Subclasses:
AdfDhtmlDialogPeer

public class AdfDhtmlPanelWindowPeer
extends AdfRichUIPeer
Client Renderer(Peer) for PanelWindow Component



Field Summary

private static Object
_ANIMATION_DURATION_SKIN_PROPERTY
private static Object
_CONTENT_CENTER_SUBID
private static Object
_CONTENT_END_EDGE_SUBID
private static Object
_CONTENT_RESIZED_INDICATOR_EXPANDO
private static Object
_CONTENT_SIZED_FOR_MINIMUMS_EXPANDO
private static Object
_CONTENT_START_EDGE_SUBID
private static Object
_CONTENT_SUBID
private static Object
_FOOTER_CENTER_CONTENT_SUBID
private static Object
_FOOTER_CENTER_EDGE_SUBID
private static Object
_FOOTER_END_EDGE_SUBID
private static Object
_FOOTER_RESIZE_END_ICON_SUBID
private static Object
_FOOTER_RESIZE_START_ICON_SUBID
private static Object
_FOOTER_START_EDGE_SUBID
protected Object
GetSubIdDomElement
Returns the dom element for a given subElementId for panelWindow.
private static Object
_HEADER_CENTER_EDGE_SUBID
private static Object
_HEADER_END_EDGE_SUBID
private static Object
_HEADER_START_EDGE_SUBID
private static Object
_HEADER_TITLE_BAR_SUBID
private Object
_onAbortDrop
private Object
_onResizeDrag
private Object
_onResizeDrop
private static Object
_PANEL_WINDOW_RESIZE_GHOST_CLASS
private static Object
_RESIZE_DRAG_SOURCE_SUBIDS
private static Object
_RESIZE_ON
private static Object
_STRETCH_CHILDREN_FIRST
private static Object
_SUB_ID_MAP
panelWindow component publishes the following sub ids [External Subid --> Internal Client SubId]:- 1.


Fields inherited from oracle.adf.view.js.laf.rich.AdfRichUIPeer

addComponentPropertyChanges, addComponentPropertyGetters, BUSY_STYLECLASS, DISABLED_STYLECLASS, DRAG_SOURCE_STYLECLASS, DROP_TARGET_STYLECLASS, FOCUS_TARGET_STYLECLASS, HOVER_TARGET_STYLECLASS, READONLY_STYLECLASS


Fields inherited from oracle.adf.view.js.base.AdfObject

constructor, superclass


Fields inherited from org.ecmascript.object.Object

prototype


Constructor Summary

public
AdfDhtmlPanelWindowPeer()
Client Renderer(Peer) for PanelWindow Component


Method Summary

protected void
BindToComponent(AdfUIComponent component, HTMLElement domElement)
Override the bind method to initialize the popup window services after the component has been replaced.
public void
calculateMinimumContentSize()
Finds the title bar widths by accumulating the widths of the individual elements in the title bar and setting the minimum width and height of the content area.
protected Object
Cancel(Object component)
Cancels the floating element by invoking the parent popup's implementation.
protected Object
ComponentContentHeightChanged(Object component, HTMLElement domElement, int newValue, int oldValue)
Optimized property change handler that applies the value directly to the content div's style property.
protected Object
ComponentContentWidthChanged(Object component, HTMLElement domElement, int newValue, int oldValue)
Optimized property change handler that applies the value directly to the content div's style property.
protected void
ComponentRemoved(AdfUIComponent component)
Calls to the AdfDhtmlSimpleFloat to unregister the shadow decorator and drag-and-drop handler.
protected Object
ComponentTitleChanged(Object component, Object domElement, Object newValue, Object oldValue)
protected Object
ComponentTitleIconSourceChanged(Object component, Object domElement, Object newValue, Object oldValue)
public string
getAnimationDurationSkinProperty()
protected Object
GetComponentContentHeight(Object component, Object domElement)
Optimized getter that returns the content height from the center content div.
protected Object
GetComponentContentWidth(Object component, HTMLElement domElement)
Optimized getter that returns the content width from the center content div.
public HTMLElement
getDragElement()
Gets the dragElement.
private AdfDhtmlSimpleFloat
_getPopupWindow(AdfUIComponent component)
Returns the AdfDhtmlSimpleFloat associated with an open component.
private static HTMLElement
_getResizableContentDom(Object component)
protected string
GetResizeGhostSelector()
private Object
_handleActivate(AdfUIInputEvent componentEvent, Boolean focusOnFirstElement)
If the event has not already been canceled, check to see if the event source is within the content of the active component.
protected Object
HandleComponentClick(AdfUIInputEvent componentEvent)
If the close icon was clicked, hide the floating element.
protected Object
HandleComponentFocus(AdfUIInputEvent componentEvent)
Activate the AdfDhtmlSimpleFloat (popup window controller) if inactive.
protected Object
HandleComponentKeyDown(AdfUIInputEvent componentEvent)
Not implemented by panelWindow but is is by dialog.
protected Object
HandleComponentKeyPress(AdfUIInputEvent componentEvent)
There is a one condition that is handled here:
protected Object
HandleComponentKeyUp(AdfUIInputEvent componentEvent)
There are a few conditions that are handled here:
protected Object
HandleComponentMouseDown(AdfUIInputEvent componentEvent)
Activate the AdfDhtmlSimpleFloat (popup window controller) if inactive.
public Object
handleEscapeKey(Object event)
Cancel when the ESC key was used.
private void
_handleResizeAbort()
private void
_handleResizeDrag(Object evt, Number deltaX, Number deltaY)
private void
_handleResizeDrop(Object evt, Number deltaX, Number deltaY)
protected Object
Hide(Object component)
Hides the floating element by invoking the parent popup's implementation.
protected Object
Init(Object component, Object usage)
Initializes the instance.
protected Object
InitDomElement(Object component, HTMLElement domElement)
Creates popup hints that are dialog/panelWindow specific.
protected static Object
InitSubclass()
protected Boolean
IsClose(Object componentEvent)
Checks to see if the event was triggered from the close button.
public boolean
isContentResized(AdfUIComponent component)
private void
_startResizeDrag(AdfDhtmlSimpleFloat popupWindow, DomEvent nativeEvent, string eventTargetSubId)


Methods inherited from oracle.adf.view.js.laf.rich.AdfRichUIPeer

addComponentEventHandlers, addComponentPropertyChanges, addComponentPropertyGetters, addDomEventHandlers, addEventHandlerToDomInstance, addSuppressedPPRAttributes, bind, cancelAllPopups, cancelPopup, ChildVisibilityChanged, ComponentInlineStyleChanged, ComponentPropertyChanged, componentRemoved, ComponentStyleClassChanged, ComponentVisibleChanged, ConvertClientIdToLocator, convertLocatorToClientId, CreateDraggableNode, createPeerClass, createSubId, CreateSubId, DefaultInitClass, DispatchComponentEvent, domReplaceNotify, DomReplaceNotify, focus, Focus, getAbsoluteId, getAbsoluteLocator, getAccessibleName, GetAccessibleName, getAllPopups, getComponent, GetComponent, GetComponentId, getComponentParent, getComponentProperty, GetComponentVisible, getDescendantComponents, getDomContentElement, getDomContentElementForComponent, GetDomContentElementForNode, getDomDocument, getDomElement, getDomElementForComponent, getDomNode, GetDomNodeForCommentComponent, getDomNodeForComponent, getDragOverFeedback, GetDragOverFeedback, getDragTransferable, GetDragTransferable, getFirstAncestorComponent, getInlineEditor, GetInlineEditor, getInlineStyleProperty, getLocatorByDomElement, getPagePosition, getPopupWindow, getReadyState, GetReadyState, GetRichResourceURL, getSubIdDomElement, GetSubIdDomElement, hideAllPopups, hidePopup, InitClass, initialize, isActive, isInActiveHeirarchy, isPopupVisible, messageNotify, MessageNotify, messageShow, MessageShow, needsChildVisibilityChanges, PopupClosed, processPushData, ProcessPushData, registerKeyStroke, replaceDomElement, ReplaceDomElement, resizeNotify, ResizeNotify, scrollIntoView, ScrollIntoView, setBusy, SetBusy, setInlineStyleProperty, showContextMenu, showPopup, TruncateClientId, TruncateClientIdOnceImpl, UnbindFromComponent, unregisterKeyStroke, visitChildren


Methods inherited from oracle.adf.view.js.base.AdfUIPeer

getDefaultDragRecognizer, getParentPeer, initiateDrag, isVisible, needsResizeNotify


Methods inherited from oracle.adf.view.js.base.AdfObject

adopt, clone, createCallback, createInitializedObject, createSubclass, ensureClassInitialization, equals, getClass, GetLazyArrayProperty, GetLazyMapProperty, getTypeName, toDebugString, toString


Field Detail


_ANIMATION_DURATION_SKIN_PROPERTY

private static Object _ANIMATION_DURATION_SKIN_PROPERTY

_CONTENT_CENTER_SUBID

private static Object _CONTENT_CENTER_SUBID

_CONTENT_END_EDGE_SUBID

private static Object _CONTENT_END_EDGE_SUBID

_CONTENT_RESIZED_INDICATOR_EXPANDO

private static Object _CONTENT_RESIZED_INDICATOR_EXPANDO

_CONTENT_SIZED_FOR_MINIMUMS_EXPANDO

private static Object _CONTENT_SIZED_FOR_MINIMUMS_EXPANDO

_CONTENT_START_EDGE_SUBID

private static Object _CONTENT_START_EDGE_SUBID

_CONTENT_SUBID

private static Object _CONTENT_SUBID

_FOOTER_CENTER_CONTENT_SUBID

private static Object _FOOTER_CENTER_CONTENT_SUBID

_FOOTER_CENTER_EDGE_SUBID

private static Object _FOOTER_CENTER_EDGE_SUBID

_FOOTER_END_EDGE_SUBID

private static Object _FOOTER_END_EDGE_SUBID

_FOOTER_RESIZE_END_ICON_SUBID

private static Object _FOOTER_RESIZE_END_ICON_SUBID

_FOOTER_RESIZE_START_ICON_SUBID

private static Object _FOOTER_RESIZE_START_ICON_SUBID

_FOOTER_START_EDGE_SUBID

private static Object _FOOTER_START_EDGE_SUBID

GetSubIdDomElement

protected Object GetSubIdDomElement

Returns the dom element for a given subElementId for panelWindow.

_HEADER_CENTER_EDGE_SUBID

private static Object _HEADER_CENTER_EDGE_SUBID

_HEADER_END_EDGE_SUBID

private static Object _HEADER_END_EDGE_SUBID

_HEADER_START_EDGE_SUBID

private static Object _HEADER_START_EDGE_SUBID

_HEADER_TITLE_BAR_SUBID

private static Object _HEADER_TITLE_BAR_SUBID

_onAbortDrop

private Object _onAbortDrop

_onResizeDrag

private Object _onResizeDrag

_onResizeDrop

private Object _onResizeDrop

_PANEL_WINDOW_RESIZE_GHOST_CLASS

private static Object _PANEL_WINDOW_RESIZE_GHOST_CLASS

_RESIZE_DRAG_SOURCE_SUBIDS

private static Object _RESIZE_DRAG_SOURCE_SUBIDS

_RESIZE_ON

private static Object _RESIZE_ON

_STRETCH_CHILDREN_FIRST

private static Object _STRETCH_CHILDREN_FIRST

_SUB_ID_MAP

private static Object _SUB_ID_MAP

panelWindow component publishes the following sub ids [External Subid --> Internal Client SubId]:- 1. [title --> _ttxt] - dialog title text 2. [content --> contentContainer] - center content area 3. [close_icon --> close] - close icon

Constructor Detail


AdfDhtmlPanelWindowPeer

public AdfDhtmlPanelWindowPeer()

Client Renderer(Peer) for PanelWindow Component

Method Detail


BindToComponent

protected void BindToComponent(AdfUIComponent component,
                               HTMLElement domElement)

Override the bind method to initialize the popup window services after the component has been replaced.

Parameters:
component  -  target component to bind
domElement  -  dom element component is bound
Return:
void - null
Overrides:
AdfRichUIPeer.BindToComponent(Object, Object)

calculateMinimumContentSize

public void calculateMinimumContentSize()

Finds the title bar widths by accumulating the widths of the individual elements in the title bar and setting the minimum width and height of the content area.

Return:
void - null

Cancel

protected Object Cancel(Object component)

Cancels the floating element by invoking the parent popup's implementation.

Parameters:
component    
Return:
Object

ComponentContentHeightChanged

protected Object ComponentContentHeightChanged(Object component,
                                               HTMLElement domElement,
                                               int newValue,
                                               int oldValue)

Optimized property change handler that applies the value directly to the content div's style property.

Parameters:
component    
domElement  -  root dom assigned to the component
newValue  -  new content height
oldValue  -  old content height
Return:
Object

ComponentContentWidthChanged

protected Object ComponentContentWidthChanged(Object component,
                                              HTMLElement domElement,
                                              int newValue,
                                              int oldValue)

Optimized property change handler that applies the value directly to the content div's style property.

Parameters:
component    
domElement  -  root dom assigned to the component
newValue  -  new content width
oldValue  -  old content width
Return:
Object

ComponentRemoved

protected void ComponentRemoved(AdfUIComponent component)

Calls to the AdfDhtmlSimpleFloat to unregister the shadow decorator and drag-and-drop handler.

Parameters:
component  -  Component being disassociated from the peer
Return:
void - null
Overrides:
AdfUIPeer.componentRemoved(AdfUIComponent)

ComponentTitleChanged

protected Object ComponentTitleChanged(Object component,
                                       Object domElement,
                                       Object newValue,
                                       Object oldValue)

Parameters:
component    
domElement    
newValue    
oldValue    
Return:
Object

ComponentTitleIconSourceChanged

protected Object ComponentTitleIconSourceChanged(Object component,
                                                 Object domElement,
                                                 Object newValue,
                                                 Object oldValue)

Parameters:
component    
domElement    
newValue    
oldValue    
Return:
Object

getAnimationDurationSkinProperty

public string getAnimationDurationSkinProperty()

Return:
string - skinning property name for the animation duration of the panelWindow.

GetComponentContentHeight

protected Object GetComponentContentHeight(Object component,
                                           Object domElement)

Optimized getter that returns the content height from the center content div.

Parameters:
component    
domElement    
Return:
Object

GetComponentContentWidth

protected Object GetComponentContentWidth(Object component,
                                          HTMLElement domElement)

Optimized getter that returns the content width from the center content div.

Parameters:
component    
domElement  -  root dom assigned to the component
Return:
Object

getDragElement

public HTMLElement getDragElement()

Gets the dragElement.

Return:
HTMLElement - returns the dom element of the title bar used as a drag source

_getPopupWindow

private AdfDhtmlSimpleFloat _getPopupWindow(AdfUIComponent component)

Returns the AdfDhtmlSimpleFloat associated with an open component. There are two methods for finding the associated AdfDhtmlSimpleFloat. 1) Most dialogs are children of a AdfRichPopup component. The first attempt at finding the floating element looks to see if the direct parent of the panelWindow/dialog is a popup component. If it is, use the popup peer to locate the floating element identified by the popup's client id. 2) There are a few uses of the AdfRichDialog component that doesn't place the dialog component in a AdfRichPopup. The AdfRichDocument is one of these components. In this case, we will use the position manager to locate the floating element that manages the DOM the dialog or panelWindow is bound too.

Parameters:
component  -  panel window or dialog component
Return:
AdfDhtmlSimpleFloat - popup controller

_getResizableContentDom

private static HTMLElement _getResizableContentDom(Object component)

Parameters:
component    
Return:
HTMLElement - node assigned content width and height

GetResizeGhostSelector

protected string GetResizeGhostSelector()

Return:
string - the selector name that is used to locate the client style that's applied the to drag ghost during drag-and-drop resizing

_handleActivate

private Object _handleActivate(AdfUIInputEvent componentEvent,
                               Boolean focusOnFirstElement)

If the event has not already been canceled, check to see if the event source is within the content of the active component. There are use cases that use nested dialog and panelWindow combinations. In this case, if we launch a nested "dialog" the click will bubble up to the parent. We need to make sure the event target is within the dom of the component. This method works because the markup content is removed from the dom when the popup is opened and placed in a zorder container.

Parameters:
componentEvent  -  wrappered click or focus event
focusOnFirstElement  -  indicates if activation should establish focus on first element within the dialog or panelWindow.
Return:
Object

HandleComponentClick

protected Object HandleComponentClick(AdfUIInputEvent componentEvent)

If the close icon was clicked, hide the floating element.

Parameters:
componentEvent  -  wrappered click event
Return:
Object

HandleComponentFocus

protected Object HandleComponentFocus(AdfUIInputEvent componentEvent)

Activate the AdfDhtmlSimpleFloat (popup window controller) if inactive.

Parameters:
componentEvent  -  wrapped focus event
Return:
Object

HandleComponentKeyDown

protected Object HandleComponentKeyDown(AdfUIInputEvent componentEvent)

Not implemented by panelWindow but is is by dialog.

Parameters:
componentEvent  -  wrapped key down event
Return:
Object

HandleComponentKeyPress

protected Object HandleComponentKeyPress(AdfUIInputEvent componentEvent)

There is a one condition that is handled here: 1.) If enter key on the close button, hide the dialog.

Parameters:
componentEvent  -  wrapped key press event
Return:
Object

HandleComponentKeyUp

protected Object HandleComponentKeyUp(AdfUIInputEvent componentEvent)

There are a few conditions that are handled here: 1.) If space key on the close button, hide the dialog. 2.) If ctrl+alt+w keys cycle through any open dialogs.

Parameters:
componentEvent  -  wrapped key up event
Return:
Object

HandleComponentMouseDown

protected Object HandleComponentMouseDown(AdfUIInputEvent componentEvent)

Activate the AdfDhtmlSimpleFloat (popup window controller) if inactive.

Parameters:
componentEvent  -  wrappered mouseDown event
Return:
Object

handleEscapeKey

public Object handleEscapeKey(Object event)

Cancel when the ESC key was used.

Parameters:
event  -  key up event
Return:
Object

_handleResizeAbort

private void _handleResizeAbort()

Return:
void - null
See also:
AdfDhtmlPage.startDrag(Object, Object, Object, Object, Object)

_handleResizeDrag

private void _handleResizeDrag(Object evt,
                               Number deltaX,
                               Number deltaY)

Parameters:
evt    
deltaX  -  summary of vertical mouse movement since the last event
deltaY  -  summary of horizontal mouse movement since the last event
Return:
void - null
See also:
AdfDhtmlPage.startDrag(Object, Object, Object, Object, Object)

_handleResizeDrop

private void _handleResizeDrop(Object evt,
                               Number deltaX,
                               Number deltaY)

Parameters:
evt    
deltaX  -  summary of vertical mouse movement since the drag started
deltaY  -  summary of horizontal mouse movement since the drag started
Return:
void - null
See also:
AdfDhtmlPage.startDrag(Object, Object, Object, Object, Object)

Hide

protected Object Hide(Object component)

Hides the floating element by invoking the parent popup's implementation.

Parameters:
component    
Return:
Object

Init

protected Object Init(Object component,
                      Object usage)

Initializes the instance. Subclasses of AdfObject must call their superclass' Init

Parameters:
component    
usage    
Return:
Object
Overrides:
AdfObject.Init()

InitDomElement

protected Object InitDomElement(Object component,
                                HTMLElement domElement)

Creates popup hints that are dialog/panelWindow specific. The hints are applied to the popup components child hints and override standard hints.

Parameters:
component    
domElement  -  root element for the component
Return:
Object
Overrides:
AdfRichUIPeer.InitDomElement(AdfUIComponent, Object)

InitSubclass

protected static Object InitSubclass()

Return:
Object

IsClose

protected Boolean IsClose(Object componentEvent)

Checks to see if the event was triggered from the close button. This is accomplished by looking at the native target dom's id and comparing to the subid of the close button.

Parameters:
componentEvent  -  source component event
Return:
Boolean - returns true if the target dom element was the close button

isContentResized

public boolean isContentResized(AdfUIComponent component)

Parameters:
component  -  dialog component
Return:
boolean - returns true if the dialog was resized using a manual drag-and-drop operation
See also:
ComponentContentHeightChanged(Object, HTMLElement, int, int)

_startResizeDrag

private void _startResizeDrag(AdfDhtmlSimpleFloat popupWindow,
                              DomEvent nativeEvent,
                              string eventTargetSubId)

Parameters:
popupWindow  -  window controller
nativeEvent  -  mouse down event that starts the drag
eventTargetSubId  -  the subid of the event target; used to determine the drag direction
Return:
void - null

SUMMARY: FIELD | CONSTR | METHOD    DETAIL: FIELD | CONSTR | METHOD

 

Generated on 2011.04.05 23:36 UTC
Copyright (c) 1998, 2011, Oracle and/or its affiliates. All rights reserved.