Main Page | Packages | Class Tree | Index | Help

xp.controls

class MDController

MovieClip
  |
  +--xp.system.UIControl
        |
        +--xp.controls.Container
              |
              +--xp.controls.MDController


class MDController
extends Container

MDController
Displays and manages multiple forms

A Muliptle Document interface controller.
Commonly used as the source content in the center frame of a FrameSet


Author:
ProWin Computers Ltd. - Rob Edgar

Version:
3.0.0.000

See also:


Field Summary

public static
classInfo: Object
A static class information object

public
forms: Object
An associative array of forms definitions

public
styleClass: String
The name of the style class this instance will use.

Fields inherited from class xp.controls.Container

__showStatusBar, __showTitleBar, acceptButton, cancelButton, children, classInfo, controlBar, controls, dataSource, enableBGMouseEvents, initialFocusControl, isRoot, lastFocus, layoutDescriptor, layoutId, layoutManager, rootContainer, styleClass, symbolId, tabList, tabModeWrap

Fields inherited from class xp.system.UIControl

__layout, allowDrop, autoLayout, bindingDefaultValue, bindingFormatter, bindingPath, bindingSource, bindingType, bindingValidator, border, causesValidation, classInfo, clickOnENTER, clickOnSPACE, container, context, data, disableAcceptButton, disableCancelButton, enableBGMouseEvents, enableDblClickEvent, enableKeyDownEvents, enableKeyEvents, enableKeyUpEvents, enableMouseWheelEvents, formatterOptions, horizontalAlignment, index, isBinding, itemId, logEnabled, parent, parentContainer, parentForm, percentageHeight, percentageWidth, styleClass, tabIndex, tabStop, tooltip, tree, verticalAlignment

Property Summary

public
activeForm: Object (read-only)
returns the currently active(visible) form

Properties inherited from class xp.controls.Container

childCount, footerHeight, headerHeight, innerBackground, innerBackgroundVisible, innerBorderBrush, innerBorderRadius, innerBorderStyle, innerBorderThickness, numChildren, showStatusBar, showTitleBar, status, title

Properties inherited from class xp.system.UIControl

alpha, autosize, background, backgroundVisible, bindings, borderBrush, borderRadius, borderShadow, borderStyle, borderThickness, bottom, dataSource, enableMouseEvents, focusManager, height, id, isEnabled, isFocused, isMouseOver, isPressed, isSelected, isValid, layout, left, margin, maxHeight, maxWidth, measuredHeight, measuredMinHeight, measuredMinWidth, measuredWidth, minHeight, minWidth, padding, readOnly, resources, right, styleName, top, triggers, visible, width, x, y

Constructor

public
MDController ( )
Constructor - This should not be called directly.


Method Summary

public
closeAll ( ): Void
closes all forms in the controller

public
first ( ): Void
Displays the first form in the MDControllers children array

public
formExists ( formId: String ): Boolean
Checks whether an instance of the form is currently open

public
getClass ( ): Function
Returns a reference to the components static class

public
hideAll ( ): Void
hides all forms in the controller

public
last ( ): Void
Displays the last form in the MDControllers children array

public
loadForm ( frmSymbol: String, formId: String, itemStyle: Object ): MovieClip
Loads (creates) a form in the MDController Creates a new instance of a form but does not show it

public static
newInstance ( owner, instanceId, depth, initObj )
Creates a new Instance of this class

public
next ( ): Void
Displays the next form in the MDControllers children array

public
previous ( ): Void
Displays the previous form in the MDControllers children array

public
showForm ( formId: String ): Object
Show a form in the MDController

public
unloadForm ( formId: String ): Void
Unloads (removes) a form from the MDController

Methods inherited from class xp.controls.Container

addChild, addChildren, addControlBar, clearAll, createChild, destroyChildAt, getChild, getChildAt, getChildFromMouse, getClass, getFooterHeight, getHeaderHeight, getNextControl, getUIBuilder, getViewMetrics, initLayoutManager, onChildFocus, processEnterKey, processEscapeKey, registerChild, selectNextControl, setDataContext, setFocus, setMeasuredMinSize, setMeasuredSize, unregisterChild

