Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.mozilla.jrex.window
Class JRexWindowManagerImpl

    java.lang.Object
      org.mozilla.jrex.window.JRexWindowManagerImpl

All Implemented Interfaces:
  JRexWindowManager

public class JRexWindowManagerImpl
extends Object
implements JRexWindowManager

Class implementing JRexWindowManager interface.

Version:
  1.0
Author:
  C.N.Medappa
See Also:
  `JRexWindowManager`

Field Summary

Fields inherited from interface org.mozilla.jrex.window.JRexWindowManager
`FORCED_TAB_MODE, INTERNAL_PANE_MODE, SINGLE_WINDOW_MODE, TAB_MODE, WINDOW_MODE`

Constructor Summary
`JRexWindowManagerImpl()` Don't use this function to create a windomanager instance use JRexFactory.

Method Summary
`void` | `addJRexWindowListener(WindowListener wl)` Invoked to add JRex WindowListener, which helps in hooking up for window create/destroy request.
`void` | `addWindow(JRexCanvas browserComp, Container parent, Container rootParent, Window window, long chromeFlags)` Used to add a window into window manger list of created windows.
`void` | `create(int mode)` Window manager creation function.
`int` | `createWindow(WindowEvent event)` Invoked when an window create request is received.
`void` | `destroyTab(int peerWindow)` Invoked to remove a tab.
`void` | `destroyWindow(WindowEvent event)` Invoked when an window destroy request is received.
`void` | `dispose()` Invoked to dispose the window manager with all its child windows.
`JRexCanvas` | `getBrowser(int peerWindow)` Finds and returns the JRexCanvas assocciated with given peer window.
`JRexBrowserData` | `getBrowserData(int peerWindow)` Finds and returns the JRexBrowserData assocciated with given peer window.
`JRexCanvas` | `getBrowserForParent(Container parent)` Finds and returns the JRexCanvas assocciated with given parent.
`Iterator` | `getBrowserForRootParent(Container rootParent)` Finds and returns the list of JRexCanvas assocciated with given rootParent.
`Iterator` | `getBrowserForWindow(Window window)` Finds and returns the list of JRexCanvas assocciated with given window.
`Container` | `getBrowserParent(int peerWindow)` Finds and returns the Container assocciated with given peer window.
`Container` | `getBrowserRootParent(int peerWindow)` Finds and returns the Root Container assocciated with given peer window.
`Window` | `getBrowserWindow(int peerWindow)` Finds and returns the Window assocciated with given peer window.
`void` | `init(JComponent parentComponent)` Window manager intialization function, window manager should be created before calling initialize function.
`void` | `openNewTab(int parentPeer, String uri, int loadFlags)` Invoked when an open new tab request is received.
`void` | `openNewWindow(int parentPeer, String uri, int loadFlags)` Invoked when an open new window request is received.
`void` | `removeJRexWindowListener()` Invoked to remove JRex WindowListener.
`void` | `removeWindow(int peerWindow)` Used to remove a window from window manger list of created windows.
`void` | `setChromeFlags(WindowEvent event)` Invoked when an chrome flags for a window needs to be changed.
`void` | `setModal(WindowEvent event)` Invoked when an dialog needs to be made modal.
`void` | `setRealized(WindowEvent event)` Invoked when jrex native implementation realizes the browser window.
`void` | `setSize(WindowEvent event)` Invoked when an window size needs to be changed.
`void` | `setTitle(WindowEvent event)` Invoked when an window title needs to be changed.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### JRexWindowManagerImpl

    public JRexWindowManagerImpl()

  Don't use this function to create a windomanager instance use JRexFactory.

See Also:
  `JRexFactory`

Method Detail

### create

    public void create(int mode)

  Description copied from interface: `JRexWindowManager`
  Window manager creation function.

  Specified by:
    `create` in interface `JRexWindowManager`
  Parameters:
    `mode` - The mode which the window manager should use.

### init

    public void init(JComponent parentComponent)

  Description copied from interface: `JRexWindowManager`
  Window manager intialization function, window manager should be created before calling initialize function.

  Specified by:
    `init` in interface `JRexWindowManager`
  Parameters:
    `parentComponent` - The parent component where the jrex browser will be attached. The `parentComponent` should already have a parent window, ie, `parentComponent` should be added to a Frame/Dialog/Window before being passed to init function. If `null` is passed a new JFrame window will be used.

### openNewWindow

    public void openNewWindow(int parentPeer,
                              String uri,
                              int loadFlags)

  Description copied from interface: `JRexWindowManager`
  Invoked when an open new window request is received. The action taken depends on the mode of the window manager.

  Specified by:
    `openNewWindow` in interface `JRexWindowManager`
  Parameters:
    `parentPeer` - the parent peer window ID which invoked this function, Usage depends on window manager mode
    `uri` - the URI to open.
    `loadFlags` - the load flags to use for loading the URI.
  See Also:
    `WebNavigationConstants`

### openNewTab

    public void openNewTab(int parentPeer,
                           String uri,
                           int loadFlags)

  Description copied from interface: `JRexWindowManager`
  Invoked when an open new tab request is received. The action taken depends on the mode of the window manager.

  Specified by:
    `openNewTab` in interface `JRexWindowManager`
  Parameters:
    `parentPeer` - the parent peer window ID which invoked this function, Usage depends on window manager mode
    `uri` - the URI to open.
    `loadFlags` - the load flags to use for loading the URI.
  See Also:
    `WebNavigationConstants`

### createWindow

    public int createWindow(WindowEvent event)

  Description copied from interface: `JRexWindowManager`
  Invoked when an window create request is received.

  Specified by:
    `createWindow` in interface `JRexWindowManager`

