You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@flex.apache.org by ah...@apache.org on 2014/02/01 08:25:58 UTC
[2/2] git commit: [flex-asjs] [refs/heads/develop] - add asdoc for
org/apache/flex/core
add asdoc for org/apache/flex/core
Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/89c12f70
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/89c12f70
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/89c12f70
Branch: refs/heads/develop
Commit: 89c12f7055d90991780f3c85be7ee8011d2f0795
Parents: 9e7ec1f
Author: Alex Harui <ah...@apache.org>
Authored: Fri Jan 31 23:24:46 2014 -0800
Committer: Alex Harui <ah...@apache.org>
Committed: Fri Jan 31 23:25:39 2014 -0800
----------------------------------------------------------------------
.../src/org/apache/flex/core/Application.as | 2 +-
.../src/org/apache/flex/core/IComboBoxModel.as | 1 +
.../src/org/apache/flex/core/IDocument.as | 3 +
.../flex/core/IItemRendererClassFactory.as | 6 +
.../org/apache/flex/core/IItemRendererParent.as | 24 +-
.../src/org/apache/flex/core/ILayoutParent.as | 54 ++++
.../org/apache/flex/core/IMeasurementBead.as | 29 +-
.../src/org/apache/flex/core/IPanelModel.as | 10 +
.../src/org/apache/flex/core/IParent.as | 56 +++-
.../FlexJSUI/src/org/apache/flex/core/IPopUp.as | 10 +-
.../src/org/apache/flex/core/IPopUpHost.as | 9 +
.../src/org/apache/flex/core/IRangeModel.as | 57 ++++
.../src/org/apache/flex/core/IRollOverModel.as | 18 ++
.../src/org/apache/flex/core/IScrollBarModel.as | 28 ++
.../src/org/apache/flex/core/ISelectionModel.as | 81 +++++-
.../src/org/apache/flex/core/IStatesImpl.as | 11 +
.../src/org/apache/flex/core/IStrand.as | 49 ++++
.../src/org/apache/flex/core/ITextModel.as | 37 ++-
.../src/org/apache/flex/core/ITitleBarModel.as | 50 +++-
.../org/apache/flex/core/IToggleButtonModel.as | 45 ++-
.../src/org/apache/flex/core/IUIBase.as | 27 ++
.../apache/flex/core/IValueToggleButtonModel.as | 37 +++
.../src/org/apache/flex/core/IValuesImpl.as | 51 ++++
.../flex/core/ItemRendererClassFactory.as | 122 +++++++-
.../src/org/apache/flex/core/PopUpManager.as | 35 ++-
.../org/apache/flex/core/SimpleCSSValuesImpl.as | 79 ++++++
.../org/apache/flex/core/SimpleStatesImpl.as | 27 +-
.../org/apache/flex/core/SimpleValuesImpl.as | 59 ++++
.../FlexJSUI/src/org/apache/flex/core/Strand.as | 75 ++++-
.../FlexJSUI/src/org/apache/flex/core/UIBase.as | 278 ++++++++++++++++++-
.../src/org/apache/flex/core/UIButtonBase.as | 177 +++++++++++-
.../src/org/apache/flex/core/UIMetrics.as | 51 ++++
.../src/org/apache/flex/core/ValuesManager.as | 34 +++
.../src/org/apache/flex/core/ViewBase.as | 132 +++++++++
.../org/apache/flex/core/ViewBaseDataBinding.as | 30 ++
35 files changed, 1733 insertions(+), 61 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/89c12f70/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/Application.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/Application.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/Application.as
index 2ca39fb..c167944 100644
--- a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/Application.as
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/Application.as
@@ -56,7 +56,7 @@ package org.apache.flex.core
[Event(name="viewChanged", type="org.apache.flex.events.Event")]
/**
- * The Application class the main class and entry point for a FlexJS
+ * The Application class is the main class and entry point for a FlexJS
* application. This Application class is different than the
* Flex SDK's mx:Application or spark:Application in that it does not contain
* user interface elements. Those UI elements go in the views. This
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/89c12f70/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IComboBoxModel.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IComboBoxModel.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IComboBoxModel.as
index 0f9b1df..4b9fdfb 100644
--- a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IComboBoxModel.as
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IComboBoxModel.as
@@ -32,6 +32,7 @@ package org.apache.flex.core
*/
public interface IComboBoxModel extends IEventDispatcher, IBeadModel
{
+ // TODO: should extend ITextModel
/**
* The text displayed in the ComboBox.
*
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/89c12f70/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IDocument.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IDocument.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IDocument.as
index 78573f7..8825672 100644
--- a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IDocument.as
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IDocument.as
@@ -35,6 +35,9 @@ package org.apache.flex.core
* it belongs to, if any, and what its assigned id is in that
* document, if any.
*
+ * @param Object document The MXML document that hosts this component.
+ * @param String id The optional id of the component in the document.
+ *
* @langversion 3.0
* @playerversion Flash 10.2
* @playerversion AIR 2.6
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/89c12f70/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IItemRendererClassFactory.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IItemRendererClassFactory.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IItemRendererClassFactory.as
index d4638f8..21b6e7a 100644
--- a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IItemRendererClassFactory.as
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IItemRendererClassFactory.as
@@ -44,6 +44,12 @@ package org.apache.flex.core
* This method is called to generate another instance of an item renderer
* and attach it to the given parent.
*
+ * @param org.apache.flex.core.IItemRendererParent parent The parent of the item renderer.
+ * @return org.apache.flex.core.IItemRenderer The item renderer.
+ *
+ * @see org.apache.flex.core.IItemRendererParent
+ * @see org.apache.flex.core.IItemRenderer
+ *
* @langversion 3.0
* @playerversion Flash 10.2
* @playerversion AIR 2.6
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/89c12f70/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IItemRendererParent.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IItemRendererParent.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IItemRendererParent.as
index 0095b2e..3466f0c 100644
--- a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IItemRendererParent.as
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IItemRendererParent.as
@@ -18,11 +18,33 @@
////////////////////////////////////////////////////////////////////////////////
package org.apache.flex.core
{
- import flash.display.DisplayObject;
import org.apache.flex.events.IEventDispatcher;
+ /**
+ * The IItemRendererParent interface is the basic interface for the
+ * container that parents item renderers.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public interface IItemRendererParent extends IParent, IEventDispatcher
{
+ /**
+ * The IItemRendererParent interface is the basic interface for the
+ * container that parents item renderers.
+ *
+ * @param int index The index of the data item.
+ * @return org.apache.flex.core.IItemRenderer The item renderer for the data item.
+ *
+ * @see org.apache.flex.core.IItemRenderer
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
function getItemRendererForIndex(index:int):IItemRenderer;
function removeAllElements():void;
}
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/89c12f70/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/ILayoutParent.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/ILayoutParent.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/ILayoutParent.as
index 3604b37..9c6fa18 100644
--- a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/ILayoutParent.as
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/ILayoutParent.as
@@ -24,15 +24,69 @@ package org.apache.flex.core
import org.apache.flex.html.staticControls.supportClasses.Border;
import org.apache.flex.html.staticControls.supportClasses.ScrollBar;
+ /**
+ * The ILayoutParent interface is the basic interface for the
+ * container that have an IBeadLayout. The layout implementation
+ * often needs to know certain things about other objects in
+ * the component.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public interface ILayoutParent
{
+ /**
+ * The container that parents all of the content.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
function get contentView():DisplayObjectContainer;
+ /**
+ * The border.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
function get border():Border;
+ /**
+ * The vertical ScrollBar.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
function get vScrollBar():ScrollBar;
+
+ /**
+ * The horizontal ScrollBar.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
function get hScrollBar():ScrollBar;
+ /**
+ * The container whose size changes
+ * imply the need for another layout pass. This
+ * is normally the host component.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
function get resizableView():DisplayObject;
}
}
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/89c12f70/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IMeasurementBead.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IMeasurementBead.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IMeasurementBead.as
index 3e294f4..1722c2d 100644
--- a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IMeasurementBead.as
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IMeasurementBead.as
@@ -18,9 +18,36 @@
////////////////////////////////////////////////////////////////////////////////
package org.apache.flex.core
{
+ /**
+ * The IMeasurementBead interface is the basic interface for the
+ * bead that can compute and report the measurements of the contents of
+ * a component.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public interface IMeasurementBead extends IBead
{
+ /**
+ * The measured width.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
function get measuredWidth():Number;
+
+ /**
+ * The measured height
.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
function get measuredHeight():Number;
}
-}
\ No newline at end of file
+}
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/89c12f70/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IPanelModel.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IPanelModel.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IPanelModel.as
index 24fac27..bd46d99 100644
--- a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IPanelModel.as
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IPanelModel.as
@@ -18,6 +18,16 @@
////////////////////////////////////////////////////////////////////////////////
package org.apache.flex.core
{
+ /**
+ * The IPanelModel interface describes the minimum set of properties
+ * available to a Panel control. More sophisticated Panel controls
+ * could have models that extend IPanelModel.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public interface IPanelModel extends IBeadModel, ITitleBarModel
{
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/89c12f70/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IParent.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IParent.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IParent.as
index 111c925..3a214c9 100755
--- a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IParent.as
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IParent.as
@@ -18,11 +18,65 @@
////////////////////////////////////////////////////////////////////////////////
package org.apache.flex.core
{
+ /**
+ * The IParent interface is the basic interface for a
+ * component that contains subcomponents, including the
+ * application class.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public interface IParent
{
+ /**
+ * Add a component to the parent.
+ *
+ * @param Object c The subcomponent to add.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
function addElement(c:Object):void;
+
+ /**
+ * Add a component to the parent.
+ *
+ * @param Object c The subcomponent to add.
+ * @param int c The index where the subcomponent should be added.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
function addElementAt(c:Object, index:int):void;
+
+ /**
+ * Gets the index of this subcomponent.
+ *
+ * @param Object c The subcomponent to add.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
function getElementIndex(c:Object):int;
- function removeElement(c:Object):void;
+
+ /**
+ * Remove a component from the parent.
+ *
+ * @param Object c The subcomponent to remove.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
+ function removeElement(c:Object):void;
}
}
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/89c12f70/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IPopUp.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IPopUp.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IPopUp.as
index 4658554..9867498 100644
--- a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IPopUp.as
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IPopUp.as
@@ -18,7 +18,15 @@
////////////////////////////////////////////////////////////////////////////////
package org.apache.flex.core
{
- // marker interface to differentiate popups from other objects
+ /**
+ * The IPopUp interface is a "marker" interface for a component that
+ * should be floated above other components that aren't an IPopUp.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public interface IPopUp
{
}
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/89c12f70/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IPopUpHost.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IPopUpHost.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IPopUpHost.as
index fc8a89a..b32d9bf 100755
--- a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IPopUpHost.as
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IPopUpHost.as
@@ -18,6 +18,15 @@
////////////////////////////////////////////////////////////////////////////////
package org.apache.flex.core
{
+ /**
+ * The IPopUpHost interface is a "marker" interface for a component that
+ * parents components that implement IPopUp.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public interface IPopUpHost extends IParent
{
}
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/89c12f70/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IRangeModel.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IRangeModel.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IRangeModel.as
index 62e886d..fa254ba 100644
--- a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IRangeModel.as
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IRangeModel.as
@@ -18,20 +18,77 @@
////////////////////////////////////////////////////////////////////////////////
package org.apache.flex.core
{
+ /**
+ * The IRangeModel interface describes the minimum set of properties
+ * available to control that let the user select from within a
+ * range of numbers like NumericStepper and Slider. More sophisticated controls
+ * could have models that extend IRangeModel.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public interface IRangeModel extends IBeadModel
{
+ /**
+ * The maximum value.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
function get maximum():Number;
function set maximum(value:Number):void;
+ /**
+ * The minimum value.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
function get minimum():Number;
function set minimum(value:Number):void;
+ /**
+ * The interval that the value is rounded to
+ * when the user is drag selecting the value
+ * or entering an arbitrary value. For example,
+ * if the snapInterval is 0.5, then only integers
+ * and values endnig in 0.5 are selectable.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
function get snapInterval():Number;
function set snapInterval(value:Number):void;
+ /**
+ * The change in value by which the increment
+ * and decrement buttons and arrow keys will
+ * affect the curent value..
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
function get stepSize():Number;
function set stepSize(value:Number):void;
+ /**
+ * The current value.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
function get value():Number;
function set value(value:Number):void;
}
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/89c12f70/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IRollOverModel.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IRollOverModel.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IRollOverModel.as
index d38aa41..5c27b7a 100644
--- a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IRollOverModel.as
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IRollOverModel.as
@@ -20,8 +20,26 @@ package org.apache.flex.core
{
import org.apache.flex.events.IEventDispatcher;
+ /**
+ * The IRollOverModel interface describes the minimum set of properties
+ * available to control that supports rollover highlighting of an item
+ * within a set of items.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public interface IRollOverModel extends IEventDispatcher, IBeadModel
{
+ /**
+ * The index of the item that is currently under the mouse.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
function get rollOverIndex():int;
function set rollOverIndex(value:int):void;
}
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/89c12f70/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IScrollBarModel.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IScrollBarModel.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IScrollBarModel.as
index 2d92999..39e289f 100644
--- a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IScrollBarModel.as
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IScrollBarModel.as
@@ -18,11 +18,39 @@
////////////////////////////////////////////////////////////////////////////////
package org.apache.flex.core
{
+ /**
+ * The IScrollBarModel interface describes the minimum set of properties
+ * available to control that let the user select from within a
+ * range of numbers like ScrollBar.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public interface IScrollBarModel extends IRangeModel
{
+ /**
+ * The size of the page. This generally is used to compute
+ * the size of the thumb in the scrollbar.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
function get pageSize():Number;
function set pageSize(value:Number):void;
+ /**
+ * The change in value when clicking on above or below the thumb on
+ * a scrollbar. Also used for pageUp/pageDown keys.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
function get pageStepSize():Number;
function set pageStepSize(value:Number):void;
}
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/89c12f70/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/ISelectionModel.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/ISelectionModel.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/ISelectionModel.as
index 518d5f9..70de3f5 100644
--- a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/ISelectionModel.as
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/ISelectionModel.as
@@ -20,17 +20,80 @@ package org.apache.flex.core
{
import org.apache.flex.events.IEventDispatcher;
+ /**
+ * The ISelectionModel interface describes the minimum set of properties
+ * available to control that let the user select from within a
+ * set of items in a dataProvider. A more sophisticated model would
+ * support multiple selection.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public interface ISelectionModel extends IEventDispatcher, IBeadModel
{
- function get dataProvider():Object;
- function set dataProvider(value:Object):void;
-
- function get selectedIndex():int;
- function set selectedIndex(value:int):void;
-
- function get selectedItem():Object;
- function set selectedItem(value:Object):void;
-
+ /**
+ * The set of choices displayed in the ComboBox's
+ * dropdown. The dataProvider can be a simple
+ * array or vector if the set of choices is not
+ * going to be modified (except by wholesale
+ * replacement of the dataProvider). To use
+ * different kinds of data sets, you may need to
+ * provide an alternate "mapping" bead that
+ * iterates the dataProvider, generates item
+ * renderers and assigns a data item to the
+ * item renderers.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
+ function get dataProvider():Object;
+ function set dataProvider(value:Object):void;
+
+ /**
+ * The index of the selected item in the
+ * dataProvider. Values less than 0 can
+ * have specific meanings but generally mean
+ * that no item is selected because the
+ * user has typed in a custom entry or has
+ * yet to make a choice.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
+ function get selectedIndex():int;
+ function set selectedIndex(value:int):void;
+
+ /**
+ * The data item selected in the
+ * dataProvider. null usually means
+ * that the user has not selected a value
+ * and has typed in a custom entry.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
+ function get selectedItem():Object;
+ function set selectedItem(value:Object):void;
+
+ // TODO: this is probably not needed in a selection model
+ // and should be in a scheme mapper model.
+ /**
+ * The property on the data item that the item renderer
+ * should renderer.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
function get labelField():String;
function set labelField(value:String):void;
}
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/89c12f70/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IStatesImpl.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IStatesImpl.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IStatesImpl.as
index 152fe8f..9d8e7a1 100644
--- a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IStatesImpl.as
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IStatesImpl.as
@@ -20,6 +20,17 @@ package org.apache.flex.core
{
import org.apache.flex.events.IEventDispatcher;
+ /**
+ * The IStatesImpl interface is a "marker" interface for the
+ * implementation view states in a View like ViewBase. The
+ * implementation watches for the currentState property to
+ * change and executes changes accordingly.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public interface IStatesImpl extends IEventDispatcher, IBead
{
}
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/89c12f70/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IStrand.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IStrand.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IStrand.as
index 8e742e2..a048376 100644
--- a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IStrand.as
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IStrand.as
@@ -18,10 +18,59 @@
////////////////////////////////////////////////////////////////////////////////
package org.apache.flex.core
{
+ /**
+ * The IStrand interface is the basic interface for a host component for
+ * a set of plug-ins known as Beads.
+ * In FlexJS, the recommended pattern is to break out optional functionality
+ * into small plug-ins that can be re-used in other components, or replaced with
+ * different implementations optimized for different things such as size,
+ * performance, advanced features, debugging, etc.
+ *
+ * Beads are added to and removed from a Strand and can find and coordinate with
+ * other beads on the strand.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public interface IStrand
{
+ /**
+ * Add a bead to the strand.
+ *
+ * @param IBead bead The bead to be added.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
function addBead(bead:IBead):void;
+
+ /**
+ * Find a bead on the strand.
+ *
+ * @param Class classOrInterface The class or interface to use
+ * to search for the bead
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
function getBeadByType(classOrInterface:Class):IBead;
+
+ /**
+ * Remove a bead from the strand.
+ *
+ * @param IBead bead The bead to be removed.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
function removeBead(bead:IBead):IBead;
}
}
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/89c12f70/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/ITextModel.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/ITextModel.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/ITextModel.as
index 478e374..ceb9439 100644
--- a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/ITextModel.as
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/ITextModel.as
@@ -18,12 +18,39 @@
////////////////////////////////////////////////////////////////////////////////
package org.apache.flex.core
{
+ /**
+ * The ITextModel interface describes the minimum set of properties
+ * available to control that displays text. More sophisticated controls
+ * often have models that extend ITextModel.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public interface ITextModel extends IBeadModel
{
- function get text():String;
- function set text(value:String):void;
-
- function get html():String;
- function set html(value:String):void;
+ /**
+ * The text displayed in the control.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
+ function get text():String;
+ function set text(value:String):void;
+
+ /**
+ * The html formatted text displayed in the control.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
+ function get html():String;
+ function set html(value:String):void;
+
}
}
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/89c12f70/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/ITitleBarModel.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/ITitleBarModel.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/ITitleBarModel.as
index 0f421a1..95a5193 100644
--- a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/ITitleBarModel.as
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/ITitleBarModel.as
@@ -18,14 +18,52 @@
////////////////////////////////////////////////////////////////////////////////
package org.apache.flex.core
{
+ /**
+ * The ITitleBarModel interface describes the minimum set of properties
+ * available to control that displays a title bar. More sophisticated controls
+ * often have models that extend ITitleBarModel.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public interface ITitleBarModel extends IBeadModel
{
- function get title():String;
- function set title(value:String):void;
-
- function get htmlTitle():String;
- function set htmlTitle(value:String):void;
-
+ /**
+ * The title of the TitleBar.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
+ function get title():String;
+ function set title(value:String):void;
+
+ /**
+ * The title of the TitleBar as HTML.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
+ function get htmlTitle():String;
+ function set htmlTitle(value:String):void;
+
+ // TODO: Consider making this a bead instead.
+ // Boolean flags should often be replaced by beads.
+ // A different bead would add min/max/restore buttons.
+ /**
+ * <code>true</code> if a close button
+ * should also be in the title bar.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
function get showCloseButton():Boolean;
function set showCloseButton(value:Boolean):void;
}
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/89c12f70/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IToggleButtonModel.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IToggleButtonModel.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IToggleButtonModel.as
index 560d40c..6b06a84 100644
--- a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IToggleButtonModel.as
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IToggleButtonModel.as
@@ -18,14 +18,49 @@
////////////////////////////////////////////////////////////////////////////////
package org.apache.flex.core
{
+ /**
+ * The IToggleButtonModel interface describes the minimum set of properties
+ * available to ToggleButton that displays a text label.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public interface IToggleButtonModel extends IBeadModel
{
- function get text():String;
- function set text(value:String):void;
-
- function get html():String;
- function set html(value:String):void;
+ // TODO: Should extend ITextModel? Or should it
+ // not assume there is a label?
+ /**
+ * The text displayed in the control.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
+ function get text():String;
+ function set text(value:String):void;
+
+ /**
+ * The html formatted text displayed in the control.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
+ function get html():String;
+ function set html(value:String):void;
+ /**
+ * <code>true</code> if the button is selected.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
function get selected():Boolean;
function set selected(value:Boolean):void;
}
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/89c12f70/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IUIBase.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IUIBase.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IUIBase.as
index 6b36a71..15605f4 100644
--- a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IUIBase.as
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IUIBase.as
@@ -18,10 +18,37 @@
////////////////////////////////////////////////////////////////////////////////
package org.apache.flex.core
{
+ /**
+ * The IUIBase interface is the basic interface for user interface components.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public interface IUIBase extends IStrand
{
+ /**
+ * Each IUIBase has an element that is actually added to
+ * the platform's display list DOM. It may not be the actual
+ * component itself.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
function get element():Object;
+ /**
+ * Called by parent components when the component is
+ * added via a call to addElement or addElementAt.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
function addedToParent():void;
}
}
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/89c12f70/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IValueToggleButtonModel.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IValueToggleButtonModel.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IValueToggleButtonModel.as
index c2d6401..07a845c 100644
--- a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IValueToggleButtonModel.as
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IValueToggleButtonModel.as
@@ -18,14 +18,51 @@
////////////////////////////////////////////////////////////////////////////////
package org.apache.flex.core
{
+ /**
+ * The IValueToggleButtonModel interface describes the minimum set of properties
+ * available each ToggleButton in a group of ToggleButtons of which only one
+ * can be selected at a time.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public interface IValueToggleButtonModel extends IToggleButtonModel
{
+ /**
+ * A value associated with this instance of the ToggleButton.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
function get value():Object;
function set value(newValue:Object):void;
+ /**
+ * The name of the group that this ToggleButton belongs to.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
function get groupName():String;
function set groupName(value:String):void;
+ /**
+ * A value associated with the instance of the ToggleButton
+ * that is currently selected. It may not be this ToggleButton.
+ * This means that you can get the selected value from any
+ * instance of a ToggleButton in the group.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
function get selectedValue():Object;
function set selectedValue(newValue:Object):void;
}
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/89c12f70/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IValuesImpl.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IValuesImpl.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IValuesImpl.as
index 530861c..5fa0d9d 100644
--- a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IValuesImpl.as
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/IValuesImpl.as
@@ -18,11 +18,62 @@
////////////////////////////////////////////////////////////////////////////////
package org.apache.flex.core
{
+ /**
+ * The IValuesImpl interface is the basic interface for the subsystem that
+ * provides default values to components. The most common implementation implements
+ * a simple version of CSS and uses data structures compiled from CSS files.
+ *
+ * @see org.apache.flex.core.SimpleCSSValuesImpl
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public interface IValuesImpl
{
+ /**
+ * Returns a value for a given object based on a property name,
+ * and optionally, the current state, and a set of property value pairs.
+ *
+ * @param Object thisObject The object to get the value for.
+ * @param String valueName The name of a property. e.g. fontFamily, color, etc.
+ * @param String state The name of a state. e.g. hovered, visited
+ * @param Object attrs A map of property value pairs that may affect the returned value.
+ * @return * A value or undefined
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
function getValue(thisObject:Object, valueName:String, state:String = null, attrs:Object = null):*;
+
+ /**
+ * Returns a shared instance, instantiating the shared instance if
+ * it doesn't exist. Often used to share "managers"
+ *
+ * @param String valueName The name of a shared instance. Often, the fully
+ * qualified class name is used.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
function getInstance(valueName:String):Object;
+ /**
+ * MXML Documents that support <fx:Style> blocks should call
+ * init to install the styles for each instance.
+ *
+ * @param Object mainClass An instance that may have styles from an <fx:Style> block.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
function init(mainClass:Object):void;
}
}
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/89c12f70/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/ItemRendererClassFactory.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/ItemRendererClassFactory.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/ItemRendererClassFactory.as
index e561d38..a580140 100644
--- a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/ItemRendererClassFactory.as
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/ItemRendererClassFactory.as
@@ -18,16 +18,37 @@
////////////////////////////////////////////////////////////////////////////////
package org.apache.flex.core
{
- import flash.display.DisplayObject;
- import flash.display.DisplayObjectContainer;
import mx.core.ClassFactory;
+ import mx.core.IFactory;
import org.apache.flex.utils.MXMLDataInterpreter;
[DefaultProperty("mxmlContent")]
+
+ /**
+ * The ItemRendererClassFactory class is the default implementation of
+ * IItemRendererClassFactory. This implementation checks for an itemRenderer
+ * property on the strand, then looks for a default definition in CSS, but
+ * also handles the renderer being defined in MXML in sub tags of the
+ * ItemRendererClassFactory. Other more advanced implementations could
+ * return different renderers based on the data item's type.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public class ItemRendererClassFactory extends Strand implements IItemRendererClassFactory, IDocument, IBead
{
+ /**
+ * Constructor.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public function ItemRendererClassFactory()
{
super();
@@ -35,6 +56,14 @@ package org.apache.flex.core
private var _strand:IStrand;
+ /**
+ * @see org.apache.flex.core.IBead#strand.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public function set strand(value:IStrand):void
{
_strand = value;
@@ -42,8 +71,8 @@ package org.apache.flex.core
// see if the _strand has an itemRenderer property that isn't empty. if that's
// true, use that value instead of pulling it from the the style
if (Object(_strand).hasOwnProperty("itemRenderer")) {
- itemRendererClassFactory = Object(_strand)["itemRenderer"] as ClassFactory;
- if (itemRendererClassFactory) {
+ itemRendererFactory = Object(_strand)["itemRenderer"] as ClassFactory;
+ if (itemRendererFactory) {
createFunction = createFromClass;
return;
}
@@ -51,45 +80,114 @@ package org.apache.flex.core
var itemRendererClass:Class = ValuesManager.valuesImpl.getValue(_strand, "iItemRenderer") as Class;
if (itemRendererClass) {
- itemRendererClassFactory = new ClassFactory(itemRendererClass);
+ itemRendererFactory = new ClassFactory(itemRendererClass);
createFunction = createFromClass;
}
}
+ /**
+ * @copy org.apache.flex.core.Application#MXMLDescriptor.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public function get MXMLDescriptor():Array
{
return null;
}
- public function get MXMLProperties():Array
- {
- return null;
- }
-
+ /**
+ * The default property. Child tags in MXML documents get assigned
+ * to this property, but are actually encoded by the compiler into the MXMLDescriptor
+ * array. Therefore, setting this property from ActionScript will have no
+ * effect at runtime.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public var mxmlContent:Array;
+ /**
+ * @copy org.apache.flex.core.IItemRendererClassFactory#createItemRenderer
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public function createItemRenderer(parent:IItemRendererParent):IItemRenderer
{
return createFunction(parent);
}
+ /**
+ * This is the method that actually does the work for createItemRenderer. It
+ * defaults to creating an instance from child MXML tags, but if the strand
+ * has an item renderer property or style, it switches to generating instances
+ * of the item renderer specified by that property or style. And yes, since
+ * it is public, you could theoretically assign some other method that generates
+ * item renderer instances.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public var createFunction:Function = createFromMXMLContent;
+ /**
+ * Creates an instance of an item renderer from child MXML tags.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
protected function createFromMXMLContent(parent:IItemRendererParent):IItemRenderer
{
return MXMLDataInterpreter.generateMXMLArray(document, parent as IParent, MXMLDescriptor, true)[0];
}
- public var itemRendererClassFactory:ClassFactory;
+ /**
+ * Stores the IFactory that will be used to generate item renderer instances if
+ * createFromClass is the createFunction.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
+ public var itemRendererFactory:IFactory;
+ /**
+ * Creates an instance of an item renderer from itemRendererFactory.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public function createFromClass(parent:IItemRendererParent):IItemRenderer
{
- var renderer:IItemRenderer = itemRendererClassFactory.newInstance();
+ var renderer:IItemRenderer = itemRendererFactory.newInstance();
parent.addElement(renderer);
return renderer;
}
private var document:Object;
+
+ /**
+ * @copy org.apache.flex.core.IDocument#setDocument
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public function setDocument(document:Object, id:String = null):void
{
this.document = document;
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/89c12f70/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/PopUpManager.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/PopUpManager.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/PopUpManager.as
index 862d70c..7b27189 100644
--- a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/PopUpManager.as
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/PopUpManager.as
@@ -22,14 +22,47 @@ package org.apache.flex.core
import flash.display.DisplayObjectContainer;
import flash.events.Event;
+ /**
+ * The PopUpManager ensures that children that implement the
+ * IPopUp interface are layered over the other children. Unlike
+ * the Flex SDK, where the PopUpManager had APIs that you had to
+ * use to add popups to the display list, this PopUpManager
+ * monitors the children in a container. It assumes that no
+ * other container will obscure the container it is monitoring.
+ * A more sophisticated PopUpManager could handle such a
+ * scenario, but most folks don't have overlapping top-level
+ * "windows" in their user interfaces any more so a simpler
+ * implementation will suffice for most applications.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public class PopUpManager implements IDocument
{
- public function PopUpManager()
+ /**
+ * Constructor.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
+ public function PopUpManager()
{
}
private var document:DisplayObjectContainer;
+ /**
+ * @copy org.apache.flex.core.IDocument#setDocument
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public function setDocument(document:Object, id:String = null):void
{
this.document = document as DisplayObjectContainer;
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/89c12f70/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/SimpleCSSValuesImpl.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/SimpleCSSValuesImpl.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/SimpleCSSValuesImpl.as
index 71c0b66..df5ac29 100644
--- a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/SimpleCSSValuesImpl.as
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/SimpleCSSValuesImpl.as
@@ -26,8 +26,30 @@ package org.apache.flex.core
import org.apache.flex.events.EventDispatcher;
import org.apache.flex.events.ValueChangeEvent;
+ /**
+ * The SimpleCSSValuesImpl class implements a minimal set of
+ * CSS lookup rules that is sufficient for most applications.
+ * It does not support attribute selectors or descendant selectors
+ * or id selectors. It will filter on a custom -flex-flash
+ * media query but not other media queries. It can be
+ * replaced with other implementations that handle more complex
+ * selector lookups.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public class SimpleCSSValuesImpl extends EventDispatcher implements IValuesImpl
{
+ /**
+ * Constructor.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public function SimpleCSSValuesImpl()
{
super();
@@ -37,6 +59,14 @@ package org.apache.flex.core
private var conditionCombiners:Object;
+ /**
+ * @copy org.apache.flex.core.IValuesImpl#init
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public function init(mainClass:Object):void
{
var styleClassName:String;
@@ -56,6 +86,15 @@ package org.apache.flex.core
generateCSSStyleDeclarations(c["factoryFunctions"], c["data"]);
}
+ /**
+ * Process the encoded CSS data into data structures. Usually not called
+ * directly by application developers.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public function generateCSSStyleDeclarations(factoryFunctions:Object, arr:Array):void
{
if (factoryFunctions == null)
@@ -194,8 +233,25 @@ package org.apache.flex.core
return arr.join(" ");
}
+ /**
+ * The map of values. The format is not documented and it is not recommended
+ * to manipulate this structure directly.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public var values:Object;
+ /**
+ * @copy org.apache.flex.core.IValuesImpl#getValue
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public function getValue(thisObject:Object, valueName:String, state:String = null, attrs:Object = null):*
{
var c:int = valueName.indexOf("-");
@@ -276,6 +332,21 @@ package org.apache.flex.core
return null;
}
+ /**
+ * A method that stores a value to be shared with other objects.
+ * It is global, not per instance. Fancier implementations
+ * may store shared values per-instance.
+ *
+ * @param Object thisObject An object associated with this value. Thiis
+ * parameter is ignored.
+ * @param String valueName The name or key of the value being stored.
+ * @param * The value to be stored.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public function setValue(thisObject:Object, valueName:String, value:*):void
{
var c:int = valueName.indexOf("-");
@@ -294,6 +365,14 @@ package org.apache.flex.core
}
}
+ /**
+ * @copy org.apache.flex.core.IValuesImpl#getInstance
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public function getInstance(valueName:String):Object
{
var o:Object = values["global"];
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/89c12f70/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/SimpleStatesImpl.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/SimpleStatesImpl.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/SimpleStatesImpl.as
index 1e850a6..97f1c43 100644
--- a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/SimpleStatesImpl.as
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/SimpleStatesImpl.as
@@ -26,13 +26,30 @@ package org.apache.flex.core
import mx.states.State;
import org.apache.flex.core.IParent;
- import org.apache.flex.events.Event;
import org.apache.flex.events.EventDispatcher;
import org.apache.flex.events.ValueChangeEvent;
import org.apache.flex.utils.MXMLDataInterpreter;
+ /**
+ * The SimpleStatesImpl class implements a minimal set of
+ * view state functionality that is sufficient for most applications.
+ * It only supports AddItems and SetProperty changes at this time.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public class SimpleStatesImpl extends EventDispatcher implements IStatesImpl, IBead
{
+ /**
+ * Constructor.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public function SimpleStatesImpl()
{
super();
@@ -40,6 +57,14 @@ package org.apache.flex.core
private var _strand:IStrand;
+ /**
+ * @see org.apache.flex.core.IBead#strand.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public function set strand(value:IStrand):void
{
_strand = value;
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/89c12f70/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/SimpleValuesImpl.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/SimpleValuesImpl.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/SimpleValuesImpl.as
index eda53de..9ff5671 100644
--- a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/SimpleValuesImpl.as
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/SimpleValuesImpl.as
@@ -21,6 +21,17 @@ package org.apache.flex.core
import org.apache.flex.events.EventDispatcher;
import org.apache.flex.events.ValueChangeEvent;
+ /**
+ * The SimpleValuesImpl class implements a simple lookup rules that is
+ * sufficient for many very simple applications. Every value
+ * is essential global and shared by other instances. Values
+ * are set via calls to setValue.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public class SimpleValuesImpl extends EventDispatcher implements IValuesImpl
{
public function SimpleValuesImpl()
@@ -28,13 +39,45 @@ package org.apache.flex.core
super();
}
+ /**
+ * The map of values. The format is not documented and it is not recommended
+ * to manipulate this structure directly.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public var values:Object;
+ /**
+ * @copy org.apache.flex.core.IValuesImpl#getValue
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public function getValue(thisObject:Object, valueName:String, state:String = null, attrs:Object = null):*
{
return values[valueName];
}
+ /**
+ * A method that stores a value to be shared with other objects.
+ * It is global, not per instance. Fancier implementations
+ * may store shared values per-instance.
+ *
+ * @param Object thisObject An object associated with this value. Thiis
+ * parameter is ignored.
+ * @param String valueName The name or key of the value being stored.
+ * @param * The value to be stored.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public function setValue(thisObject:Object, valueName:String, value:Object):void
{
var oldValue:Object = values[valueName];
@@ -45,11 +88,27 @@ package org.apache.flex.core
}
}
+ /**
+ * @copy org.apache.flex.core.IValuesImpl#getInstance
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public function getInstance(valueName:String):Object
{
return values[valueName];
}
+ /**
+ * @copy org.apache.flex.core.IValuesImpl#init
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public function init(mainClass:Object):void
{
// do nothing
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/89c12f70/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/Strand.as
----------------------------------------------------------------------
diff --git a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/Strand.as b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/Strand.as
index daeca4b..be19394 100644
--- a/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/Strand.as
+++ b/frameworks/as/projects/FlexJSUI/src/org/apache/flex/core/Strand.as
@@ -22,10 +22,24 @@ package org.apache.flex.core
import org.apache.flex.events.EventDispatcher;
/**
- * Base class for non-display objects implementing a IStrand
+ * The Strand class is the base class for non-display object
+ * that implement a strand.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
*/
public class Strand extends EventDispatcher implements IStrand
{
+ /**
+ * Constructor.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public function Strand()
{
super();
@@ -33,6 +47,17 @@ package org.apache.flex.core
private var _model:IBeadModel;
+
+ /**
+ * An IBeadModel that serves as the data model for the component.
+ * Note that there is no controller or view properties since
+ * this not a display object.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public function get model():IBeadModel
{
if (_model == null)
@@ -42,6 +67,10 @@ package org.apache.flex.core
}
return _model;
}
+
+ /**
+ * @private
+ */
public function set model(value:IBeadModel):void
{
if (_model != value)
@@ -52,6 +81,15 @@ package org.apache.flex.core
}
private var _id:String;
+
+ /**
+ * An id property for MXML documents.
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public function get id():String
{
return _id;
@@ -65,11 +103,26 @@ package org.apache.flex.core
}
}
- // beads declared in MXML are added to the strand.
- // from AS, just call addBead()
+ /**
+ * @copy org.apache.flex.core.Application#beads
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public var beads:Array;
private var _beads:Vector.<IBead>;
+
+ /**
+ * @see org.apache.flex.core.IStrand#addBead
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public function addBead(bead:IBead):void
{
if (!_beads)
@@ -80,6 +133,14 @@ package org.apache.flex.core
bead.strand = this;
}
+ /**
+ * @see org.apache.flex.core.IStrand#getBeadByType
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public function getBeadByType(classOrInterface:Class):IBead
{
for each (var bead:IBead in _beads)
@@ -90,6 +151,14 @@ package org.apache.flex.core
return null;
}
+ /**
+ * @see org.apache.flex.core.IStrand#removeBead
+ *
+ * @langversion 3.0
+ * @playerversion Flash 10.2
+ * @playerversion AIR 2.6
+ * @productversion FlexJS 0.0
+ */
public function removeBead(value:IBead):IBead
{
var n:int = _beads.length;