Packageflexlib.mdi.managers
Classpublic class MDIManager
InheritanceMDIManager Inheritance flash.events.EventDispatcher

Class responsible for applying effects and default behaviors to MDIWindow instances such as tiling, cascading, minimizing, maximizing, etc.



Public Properties
 PropertyDefined by
  container : UIComponent
MDIManager
  effects : IMDIEffectsDescriptor
MDIManager
  enforceBoundaries : Boolean = true
MDIManager
  global : MDIManager
[static][read-only]
MDIManager
  minTilePadding : Number = 5
MDIManager
  showMinimizedTiles : Boolean = false
MDIManager
  tileMinimize : Boolean = true
MDIManager
  tileMinimizeWidth : int = 200
MDIManager
  tilePadding : Number = 8
MDIManager
  windowList : Array
MDIManager
Public Methods
 MethodDefined by
  
MDIManager(container:UIComponent, effects:IMDIEffectsDescriptor = null)
Contstructor()
MDIManager
  
absPos(window:MDIWindow, x:int, y:int):void
Positions a window in an absolute position
MDIManager
  
add(window:MDIWindow):void
MDIManager
  
addCenter(window:MDIWindow):void
MDIManager
  
addContextMenu(window:MDIWindow, contextMenu:ContextMenu = null):void
MDIManager
  
bringToFront(window:MDIWindow):void
Brings a window to the front of the screen.
MDIManager
  
cascade():void
Cascades all managed windows from top left to bottom right
MDIManager
  
center(window:MDIWindow):void
Positions a window in the center of the available screen.
MDIManager
  
executeDefaultBehavior(event:Event):void
MDIManager
  
Gets a list of open windows for scenarios when only open windows need to be managed
MDIManager
  
manage(window:MDIWindow):void
Pushes a window onto the managed window stack
MDIManager
  
position(window:MDIWindow):void
Positions a window on the screen

This is primarly used as the default space on the screen to position the window.

MDIManager
  
remove(window:MDIWindow):void
Removes a window instance from the managed window stack
MDIManager
  
removeAll():void
Removes all windows from managed window stack;
MDIManager
  
resize(window:MDIWindow):void
MDIManager
  
MDIManager
  
tile(fillAvailableSpace:Boolean = false, gap:Number = 0):void
Tiles the window across the screen

By default, windows will be tiled to all the same size and use only the space they can accomodate.

MDIManager
Events
 EventSummaryDefined by
   Dispatched when the windows are cascaded.MDIManager
   Dispatched when the windows are tiled.MDIManager
   Dispatched when a window is added to the manager.MDIManager
   Dispatched when the minimize button is clicked.MDIManager
   Dispatched while the window is being dragged.MDIManager
   Dispatched when the window stops being dragged.MDIManager
   Dispatched when the window begins being dragged.MDIManager
   Dispatched when the window loses focus and no longer has topmost z-index of MDIManager's children.MDIManager
   Dispatched when the window gains focus and is given topmost z-index of MDIManager's children.MDIManager
   Dispatched when the maximize button is clicked or when the window is in a normal state (not minimized or maximized) and the titleBar is double clicked.MDIManager
   Dispatched when the minimize button is clicked.MDIManager
   Dispatched while the mouse is down on a resize handle.MDIManager
   Dispatched when the mouse is released from a resize handle.MDIManager
   Dispatched when a resize handle is pressed.MDIManager
   If the window is minimized, this event is dispatched when the titleBar is clicked.MDIManager
Public Constants
 ConstantDefined by
  CONTEXT_MENU_LABEL_CASCADE : String = "Cascade"
[static]
MDIManager
  CONTEXT_MENU_LABEL_SHOW_ALL : String = "Show All Windows"
[static]
MDIManager
  CONTEXT_MENU_LABEL_TILE : String = "Tile"
[static]
MDIManager
  CONTEXT_MENU_LABEL_TILE_FILL : String = "Tile + Fill"
[static]
MDIManager
Property detail
containerproperty
container:UIComponent  [read-write]Implementation
    public function get container():UIComponent
    public function set container(value:UIComponent):void
effectsproperty 
public var effects:IMDIEffectsDescriptor
enforceBoundariesproperty 
public var enforceBoundaries:Boolean = true
globalproperty 
global:MDIManager  [read-only]Implementation
    public static function get global():MDIManager
minTilePaddingproperty 
public var minTilePadding:Number = 5
showMinimizedTilesproperty 
public var showMinimizedTiles:Boolean = false
tileMinimizeproperty 
public var tileMinimize:Boolean = true
tileMinimizeWidthproperty 
public var tileMinimizeWidth:int = 200
tilePaddingproperty 
public var tilePadding:Number = 8
windowListproperty 
public var windowList:Array

This property can be used as the source for data binding.

Constructor detail
MDIManager()constructor
public function MDIManager(container:UIComponent, effects:IMDIEffectsDescriptor = null)

Contstructor()

Parameters
container:UIComponent
 
effects:IMDIEffectsDescriptor (default = null)
Method detail
absPos()method
public function absPos(window:MDIWindow, x:int, y:int):void

Positions a window in an absolute position

Parameters
window:MDIWindow — Window to position
 
