| PREV CLASS Documentation homepage NEXT CLASS |
IlvObject
|
+--IlvEmptyView
|
+--IlvGlassView
IlvGlassView is an extension of IlvEmptyView
that is designed to capture keyboard and mouse input events and forward them
to an event handler. By default, an IlvGlassView is transparent.
Therefore, you can place a glass view above other content as a way to
trap user input events. | Constructor Summary | |
|---|---|
IlvGlassView(left, top, width, height)
|
|
| Method Summary | |
|---|---|
childrenToHTML()
Creates the HTML for this component's children. |
|
dispose()
Disposes of all resources being used by the view. |
|
enhanceEvent(e, forceClone)
This method returns an Event suitable for the IlvGlassView |
|
getContent()
Returns the HTML content of the glass view. |
|
getCursor()
Returns the cursor of the view. |
|
getEventHandler()
Returns the event handler that is receiving keyboard and mouse events from this view. |
|
getEventOriginLeft()
Returns the origin along the x-axis that is used to compute the relative e.mouseX coordinate when mouse events are forwarded to the event
handler. |
|
getEventOriginTop()
Returns the origin along the y-axis that is used to compute the relative e.mouseY coordinate when mouse events are forwarded to the event
handler. |
|
getHTMLId()
Returns the ID of the HTML element that represents the IlvGlassView in the HTML document. |
|
getToolTipText()
Returns the tooltip text of the view. |
|
isEnabled()
Returns whether the view is enabled. |
|
isVisible()
Returns the visibility of this view. |
|
setBackgroundColor(color)
Sets the background color of the glass view. |
|
setChildrenBounds(left, top, width, height)
Changes the size of this view's children. |
|
setContent(content, onContentSet)
Sets the HTML content of the glass view. |
|
setCursor(cursor)
Changes the cursor of the view. |
|
setEnabled(enabled)
Enables or disables the view. |
|
setEventHandler(eventHandler)
Sets the event handler that will receive keyboard and mouse events from this view. |
|
setToolTipText(string)
Sets the tooltip text of the view. |
|
setVisible(visible)
Sets the visibility of this view. |
|
setZIndex(zindex)
Change the Z coordinate of the view |
|
| Constructor Detail |
IlvGlassView(left, top, width, height)
| Method Detail |
childrenToHTML()
IlvGlassView's internal implementation
and is not a public API. dispose()
IlvObject.callDispose() function on the onunload event
of the page:
<body onunload="IlvObject.callDispose()">
enhanceEvent(e, forceClone)
Event suitable for the IlvGlassView
coordinate system from the given Event coming from the browser
event system. The new coordinate are stored in mouseX and
mouseY properties of the returned event. e - The mouse EventforceClone - true to force the cloning of the event.getContent()
IlvConstants.ilvImagePath + "empty.gif", where
IlvConstants.ilvImagePath = "script/images/". getCursor()
getEventHandler()
getEventOriginLeft()
e.mouseX coordinate when mouse events are forwarded to the event
handler. This implementation returns the left coordinate of this glass view.
Override this function to forward mouse events that are relative to a different
origin. getEventOriginTop()
e.mouseY coordinate when mouse events are forwarded to the event
handler. This implementation returns the top coordinate of this glass view.
Override this function to forward mouse events that are relative to a different
origin. getHTMLId()
IlvGlassView in the HTML document.
getToolTipText()
isEnabled()
isVisible()
setBackgroundColor(color)
color - A string describing the color.
For example, "#FFFFFF" corresponds to white.setChildrenBounds(left, top, width, height)
IlvGlassView's internal implementation
and is not a public API. left - The absolute x position of the view on the page.top - The absolute y position of the view on the page.width - The width of the view.height - The height of the view.setContent(content, onContentSet)
IlvConstants.ilvImagePath + "empty.gif", where
IlvConstants.ilvImagePath = "script/images/". onContentSet - An optional JavaScript fragment that will be evaluated
after the browser's DOM has stabilized from the changes made by this method.setCursor(cursor)
cursor - The cursor name.setEnabled(enabled)
setEventHandler(eventHandler)
keyPress(e) handles Key press events.e - The key event with the following read-only properties:
e.type: A string representing the event type.
e.keyCode: The code of the key.
mouseMove(e) handles Mouse move events.e - The mouse event with 8 read-only properties:
e.type: A string representing the event type.
e.mouseX: The mouse X coordinate relative to the value returned by the getEventOriginLeft function.
e.mouseY: The mouse Y coordinate relative to the value returned by the getEventOriginTop function.
e.screenX: The absolute mouse X coordinate in the screen.
e.screenY: The absolute mouse Y coordinate in the screen.
e.altKey: A Boolean, true when the ALT key is pressed.
e.ctrlKey: A Boolean, true when the CONTROL key is pressed.
e.shiftKey: A Boolean, true when the SHIFT key is pressed.
mouseDown(e) handles Mouse down events.e - The mouse event with 8 read-only properties:
e.type: A string representing the event type.
e.mouseX: The mouse X coordinate relative to the value returned by the getEventOriginLeft function.
e.mouseY: The mouse Y coordinate relative to the value returned by the getEventOriginTop function.
e.screenX: The absolute mouse X coordinate in the screen.
e.screenY: The absolute mouse Y coordinate in the screen.
e.altKey: A Boolean, true when the ALT key is pressed.
e.ctrlKey: A Boolean, true when the CONTROL key is pressed.
e.shiftKey: A Boolean, true when the SHIFT key is pressed.
mouseDrag(e) handles Mouse drag events.e - The mouse event with 8 read-only properties:
e.type: A string representing the event type.
e.mouseX: The mouse X coordinate relative to the value returned by the getEventOriginLeft function.
e.mouseY: The mouse Y coordinate relative to the value returned by the getEventOriginTop function.
e.screenX: The absolute mouse X coordinate in the screen.
e.screenY: The absolute mouse Y coordinate in the screen.
e.altKey: A Boolean, true when the ALT key is pressed.
e.ctrlKey: A Boolean, true when the CONTROL key is pressed.
e.shiftKey: A Boolean, true when the SHIFT key is pressed.
mouseUp(e) handles Mouse up events.e - The mouse event with 8 read-only properties:
e.type: A string representing the event type.
e.mouseX: The mouse X coordinate relative to the value returned by the getEventOriginLeft function.
e.mouseY: The mouse Y coordinate relative to the value returned by the getEventOriginTop function.
e.screenX: The absolute mouse X coordinate in the screen.
e.screenY: The absolute mouse Y coordinate in the screen.
e.altKey: A Boolean, true when the ALT key is pressed.
e.ctrlKey: A Boolean, true when the CONTROL key is pressed.
e.shiftKey: A Boolean, true when the SHIFT key is pressed.
mouseOver(e) handles Mouse over events.e - The mouse event with 8 read-only properties:
e.type: A string representing the event type.
e.mouseX: The mouse X coordinate relative to the value returned by the getEventOriginLeft function.
e.mouseY: The mouse Y coordinate relative to the value returned by the getEventOriginTop function.
e.screenX: The absolute mouse X coordinate in the screen.
e.screenY: The absolute mouse Y coordinate in the screen.
e.altKey: A Boolean, true when the ALT key is pressed.
e.ctrlKey: A Boolean, true when the CONTROL key is pressed.
e.shiftKey: A Boolean, true when the SHIFT key is pressed.
mouseOut(e) handles Mouse out events.e - The mouse event with 8 read-only properties:
e.type: A string representing the event type.
e.mouseX: The mouse X coordinate relative to the value returned by the getEventOriginLeft function.
e.mouseY: The mouse Y coordinate relative to the value returned by the getEventOriginTop function.
e.screenX: The absolute mouse X coordinate in the screen.
e.screenY: The absolute mouse Y coordinate in the screen.
e.altKey: A Boolean, true when the ALT key is pressed.
e.ctrlKey: A Boolean, true when the CONTROL key is pressed.
e.shiftKey: A Boolean, true when the SHIFT key is pressed.
mouseWheel(e) handles Mouse wheel events.e - The mouse event with the following read-only property:
e.wheelDelta: The amount of scrolling: This value is positive if the mouse wheel was scrolled up and negative otherwise.
This amount depends on the mouse configuration and on the browser.
eventHandler - The handler that will receive events from this glass
view.setToolTipText(string)
string - A string.setVisible(visible)
setZIndex(zindex)
| Inherited Methods from IlvEmptyView |
| Inherited Methods from IlvObject |
| PREV CLASS Documentation homepage NEXT CLASS |