# JavaScript API Reference for Oracle ADF Faces

Overview | Package | Class | Tree | Deprecated | Index | Help
| Oracle® Fusion Middleware Javascript API Reference for Oracle ADF Faces 12c (12.2.1.4.0) E81451-01
PREV NEXT | FRAMES NO FRAMES Warning: private items are visible |

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

# oracle.adfinternal.view.js.agent.gecko
Class AdfGeckoAgent

## Warning:

- This is an unsupported, internal implementation class.
- Use an API class that might provide equivalent functionality instead.
- This class will change without notice.
- It is not recommended that you use anything in this class.

    org.ecmascript.object.Object
       |
       +--oracle.adf.view.js.base.AdfObject
             |
             +--oracle.adf.view.js.agent.AdfAgent
                   |
                   +--oracle.adfinternal.view.js.agent.gecko.AdfGeckoAgent

Direct Known Subclasses:
  AdfGecko5Agent

    public class AdfGeckoAgent
    extends AdfAgent

Gecko AdfAgent AdfAgent capabilities.

## Field Summary
`private static Object` | `_CSS_TO_DOM_MAP` Maps the CSS property name to DOM property name.
`private static Object` | `_FAKE_MOUSEMOVE_EVENT`
`private Object` | `_ID_TO_DOM_MAP`
`private static Object` | `_MOZ_USER_DEFINED`

### Fields inherited from oracle.adf.view.js.agent.AdfAgent
`ANDROID_OS, CAP_TOUCH_SCREEN, CAP_TOUCH_SCREEN_MULTIPLE, CAP_TOUCH_SCREEN_NONE, CAP_TOUCH_SCREEN_SINGLE, DRAG_GHOST_STYLECLASS, EDGE_PLATFORM, GECKO_PLATFORM, IE_PLATFORM, KEY_EVENTS, MAC_OS, OPERA_PLATFORM, REDISTRIBUTE_EVENTS, SOLARIS_OS, UNKNOWN_OS, UNKNOWN_PLATFORM, WEBKIT_PLATFORM, WINDOWS_OS`

### Fields inherited from oracle.adf.view.js.base.AdfObject
`constructor, superclass`

### Fields inherited from org.ecmascript.object.Object
`prototype`

## Constructor Summary
`public` | `AdfGeckoAgent(Object version, Object domWindow)` Gecko AdfAgent AdfAgent capabilities.

