}
public void webWindowClosed(WebWindowEvent event) {
// Check if the event window refers to us or one of our parent windows
// setup the currentWindow appropriately if necessary
WebWindow curr = currentWindow;
do {
// Instance equality is okay in this case
if (curr == event.getWebWindow()) {
currentWindow = currentWindow.getTopWindow();
return;
}
curr = curr.getParentWindow();
} while (curr != currentWindow.getTopWindow());
}
});
// Now put us on the home page, like a real browser