Methods inherited from class xp.system.UIControl

addBinding, addBindings, addEventListener, addPropertyTrigger, applyStyle, beginDeferUpdate, canUpdate, centerContent, checkState, containsFocus, destroy, destroyObject, drawFocus, endDeferUpdate, findFocusFromObject, findFocusInChildren, getBinding, getBounds, getCenter, getClass, getFocus, getFocusManager, getFocusRect, getLocation, getPropertyValue, getSize, getStateName, getTrigger, globalToLocalPoint, invalidate, invalidateLayout, invalidateSize, invalidateSizeAndLayout, invalidChild, isChild, isMouseDirectlyOver, isParent, localToGlobalPoint, localToLocalPoint, measure, mouseWheel, move, onChildFocus, onKillFocus, onSetFocus, processEnterKey, processEscapeKey, processTabKey, redraw, refresh, removeEventListener, routeEvent, setBounds, setFocus, setLocation, setPropertyValue, setSize, setValueChanged, update, validate



Field Documentation

classInfo

public static var classInfo: Object
A static class information object

Every class has an associated classInfo object that holds the version and other static information. The classInfo can be accessed either directly by referencing the static class or by calling getClass() on any class instance.

forms

public var forms: Object
An associative array of forms definitions

This array contains forms descriptors which are used in creating form instances on demand. A form can be loaded direclty by manually calling loadForm but this array simplifies the process by allowing the MDController to create forms as required. the actual instances are in children/items arrays items is the clip container indexed by instanceId children is an array of child forms index by numerical stack order

styleClass

public var styleClass: String
The name of the style class this instance will use.


Property Documentation

activeForm

public activeForm: Object (read-only)
returns the currently active(visible) form


Constructor Documentation

MDController

public function MDController()
Constructor - This should not be called directly.

If you want to dynamically create a new instance of a control use its static newInstance method


Method Documentation

closeAll

public function closeAll(): Void
closes all forms in the controller

first

public function first(): Void
Displays the first form in the MDControllers children array

formExists

public function formExists(formId: String): Boolean
Checks whether an instance of the form is currently open

Parameters:
formId
the id of the form to check for

getClass

public function getClass(): Function
Returns a reference to the components static class

Overrides:

hideAll

public function hideAll(): Void
hides all forms in the controller

last

public function last(): Void
Displays the last form in the MDControllers children array

loadForm

public function loadForm(frmSymbol: String,
 formId: String,
 itemStyle: Object): MovieClip
Loads (creates) a form in the MDController Creates a new instance of a form but does not show it

Parameters:
frmSymbol
- library symbol of a form to load
formId
an instance id for the new form
itemStyle
- a property bag of properties to be applied to hte new form when loaded

newInstance

public static function newInstance(owner,
 instanceId,
 depth,
 initObj)
Creates a new Instance of this class

Creates an instance of a component at runtime. You need to use the import statement and specify the class package name before calling this method. In addition, the component must be in the FLA file’s library.

Parameters:
owner
A reference to the movie clip or object that will contains the new Instance.
instanceId
A string indicating the instance name of the new instance.(optional)
depth
A number indicating the depth of the new instance.(optional)
initObj
An object containing initialization properties for the new instance.(optional)
Returns:
A object that is an instance of the specified class.

next

public function next(): Void
Displays the next form in the MDControllers children array

previous

public function previous(): Void
Displays the previous form in the MDControllers children array

showForm

public function showForm(formId: String): Object
Show a form in the MDController

Displays a form in the MDController. If the form already exists it is brought to the front of the display stack. If it doesnt exits then the form definition is looked up from the forms array and then it is created and brought to the front.

unloadForm

public function unloadForm(formId: String): Void
Unloads (removes) a form from the MDController


The documentation was generated from the following file:


Generated on 10/30/2005 9:34:02 PM by AS2Doc