Jitsi: the OpenSource Java VoIP and Instant Messaging client.

net.java.sip.communicator.service.gui
Class AbstractExportedWindow<T extends Window>

java.lang.Object
  extended by net.java.sip.communicator.service.gui.AbstractExportedWindow<T>
All Implemented Interfaces:
ExportedWindow

public abstract class AbstractExportedWindow<T extends Window>
extends Object
implements ExportedWindow


Field Summary
protected  T window
          The Window wrapped by this instance and to which ExportedWindow capabilities are provided.
 
Fields inherited from interface net.java.sip.communicator.service.gui.ExportedWindow
ABOUT_WINDOW, ADD_CONTACT_WINDOW, CHAT_WINDOW, MAIN_WINDOW
 
Constructor Summary
AbstractExportedWindow()
           
 
Method Summary
 void bringToFront()
          Brings the focus to this window.
protected abstract  T createWindow()
          Creates the Window instance to be wrapped by this instance and to which ExportedWindow capabilities are provided.
 Object getSource()
          The source of the window
protected  T getWindow()
          Gets the Window wrapped by this instance and to which ExportedWindow capabilities are provided.
 boolean isFocused()
          Returns TRUE if this component is currently the focused component, FALSE - otherwise.
 boolean isVisible()
          Returns TRUE if the component is visible and FALSE otherwise.
 void maximize()
          Implements ExportedWindow.maximize().
 void minimize()
          Implements ExportedWindow.minimize().
 void setLocation(int x, int y)
          Moves the window to the given coordinates.
 void setParams(Object[] windowParams)
          Implements ExportedWindow.setParams(Object[]).
 void setSize(int width, int height)
          Resizes the window with the given width and height.
 void setVisible(boolean visible)
          Shows or hides this component.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface net.java.sip.communicator.service.gui.ExportedWindow
getIdentifier
 

Field Detail

window

protected T extends Window window
The Window wrapped by this instance and to which ExportedWindow capabilities are provided.

Constructor Detail

AbstractExportedWindow

public AbstractExportedWindow()
Method Detail

bringToFront

public void bringToFront()
Description copied from interface: ExportedWindow
Brings the focus to this window.

Specified by:
bringToFront in interface ExportedWindow

createWindow

protected abstract T createWindow()
Creates the Window instance to be wrapped by this instance and to which ExportedWindow capabilities are provided.

Returns:
the Window instance to be wrapped by this instance and to which ExportedWindow capabilities are provided

getSource

public Object getSource()
Description copied from interface: ExportedWindow
The source of the window

Specified by:
getSource in interface ExportedWindow
Returns:
the source of the window

getWindow

protected T getWindow()
Gets the Window wrapped by this instance and to which ExportedWindow capabilities are provided.

Returns:
the Window wrapped by this instance and to which ExportedWindow capabilities are provided

isFocused

public boolean isFocused()
Description copied from interface: ExportedWindow
Returns TRUE if this component is currently the focused component, FALSE - otherwise.

Specified by:
isFocused in interface ExportedWindow
Returns:
TRUE if this component is currently the focused component, FALSE - otherwise.

isVisible

public boolean isVisible()
Description copied from interface: ExportedWindow
Returns TRUE if the component is visible and FALSE otherwise.

Specified by:
isVisible in interface ExportedWindow
Returns:
true if the component is visible and false otherwise.

maximize

public void maximize()
Implements ExportedWindow.maximize(). Maximizes the wrapped Window instance if it is a Frame.

Specified by:
maximize in interface ExportedWindow

minimize

public void minimize()
Implements ExportedWindow.minimize(). Minimizes the wrapped Window instance if it is a Frame.

Specified by:
minimize in interface ExportedWindow

setLocation

public void setLocation(int x,
                        int y)
Description copied from interface: ExportedWindow
Moves the window to the given coordinates.

Specified by:
setLocation in interface ExportedWindow
Parameters:
x - The x coordinate.
y - The y coordinate.

setParams

public void setParams(Object[] windowParams)
Implements ExportedWindow.setParams(Object[]). Does nothing.

Specified by:
setParams in interface ExportedWindow
Parameters:
windowParams - the parameters to set to the Window wrapped in this instance

setSize

public void setSize(int width,
                    int height)
Description copied from interface: ExportedWindow
Resizes the window with the given width and height.

Specified by:
setSize in interface ExportedWindow
Parameters:
width - The new width.
height - The new height.

setVisible

public void setVisible(boolean visible)
Description copied from interface: ExportedWindow
Shows or hides this component.

Specified by:
setVisible in interface ExportedWindow
Parameters:
visible - indicates whether to set this window visible or hide it

Jitsi: the OpenSource Java VoIP and Instant Messaging client.

Jitsi, the OpenSource Java VoIP and Instant Messaging client.
Distributable under LGPL license.