### addWindow

    public void addWindow(JRexCanvas browserComp,
                          Container parent,
                          Container rootParent,
                          Window window,
                          long chromeFlags)

  Description copied from interface: `JRexWindowManager`
  Used to add a window into window manger list of created windows.

  Specified by:
    `addWindow` in interface `JRexWindowManager`
  Parameters:
    `browserComp` - the browser component associated window.
    `parent` - the Container containing the browser component.
    `rootParent` - the rootContainer containing the browser component, like the content pane of JFrame or can be parent itself or
    `window` - the window containing the browser component.
    `chromeFlags` - the Chrome Flags for the window.

### removeWindow

    public void removeWindow(int peerWindow)

  Description copied from interface: `JRexWindowManager`
  Used to remove a window from window manger list of created windows.

  Specified by:
    `removeWindow` in interface `JRexWindowManager`
  Parameters:
    `peerWindow` - the peer window ID for the window.

### setModal

    public void setModal(WindowEvent event)

  Description copied from interface: `JRexWindowManager`
  Invoked when an dialog needs to be made modal.

  Specified by:
    `setModal` in interface `JRexWindowManager`

### setSize

    public void setSize(WindowEvent event)

  Description copied from interface: `JRexWindowManager`
  Invoked when an window size needs to be changed.

  Specified by:
    `setSize` in interface `JRexWindowManager`

### setTitle

    public void setTitle(WindowEvent event)

  Description copied from interface: `JRexWindowManager`
  Invoked when an window title needs to be changed.

  Specified by:
    `setTitle` in interface `JRexWindowManager`

### setChromeFlags

    public void setChromeFlags(WindowEvent event)

  Description copied from interface: `JRexWindowManager`
  Invoked when an chrome flags for a window needs to be changed. Chrome flags help in identifying the type of window to be opened.

  Specified by:
    `setChromeFlags` in interface `JRexWindowManager`

### setRealized

    public void setRealized(WindowEvent event)

  Description copied from interface: `JRexWindowManager`
  Invoked when jrex native implementation realizes the browser window. Used to indicate Java implementation about the realization so the event listeners can be added.

  Specified by:
    `setRealized` in interface `JRexWindowManager`

### destroyWindow

    public void destroyWindow(WindowEvent event)

  Description copied from interface: `JRexWindowManager`
  Invoked when an window destroy request is received.

  Specified by:
    `destroyWindow` in interface `JRexWindowManager`

### destroyTab

    public void destroyTab(int peerWindow)

  Description copied from interface: `JRexWindowManager`
  Invoked to remove a tab. The action taken depends on the mode of the window manager.

  Specified by:
    `destroyTab` in interface `JRexWindowManager`
  Parameters:
    `peerWindow` - the peer browser ID for the tab.

### getBrowser

    public JRexCanvas getBrowser(int peerWindow)

  Description copied from interface: `JRexWindowManager`
  Finds and returns the JRexCanvas assocciated with given peer window.

  Specified by:
    `getBrowser` in interface `JRexWindowManager`

### getBrowserForWindow

    public Iterator getBrowserForWindow(Window window)

  Description copied from interface: `JRexWindowManager`
  Finds and returns the list of JRexCanvas assocciated with given window.

  Specified by:
    `getBrowserForWindow` in interface `JRexWindowManager`

### getBrowserForRootParent

    public Iterator getBrowserForRootParent(Container rootParent)

  Description copied from interface: `JRexWindowManager`
  Finds and returns the list of JRexCanvas assocciated with given rootParent.

  Specified by:
    `getBrowserForRootParent` in interface `JRexWindowManager`

### getBrowserForParent

    public JRexCanvas getBrowserForParent(Container parent)

  Description copied from interface: `JRexWindowManager`
  Finds and returns the JRexCanvas assocciated with given parent.

  Specified by:
    `getBrowserForParent` in interface `JRexWindowManager`

### getBrowserParent

    public Container getBrowserParent(int peerWindow)

  Description copied from interface: `JRexWindowManager`
  Finds and returns the Container assocciated with given peer window.

  Specified by:
    `getBrowserParent` in interface `JRexWindowManager`

### getBrowserRootParent

    public Container getBrowserRootParent(int peerWindow)

  Description copied from interface: `JRexWindowManager`
  Finds and returns the Root Container assocciated with given peer window.

  Specified by:
    `getBrowserRootParent` in interface `JRexWindowManager`

### getBrowserWindow

    public Window getBrowserWindow(int peerWindow)

  Description copied from interface: `JRexWindowManager`
  Finds and returns the Window assocciated with given peer window.

  Specified by:
    `getBrowserWindow` in interface `JRexWindowManager`

### getBrowserData

    public JRexBrowserData getBrowserData(int peerWindow)

  Description copied from interface: `JRexWindowManager`
  Finds and returns the JRexBrowserData assocciated with given peer window.

  Specified by:
    `getBrowserData` in interface `JRexWindowManager`

### addJRexWindowListener

    public void addJRexWindowListener(WindowListener wl)

  Description copied from interface: `JRexWindowManager`
  Invoked to add JRex WindowListener, which helps in hooking up for window create/destroy request.

  Specified by:
    `addJRexWindowListener` in interface `JRexWindowManager`

### removeJRexWindowListener

    public void removeJRexWindowListener()

  Description copied from interface: `JRexWindowManager`
  Invoked to remove JRex WindowListener.

  Specified by:
    `removeJRexWindowListener` in interface `JRexWindowManager`

### dispose

    public void dispose()

  Description copied from interface: `JRexWindowManager`
  Invoked to dispose the window manager with all its child windows.

  Specified by:
    `dispose` in interface `JRexWindowManager`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2004 C.N.Medappa. All Rights Reserved.