x:int — The x position of the window
 
y:int — The y position of the window
add()method 
public function add(window:MDIWindow):voidParameters
window:MDIWindow
addCenter()method 
public function addCenter(window:MDIWindow):voidParameters
window:MDIWindow
addContextMenu()method 
public function addContextMenu(window:MDIWindow, contextMenu:ContextMenu = null):voidParameters
window:MDIWindow
 
contextMenu:ContextMenu (default = null)
bringToFront()method 
public function bringToFront(window:MDIWindow):void

Brings a window to the front of the screen.

Parameters
window:MDIWindow — Window to bring to front
cascade()method 
public function cascade():void

Cascades all managed windows from top left to bottom right

center()method 
public function center(window:MDIWindow):void

Positions a window in the center of the available screen.

Parameters
window:MDIWindow — to center
executeDefaultBehavior()method 
public function executeDefaultBehavior(event:Event):voidParameters
event:Event
getOpenWindowList()method 
public function getOpenWindowList():Array

Gets a list of open windows for scenarios when only open windows need to be managed

Returns
Array — Array
manage()method 
public function manage(window:MDIWindow):void

Pushes a window onto the managed window stack

Parameters
window:MDIWindow — Window:MDIWindow to push onto managed windows stack
position()method 
public function position(window:MDIWindow):void

Positions a window on the screen

This is primarly used as the default space on the screen to position the window.

Parameters
window:MDIWindow — Window to position
remove()method 
public function remove(window:MDIWindow):void

Removes a window instance from the managed window stack

Parameters
window:MDIWindow — Window to remove
removeAll()method 
public function removeAll():void

Removes all windows from managed window stack;

resize()method 
public function resize(window:MDIWindow):voidParameters
window:MDIWindow
showAllWindows()method 
public function showAllWindows():void
tile()method 
public function tile(fillAvailableSpace:Boolean = false, gap:Number = 0):void

Tiles the window across the screen

By default, windows will be tiled to all the same size and use only the space they can accomodate. If you set fillAvailableSpace = true, tile will use all the space available to tile the windows with the windows being arranged by varying heights and widths.

Parameters
fillAvailableSpace:Boolean (default = false) — Variable to determine whether to use the fill the entire available screen
 
gap:Number (default = 0)
Event detail
cascadeevent 
Event object type: flexlib.mdi.events.MDIManagerEvent

Dispatched when the windows are cascaded.

tileevent  
Event object type: flexlib.mdi.events.MDIManagerEvent

Dispatched when the windows are tiled.

windowAddevent  
Event object type: flexlib.mdi.events.MDIManagerEvent

Dispatched when a window is added to the manager.

windowCloseevent  
Event object type: flexlib.mdi.events.MDIManagerEvent

Dispatched when the minimize button is clicked.

windowDragevent  
Event object type: flexlib.mdi.events.MDIManagerEvent

Dispatched while the window is being dragged.

windowDragEndevent  
Event object type: flexlib.mdi.events.MDIManagerEvent

Dispatched when the window stops being dragged.

windowDragStartevent  
Event object type: flexlib.mdi.events.MDIManagerEvent

Dispatched when the window begins being dragged.

windowFocusEndevent  
Event object type: flexlib.mdi.events.MDIManagerEvent

Dispatched when the window loses focus and no longer has topmost z-index of MDIManager's children.

windowFocusStartevent  
Event object type: flexlib.mdi.events.MDIManagerEvent

Dispatched when the window gains focus and is given topmost z-index of MDIManager's children.

windowMaximizeevent  
Event object type: flexlib.mdi.events.MDIManagerEvent

Dispatched when the maximize button is clicked or when the window is in a normal state (not minimized or maximized) and the titleBar is double clicked.

windowMinimizeevent  
Event object type: flexlib.mdi.events.MDIManagerEvent

Dispatched when the minimize button is clicked.

windowResizeevent  
Event object type: flexlib.mdi.events.MDIManagerEvent

Dispatched while the mouse is down on a resize handle.

windowResizeEndevent  
Event object type: flexlib.mdi.events.MDIManagerEvent

Dispatched when the mouse is released from a resize handle.

windowResizeStartevent  
Event object type: flexlib.mdi.events.MDIManagerEvent

Dispatched when a resize handle is pressed.

windowRestoreevent  
Event object type: flexlib.mdi.events.MDIManagerEvent

If the window is minimized, this event is dispatched when the titleBar is clicked. If the window is maxmimized, this event is dispatched upon clicking the restore button or double clicking the titleBar.

Constant detail
CONTEXT_MENU_LABEL_CASCADEconstant
public static const CONTEXT_MENU_LABEL_CASCADE:String = "Cascade"
CONTEXT_MENU_LABEL_SHOW_ALLconstant 
public static const CONTEXT_MENU_LABEL_SHOW_ALL:String = "Show All Windows"
CONTEXT_MENU_LABEL_TILEconstant 
public static const CONTEXT_MENU_LABEL_TILE:String = "Tile"
CONTEXT_MENU_LABEL_TILE_FILLconstant 
public static const CONTEXT_MENU_LABEL_TILE_FILL:String = "Tile + Fill"