public class BrowserWindow extends Object
Modifier and Type | Class and Description |
---|---|
static class |
BrowserWindow.EvalRequest
A future that is returned from the eval() method.
|
Constructor and Description |
---|
BrowserWindow(String startURL)
Creates a new browser window with the given starting URL.
|
Modifier and Type | Method and Description |
---|---|
void |
addCloseListener(ActionListener l)
Adds listener to be notified when the browser window is closed.
|
void |
addLoadListener(ActionListener l)
Adds listeners to be notified when a page is loaded in the browser window.
|
void |
close()
Closes the browser window.
|
void |
removeCloseListener(ActionListener l)
Removes listener from being notified when the browser window is closed.
|
void |
removeLoadListener(ActionListener l)
Removes listeners from being notified when page is loaded in the browser window.
|
void |
setSize(int width,
int height)
Sets the size in pixels of the browser window.
|
void |
setTitle(String title)
Sets the window title for the browser window.
|
void |
show()
Shows the browser window.
|
public BrowserWindow(String startURL)
startURL
- The URL to start with.public void addLoadListener(ActionListener l)
l
- Listener to add.public void removeLoadListener(ActionListener l)
l
- public void setTitle(String title)
title
- The title for the window.public void setSize(int width, int height)
width
- The width in pixelsheight
- The height in pixelspublic void close()
public void addCloseListener(ActionListener l)
l
- public void removeCloseListener(ActionListener l)
l
- public void show()