## Method Summary
`public Object` | `addEventBubbles(Object node, Object listener)` Override to reset throbber via iframe and add focus and blur as capture events
`public Object` | `allElementsRemoved()` Resets any id->element cache when all elements are removed This method should be called AFTER the elements are removed
`public boolean` | `atLeast(Object platform, Object version)` Overridden from the base agent to handle the fully qualifed Gecko version.
`public Object` | `cloneEvent(Object event, Object newTarget)` Returns a new Event Object, based on a current event, retargetted to the new target.
`private Object` | `_copyKeyboardEvent(Object event, Object eventType, Object newTarget)`
`protected Object` | `CreateDefaultLogWriter(Object nativeLogWriter)` Creates and returns the default AdfLogWriter to use for this AdfPage.
`protected Object` | `CreateNativeLogWriter()` Override to return an AdfLogWriter that writes to the Gecko console
`protected Object` | `CreateUIInputEvent(Object component, Object type, Object nativeEvent)`
`public Object` | `disableUserSelect(Object element)` Disable the user's ability to select text in this component
`public Object` | `elementsAdded(Object node)` Updates any id->element cache by adding the elements in the specified subtree
`public Object` | `elementsRemoved(Object node)` Updates any id->element cache by removing the elements in the specified subtree
`public Object` | `enableUserSelect(Object element)` Enable the user's ability to select text in this component
`static Float` | `__getAgentVersion(Object userAgent)` Checks the user agent string returning the current browser version.
`private static Object` | `_getBoxObjectFor(Object elem)`
`public String` | `getBoxSizing(HTMLElement element, CSSStyleDeclaration currentStyle)` Returns the box model associated with an element (http://www.w3.org/TR/css3-ui/#box-sizing)
`protected Object` | `GetCssToDomPropertyNameMap()` Returns the map which contains the CSS property name and it's DOM version.
`public Object` | `getElementById(Object id)` Cover function to allow more performant implementations of document.getElementById()
`public Object` | `getKeyCode(Object keyEvent)` Returns the unicode key code for the given key event.
`public Object` | `getMaxConnectionsPerDomain()` Gets the maximum number of simultaneous connections allowed per domain by the client
`public Object` | `getNodeType(Object element)` Override due to a bug in FF
`private Object` | `_getSessionStorageKey(Object propKey)` Returns a propKey prefixed by the current protocol used.
`static String` | `__getSpecificAgentClassName(Object userAgent, Object version)` Returns the specific agent class name that should be instantiated for this user agent string.
`static Boolean` | `__getSupported(Object userAgent, Object version)` Checks if this browser is supported.
`public Number` | `getWindowClientHeight(Window domWindow)` Returns the client (or inner) height of the DOM window Object
`public Number` | `getWindowClientWidth(Window domWindow)` Returns the client (or inner) width of the DOM window Object
`protected Object` | `Init(Object version, Object domWindow)` Initializes the instance.
`protected static Object` | `InitClass()`
`public Boolean` | `isChromeEvent(Event domEvent)` Returns `true` if the event was on the element chrome
`public Object` | `isDragPrepEvent(Object componentEvent)` Override to not start drags on scrollbars
`public Object` | `isElementHTML(Object element)`
`public Object` | `isFunctionKey(Object keyEvent)` Returns whether the event's keycode should be considered as a function key.
`public Object` | `isLeftButtonClick(Object evt)` Tests whether event is a left button click event.
`public Object` | `pointInElementBounds(Object element, Object pageX, Object pageY)` Returns true if the specified point in page space is in the bounds of this element
`public Object` | `pointInElementOrChildBounds(HTMLElement element, Number pageX, Number pageY)` Returns true if the specified point in page space is in the bounds of this element or one of its non-absolute children elements.
`public Object` | `removeEventBubbles(Object node, Object listener)` Removes event bubbles for all of the events that the Rich client framework is interested in from the relevant element using the specified listener
`public Object` | `removeIdsFromDomSubTree(HTMLElement subTreeRoot)` Removes all of the ID values from every element in the given DOM sub tree.
`private static Object` | `_resetThrobber(Object event)`
`public Object` | `setButtonTextContent(Object node, Object newText)` Override to avoid Gecko bug.
`public Object` | `setImageSource(Object img, Object src)` Sets the image source.
`public Object` | `setImageTooltip(Object img, Object tooltip)` Gecko needs the tooltip on the "title" attribute.
`public Object` | `showBusyCursor(Object ownerDocument, Object show)` Displays busy/default cursor.
`public Object` | `slice(Object file, Object startByte, Object stopByte)` For agents which support the File API, slices the File.

### Methods inherited from oracle.adf.view.js.agent.AdfAgent
`addBubbleEventListener, addEventCaptures, addKeyEventListener, addOption, addResizeListener, autoCompleteForm, beginDirtyStateTracking, checkMouseOutEvent, clearSubtreeIds, cloneNode, CopyDragSize, copyEvent, copyStyle, createContextMenuEventGenerator, createDefaultLogWriter, createDraggableNode, createStyle, createTouchMoveManager, createXmlDocument, createXMLHttpRequest, disableBrowserContextMenu, disableSelectionToggleOnEditableCell, dispatchEvent, eatEvent, eatEventCallback, elementFromPagePoint, endDirtyStateTracking, endDocumentKeyEventCapture, execScript, forceCursorChange, getAgent, getAgentClassNameFromAgentString, getAttribute, getAttributeName, getBooleanAttribute, getBrowserViewportScrollLeft, getBrowserViewportScrollTop, getCapabilities, getComponentEvent, getComputedStyle, getCSS2Cursor, getCSSLengthAsInt, getCursor, getDescendantComponentsForNode, getDomDocument, getDomForCSSPropertyName, getDomWindow, getElementLeft, getElementPageBounds, getElementPosition, getElementsByName, getElementTop, getEventFromElement, getEventTarget, getEventToElement, getExpandoProperty, getFormElement, getIntAttribute, getLocalName, getModifierDisplayName, getMousePosition, getNodeName, getNodeXml, getOrigin, getOS, getOuterHeight, getOuterWidth, getOverrideStyle, getPlatform, getPreferredKeyEventForRepetition, getPrefix, getScrollLeft, getSessionStorageProperty, getStyleProperty, getTableRow, getTableRowCells, getTableRows, getTextContent, GetTouchCapability, getVersion, getWindowHeight, getWindowScrollHeight, getWindowScrollWidth, getWindowWidth, guessOS, guessVersion, hasAttribute, installKeyboardBlocker, isAttributeSpecified, isClipped, IsComputedWidthAuto, isDefaultPrevented, isDirty, isDisabledOptionSupported, isEqualIcon, isEventInElement, isInlineDialogRepositioningOnScroll, isKeyboardEvent, isLeftButton, isMouseEvent, isSelectionToggle, isSessionStorageEnabled, isTouchFirstDevice, mapNativeToComponentEventType, modifyIdsInDomSubTree, parseXML, pointInElementChrome, prepareStretchedChild, preventDefault, preventDefaultCallback, removeBubbleEventListener, removeEventCaptures, removeKeyEventListener, removeResizeListener, removeSessionStorageProperty, removeStyleProperty, replaceNode, repositionStretchedElement, resizeStretchedChild, resizeStretchedElement, scrollToPos, setAttribute, setCssFloat, setCursor, setDirty, setExpandoProperty, setInstance, setOpacity, setOuterHeight, setOuterMaxHeight, setOuterMaxWidth, setOuterWidth, setScrollLeft, setSessionStorageProperty, setTableRowHeight, setTextContent, showTooltip, startDocumentKeyEventCapture, startMouseEventCapture, stopMouseEventCapture, stopPropagation, supportsTransientStyleClasses, toISOString`

### Methods inherited from oracle.adf.view.js.base.AdfObject
`adopt, clone, createCallback, createInitializedObject, createSubclass, ensureClassInitialization, equals, exportPrototypeSymbol, getClass, GetLazyArrayProperty, GetLazyMapProperty, getTypeName, toDebugString, toString`

## Field Detail

### _CSS_TO_DOM_MAP

`private static Object _CSS_TO_DOM_MAP`
  Maps the CSS property name to DOM property name.
  Overrides:
    `AdfAgent._CSS_TO_DOM_MAP`

### _FAKE_MOUSEMOVE_EVENT

`private static Object _FAKE_MOUSEMOVE_EVENT`

### _ID_TO_DOM_MAP

`private Object _ID_TO_DOM_MAP`

### _MOZ_USER_DEFINED

`private static Object _MOZ_USER_DEFINED`

## Constructor Detail

### AdfGeckoAgent

`public AdfGeckoAgent(Object version,
Object domWindow)`
  Gecko AdfAgent AdfAgent capabilities.
  Parameters:

    `version` |  |
    `domWindow` |  |

## Method Detail

### addEventBubbles

`public Object addEventBubbles(Object node,
Object listener)`
  Override to reset throbber via iframe and add focus and blur as capture events
  Parameters:

    `node` |  |
    `listener` |  |

  Return:
    `Object`
  Overrides:
    `AdfAgent.addEventBubbles(Object, Object)`

### allElementsRemoved

`public Object allElementsRemoved()`
  Resets any id->element cache when all elements are removed This method should be called AFTER the elements are removed
  Return:
    `Object`
  See also:
    `getElementById(Object)`
    `elementsAdded(Object)`
  Overrides:
    `AdfAgent.allElementsRemoved()`

### atLeast

`public boolean atLeast(Object platform,
Object version)`
  Overridden from the base agent to handle the fully qualifed Gecko version. The base agent only handles the first two digits of the Gecko Agent but the third differentiates FF 3.5 from prior versions ("Gecko 1.9.1" == FF 3.5). Passing a dot delimited string will compare against the full version versus just the first two digits.
  Parameters:

    `platform` |  |
    `version` |  |

  Return:
    `boolean` - null `true` if the `platform`
  Overrides:
    `AdfAgent.atLeast(Object, Object)`

### cloneEvent

`public Object cloneEvent(Object event,
Object newTarget)`
  Returns a new Event Object, based on a current event, retargetted to the new target. If no newTarget is specified, the event will be cloned with the current target.
  Parameters:

    `event` | - | Event to base the new event on
    `newTarget` | - | Optional DOM Node to retarget the event to

  Return:
    `Object`
  Overrides:
    `AdfAgent.cloneEvent(Event, HTMLElement)`

### _copyKeyboardEvent

`private Object _copyKeyboardEvent(Object event,
Object eventType,
Object newTarget)`
  Parameters:

    `event` |  |
    `eventType` |  |
    `newTarget` |  |

  Return:
    `Object`
  Overrides:
    `AdfAgent._copyKeyboardEvent(Object, Object, Object)`

### CreateDefaultLogWriter

`protected Object CreateDefaultLogWriter(Object nativeLogWriter)`
  Creates and returns the default AdfLogWriter to use for this AdfPage. Subclassers should override CreateDefaultLogWriter instead
  Parameters:

    `nativeLogWriter` |  |

  Return:
    `Object`
  Overrides:
    `AdfAgent.createDefaultLogWriter()`

### CreateNativeLogWriter

`protected Object CreateNativeLogWriter()`
  Override to return an AdfLogWriter that writes to the Gecko console
  Return:
    `Object`
  Overrides:
    `AdfAgent.CreateNativeLogWriter()`

### CreateUIInputEvent

`protected Object CreateUIInputEvent(Object component,
Object type,
Object nativeEvent)`
  Parameters:

    `component` |  |
    `type` |  |
    `nativeEvent` |  |

  Return:
    `Object`
  Overrides:
    `AdfAgent.CreateUIInputEvent(Object, Object, Object)`

### disableUserSelect

`public Object disableUserSelect(Object element)`
  Disable the user's ability to select text in this component
  Parameters:

    `element` |  |

  Return:
    `Object`
  Overrides:
    `AdfAgent.disableUserSelect(Object)`

### elementsAdded

`public Object elementsAdded(Object node)`
  Updates any id->element cache by adding the elements in the specified subtree
  Parameters:

    `node` | - | Either element or document node that is being added

  Return:
    `Object`
  See also:
    `getElementById(Object)`
    `elementsRemoved(Object)`
  Overrides:
    `AdfAgent.elementsAdded(Object)`

### elementsRemoved

`public Object elementsRemoved(Object node)`
  Updates any id->element cache by removing the elements in the specified subtree
  Parameters:

    `node` | - | Either element or document node that is being removed

  Return:
    `Object`
  See also:
    `getElementById(Object)`
    `elementsAdded(Object)`
  Overrides:
    `AdfAgent.elementsRemoved(Object)`

### enableUserSelect

`public Object enableUserSelect(Object element)`
  Enable the user's ability to select text in this component
  Parameters:

    `element` |  |

  Return:
    `Object`
  Overrides:
    `AdfAgent.enableUserSelect(Object)`

### __getAgentVersion

`static Float __getAgentVersion(Object userAgent)`
  Checks the user agent string returning the current browser version.
  Parameters:

    `userAgent` |  |

  Return:
    `Float` - version identified by the user agent string
  Overrides:
    `AdfAgent.__getAgentVersion(Object)`

### _getBoxObjectFor

`private static Object _getBoxObjectFor(Object elem)`
  Parameters:

    `elem` |  |

  Return:
    `Object`

### getBoxSizing

`public String getBoxSizing(HTMLElement element,
CSSStyleDeclaration currentStyle)`
  Returns the box model associated with an element (http://www.w3.org/TR/css3-ui/#box-sizing)
  Parameters:

    `element` | - | The element to check
    `currentStyle` | - | the current style that can be optionally passed in Default value = null

  Return:
    `String` - the box sizing, either "content-box" or "border-box"
  Overrides:
    `AdfAgent.getBoxSizing(HTMLElement, CSSStyleDeclaration)`

### GetCssToDomPropertyNameMap

`protected Object GetCssToDomPropertyNameMap()`
  Returns the map which contains the CSS property name and it's DOM version.
  Return:
    `Object`
  Overrides:
    `AdfAgent.GetCssToDomPropertyNameMap()`

### getElementById

`public Object getElementById(Object id)`
  Cover function to allow more performant implementations of document.getElementById()
  Parameters:

    `id` |  |

  Return:
    `Object`
  See also:
    `elementsRemoved(Object)`
    `elementsAdded(Object)`
  Overrides:
    `AdfAgent.getElementById(Object)`

### getKeyCode

`public Object getKeyCode(Object keyEvent)`
  Returns the unicode key code for the given key event.
  Parameters:

    `keyEvent` |  |

  Return:
    `Object`
  Overrides:
    `AdfAgent.getKeyCode(Object)`

### getMaxConnectionsPerDomain

`public Object getMaxConnectionsPerDomain()`
  Gets the maximum number of simultaneous connections allowed per domain by the client
  Return:
    `Object`
  Overrides:
    `AdfAgent.getMaxConnectionsPerDomain()`

### getNodeType

`public Object getNodeType(Object element)`
  Override due to a bug in FF
  Parameters:

    `element` |  |

  Return:
    `Object`
  Overrides:
    `AdfAgent.getNodeType(Object)`

### _getSessionStorageKey

`private Object _getSessionStorageKey(Object propKey)`
  Returns a propKey prefixed by the current protocol used. If protocol is undefined or null, it returns propKey.
  Parameters:

    `propKey` |  |

  Return:
    `Object`

### __getSpecificAgentClassName

`static String __getSpecificAgentClassName(Object userAgent,
Object version)`
  Returns the specific agent class name that should be instantiated for this user agent string.
  Parameters:

    `userAgent` |  |
    `version` |  |

  Return:
    `String` - specific agent class to be instantiated
  Overrides:
    `AdfAgent.__getSpecificAgentClassName(Object, Object)`

### __getSupported

`static Boolean __getSupported(Object userAgent,
Object version)`
  Checks if this browser is supported.
  Parameters:

    `userAgent` |  |
    `version` |  |

  Return:
    `Boolean` - supported
  Overrides:
    `AdfAgent.__getSupported(Object, Object)`

### getWindowClientHeight

`public Number getWindowClientHeight(Window domWindow)`
  Returns the client (or inner) height of the DOM window Object
  Parameters:

    `domWindow` |  |

  Return:
    `Number` - null
  Overrides:
    `AdfAgent.getWindowClientHeight(Window)`

### getWindowClientWidth

`public Number getWindowClientWidth(Window domWindow)`
  Returns the client (or inner) width of the DOM window Object
  Parameters:

    `domWindow` |  |

  Return:
    `Number` - null
  Overrides:
    `AdfAgent.getWindowClientWidth(Window)`

### Init

`protected Object Init(Object version,
Object domWindow)`
  Initializes the instance. Subclasses of AdfObject must call their superclass' Init
  Parameters:

    `version` |  |
    `domWindow` |  |

  Return:
    `Object`
  Overrides:
    `AdfObject.Init()`

### InitClass

`protected static Object InitClass()`
  Return:
    `Object`
  Overrides:
    `AdfAgent.InitClass()`

### isChromeEvent

`public Boolean isChromeEvent(Event domEvent)`
  Returns `true` if the event was on the element chrome
  Parameters:

    `domEvent` | - | The DOM event to check the original target of

  Return:
    `Boolean` - null `true` if the event was on the element chrome
  Overrides:
    `AdfAgent.isChromeEvent(Event)`

### isDragPrepEvent

`public Object isDragPrepEvent(Object componentEvent)`
  Override to not start drags on scrollbars
  Parameters:

    `componentEvent` |  |

  Return:
    `Object`
  Overrides:
    `AdfAgent.isDragPrepEvent(AdfComponentEvent)`

### isElementHTML

`public Object isElementHTML(Object element)`
  Parameters:

    `element` |  |

  Return:
    `Object`
  Overrides:
    `AdfAgent.isElementHTML(Object)`

### isFunctionKey

`public Object isFunctionKey(Object keyEvent)`
  Returns whether the event's keycode should be considered as a function key.
  Parameters:

    `keyEvent` |  |

  Return:
    `Object`
  Overrides:
    `AdfAgent.isFunctionKey(Object)`

### isLeftButtonClick

`public Object isLeftButtonClick(Object evt)`
  Tests whether event is a left button click event. Browsers may differ in whether they fire click events for right button clicks. This method provides a simple way to test whether a click event corresponds to a left button click.
  Parameters:

    `evt` |  |

  Return:
    `Object`
  Overrides:
    `AdfAgent.isLeftButtonClick(Event)`

### pointInElementBounds

`public Object pointInElementBounds(Object element,
Object pageX,
Object pageY)`
  Returns true if the specified point in page space is in the bounds of this element
  Parameters:

    `element` |  |
    `pageX` |  |
    `pageY` |  |

  Return:
    `Object`
  Overrides:
    `AdfAgent.pointInElementBounds(Object, Object, Object)`

### pointInElementOrChildBounds

`public Object pointInElementOrChildBounds(HTMLElement element,
Number pageX,
Number pageY)`
  Returns true if the specified point in page space is in the bounds of this element or one of its non-absolute children elements. This has a subtle implementation difference than pointInElementBounds for use cases when, in certain browsers, an element's bounds may not be stretched to reflect the bounds of its children.
  Parameters:

    `element` | - | The element to check
    `pageX` | - | The X coordinate of the location of the point on the page
    `pageY` | - | The Y coordinate of the location of the point on the page

  Return:
    `Object`
  See also:
    `pointInElementBounds(Object, Object, Object)`
  Overrides:
    `AdfAgent.pointInElementOrChildBounds(HTMLElement, Number, Number)`

### removeEventBubbles

`public Object removeEventBubbles(Object node,
Object listener)`
  Removes event bubbles for all of the events that the Rich client framework is interested in from the relevant element using the specified listener
  Parameters:

    `node` |  |
    `listener` |  |

  Return:
    `Object`
  Overrides:
    `AdfAgent.removeEventBubbles(Object, Object)`

### removeIdsFromDomSubTree

`public Object removeIdsFromDomSubTree(HTMLElement subTreeRoot)`
  Removes all of the ID values from every element in the given DOM sub tree.
  Parameters:

    `subTreeRoot` | - | the root of the sub tree to remove IDs from

  Return:
    `Object`
  Overrides:
    `AdfAgent.removeIdsFromDomSubTree(HTMLElement)`

### _resetThrobber

`private static Object _resetThrobber(Object event)`
  Parameters:

    `event` |  |

  Return:
    `Object`

### setButtonTextContent

`public Object setButtonTextContent(Object node,
Object newText)`
  Override to avoid Gecko bug.
  Parameters:

    `node` |  |
    `newText` |  |

  Return:
    `Object`
  Overrides:
    `AdfAgent.setButtonTextContent(Object, Object)`

### setImageSource

`public Object setImageSource(Object img,
Object src)`
  Sets the image source.
  Parameters:

    `img` |  |
    `src` |  |

  Return:
    `Object`
  Overrides:
    `AdfAgent.setImageSource(Object, Object)`

### setImageTooltip

`public Object setImageTooltip(Object img,
Object tooltip)`
  Gecko needs the tooltip on the "title" attribute.
  Parameters:

    `img` | - | the img element
    `tooltip` | - | the image tooltip

  Return:
    `Object`
  Overrides:
    `AdfAgent.setImageTooltip(Object, Object)`

### showBusyCursor

`public Object showBusyCursor(Object ownerDocument,
Object show)`
  Displays busy/default cursor.
  Parameters:

    `ownerDocument` | - | The document to display/hide the busy cursor on
    `show` | - | boolean for displaying busy cursor or not

  Return:
    `Object`
  Overrides:
    `AdfAgent.showBusyCursor(Object, Object)`

### slice

`public Object slice(Object file,
Object startByte,
Object stopByte)`
  For agents which support the File API, slices the File. If slice is not supported then returns undefined.
  Parameters:

    `file` |  |
    `startByte` |  |
    `stopByte` |  |

  Return:
    `Object`
  Overrides:
    `AdfAgent.slice(File, Number, Number)`

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

Overview | Package | Class | Tree | Deprecated | Index | Help
| Oracle® Fusion Middleware Javascript API Reference for Oracle ADF Faces 12c (12.2.1.4.0) E81451-01
PREV NEXT | FRAMES NO FRAMES Warning: private items are visible |

Copyright (c) 1998, 2018, Oracle and/or its affiliates. All rights reserved.