public class nUIWebviewElement extends nUIElementDisplay
Y_IDENTIFIER_PREV_BOTTOM
COLOR_BACKGROUND_NORMAL, COLOR_BLACK, COLOR_FOREGROUND_DARK, COLOR_FOREGROUND_LIGHT, COLOR_FOREGROUND_NORMAL, COLOR_TRANSPARENT, COLOR_WHITE, DIMENSIONS_IDENTIFIER_PARENT_DIMENSIONS
event_listener, event_listener_exclusive, first_child, last_child, next_sibling, nuiid, parent, prev_sibling, unlink_children_on_removal_from_parent
Constructor and Description |
---|
nUIWebviewElement(int nuiid) |
Modifier and Type | Method and Description |
---|---|
java.lang.String |
callJavaScript(java.lang.String method,
java.lang.String[] parameters)
Evaluate some JavaScript on this page.
|
void |
callJavaScript(java.lang.String method,
java.lang.String[] parameters,
IJSCallback callback)
Evaluate some JavaScript on this page.
|
boolean |
getHscrollable()
Determine whether this web element will scroll horizontally.
|
boolean |
getVscrollable()
Determine whether this web element will scroll vertically.
|
boolean |
isOverscrollingEnabled()
Determine if overscrolling is enabled on this nUIWebviewElement.
|
boolean |
isScaleToFitEnabled()
Determine if this nUIWebviewElement will attempt to scale HTML content to fit the page.
|
boolean |
registerCallBack(nUIWebviewCallBack callback)
Register a callback to process url requests from this webview.
|
void |
reload()
Reload the current document.
|
void |
renderInternal(javax.microedition.lcdui.Graphics g,
int x,
int y,
int width,
int height,
int parent_inner_x,
int parent_inner_y,
int parent_inner_width,
int parent_inner_height,
boolean webviewTop) |
void |
setBgcolor(int bgcolor)
Sets the background colour of this nUIWebviewElement.
|
com.softwareag.mobile.runtime.nui.IWebviewElement |
setDelegate(com.softwareag.mobile.runtime.nui.IWebviewElement delegate)
Sets new delegate
|
void |
setFocus(boolean focus) |
void |
setHscrollable(boolean hscrollable)
Sets whether this web element should be allowed to scroll horizontally.
|
void |
setHTMLText(java.lang.String html_data)
Sets the content of the page directly by passing in raw html.
|
void |
setOverscrollingEnabled(boolean overscrollingEnabled)
Enable or disable overscrolling when reaching the end of the content of this
nUIWebviewElement (sometimes called "bouncing").
|
void |
setScaleToFitEnabled(boolean scaleToFitEnabled)
Enable or disable scaling web content to fit the page (if available).
|
void |
setURL(java.lang.String url)
Sets the current URL to visit.
|
void |
setVscrollable(boolean vscrollable)
Sets whether this web element should be allowed to scroll vertically.
|
getY, insertAt
getBackgroundDrawable, getBgcolor, getBottom, getFocus, getFocusable, getGesturable, getHeight, getInnerHeight, getInnerWidth, getInnerX, getInnerY, getLeft, getMaxChildX, getMaxChildY, getRight, getScreenInnerX, getScreenInnerY, getScreenX, getScreenY, getTop, getTopLevelParentView, getTopLevelParentWindow, getTriggerable, getWidth, getX, insertAtInternal, isEnabled, onRemoved, remove, setBackgroundDrawable, setBottom, setChildFocus, setEnabled, setFocus, setFocusable, setGesturable, setHeight, setInnerHeight, setInnerWidth, setInnerX, setInnerY, setLeft, setRight, setTop, setTriggerable, setWidth, setX, setY
add, addEventListener, childElementAt, childIndexOf, getTag, insertAfter, insertBefore, outputChildHierarchy, remove, removeEventListener, replace, replace, setTag
public com.softwareag.mobile.runtime.nui.IWebviewElement setDelegate(com.softwareag.mobile.runtime.nui.IWebviewElement delegate)
public void setURL(java.lang.String url)
url
- the url to load nowpublic void reload()
public void setHTMLText(java.lang.String html_data)
html_data
- public void setHscrollable(boolean hscrollable)
hscrollable
- true if scrolling should be allowed.public boolean getHscrollable()
public void setVscrollable(boolean vscrollable)
vscrollable
- true to enable scrolling.public boolean getVscrollable()
public boolean registerCallBack(nUIWebviewCallBack callback)
callback
- the nUIWebviewCallBack
to register,
or null
to remove the existing callback.public java.lang.String callJavaScript(java.lang.String method, java.lang.String[] parameters)
method
- The name of the JavaScript method to call, e.g. "myMethod".parameters
- String constants that should be passed to the method to be called, in order.public void callJavaScript(java.lang.String method, java.lang.String[] parameters, IJSCallback callback)
method
- The name of the JavaScript method to call, e.g. "myMethod".parameters
- String constants that should be passed to the method to be called, in order.callback
- The callback that will be notified when evaluation completes.public void setBgcolor(int bgcolor)
setBgcolor
in class nUIDisplayObject
bgcolor
- an ARGB color.public void setOverscrollingEnabled(boolean overscrollingEnabled)
overscrollingEnabled
- indicates if overscrolling is enabled or not.public boolean isOverscrollingEnabled()
public void setScaleToFitEnabled(boolean scaleToFitEnabled)
scaleToFitEnabled
- indicates if scaling to fit is enabled or not.public boolean isScaleToFitEnabled()
public void renderInternal(javax.microedition.lcdui.Graphics g, int x, int y, int width, int height, int parent_inner_x, int parent_inner_y, int parent_inner_width, int parent_inner_height, boolean webviewTop)
public void setFocus(boolean focus)