WHITE PAPERS  |  PRICING  |  DOWNLOADS

 

username

password

 

 

 

 

 

 

 

 

 

 

  Desktop Edition Details  

 

  > Features  

  > Key Benefits  

  > Screenshots  

  > Standards Supported  

  > Pricing  

  > Download Now

 

 

  Developer Resources  

 

  > API Documentation  

  > Developers Guide  

  > Code Examples  

  > Updated Builds  

  > Technical Articles  

 

 

 

 

 

Jump to:

General WebRenderer Functions

  WebRenderer example code base.

 

Advanced WebRenderer functions

 

Application test examples

 

Deploying WebRenderer

WebRenderer DOM

  

  

 

Handling Popup windows in WebRenderer

 

 

 

Capturing and customizing popup windows

The WebRenderer Window Event class makes available Events for the handling and customization of popup windows. The Window Events class makes available handles to the popup window browser objects. The Window Event class also has methods for capturing popup window resize and destroy events.

browser.addWindowListener(new com.webrenderer.event.WindowListener() {
       // Fired when a popup window is to be displayed
       public void onNewWindow(com.webrenderer.event.WindowEvent e) {
                 // If this event is captured you must handle the display of the popup window
                 IBrowserCanvas browser = e.getPopupBrowser();
                 // The browser can then be placed into a JFrame and displayed. This is useful for customizing popups.
       }
       // Fired when the Window receives a resize event
       public void onWindowResize(com.webrenderer.event.WindowEvent e) {
                 System.out.println("Browser resize event: - Width: " + e.getWidth() + " and Height: " + e.getHeight() );
       }
       // Fired when the browser window is destroyed
       public void onWindowDestroy(com.webrenderer.event.WindowEvent e) {
                 System.out.println("Browser Window destroyed");
       }
});

  top

 

 

 Sun, Sun Microsystems, and the Sun Logo are trademarks or registered trademarks of Sun Microsystems, Inc. in the United States and other countries 

Privacy Policy  |   Disclaimer