Maven module :un.engine : engine-ui :
Class : un.api.desktop.Frame
Extends/Implements : un.api.event.EventSource
Subclasses : -

A Frame is rectangle shape displayed on the desktop.
author  Johann Sorel


Variables : PROP_TITLE, PROP_ON_SCREEN_LOCATION, PROP_SIZE, PROP_VISIBLE, PROP_FOCUSED_WIDGET, PROP_MAXIMIZABLE, PROP_MINIMIZABLE, PROP_PINABLE, PROP_CLOSABLE, PROP_ALWAYSONTOP, PROP_CURSOR, PROP_STATE, PROP_DISPOSED, STATE_NORMAL, STATE_MINIMIZED, STATE_MAXIMIZED, STATE_MAXIMIZED_VERTICAL, STATE_MAXIMIZED_HORIZONTAL, STATE_FULLSCREEN
Functions : getParentFrame, getChildrenFrames, getManager, getContainer, getFocusedWidget, setFocusedWidget, getTitle, setTitle, getCursor, setCursor, setOnScreenLocation, getOnScreenLocation, setSize, getSize, setVisible, isVisible, isModale, getSystemDecoration, setDecoration, getDecoration, getState, setState, setMaximizable, isMaximizable, setMinimizable, isMinimizable, setClosable, isClosable, setPinable, isPinable, setAlwaysonTop, isAlwaysOnTop, isTranslucent, dispose, isDisposed, waitForDisposal


public Chars PROP_TITLE

public Chars PROP_ON_SCREEN_LOCATION

public Chars PROP_SIZE

public Chars PROP_VISIBLE

public Chars PROP_FOCUSED_WIDGET

public Chars PROP_MAXIMIZABLE

public Chars PROP_MINIMIZABLE

public Chars PROP_PINABLE

public Chars PROP_CLOSABLE

public Chars PROP_ALWAYSONTOP

public Chars PROP_CURSOR

public Chars PROP_STATE

public Chars PROP_DISPOSED

public int STATE_NORMAL

public int STATE_MINIMIZED

public int STATE_MAXIMIZED

public int STATE_MAXIMIZED_VERTICAL

public int STATE_MAXIMIZED_HORIZONTAL

public int STATE_FULLSCREEN



Get parent frame.
return  parent frame, can be null.
Frame getParentFrame ()


Get children frames if any.
return  children frames, never null, can be empty.
Sequence getChildrenFrames ()


Get frame manager.
return  FrameManager who created this frame.
FrameManager getManager ()


Get frame main container.
return  WContainer
WContainer getContainer ()


Get focused widget.
return  Widget, can be null
Widget getFocusedWidget ()


Set focused widget.
param  widget can be null.
void setFocusedWidget (Widget widget)


Get frame title.
return  frame title, can be null
CharArray getTitle ()


Set frame title.
param  title , can be null
void setTitle (CharArray title)


Get frame base cursor.
return  Cursor, can be null
Cursor getCursor ()


param  cursor, null to hide cursor.
void setCursor (Cursor cursor)


Set frame location on screen.
param  location
void setOnScreenLocation (Tuple location)


Get frame location on screen.
return  frame location on screen.
Tuple getOnScreenLocation ()


Set frame size.
param  width
param  height
void setSize (int width, int height)


Get frame size.
return  size
Extent getSize ()


Set frame visible.
param  visible
void setVisible (boolean visible)


Get frame visibility.
return  true if frame is visible.
boolean isVisible ()


Get frame modale state.
return  true if frame is modale
boolean isModale ()


Create a system dependant frame decoration.
return  FrameDecoration
FrameDecoration getSystemDecoration ()


param  decoration frame decoration, null to make frame undecorated
void setDecoration (FrameDecoration decoration)


return  frame decoration, can be null.
FrameDecoration getDecoration ()


A frame can be in only one state at the time.
States include :
int getState ()


Set frame state.
param  state
void setState (int state)


Set frame maximizable state.
param  maximizable
void setMaximizable (boolean maximizable)


Get frame maximizable state.
return  true if frame is maximizable.
boolean isMaximizable ()


Set frame minimizable state.
param  minimizable
void setMinimizable (boolean minimizable)


Get frame minimizable state.
return  true if frame is minimizable.
boolean isMinimizable ()


Set frame closable state.
param  closable
void setClosable (boolean closable)


Get frame closable state.
return  true if frame is closable.
boolean isClosable ()


Set frame can be set always on top
param  pinable
void setPinable (boolean pinable)


Get frame can be set always on top.
return  true if frame is pinable.
boolean isPinable ()


Ask to always put the frame on top of any other.
param  ontop
void setAlwaysonTop (boolean ontop)


Get frame on-top state.
return  true if frame is always on top.
boolean isAlwaysOnTop ()


Get frame translucent state.
return  true if frame has a translucent background
boolean isTranslucent ()


Release all resources used by the frame.
It should not be used after this call.
void dispose ()


Indicate if frame has been disposed.
boolean isDisposed ()


Block calling thread until this frame has been disposed.
TODO : seems strange, find a better way to implement this need
void waitForDisposal ()