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 2015/04/15 23:43:24 UTC

[19/55] [abbrv] git commit: [flex-asjs] [refs/heads/develop] - move handwritten JS code to final home. Build scripts still need fixing up

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/b677c658/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/ListView.js
----------------------------------------------------------------------
diff --git a/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/ListView.js b/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/ListView.js
new file mode 100644
index 0000000..6f7cc65
--- /dev/null
+++ b/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/ListView.js
@@ -0,0 +1,177 @@
+/**
+ * Licensed under the Apache License, Version 2.0 (the 'License');
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an 'AS IS' BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+goog.provide('org_apache_flex_html_beads_ListView');
+
+goog.require('org_apache_flex_core_IBeadLayout');
+goog.require('org_apache_flex_core_IBeadView');
+goog.require('org_apache_flex_core_IItemRendererParent');
+goog.require('org_apache_flex_core_ILayoutParent');
+goog.require('org_apache_flex_core_ValuesManager');
+goog.require('org_apache_flex_html_beads_IListView');
+goog.require('org_apache_flex_html_beads_TextItemRendererFactoryForArrayData');
+goog.require('org_apache_flex_html_beads_models_ArraySelectionModel');
+goog.require('org_apache_flex_html_supportClasses_NonVirtualDataGroup');
+
+
+
+/**
+ * @constructor
+ * @implements {org_apache_flex_core_ILayoutParent}
+ * @implements {org_apache_flex_html_beads_IListView}
+ */
+org_apache_flex_html_beads_ListView = function() {
+  this.lastSelectedIndex = -1;
+
+  this.className = 'ListView';
+};
+
+
+/**
+ * Metadata
+ *
+ * @type {Object.<string, Array.<Object>>}
+ */
+org_apache_flex_html_beads_ListView.prototype.
+    FLEXJS_CLASS_INFO =
+    { names: [{ name: 'ListView',
+                qName: 'org_apache_flex_html_beads_ListView' }],
+      interfaces: [org_apache_flex_html_beads_IListView, org_apache_flex_core_ILayoutParent] };
+
+
+Object.defineProperties(org_apache_flex_html_beads_ListView.prototype, {
+    /** @expose */
+    strand: {
+        /** @this {org_apache_flex_html_beads_ListView} */
+        set: function(value) {
+            this.strand_ = value;
+
+            this.strand_.addEventListener('sizeChanged',
+                goog.bind(this.handleSizeChange, this));
+            this.strand_.addEventListener('widthChanged',
+                goog.bind(this.handleSizeChange, this));
+            this.strand_.addEventListener('heightChanged',
+                goog.bind(this.handleSizeChange, this));
+
+            this.model = this.strand_.model;
+            this.model.addEventListener('selectedIndexChanged',
+                goog.bind(this.selectionChangeHandler, this));
+            this.model.addEventListener('dataProviderChanged',
+                goog.bind(this.dataProviderChangeHandler, this));
+
+            if (this.dataGroup_ == null) {
+              var m2 = org_apache_flex_core_ValuesManager.valuesImpl.
+                  getValue(this.strand_, 'iDataGroup');
+              this.dataGroup_ = new m2();
+            }
+            this.dataGroup_.strand = this;
+            this.strand_.addElement(this.dataGroup_);
+
+            if (this.strand_.getBeadByType(org_apache_flex_core_IBeadLayout) == null) {
+              var m3 = org_apache_flex_core_ValuesManager.valuesImpl.getValue(this.strand_, 'iBeadLayout');
+              this.layout_ = new m3();
+              this.strand_.addBead(this.layout_);
+              //this.layout_.strand = this.strand_;
+            }
+
+            this.handleSizeChange(null);
+        }
+    },
+    /** @expose */
+    dataGroup: {
+        /** @this {org_apache_flex_html_beads_ListView} */
+        get: function() {
+            return this.dataGroup_;
+        },
+        /** @this {org_apache_flex_html_beads_ListView} */
+        set: function(value) {
+            this.dataGroup_ = value;
+        }
+    }
+});
+
+
+/**
+ * @expose
+ * @param {Object} value The event that triggered the selection.
+ */
+org_apache_flex_html_beads_ListView.prototype.
+    selectionChangeHandler = function(value) {
+  var ir;
+  if (this.lastSelectedIndex != -1) {
+    ir = this.dataGroup_.getItemRendererForIndex(this.lastSelectedIndex);
+    if (ir) ir.selected = false;
+  }
+  if (this.model.selectedIndex != -1) {
+    ir = this.dataGroup_.getItemRendererForIndex(
+        this.model.selectedIndex);
+    if (ir) ir.selected = true;
+  }
+  this.lastSelectedIndex = this.model.selectedIndex;
+};
+
+
+/**
+ * @expose
+ * @param {Object} value The event that triggeed the selection.
+ */
+org_apache_flex_html_beads_ListView.prototype.
+    dataProviderChangeHandler = function(value) {
+    // override in subclass
+};
+
+
+Object.defineProperties(org_apache_flex_html_beads_ListView.prototype, {
+    /** @expose */
+    contentView: {
+        /** @this {org_apache_flex_html_beads_ListView} */
+        get: function() {
+            return this.dataGroup_;
+        }
+    },
+    /** @expose */
+    border: {
+        /** @this {org_apache_flex_html_beads_ListView} */
+        get: function() {
+            return null;
+        }
+    },
+    /** @expose */
+    vScrollBar: {
+        /** @this {org_apache_flex_html_beads_ListView} */
+        get: function() {
+            return null;
+        },
+        /** @this {org_apache_flex_html_beads_ListView} */
+        set: function(value) {
+        }
+    },
+    /** @expose */
+    resizeableView: {
+        /** @this {org_apache_flex_html_beads_ListView} */
+        get: function() {
+            return this;
+        }
+    }
+});
+
+
+/**
+ * @expose
+ * @param {Object} event The event that triggered the resize.
+ */
+org_apache_flex_html_beads_ListView.prototype.handleSizeChange = function(event) {
+  this.dataGroup_.width = this.strand_.width;
+  this.dataGroup_.height = this.strand_.height;
+};

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/b677c658/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/PanelView.js
----------------------------------------------------------------------
diff --git a/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/PanelView.js b/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/PanelView.js
new file mode 100644
index 0000000..4042eec
--- /dev/null
+++ b/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/PanelView.js
@@ -0,0 +1,129 @@
+/**
+ * Licensed under the Apache License, Version 2.0 (the 'License');
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an 'AS IS' BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+goog.provide('org_apache_flex_html_beads_PanelView');
+
+goog.require('org_apache_flex_core_IBeadView');
+
+
+
+/**
+ * @constructor
+ */
+org_apache_flex_html_beads_PanelView = function() {
+  /**
+   * @private
+   * @type {boolean}
+  */
+  this.titleBarAdded_ = false;
+
+  /**
+   * @private
+   * @type {?Object}
+  */
+  this.titleBar_ = null;
+};
+
+
+/**
+ * Metadata
+ *
+ * @type {Object.<string, Array.<Object>>}
+ */
+org_apache_flex_html_beads_PanelView
+  .prototype.FLEXJS_CLASS_INFO =
+    { names: [{ name: 'PanelView',
+                qName: 'org_apache_flex_html_beads_PanelView'}],
+      interfaces: [org_apache_flex_core_IBeadView] };
+
+
+Object.defineProperties(org_apache_flex_html_beads_PanelView.prototype, {
+    /** @expose */
+    strand: {
+        /** @this {org_apache_flex_html_beads_PanelView} */
+        set: function(value) {
+            this.strand_ = value;
+
+            if (!this.titleBar_)
+              this.titleBar_ = new org_apache_flex_html_TitleBar();
+
+            this.strand_.titleBar = this.titleBar_;
+            this.titleBar_.id = 'titleBar';
+            this.titleBar_.model = this.strand_.model;
+
+            this.strand_.controlBar =
+                new org_apache_flex_html_ControlBar();
+
+            this.strand_.addEventListener('childrenAdded',
+                goog.bind(this.changeHandler, this));
+
+            // listen for changes to the strand's model so items can be changed
+            // in the view
+            this.strand_.model.addEventListener('titleChange',
+                goog.bind(this.changeHandler, this));
+        }
+    },
+    /** @expose */
+    titleBar: {
+        /** @this {org_apache_flex_html_beads_PanelView} */
+        get: function() {
+            return this.titleBar_;
+        },
+        /** @this {org_apache_flex_html_beads_PanelView} */
+        set: function(value) {
+            this.titleBar_ = value;
+        }
+    }
+});
+
+
+/**
+ * @param {Object} event The event that triggered this handler.
+ */
+org_apache_flex_html_beads_PanelView.prototype.changeHandler =
+    function(event) {
+  var strand = this.strand_;
+  if (!this.titleBarAdded_)
+  {
+    this.titleBarAdded_ = true;
+    strand.addElement(this.titleBar_);
+    if (strand.controlBar != null)
+      strand.addElement(strand.controlBar);
+  }
+
+  if (event.type == 'titleChange') {
+    this.titleBar_.title = strand.model.title;
+  }
+
+  var p = this.strand_.positioner;
+  if (!strand.isWidthSizedToContent()) {
+    var w = strand.width;
+    w -= p.offsetWidth - p.clientWidth;
+    this.titleBar_.setWidth(w);
+    strand.contentArea.style.width = w.toString() + 'px';
+    if (strand.controlBar)
+      strand.controlBar.setWidth(w);
+  }
+  if (!strand.isHeightSizedToContent()) {
+    var t = this.titleBar_.height;
+    var b = 0;
+    if (strand.controlBar)
+      b = strand.controlBar.height;
+    strand.contentArea.style.top = t.toString() + 'px';
+    var h = strand.height - t - b;
+    h -= p.offsetHeight - p.clientHeight;
+    strand.contentArea.style.height = h.toString() + 'px';
+  }
+  this.strand_.dispatchEvent('layoutNeeded');
+};

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/b677c658/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/ScrollingContainerView.js
----------------------------------------------------------------------
diff --git a/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/ScrollingContainerView.js b/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/ScrollingContainerView.js
new file mode 100644
index 0000000..2e32c98
--- /dev/null
+++ b/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/ScrollingContainerView.js
@@ -0,0 +1,81 @@
+/**
+ * Licensed under the Apache License, Version 2.0 (the 'License');
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an 'AS IS' BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+goog.provide('org_apache_flex_html_beads_ScrollingContainerView');
+
+goog.require('org_apache_flex_html_beads_ContainerView');
+
+
+
+/**
+ * @constructor
+ * @extends {org_apache_flex_html_beads_ContainerView}
+ */
+org_apache_flex_html_beads_ScrollingContainerView = function() {
+  this.lastSelectedIndex = -1;
+  org_apache_flex_html_beads_ScrollingContainerView.base(this, 'constructor');
+
+  this.className = 'ScrollingContainerView';
+};
+goog.inherits(
+    org_apache_flex_html_beads_ScrollingContainerView,
+    org_apache_flex_html_beads_ContainerView);
+
+
+/**
+ * Metadata
+ *
+ * @type {Object.<string, Array.<Object>>}
+ */
+org_apache_flex_html_beads_ScrollingContainerView.prototype.FLEXJS_CLASS_INFO =
+    { names: [{ name: 'ScrollingContainerView',
+                qName: 'org_apache_flex_html_beads_ScrollingContainerView' }],
+    interfaces: [org_apache_flex_core_ILayoutParent]
+    };
+
+
+Object.defineProperties(org_apache_flex_html_beads_ScrollingContainerView.prototype, {
+    /** @expose */
+    contentView: {
+        /** @this {org_apache_flex_html_beads_ScrollingContainerView} */
+        get: function() {
+            return this._strand;
+        }
+    },
+    /** @expose */
+    resizableView: {
+        /** @this {org_apache_flex_html_beads_ScrollingContainerView} */
+        get: function() {
+            return this._strand;
+        }
+    },
+    /** @expose */
+    verticalScrollPosition: {
+        /** @this {org_apache_flex_html_beads_ScrollingContainerView} */
+        get: function() {
+           return this._strand.scrollTop;
+        },
+        /** @this {org_apache_flex_html_beads_ScrollingContainerView} */
+        set: function(value) {
+           this._strand.scrollTop = value;
+        }
+    },
+    /** @expose */
+    maxVerticalScrollPosition: {
+        /** @this {org_apache_flex_html_beads_ScrollingContainerView} */
+        get: function() {
+            return this._strand.scrollHeight - this._strand.clientHeight;
+        }
+    }
+});

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/b677c658/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/SliderThumbView.js
----------------------------------------------------------------------
diff --git a/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/SliderThumbView.js b/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/SliderThumbView.js
new file mode 100644
index 0000000..6588b42
--- /dev/null
+++ b/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/SliderThumbView.js
@@ -0,0 +1,62 @@
+/**
+ * Licensed under the Apache License, Version 2.0 (the 'License');
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an 'AS IS' BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+goog.provide('org_apache_flex_html_beads_SliderThumbView');
+
+
+
+/**
+ * @constructor
+ */
+org_apache_flex_html_beads_SliderThumbView = function() {
+};
+
+
+/**
+ * Metadata
+ *
+ * @type {Object.<string, Array.<Object>>}
+ */
+org_apache_flex_html_beads_SliderThumbView
+  .prototype.FLEXJS_CLASS_INFO =
+    { names: [{ name: 'SliderThumbView',
+                qName: 'org_apache_flex_html_beads_SliderThumbView'}] };
+
+
+Object.defineProperties(org_apache_flex_html_beads_SliderThumbView.prototype, {
+    /** @expose */
+    strand: {
+        /** @this {org_apache_flex_html_beads_SliderThumbView} */
+        set: function(value) {
+            this.strand_ = value;
+
+            this.element = document.createElement('div');
+            this.element.className = 'SliderThumb';
+            this.element.id = 'thumb';
+            this.element.style.backgroundColor = '#949494';
+            this.element.style.border = 'thin solid #747474';
+            this.element.style.position = 'relative';
+            this.element.style.height = '30px';
+            this.element.style.width = '10px';
+            this.element.style.zIndex = '2';
+            this.element.style.top = '-10px';
+            this.element.style.left = '20px';
+
+            this.strand_.element.appendChild(this.element);
+
+            this.positioner = this.element;
+            this.element.flexjs_wrapper = this;
+        }
+    }
+});

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/b677c658/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/SliderTrackView.js
----------------------------------------------------------------------
diff --git a/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/SliderTrackView.js b/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/SliderTrackView.js
new file mode 100644
index 0000000..f23e3e9
--- /dev/null
+++ b/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/SliderTrackView.js
@@ -0,0 +1,62 @@
+/**
+ * Licensed under the Apache License, Version 2.0 (the 'License');
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an 'AS IS' BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+goog.provide('org_apache_flex_html_beads_SliderTrackView');
+
+
+
+/**
+ * @constructor
+ */
+org_apache_flex_html_beads_SliderTrackView = function() {
+};
+
+
+/**
+ * Metadata
+ *
+ * @type {Object.<string, Array.<Object>>}
+ */
+org_apache_flex_html_beads_SliderTrackView
+  .prototype.FLEXJS_CLASS_INFO =
+    { names: [{ name: 'SliderTrackView',
+                qName: 'org_apache_flex_html_beads_SliderTrackView'}] };
+
+
+Object.defineProperties(org_apache_flex_html_beads_SliderTrackView.prototype, {
+    /** @expose */
+    strand: {
+        /** @this {org_apache_flex_html_beads_SliderTrackView} */
+        set: function(value) {
+            this.strand_ = value;
+
+            this.element = document.createElement('div');
+            this.element.className = 'SliderTrack';
+            this.element.id = 'track';
+            this.element.style.backgroundColor = '#E4E4E4';
+            this.element.style.height = '10px';
+            this.element.style.width = '200px';
+            this.element.style.border = 'thin solid #C4C4C4';
+            this.element.style.position = 'relative';
+            this.element.style.left = '0px';
+            this.element.style.top = '10px';
+            this.element.style.zIndex = '1';
+
+            this.strand_.element.appendChild(this.element);
+
+            this.positioner = this.element;
+            this.element.flexjs_wrapper = this;
+        }
+    }
+});

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/b677c658/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/TextInputWithBorderView.js
----------------------------------------------------------------------
diff --git a/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/TextInputWithBorderView.js b/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/TextInputWithBorderView.js
new file mode 100644
index 0000000..51cb4e7
--- /dev/null
+++ b/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/TextInputWithBorderView.js
@@ -0,0 +1,45 @@
+/**
+ * Licensed under the Apache License, Version 2.0 (the 'License');
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an 'AS IS' BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+goog.provide('org_apache_flex_html_beads_TextInputWithBorderView');
+
+
+
+/**
+ * @constructor
+ */
+org_apache_flex_html_beads_TextInputWithBorderView = function() {
+};
+
+
+/**
+ * Metadata
+ *
+ * @type {Object.<string, Array.<Object>>}
+ */
+org_apache_flex_html_beads_TextInputWithBorderView
+  .prototype.FLEXJS_CLASS_INFO =
+    { names: [{ name: 'TextInputWithBorderView',
+                qName: 'org_apache_flex_html_beads_TextInputWithBorderView'}] };
+
+
+Object.defineProperties(org_apache_flex_html_beads_TextInputWithBorderView.prototype, {
+    /** @expose */
+    strand: {
+        /** @this {org_apache_flex_html_beads_TextInputWithBorderView} */
+        set: function(value) {
+            this.strand_ = value;
+        }
+    }
+});

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/b677c658/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/TextItemRendererFactoryForArrayData.js
----------------------------------------------------------------------
diff --git a/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/TextItemRendererFactoryForArrayData.js b/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/TextItemRendererFactoryForArrayData.js
new file mode 100644
index 0000000..02da71c
--- /dev/null
+++ b/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/TextItemRendererFactoryForArrayData.js
@@ -0,0 +1,94 @@
+/**
+ * Licensed under the Apache License, Version 2.0 (the 'License');
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an 'AS IS' BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+goog.provide('org_apache_flex_html_beads_TextItemRendererFactoryForArrayData');
+
+goog.require('org_apache_flex_core_IDataProviderItemRendererMapper');
+goog.require('org_apache_flex_core_IItemRenderer');
+goog.require('org_apache_flex_events_Event');
+goog.require('org_apache_flex_events_EventDispatcher');
+goog.require('org_apache_flex_html_beads_models_ArraySelectionModel');
+goog.require('org_apache_flex_html_supportClasses_StringItemRenderer');
+
+
+
+/**
+ * @constructor
+ * @extends {org_apache_flex_events_EventDispatcher}
+ * @implements {org_apache_flex_core_IItemRenderer}
+ */
+org_apache_flex_html_beads_TextItemRendererFactoryForArrayData =
+    function() {
+  org_apache_flex_html_beads_TextItemRendererFactoryForArrayData.base(this, 'constructor');
+};
+goog.inherits(
+    org_apache_flex_html_beads_TextItemRendererFactoryForArrayData,
+    org_apache_flex_events_EventDispatcher);
+
+
+/**
+ * Metadata
+ *
+ * @type {Object.<string, Array.<Object>>}
+ */
+org_apache_flex_html_beads_TextItemRendererFactoryForArrayData.
+    prototype.FLEXJS_CLASS_INFO =
+    { names: [{ name: 'TextItemRendererFactoryForArrayData',
+                qName: 'org_apache_flex_html_beads_TextItemRendererFactoryForArrayData' }],
+      interfaces: [org_apache_flex_core_IItemRenderer] };
+
+
+Object.defineProperties(org_apache_flex_html_beads_TextItemRendererFactoryForArrayData.prototype, {
+    /** @expose */
+    strand: {
+        /** @this {org_apache_flex_html_beads_TextItemRendererFactoryForArrayData} */
+        set: function(value) {
+            this.strand_ = value;
+
+            this.model = value.getBeadByType(
+                org_apache_flex_html_beads_models_ArraySelectionModel);
+
+            this.listView = value.getBeadByType(
+                org_apache_flex_html_beads_ListView);
+            this.dataGroup = this.listView.dataGroup;
+
+            this.model.addEventListener('dataProviderChanged',
+                goog.bind(this.dataProviderChangedHandler, this));
+
+            this.dataProviderChangedHandler(null);
+        }
+    }
+});
+
+
+/**
+ * @expose
+ * @param {Object} event The event that triggered the dataProvider change.
+ */
+org_apache_flex_html_beads_TextItemRendererFactoryForArrayData.
+    prototype.dataProviderChangedHandler = function(event) {
+  var dp, i, n, opt;
+
+  dp = this.model.dataProvider;
+  n = dp.length;
+  for (i = 0; i < n; i++) {
+    opt = new
+        org_apache_flex_html_supportClasses_StringItemRenderer();
+    this.dataGroup.addElement(opt);
+    opt.text = dp[i];
+  }
+
+  var newEvent = new org_apache_flex_events_Event('itemsCreated');
+  this.strand_.dispatchEvent(newEvent);
+};

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/b677c658/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/controllers/ItemRendererMouseController.js
----------------------------------------------------------------------
diff --git a/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/controllers/ItemRendererMouseController.js b/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/controllers/ItemRendererMouseController.js
new file mode 100644
index 0000000..8068249
--- /dev/null
+++ b/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/controllers/ItemRendererMouseController.js
@@ -0,0 +1,119 @@
+/**
+ * Licensed under the Apache License, Version 2.0 (the 'License');
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an 'AS IS' BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+goog.provide('org_apache_flex_html_beads_controllers_ItemRendererMouseController');
+
+goog.require('org_apache_flex_core_IBeadController');
+
+
+
+/**
+ * @constructor
+ * @implements {org_apache_flex_core_IBeadController}
+ */
+org_apache_flex_html_beads_controllers_ItemRendererMouseController = function() {
+};
+
+
+/**
+ * Metadata
+ *
+ * @type {Object.<string, Array.<Object>>}
+ */
+org_apache_flex_html_beads_controllers_ItemRendererMouseController.prototype.FLEXJS_CLASS_INFO =
+    { names: [{ name: 'ItemRendererMouseController',
+                qName: 'org_apache_flex_html_beads_controllers_ItemRendererMouseController' }],
+      interfaces: [org_apache_flex_core_IBeadController] };
+
+
+Object.defineProperties(org_apache_flex_html_beads_controllers_ItemRendererMouseController.prototype, {
+    /** @expose */
+    strand: {
+        /** @this {org_apache_flex_html_beads_controllers_ItemRendererMouseController} */
+        set: function(value) {
+            this.strand_ = value;
+
+            goog.events.listen(this.strand_.element, goog.events.EventType.MOUSEOVER,
+                goog.bind(this.handleMouseOver, this));
+
+            goog.events.listen(this.strand_.element, goog.events.EventType.MOUSEOUT,
+                goog.bind(this.handleMouseOut, this));
+
+            goog.events.listen(this.strand_.element, goog.events.EventType.MOUSEDOWN,
+                goog.bind(this.handleMouseDown, this));
+
+            goog.events.listen(this.strand_.element, goog.events.EventType.MOUSEUP,
+                goog.bind(this.handleMouseUp, this));
+        }
+    }
+});
+
+
+/**
+ * @expose
+ * @param {Object} event The mouse event that triggered the hover.
+ */
+org_apache_flex_html_beads_controllers_ItemRendererMouseController.prototype.handleMouseOver = function(event) {
+
+  this.strand_.hovered = true;
+
+  var newEvent = new goog.events.Event('rollover');
+  newEvent.target = this.strand_;
+  this.strand_.itemRendererParent.dispatchEvent(newEvent);
+};
+
+
+/**
+ * @expose
+ * @param {Object} event The mouse-out event.
+ */
+org_apache_flex_html_beads_controllers_ItemRendererMouseController.prototype.handleMouseOut = function(event) {
+
+  this.strand_.hovered = false;
+
+  var newEvent = new goog.events.Event('rollout');
+  newEvent.target = this.strand_;
+  this.strand_.itemRendererParent.dispatchEvent(newEvent);
+};
+
+
+/**
+ * @expose
+ * @param {Object} event The mouse-down event.
+ */
+org_apache_flex_html_beads_controllers_ItemRendererMouseController.prototype.handleMouseDown = function(event) {
+
+  // ??
+};
+
+
+/**
+ * @expose
+ * @param {Object} event The mouse-up event that triggers the selection.
+ */
+org_apache_flex_html_beads_controllers_ItemRendererMouseController.prototype.handleMouseUp = function(event) {
+
+  var newEvent = new goog.events.Event('selected');
+
+  // normally you do not - and should not - change the target of an event,
+  // but these events do not propagate nor bubble up the object tree, so
+  // we have to force the event's target to be this item renderer instance.
+
+  newEvent.target = this.strand_;
+
+  // since the event is not going to up the chain, we also have to dispatch
+  // it against its final destination.
+
+  this.strand_.itemRendererParent.dispatchEvent(newEvent);
+};

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/b677c658/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/controllers/ListSingleSelectionMouseController.js
----------------------------------------------------------------------
diff --git a/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/controllers/ListSingleSelectionMouseController.js b/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/controllers/ListSingleSelectionMouseController.js
new file mode 100644
index 0000000..0d3595c
--- /dev/null
+++ b/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/controllers/ListSingleSelectionMouseController.js
@@ -0,0 +1,75 @@
+/**
+ * Licensed under the Apache License, Version 2.0 (the 'License');
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an 'AS IS' BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+goog.provide('org_apache_flex_html_beads_controllers_ListSingleSelectionMouseController');
+
+goog.require('org_apache_flex_core_IBeadController');
+goog.require('org_apache_flex_html_beads_ListView');
+goog.require('org_apache_flex_html_beads_models_ArraySelectionModel');
+
+
+
+/**
+ * @constructor
+ * @implements {org_apache_flex_core_IBeadController}
+ */
+org_apache_flex_html_beads_controllers_ListSingleSelectionMouseController = function() {
+};
+
+
+/**
+ * Metadata
+ *
+ * @type {Object.<string, Array.<Object>>}
+ */
+org_apache_flex_html_beads_controllers_ListSingleSelectionMouseController.prototype.FLEXJS_CLASS_INFO =
+    { names: [{ name: 'ListSingleSelectionMouseController',
+                qName: 'org_apache_flex_html_beads_controllers_ListSingleSelectionMouseController' }],
+      interfaces: [org_apache_flex_core_IBeadController] };
+
+
+Object.defineProperties(org_apache_flex_html_beads_controllers_ListSingleSelectionMouseController.prototype, {
+    /** @expose */
+    strand: {
+        /** @this {org_apache_flex_html_beads_controllers_ListSingleSelectionMouseController} */
+        set: function(value) {
+            this.strand_ = value;
+
+            this.model = value.getBeadByType(
+                org_apache_flex_html_beads_models_ArraySelectionModel);
+            this.listView = value.getBeadByType(
+                org_apache_flex_html_beads_ListView);
+
+            this.dataGroup = this.listView.dataGroup;
+            this.dataGroup.addEventListener('selected',
+                goog.bind(this.selectedHandler, this));
+        }
+    }
+});
+
+
+/**
+ * @expose
+ *        ListSingleSelectionMouseController}
+ * @param {Object} event The event that triggered the selection.
+ */
+org_apache_flex_html_beads_controllers_ListSingleSelectionMouseController.prototype.selectedHandler =
+        function(event) {
+
+  var index = event.target.index;
+  this.model.selectedIndex = index;
+
+  var newEvent = new org_apache_flex_events_Event('change');
+  this.strand_.dispatchEvent(newEvent);
+};

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/b677c658/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/controllers/SliderMouseController.js
----------------------------------------------------------------------
diff --git a/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/controllers/SliderMouseController.js b/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/controllers/SliderMouseController.js
new file mode 100644
index 0000000..294efb2
--- /dev/null
+++ b/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/controllers/SliderMouseController.js
@@ -0,0 +1,172 @@
+/**
+ * Licensed under the Apache License, Version 2.0 (the 'License');
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an 'AS IS' BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+goog.provide('org_apache_flex_html_beads_controllers_SliderMouseController');
+
+goog.require('org_apache_flex_html_beads_SliderThumbView');
+goog.require('org_apache_flex_html_beads_SliderTrackView');
+
+
+
+/**
+ * @constructor
+ */
+org_apache_flex_html_beads_controllers_SliderMouseController =
+    function() {
+};
+
+
+/**
+ * Metadata
+ *
+ * @type {Object.<string, Array.<Object>>}
+ */
+org_apache_flex_html_beads_controllers_SliderMouseController.prototype.FLEXJS_CLASS_INFO =
+    { names: [{ name: 'SliderMouseController',
+                qName: 'org_apache_flex_html_beads_controllers_SliderMouseController' }] };
+
+
+Object.defineProperties(org_apache_flex_html_beads_controllers_SliderMouseController.prototype, {
+    /** @expose */
+    strand: {
+        /** @this {org_apache_flex_html_beads_controllers_SliderMouseController} */
+        set: function(value) {
+            this.strand_ = value;
+
+            this.track = this.strand_.getBeadByType(
+                org_apache_flex_html_beads_SliderTrackView);
+            this.thumb = this.strand_.getBeadByType(
+                org_apache_flex_html_beads_SliderThumbView);
+
+            goog.events.listen(this.track.element, goog.events.EventType.CLICK,
+                     this.handleTrackClick, false, this);
+
+            goog.events.listen(this.thumb.element, goog.events.EventType.MOUSEDOWN,
+                     this.handleThumbDown, false, this);
+        }
+    }
+});
+
+
+/**
+ *        SliderMouseController}
+ * @param {Event} event The event triggering the function.
+ * @return {void} Handles click on track.
+ */
+org_apache_flex_html_beads_controllers_SliderMouseController.
+    prototype.handleTrackClick =
+    function(event)
+    {
+  var xloc = event.clientX;
+  var p = Math.min(1, xloc / parseInt(this.track.element.style.width, 10));
+  var n = p * (this.strand_.maximum - this.strand_.minimum) +
+          this.strand_.minimum;
+
+  this.strand_.value = n;
+
+  this.origin = parseInt(this.thumb.element.style.left, 10);
+  this.position = parseInt(this.thumb.element.style.left, 10);
+
+  this.calcValFromMousePosition(event, true);
+
+  this.strand_.dispatchEvent(new org_apache_flex_events_Event('valueChange'));
+};
+
+
+/**
+ *        SliderMouseController}
+ * @param {Event} event The event triggering the function.
+ * @return {void} Handles mouse-down on the thumb.
+ */
+org_apache_flex_html_beads_controllers_SliderMouseController.
+    prototype.handleThumbDown =
+    function(event)
+    {
+  goog.events.listen(this.strand_.element, goog.events.EventType.MOUSEUP,
+                     this.handleThumbUp, false, this);
+  goog.events.listen(this.strand_.element, goog.events.EventType.MOUSEMOVE,
+                     this.handleThumbMove, false, this);
+
+  this.origin = event.clientX;
+  this.position = parseInt(this.thumb.element.style.left, 10);
+};
+
+
+/**
+ *        SliderMouseController}
+ * @param {Event} event The event triggering the function.
+ * @return {void} Handles mouse-up on the thumb.
+ */
+org_apache_flex_html_beads_controllers_SliderMouseController.
+    prototype.handleThumbUp =
+    function(event)
+    {
+  goog.events.unlisten(this.strand_.element, goog.events.EventType.MOUSEUP,
+                       this.handleThumbUp, false, this);
+  goog.events.unlisten(this.strand_.element, goog.events.EventType.MOUSEMOVE,
+                       this.handleThumbMove, false, this);
+
+  this.calcValFromMousePosition(event, false);
+
+  this.strand_.dispatchEvent(new org_apache_flex_events_Event('valueChange'));
+};
+
+
+/**
+ *        SliderMouseController}
+ * @param {Event} event The event triggering the function.
+ * @return {void} Handles mouse-move on the thumb.
+ */
+org_apache_flex_html_beads_controllers_SliderMouseController.
+    prototype.handleThumbMove =
+    function(event)
+    {
+  this.calcValFromMousePosition(event, false);
+
+  this.strand_.dispatchEvent(new org_apache_flex_events_Event('valueChange'));
+};
+
+
+/**
+ *        SliderMouseController}
+ * @param {Event} event The event triggering the function.
+ * @param {boolean} useOffset If true, event.offsetX is used in the calculation.
+ * @return {void} Determines the new value based on the movement of the mouse
+ * along the slider.
+ */
+org_apache_flex_html_beads_controllers_SliderMouseController.
+    prototype.calcValFromMousePosition =
+    function(event, useOffset)
+    {
+  var deltaX = (useOffset ? event.offsetX : event.clientX) - this.origin;
+  var thumbW = parseInt(this.thumb.element.style.width, 10) / 2;
+  var newX = this.position + deltaX;
+
+  var p = newX / parseInt(this.track.element.style.width, 10);
+  var n = p * (this.strand_.maximum - this.strand_.minimum) +
+          this.strand_.minimum;
+  n = this.strand_.snap(n);
+  if (n < this.strand_.minimum) n = this.strand_.minimum;
+  else if (n > this.strand_.maximum) n = this.strand_.maximum;
+
+  p = (n - this.strand_.minimum) / (this.strand_.maximum -
+      this.strand_.minimum);
+  newX = p * parseInt(this.track.element.style.width, 10);
+
+  this.thumb.element.style.left = String(newX -
+      parseInt(this.thumb.element.style.width, 10) / 2) + 'px';
+
+  this.strand_.value = n;
+};
+

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/b677c658/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/controllers/SpinnerMouseController.js
----------------------------------------------------------------------
diff --git a/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/controllers/SpinnerMouseController.js b/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/controllers/SpinnerMouseController.js
new file mode 100644
index 0000000..e54acab
--- /dev/null
+++ b/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/controllers/SpinnerMouseController.js
@@ -0,0 +1,85 @@
+/**
+ * Licensed under the Apache License, Version 2.0 (the 'License');
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an 'AS IS' BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+goog.provide('org_apache_flex_html_beads_controllers_SpinnerMouseController');
+
+goog.require('org_apache_flex_html_TextButton');
+
+
+
+/**
+ * @constructor
+ */
+org_apache_flex_html_beads_controllers_SpinnerMouseController =
+    function() {
+};
+
+
+/**
+ * Metadata
+ *
+ * @type {Object.<string, Array.<Object>>}
+ */
+org_apache_flex_html_beads_controllers_SpinnerMouseController.prototype.FLEXJS_CLASS_INFO =
+    { names: [{ name: 'SpinnerMouseController',
+                qName: 'org_apache_flex_html_beads_controllers_SpinnerMouseController' }] };
+
+
+Object.defineProperties(org_apache_flex_html_beads_controllers_SpinnerMouseController.prototype, {
+    /** @expose */
+    strand: {
+        /** @this {org_apache_flex_html_beads_controllers_SpinnerMouseController} */
+        set: function(value) {
+            this.strand_ = value;
+
+            this.incrementButton = this.strand_.incrementButton;
+            this.decrementButton = this.strand_.decrementButton;
+
+            goog.events.listen(this.incrementButton.element, goog.events.EventType.CLICK,
+                goog.bind(this.handleIncrementClick, this));
+
+            goog.events.listen(this.decrementButton.element, goog.events.EventType.CLICK,
+                goog.bind(this.handleDecrementClick, this));
+        }
+    }
+});
+
+
+/**
+ *        SpinnerMouseController}
+ * @param {Object} event The event object.
+ */
+org_apache_flex_html_beads_controllers_SpinnerMouseController.
+    prototype.handleIncrementClick = function(event)
+    {
+  var newValue = this.strand_.snap(Math.min(this.strand_.maximum,
+      this.strand_.value +
+      this.strand_.stepSize));
+  this.strand_.value = newValue;
+};
+
+
+/**
+ *        SpinnerMouseController}
+ * @param {Event} event The event object.
+ */
+org_apache_flex_html_beads_controllers_SpinnerMouseController.
+    prototype.handleDecrementClick =
+    function(event)
+    {
+  var newValue = this.strand_.snap(Math.max(this.strand_.minimum,
+      this.strand_.value -
+      this.strand_.stepSize));
+  this.strand_.value = newValue;
+};

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/b677c658/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/layouts/ButtonBarLayout.js
----------------------------------------------------------------------
diff --git a/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/layouts/ButtonBarLayout.js b/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/layouts/ButtonBarLayout.js
new file mode 100644
index 0000000..0a927d3
--- /dev/null
+++ b/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/layouts/ButtonBarLayout.js
@@ -0,0 +1,118 @@
+/**
+ * Licensed under the Apache License, Version 2.0 (the 'License');
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an 'AS IS' BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+goog.provide('org_apache_flex_html_beads_layouts_ButtonBarLayout');
+
+goog.require('org_apache_flex_core_IBeadLayout');
+goog.require('org_apache_flex_html_beads_ListView');
+
+
+
+/**
+ * @constructor
+ * @implements {org_apache_flex_core_IBeadLayout}
+ */
+org_apache_flex_html_beads_layouts_ButtonBarLayout =
+    function() {
+  this.strand_ = null;
+
+  this.className = 'ButtonBarLayout';
+};
+
+
+/**
+ * Metadata
+ *
+ * @type {Object.<string, Array.<Object>>}
+ */
+org_apache_flex_html_beads_layouts_ButtonBarLayout
+    .prototype.FLEXJS_CLASS_INFO =
+    { names: [{ name: 'ButtonBarLayout',
+                qName: 'org_apache_flex_html_beads_layouts_ButtonBarLayout' }],
+      interfaces: [org_apache_flex_core_IBeadLayout] };
+
+
+Object.defineProperties(org_apache_flex_html_beads_layouts_ButtonBarLayout.prototype, {
+    /** @expose */
+    strand: {
+        /** @this {org_apache_flex_html_beads_layouts_ButtonBarLayout} */
+        set: function(value) {
+            if (this.strand_ !== value) {
+              this.strand_ = value;
+              this.strand_.addEventListener('childrenAdded',
+                  goog.bind(this.changeHandler, this));
+              this.strand_.addEventListener('itemsCreated',
+                  goog.bind(this.changeHandler, this));
+              this.strand_.addEventListener('widthChanged',
+                  goog.bind(this.changeHandler, this));
+              this.strand_.addEventListener('heightChanged',
+                  goog.bind(this.changeHandler, this));
+              this.strand_.addEventListener('sizeChanged',
+                  goog.bind(this.changeHandler, this));
+              this.strand_.element.style.display = 'block';
+            }
+        }
+    },
+    /** @expose */
+    buttonWidths: {
+        /** @this {org_apache_flex_html_beads_layouts_ButtonBarLayout} */
+        set: function(value) {
+            this.buttonWidths_ = value;
+        },
+        /** @this {org_apache_flex_html_beads_layouts_ButtonBarLayout} */
+        get: function() {
+            return this.buttonWidths_;
+        }
+    }
+});
+
+
+/**
+ * @param {org_apache_flex_events_Event} event The text getter.
+ */
+org_apache_flex_html_beads_layouts_ButtonBarLayout.
+    prototype.changeHandler = function(event) {
+
+  var layoutParent = this.strand_.getBeadByType(org_apache_flex_core_ILayoutParent);
+  var contentView = layoutParent.contentView;
+  var itemRendererParent = contentView;
+
+  var n = itemRendererParent.numElements;
+  var xpos = 0;
+  var useWidth = this.strand_.width / n;
+  var useHeight = this.strand_.height;
+
+  for (var i = 0; i < n; i++)
+  {
+    var ir = itemRendererParent.getElementAt(i);
+    ir.y = 0;
+    ir.height = useHeight;
+    ir.x = xpos;
+    ir.element.internalDisplay = 'inline-block';
+    ir.element.style['vertical-align'] = 'middle';
+    ir.element.style['text-align'] = 'center';
+    ir.element.style['left-margin'] = 'auto';
+    ir.element.style['right-margin'] = 'auto';
+
+    if (this.buttonWidths_ && !isNaN(this.buttonWidths_[i])) ir.width = this.buttonWidths_[i];
+    else ir.width = useWidth;
+
+    if (ir.element.style.display == 'none')
+      ir.lastDisplay_ = 'inline-block';
+    else
+      ir.element.style.display = 'inline-block';
+
+    xpos += ir.width;
+  }
+};

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/b677c658/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/layouts/NonVirtualBasicLayout.js
----------------------------------------------------------------------
diff --git a/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/layouts/NonVirtualBasicLayout.js b/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/layouts/NonVirtualBasicLayout.js
new file mode 100644
index 0000000..73ae4db
--- /dev/null
+++ b/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/layouts/NonVirtualBasicLayout.js
@@ -0,0 +1,134 @@
+/**
+ * Licensed under the Apache License, Version 2.0 (the 'License');
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an 'AS IS' BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+goog.provide('org_apache_flex_html_beads_layouts_NonVirtualBasicLayout');
+
+goog.require('org_apache_flex_core_IBeadLayout');
+goog.require('org_apache_flex_core_ILayoutChild');
+goog.require('org_apache_flex_core_ValuesManager');
+goog.require('org_apache_flex_utils_Language');
+
+
+
+/**
+ * @constructor
+ * @implements {org_apache_flex_core_IBeadLayout}
+ */
+org_apache_flex_html_beads_layouts_NonVirtualBasicLayout =
+    function() {
+  this.strand_ = null;
+  this.className = 'NonVirtualBasicLayout';
+};
+
+
+/**
+ * Metadata
+ *
+ * @type {Object.<string, Array.<Object>>}
+ */
+org_apache_flex_html_beads_layouts_NonVirtualBasicLayout.prototype.FLEXJS_CLASS_INFO =
+    { names: [{ name: 'NonVirtualBasicLayout',
+                qName: 'org_apache_flex_html_beads_layouts_NonVirtualBasicLayout'}],
+      interfaces: [org_apache_flex_core_IBeadLayout] };
+
+
+Object.defineProperties(org_apache_flex_html_beads_layouts_NonVirtualBasicLayout.prototype, {
+    /** @expose */
+    strand: {
+        /** @this {org_apache_flex_html_beads_layouts_NonVirtualBasicLayout} */
+        set: function(value) {
+            if (this.strand_ !== value) {
+              this.strand_ = value;
+              if (this.strand_.isWidthSizedToContent() &&
+                this.strand_.isHeightSizedToContent())
+                this.addOtherListeners();
+              else {
+                this.strand_.addEventListener('heightChanged',
+                    goog.bind(this.changeHandler, this));
+                this.strand_.addEventListener('widthChanged',
+                    goog.bind(this.changeHandler, this));
+                this.strand_.addEventListener('sizeChanged',
+                    goog.bind(this.sizeChangeHandler, this));
+
+                this.addOtherListeners();
+              }
+            }
+        }
+    }
+});
+
+
+/**
+ *
+ */
+org_apache_flex_html_beads_layouts_NonVirtualBasicLayout.
+    prototype.addOtherListeners = function() {
+  this.strand_.addEventListener('childrenAdded',
+      goog.bind(this.changeHandler, this));
+  this.strand_.addEventListener('layoutNeeded',
+     goog.bind(this.changeHandler, this));
+  this.strand_.addEventListener('itemsCreated',
+     goog.bind(this.changeHandler, this));
+};
+
+
+/**
+ * @param {org_apache_flex_events_Event} event The event.
+ */
+org_apache_flex_html_beads_layouts_NonVirtualBasicLayout.
+    prototype.sizeChangeHandler = function(event) {
+  this.addOtherListeners();
+  this.changeHandler(event);
+};
+
+
+/**
+ * @param {org_apache_flex_events_Event} event The text getter.
+ */
+org_apache_flex_html_beads_layouts_NonVirtualBasicLayout.
+    prototype.changeHandler = function(event) {
+  var i, n, h, w;
+
+  var viewBead = this.strand_.getBeadByType(org_apache_flex_core_ILayoutParent);
+  var contentView = viewBead.contentView;
+  w = contentView.width;
+  h = contentView.height;
+  n = contentView.numElements;
+  for (i = 0; i < n; i++) {
+    var child = contentView.getElementAt(i);
+    child.positioner.internalDisplay = 'block';
+    var left = org_apache_flex_core_ValuesManager.valuesImpl.getValue(child, 'left');
+    var right = org_apache_flex_core_ValuesManager.valuesImpl.getValue(child, 'right');
+    var top = org_apache_flex_core_ValuesManager.valuesImpl.getValue(child, 'top');
+    var bottom = org_apache_flex_core_ValuesManager.valuesImpl.getValue(child, 'bottom');
+
+    if (!isNaN(left)) {
+      child.positioner.style.position = 'absolute';
+      child.positioner.style.left = left.toString() + 'px';
+    }
+    if (!isNaN(top)) {
+      child.positioner.style.position = 'absolute';
+      child.positioner.style.top = top.toString() + 'px';
+    }
+    if (!isNaN(right)) {
+      child.positioner.style.position = 'absolute';
+      child.positioner.style.right = right.toString() + 'px';
+    }
+    if (!isNaN(bottom)) {
+      child.positioner.style.position = 'absolute';
+      child.positioner.style.bottom = bottom.toString() + 'px';
+    }
+    child.dispatchEvent('sizeChanged');
+  }
+};

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/b677c658/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/layouts/NonVirtualBasicScrollingLayout.js
----------------------------------------------------------------------
diff --git a/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/layouts/NonVirtualBasicScrollingLayout.js b/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/layouts/NonVirtualBasicScrollingLayout.js
new file mode 100644
index 0000000..4cdf12f
--- /dev/null
+++ b/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/layouts/NonVirtualBasicScrollingLayout.js
@@ -0,0 +1,99 @@
+/**
+ * Licensed under the Apache License, Version 2.0 (the 'License');
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an 'AS IS' BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+goog.provide('org_apache_flex_html_beads_layouts_NonVirtualBasicScrollingLayout');
+
+goog.require('org_apache_flex_core_IBeadLayout');
+
+
+
+/**
+ * @constructor
+ * @implements {org_apache_flex_core_IBeadLayout}
+ */
+org_apache_flex_html_beads_layouts_NonVirtualBasicScrollingLayout =
+    function() {
+  this.strand_ = null;
+  this.className = 'NonVirtualBasicScrollingLayout';
+};
+
+
+/**
+ * Metadata
+ *
+ * @type {Object.<string, Array.<Object>>}
+ */
+org_apache_flex_html_beads_layouts_NonVirtualBasicScrollingLayout.prototype.FLEXJS_CLASS_INFO =
+    { names: [{ name: 'NonVirtualBasicScrollingLayout',
+                qName: 'org_apache_flex_html_beads_layouts_NonVirtualBasicScrollingLayout'}],
+      interfaces: [org_apache_flex_core_IBeadLayout] };
+
+
+Object.defineProperties(org_apache_flex_html_beads_layouts_NonVirtualBasicScrollingLayout.prototype, {
+    /** @expose */
+    strand: {
+        /** @this {org_apache_flex_html_beads_layouts_NonVirtualBasicScrollingLayout} */
+        set: function(value) {
+            if (this.strand_ !== value) {
+              this.strand_ = value;
+              this.strand_.addEventListener('childrenAdded',
+                  goog.bind(this.changeHandler, this));
+              this.strand_.addEventListener('layoutNeeded',
+                  goog.bind(this.changeHandler, this));
+            }
+        }
+    }
+});
+
+
+/**
+ * @param {org_apache_flex_events_Event} event The text getter.
+ */
+org_apache_flex_html_beads_layouts_NonVirtualBasicScrollingLayout.
+    prototype.changeHandler = function(event) {
+  var i, n, h, w;
+
+  var viewBead = this.strand_.getBeadByType(org_apache_flex_core_ILayoutParent);
+  var contentView = viewBead.contentView;
+  contentView.element.style.overflow = 'auto';
+  w = contentView.width;
+  h = contentView.height;
+  n = contentView.numElements;
+  for (i = 0; i < n; i++) {
+    var child = contentView.getElementAt(i);
+    child.positioner.internalDisplay = 'block';
+    var left = org_apache_flex_core_ValuesManager.valuesImpl.getValue(child, 'left');
+    var right = org_apache_flex_core_ValuesManager.valuesImpl.getValue(child, 'right');
+    var top = org_apache_flex_core_ValuesManager.valuesImpl.getValue(child, 'top');
+    var bottom = org_apache_flex_core_ValuesManager.valuesImpl.getValue(child, 'bottom');
+
+    if (!isNaN(left)) {
+      child.positioner.style.position = 'absolute';
+      child.positioner.style.left = left.toString() + 'px';
+    }
+    if (!isNaN(top)) {
+      child.positioner.style.position = 'absolute';
+      child.positioner.style.top = top.toString() + 'px';
+    }
+    if (!isNaN(right)) {
+      child.positioner.style.position = 'absolute';
+      child.positioner.style.right = right.toString() + 'px';
+    }
+    if (!isNaN(bottom)) {
+      child.positioner.style.position = 'absolute';
+      child.positioner.style.bottom = bottom.toString() + 'px';
+    }
+    child.dispatchEvent('sizeChanged');
+  }
+};

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/b677c658/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/layouts/NonVirtualHorizontalLayout.js
----------------------------------------------------------------------
diff --git a/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/layouts/NonVirtualHorizontalLayout.js b/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/layouts/NonVirtualHorizontalLayout.js
new file mode 100644
index 0000000..514de64
--- /dev/null
+++ b/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/layouts/NonVirtualHorizontalLayout.js
@@ -0,0 +1,116 @@
+/**
+ * Licensed under the Apache License, Version 2.0 (the 'License');
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an 'AS IS' BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+goog.provide('org_apache_flex_html_beads_layouts_NonVirtualHorizontalLayout');
+
+goog.require('org_apache_flex_core_IBeadLayout');
+
+
+
+/**
+ * @constructor
+ * @implements {org_apache_flex_core_IBeadLayout}
+ */
+org_apache_flex_html_beads_layouts_NonVirtualHorizontalLayout =
+    function() {
+  this.strand_ = null;
+  this.className = 'NonVirtualHorizontalLayout';
+};
+
+
+/**
+ * Metadata
+ *
+ * @type {Object.<string, Array.<Object>>}
+ */
+org_apache_flex_html_beads_layouts_NonVirtualHorizontalLayout.
+    prototype.FLEXJS_CLASS_INFO =
+    { names: [{ name: 'NonVirtualHorizontalLayout',
+                qName: 'org_apache_flex_html_beads_layouts_NonVirtualHorizontalLayout' }],
+      interfaces: [org_apache_flex_core_IBeadLayout] };
+
+
+Object.defineProperties(org_apache_flex_html_beads_layouts_NonVirtualHorizontalLayout.prototype, {
+    /** @expose */
+    strand: {
+        /** @this {org_apache_flex_html_beads_layouts_NonVirtualHorizontalLayout} */
+        set: function(value) {
+            if (this.strand_ !== value) {
+              this.strand_ = value;
+              if (this.strand_.isWidthSizedToContent() &&
+                  this.strand_.isHeightSizedToContent())
+                this.addOtherListeners();
+              else {
+                this.strand_.addEventListener('heightChanged',
+                    goog.bind(this.changeHandler, this));
+                this.strand_.addEventListener('widthChanged',
+                    goog.bind(this.changeHandler, this));
+                this.strand_.addEventListener('sizeChanged',
+                    goog.bind(this.sizeChangeHandler, this));
+                if (!isNaN(this.strand_.explicitWidth) &&
+                    !isNaN(this.strand_.explicitHeight))
+                    this.addOtherListeners();
+              }
+              this.strand_.element.style.display = 'block';
+            }
+        }
+    }
+});
+
+
+/**
+ *
+ */
+org_apache_flex_html_beads_layouts_NonVirtualHorizontalLayout.
+    prototype.addOtherListeners = function() {
+  this.strand_.addEventListener('childrenAdded',
+      goog.bind(this.changeHandler, this));
+  this.strand_.addEventListener('layoutNeeded',
+     goog.bind(this.changeHandler, this));
+  this.strand_.addEventListener('itemsCreated',
+     goog.bind(this.changeHandler, this));
+};
+
+
+/**
+ * @param {org_apache_flex_events_Event} event The event.
+ */
+org_apache_flex_html_beads_layouts_NonVirtualHorizontalLayout.
+    prototype.sizeChangeHandler = function(event) {
+  this.addOtherListeners();
+  this.changeHandler(event);
+};
+
+
+/**
+ * @param {org_apache_flex_events_Event} event The text getter.
+ */
+org_apache_flex_html_beads_layouts_NonVirtualHorizontalLayout.
+    prototype.changeHandler = function(event) {
+  var children, i, n;
+
+  children = this.strand_.internalChildren();
+  n = children.length;
+  for (i = 0; i < n; i++)
+  {
+    var child = children[i];
+    child.internalDisplay = 'inline-block';
+    if (child.style.display == 'none')
+      child.lastDisplay_ = 'inline-block';
+    else
+      child.style.display = 'inline-block';
+    child.style.verticalAlign = 'middle';
+    child.flexjs_wrapper.dispatchEvent('sizeChanged');
+  }
+};

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/b677c658/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/layouts/NonVirtualVerticalLayout.js
----------------------------------------------------------------------
diff --git a/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/layouts/NonVirtualVerticalLayout.js b/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/layouts/NonVirtualVerticalLayout.js
new file mode 100644
index 0000000..210df3f
--- /dev/null
+++ b/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/layouts/NonVirtualVerticalLayout.js
@@ -0,0 +1,114 @@
+/**
+ * Licensed under the Apache License, Version 2.0 (the 'License');
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an 'AS IS' BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+goog.provide('org_apache_flex_html_beads_layouts_NonVirtualVerticalLayout');
+
+goog.require('org_apache_flex_core_IBeadLayout');
+
+
+
+/**
+ * @constructor
+ * @implements {org_apache_flex_core_IBeadLayout}
+ */
+org_apache_flex_html_beads_layouts_NonVirtualVerticalLayout =
+    function() {
+  this.strand_ = null;
+  this.className = 'NonVirtualVerticalLayout';
+};
+
+
+/**
+ * Metadata
+ *
+ * @type {Object.<string, Array.<Object>>}
+ */
+org_apache_flex_html_beads_layouts_NonVirtualVerticalLayout.prototype.FLEXJS_CLASS_INFO =
+    { names: [{ name: 'NonVirtualVerticalLayout',
+                qName: 'org_apache_flex_html_beads_layouts_NonVirtualVerticalLayout'}],
+      interfaces: [org_apache_flex_core_IBeadLayout] };
+
+
+Object.defineProperties(org_apache_flex_html_beads_layouts_NonVirtualVerticalLayout.prototype, {
+    /** @expose */
+    strand: {
+        /** @this {org_apache_flex_html_beads_layouts_NonVirtualVerticalLayout} */
+        set: function(value) {
+            if (this.strand_ !== value) {
+              this.strand_ = value;
+              if (this.strand_.isWidthSizedToContent() &&
+                this.strand_.isHeightSizedToContent())
+                this.addOtherListeners();
+              else {
+                this.strand_.addEventListener('heightChanged',
+                    goog.bind(this.changeHandler, this));
+                this.strand_.addEventListener('widthChanged',
+                    goog.bind(this.changeHandler, this));
+                this.strand_.addEventListener('sizeChanged',
+                    goog.bind(this.sizeChangeHandler, this));
+                if (!isNaN(this.strand_.explicitWidth) &&
+                    !isNaN(this.strand_.explicitHeight))
+                  this.addOtherListeners();
+               }
+            }
+        }
+    }
+});
+
+
+/**
+ *
+ */
+org_apache_flex_html_beads_layouts_NonVirtualVerticalLayout.
+    prototype.addOtherListeners = function() {
+  this.strand_.addEventListener('childrenAdded',
+      goog.bind(this.changeHandler, this));
+  this.strand_.addEventListener('layoutNeeded',
+     goog.bind(this.changeHandler, this));
+  this.strand_.addEventListener('itemsCreated',
+     goog.bind(this.changeHandler, this));
+};
+
+
+/**
+ * @param {org_apache_flex_events_Event} event The event.
+ */
+org_apache_flex_html_beads_layouts_NonVirtualVerticalLayout.
+    prototype.sizeChangeHandler = function(event) {
+  this.addOtherListeners();
+  this.changeHandler(event);
+};
+
+
+/**
+ * @param {org_apache_flex_events_Event} event The text getter.
+ */
+org_apache_flex_html_beads_layouts_NonVirtualVerticalLayout.
+    prototype.changeHandler = function(event) {
+  var children, i, n;
+
+  children = this.strand_.internalChildren();
+  n = children.length;
+  for (i = 0; i < n; i++)
+  {
+    var child = children[i];
+    child.internalDisplay = 'block';
+    if (child.style.display === 'none') {
+      child.lastDisplay_ = 'block';
+    } else {
+      child.style.display = 'block';
+    }
+    child.flexjs_wrapper.dispatchEvent('sizeChanged');
+  }
+};

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/b677c658/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/layouts/NonVirtualVerticalScrollingLayout.js
----------------------------------------------------------------------
diff --git a/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/layouts/NonVirtualVerticalScrollingLayout.js b/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/layouts/NonVirtualVerticalScrollingLayout.js
new file mode 100644
index 0000000..0d9fbda
--- /dev/null
+++ b/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/layouts/NonVirtualVerticalScrollingLayout.js
@@ -0,0 +1,52 @@
+/**
+ * Licensed under the Apache License, Version 2.0 (the 'License');
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an 'AS IS' BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+goog.provide('org_apache_flex_html_beads_layouts_NonVirtualVerticalScrollingLayout');
+
+goog.require('org_apache_flex_core_IBeadLayout');
+
+
+
+/**
+ * @constructor
+ * @implements {org_apache_flex_core_IBeadLayout}
+ */
+org_apache_flex_html_beads_layouts_NonVirtualVerticalScrollingLayout = function() {
+  this.strand_ = null;
+  this.className = 'NonVirtualVerticalScrollingLayout';
+};
+
+
+/**
+ * Metadata
+ *
+ * @type {Object.<string, Array.<Object>>}
+ */
+org_apache_flex_html_beads_layouts_NonVirtualVerticalScrollingLayout.prototype.FLEXJS_CLASS_INFO =
+    { names: [{ name: 'NonVirtualVerticalScrollingLayout',
+                qName: 'org_apache_flex_html_beads_layouts_NonVirtualVerticalScrollingLayout' }],
+      interfaces: [org_apache_flex_core_IBeadLayout] };
+
+
+Object.defineProperties(org_apache_flex_html_beads_layouts_NonVirtualVerticalScrollingLayout.prototype, {
+    /** @expose */
+    strand: {
+        /** @this {org_apache_flex_html_beads_layouts_NonVirtualVerticalScrollingLayout} */
+        set: function(value) {
+            if (this.strand_ !== value) {
+              this.strand_ = value;
+            }
+        }
+    }
+});

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/b677c658/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/layouts/TileLayout.js
----------------------------------------------------------------------
diff --git a/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/layouts/TileLayout.js b/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/layouts/TileLayout.js
new file mode 100644
index 0000000..72354b0
--- /dev/null
+++ b/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/layouts/TileLayout.js
@@ -0,0 +1,141 @@
+/**
+ * Licensed under the Apache License, Version 2.0 (the 'License');
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an 'AS IS' BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+goog.provide('org_apache_flex_html_beads_layouts_TileLayout');
+
+goog.require('org_apache_flex_core_IBeadLayout');
+
+
+
+/**
+ * @constructor
+ * @implements {org_apache_flex_core_IBeadLayout}
+ */
+org_apache_flex_html_beads_layouts_TileLayout =
+    function() {
+  this.strand_ = null;
+  this.className = 'TileLayout';
+};
+
+
+/**
+ * Metadata
+ *
+ * @type {Object.<string, Array.<Object>>}
+ */
+org_apache_flex_html_beads_layouts_TileLayout.prototype.FLEXJS_CLASS_INFO =
+    { names: [{ name: 'TileLayout',
+                qName: 'org_apache_flex_html_beads_layouts_TileLayout'}],
+      interfaces: [org_apache_flex_core_IBeadLayout] };
+
+
+Object.defineProperties(org_apache_flex_html_beads_layouts_TileLayout.prototype, {
+    /** @expose */
+    strand: {
+        /** @this {org_apache_flex_html_beads_layouts_TileLayout} */
+        set: function(value) {
+            if (this.strand_ !== value) {
+              this.strand_ = value;
+              this.strand_.addEventListener('childrenAdded',
+                  goog.bind(this.changeHandler, this));
+              this.strand_.addEventListener('layoutNeeded',
+                  goog.bind(this.changeHandler, this));
+            }
+        }
+    },
+    /** @expose */
+    numColumns: {
+        /** @this {org_apache_flex_html_beads_layouts_TileLayout} */
+        get: function() {
+            return this._numColumns;
+        },
+        /** @this {org_apache_flex_html_beads_layouts_TileLayout} */
+        set: function(value) {
+            this._numColumns = value;
+        }
+    },
+    /** @expose */
+    columnWidth: {
+        /** @this {org_apache_flex_html_beads_layouts_TileLayout} */
+        get: function() {
+            return this._columnWidth;
+        },
+        /** @this {org_apache_flex_html_beads_layouts_TileLayout} */
+        set: function(value) {
+            this._columnWidth = value;
+        }
+    },
+    /** @expose */
+    rowHeight: {
+        /** @this {org_apache_flex_html_beads_layouts_TileLayout} */
+        get: function() {
+            return this._rowHeight;
+        },
+        /** @this {org_apache_flex_html_beads_layouts_TileLayout} */
+        set: function(value) {
+            this._rowHeight = value;
+        }
+    }
+});
+
+
+/**
+ * @param {org_apache_flex_events_Event} event The text getter.
+ */
+org_apache_flex_html_beads_layouts_TileLayout.
+    prototype.changeHandler = function(event) {
+  var children, i, n, child;
+  var xpos, ypos, useWidth, useHeight;
+
+  children = this.strand_.internalChildren();
+  n = children.length;
+  if (n === 0) return;
+
+  var realN = n;
+  for (i = 0; i < n; i++)
+  {
+    child = children[i].flexjs_wrapper;
+    if (!child.get_visible()) realN--;
+  }
+
+  xpos = 0;
+  ypos = 0;
+  useWidth = this.columnWidth;
+  useHeight = this.rowHeight;
+
+  if (isNaN(useWidth)) useWidth = Math.floor(this.strand_.width / this.numColumns); // + gap
+  if (isNaN(useHeight)) {
+    // given the width and total number of items, how many rows?
+    var numRows = Math.floor(realN / this.numColumns);
+    useHeight = Math.floor(this.strand_.height / numRows);
+  }
+
+  for (i = 0; i < n; i++)
+  {
+    child = children[i].flexjs_wrapper;
+    if (!child.visible) continue;
+    child.positioner.internalDisplay = 'inline-block';
+    child.width = useWidth;
+    child.height = useHeight;
+    child.x = xpos;
+    child.y = ypos;
+
+    xpos += useWidth;
+
+    if (((i + 1) % this.numColumns) === 0) {
+      xpos = 0;
+      ypos += useHeight;
+    }
+  }
+};

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/b677c658/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/models/ArraySelectionModel.js
----------------------------------------------------------------------
diff --git a/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/models/ArraySelectionModel.js b/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/models/ArraySelectionModel.js
new file mode 100644
index 0000000..b222cfd
--- /dev/null
+++ b/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/models/ArraySelectionModel.js
@@ -0,0 +1,125 @@
+/**
+ * Licensed under the Apache License, Version 2.0 (the 'License');
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an 'AS IS' BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+goog.provide('org_apache_flex_html_beads_models_ArraySelectionModel');
+
+goog.require('org_apache_flex_core_ISelectionModel');
+goog.require('org_apache_flex_events_EventDispatcher');
+
+
+
+/**
+ * @constructor
+ * @extends {org_apache_flex_events_EventDispatcher}
+ * @implements {org_apache_flex_core_ISelectionModel}
+ */
+org_apache_flex_html_beads_models_ArraySelectionModel =
+    function() {
+  org_apache_flex_html_beads_models_ArraySelectionModel.base(this, 'constructor');
+  this.className = 'ArraySelectionModel';
+};
+goog.inherits(
+    org_apache_flex_html_beads_models_ArraySelectionModel,
+    org_apache_flex_events_EventDispatcher);
+
+
+/**
+ * Metadata
+ *
+ * @type {Object.<string, Array.<Object>>}
+ */
+org_apache_flex_html_beads_models_ArraySelectionModel.prototype.FLEXJS_CLASS_INFO =
+    { names: [{ name: 'ArraySelectionModel',
+                qName: 'org_apache_flex_html_beads_models_ArraySelectionModel' }],
+      interfaces: [org_apache_flex_core_ISelectionModel] };
+
+
+Object.defineProperties(org_apache_flex_html_beads_models_ArraySelectionModel.prototype, {
+    /** @expose */
+    strand: {
+        /** @this {org_apache_flex_html_beads_models_ArraySelectionModel} */
+        set: function(value) {
+            this.strand_ = value;
+        }
+    },
+    /** @expose */
+    dataProvider: {
+        /** @this {org_apache_flex_html_beads_models_ArraySelectionModel} */
+        get: function() {
+            return this.dataProvider_;
+        },
+        /** @this {org_apache_flex_html_beads_models_ArraySelectionModel} */
+        set: function(value) {
+            this.dataProvider_ = value;
+            this.dispatchEvent('dataProviderChanged');
+        }
+    },
+    /** @expose */
+    selectedIndex: {
+        /** @this {org_apache_flex_html_beads_models_ArraySelectionModel} */
+        get: function() {
+            return this.selectedIndex_;
+        },
+        /** @this {org_apache_flex_html_beads_models_ArraySelectionModel} */
+        set: function(value) {
+            this.selectedIndex_ = value;
+            this.dispatchEvent('selectedIndexChanged');
+        }
+    },
+    /** @expose */
+    selectedItem: {
+        /** @this {org_apache_flex_html_beads_models_ArraySelectionModel} */
+        get: function() {
+            var si;
+
+            si = this.selectedIndex_;
+
+            if (!this.dataProvider_ || si < 0 ||
+                si >= this.dataProvider_.length) {
+              return null;
+            }
+
+            return this.dataProvider_[si];
+        },
+        /** @this {org_apache_flex_html_beads_models_ArraySelectionModel} */
+        set: function(value) {
+            // find item in dataProvider and set selectedIndex or -1 if not exists
+
+            this.selectedIndex_ = -1;
+            var n = this.dataProvider_.length;
+            for (var i = 0; i < n; i++) {
+              var item = this.dataProvider_[i];
+              if (item == value) {
+                this.selectedIndex_ = i;
+                break;
+              }
+            }
+
+            this.dispatchEvent('selectedItemChanged');
+            this.dispatchEvent('selectedIndexChanged');
+        }
+    },
+    /** @expose */
+    labelField: {
+        /** @this {org_apache_flex_html_beads_models_ArraySelectionModel} */
+        get: function() {
+            return this.labelField_;
+        },
+        /** @this {org_apache_flex_html_beads_models_ArraySelectionModel} */
+        set: function(value) {
+            this.labelField_ = value;
+            this.dispatchEvent('labelFieldChanged');
+        }
+    }
+});

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/b677c658/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/models/DataGridModel.js
----------------------------------------------------------------------
diff --git a/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/models/DataGridModel.js b/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/models/DataGridModel.js
new file mode 100644
index 0000000..a9e4579
--- /dev/null
+++ b/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/models/DataGridModel.js
@@ -0,0 +1,72 @@
+/**
+ * Licensed under the Apache License, Version 2.0 (the 'License');
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an 'AS IS' BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+goog.provide('org_apache_flex_html_beads_models_DataGridModel');
+
+goog.require('org_apache_flex_core_IDataGridModel');
+goog.require('org_apache_flex_html_beads_models_ArraySelectionModel');
+goog.require('org_apache_flex_utils_Language');
+
+
+
+/**
+ * @constructor
+ * @extends {org_apache_flex_html_beads_models_ArraySelectionModel}
+ * @implements {org_apache_flex_core_IDataGridModel}
+ */
+org_apache_flex_html_beads_models_DataGridModel =
+    function() {
+  org_apache_flex_html_beads_models_DataGridModel.base(this, 'constructor');
+
+  this.labelFields_ = [];
+
+  this.className = 'DataGridModel';
+};
+goog.inherits(
+    org_apache_flex_html_beads_models_DataGridModel,
+    org_apache_flex_html_beads_models_ArraySelectionModel);
+
+
+/**
+ * Metadata
+ *
+ * @type {Object.<string, Array.<Object>>}
+ */
+org_apache_flex_html_beads_models_DataGridModel.prototype.FLEXJS_CLASS_INFO =
+    { names: [{ name: 'DataGridModel',
+                qName: 'org_apache_flex_html_beads_models_DataGridModel' }],
+      interfaces: [org_apache_flex_core_IDataGridModel] };
+
+
+Object.defineProperties(org_apache_flex_html_beads_models_DataGridModel.prototype, {
+    /** @expose */
+    strand: {
+        /** @this {org_apache_flex_html_beads_models_DataGridModel} */
+        set: function(value) {
+            org_apache_flex_utils_Language(org_apache_flex_html_beads_models_DataGridModel, this, 'strand', value);
+            this.strand_ = value;
+        }
+    },
+    /** @expose */
+    columns: {
+        /** @this {org_apache_flex_html_beads_models_DataGridModel} */
+        set: function(value) {
+            this.columns_ = value;
+        },
+        /** @this {org_apache_flex_html_beads_models_DataGridModel} */
+        get: function() {
+            return this.columns_;
+        }
+    }
+});

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/b677c658/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/models/ImageModel.js
----------------------------------------------------------------------
diff --git a/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/models/ImageModel.js b/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/models/ImageModel.js
new file mode 100644
index 0000000..8eec911
--- /dev/null
+++ b/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/models/ImageModel.js
@@ -0,0 +1,66 @@
+/**
+ * Licensed under the Apache License, Version 2.0 (the 'License');
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an 'AS IS' BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+goog.provide('org_apache_flex_html_beads_models_ImageModel');
+
+goog.require('org_apache_flex_core_IBeadModel');
+goog.require('org_apache_flex_events_EventDispatcher');
+
+
+
+/**
+ * @constructor
+ * @extends {org_apache_flex_events_EventDispatcher}
+ */
+org_apache_flex_html_beads_models_ImageModel =
+    function() {
+  org_apache_flex_html_beads_models_ImageModel.base(this, 'constructor');
+};
+goog.inherits(
+    org_apache_flex_html_beads_models_ImageModel,
+    org_apache_flex_events_EventDispatcher);
+
+
+/**
+ * Metadata
+ *
+ * @type {Object.<string, Array.<Object>>}
+ */
+org_apache_flex_html_beads_models_ImageModel.prototype.FLEXJS_CLASS_INFO =
+    { names: [{ name: 'ImageModel',
+                qName: 'org_apache_flex_html_beads_models_ImageModel'}],
+      interfaces: [org_apache_flex_core_IBeadModel]};
+
+
+Object.defineProperties(org_apache_flex_html_beads_models_ImageModel.prototype, {
+    /** @expose */
+    strand: {
+        /** @this {org_apache_flex_html_beads_models_ImageModel} */
+        set: function(value) {
+            this.strand_ = value;
+        }
+    },
+    /** @expose */
+    source: {
+        /** @this {org_apache_flex_html_beads_models_ImageModel} */
+        get: function() {
+            return this.source_;
+        },
+        /** @this {org_apache_flex_html_beads_models_ImageModel} */
+        set: function(value) {
+            this.source_ = value;
+            this.dispatchEvent('sourceChanged');
+        }
+    }
+});

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/b677c658/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/models/ListPresentationModel.js
----------------------------------------------------------------------
diff --git a/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/models/ListPresentationModel.js b/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/models/ListPresentationModel.js
new file mode 100644
index 0000000..11167bf
--- /dev/null
+++ b/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/models/ListPresentationModel.js
@@ -0,0 +1,75 @@
+/**
+ * Licensed under the Apache License, Version 2.0 (the 'License');
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an 'AS IS' BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+goog.provide('org_apache_flex_html_beads_models_ListPresentationModel');
+
+goog.require('org_apache_flex_core_IListPresentationModel');
+goog.require('org_apache_flex_events_EventDispatcher');
+
+
+
+/**
+ * @constructor
+ * @extends {org_apache_flex_events_EventDispatcher}
+ * @implements {org_apache_flex_core_IListPresentationModel}
+ */
+org_apache_flex_html_beads_models_ListPresentationModel =
+    function() {
+  org_apache_flex_html_beads_models_ListPresentationModel.base(this, 'constructor');
+  this.className = 'ListPresentationModel';
+};
+goog.inherits(
+    org_apache_flex_html_beads_models_ListPresentationModel,
+    org_apache_flex_events_EventDispatcher);
+
+
+/**
+ * @private
+ * @type {number}
+ */
+org_apache_flex_html_beads_models_ListPresentationModel.prototype.rowHeight_ = 30;
+
+
+/**
+ * Metadata
+ *
+ * @type {Object.<string, Array.<Object>>}
+ */
+org_apache_flex_html_beads_models_ListPresentationModel.prototype.FLEXJS_CLASS_INFO =
+    { names: [{ name: 'ListPresentationModel',
+                qName: 'org_apache_flex_html_beads_models_ListPresentationModel' }],
+      interfaces: [org_apache_flex_core_IListPresentationModel] };
+
+
+Object.defineProperties(org_apache_flex_html_beads_models_ListPresentationModel.prototype, {
+    /** @expose */
+    strand: {
+        /** @this {org_apache_flex_html_beads_models_ListPresentationModel} */
+        set: function(value) {
+            this.strand_ = value;
+        }
+    },
+    /** @expose */
+    rowHeight: {
+        /** @this {org_apache_flex_html_beads_models_ListPresentationModel} */
+        get: function() {
+            return this.rowHeight_;
+        },
+        /** @this {org_apache_flex_html_beads_models_ListPresentationModel} */
+        set: function(value) {
+            this.rowHeight_ = value;
+            this.dispatchEvent('rowHeightChanged');
+        }
+    }
+});

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/b677c658/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/models/PanelModel.js
----------------------------------------------------------------------
diff --git a/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/models/PanelModel.js b/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/models/PanelModel.js
new file mode 100644
index 0000000..0f2c434
--- /dev/null
+++ b/frameworks/projects/HTML/js/src/org/apache/flex/html/beads/models/PanelModel.js
@@ -0,0 +1,109 @@
+/**
+ * Licensed under the Apache License, Version 2.0 (the 'License');
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an 'AS IS' BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+goog.provide('org_apache_flex_html_beads_models_PanelModel');
+
+goog.require('org_apache_flex_events_EventDispatcher');
+
+
+
+/**
+ * @constructor
+ * @extends {org_apache_flex_events_EventDispatcher}
+ */
+org_apache_flex_html_beads_models_PanelModel = function() {
+  org_apache_flex_html_beads_models_PanelModel.base(this, 'constructor');
+
+  /**
+   * @private
+   * @type {string}
+   */
+  this.title_ = '';
+  /**
+   * @private
+   * @type {string}
+   */
+  this.htmlTitle_ = '';
+  /**
+   * @private
+   * @type {boolean}
+   */
+  this.showCloseButton_ = false;
+};
+goog.inherits(org_apache_flex_html_beads_models_PanelModel,
+    org_apache_flex_events_EventDispatcher);
+
+
+/**
+ * Metadata
+ *
+ * @type {Object.<string, Array.<Object>>}
+ */
+org_apache_flex_html_beads_models_PanelModel.prototype.FLEXJS_CLASS_INFO =
+    { names: [{ name: 'PanelModel',
+                qName: 'org_apache_flex_html_beads_models_PanelModel'}],
+      interfaces: [org_apache_flex_core_IBeadModel] };
+
+
+Object.defineProperties(org_apache_flex_html_beads_models_PanelModel.prototype, {
+    /** @expose */
+    strand: {
+        /** @this {org_apache_flex_html_beads_models_PanelModel} */
+        set: function(value) {
+            this.strand_ = value;
+        }
+    },
+    /** @expose */
+    title: {
+        /** @this {org_apache_flex_html_beads_models_PanelModel} */
+        get: function() {
+            return this.title_;
+        },
+        /** @this {org_apache_flex_html_beads_models_PanelModel} */
+        set: function(value) {
+            if (this.title_ != value) {
+              this.title_ = value;
+              this.dispatchEvent('titleChange');
+            }
+        }
+    },
+    /** @expose */
+    htmlTitle: {
+        /** @this {org_apache_flex_html_beads_models_PanelModel} */
+        get: function() {
+            return this.htmlTitle_;
+        },
+        /** @this {org_apache_flex_html_beads_models_PanelModel} */
+        set: function(value) {
+            if (this.htmlTitle_ != value) {
+              this.htmlTitle_ = value;
+              this.dispatchEvent('htmlTitleChange');
+            }
+        }
+    },
+    /** @expose */
+    showCloseButton: {
+        /** @this {org_apache_flex_html_beads_models_PanelModel} */
+        get: function() {
+            return this.showCloseButton_;
+        },
+        /** @this {org_apache_flex_html_beads_models_PanelModel} */
+        set: function(value) {
+            if (this.showCloseButton_ != value) {
+              this.showCloseButton_ = value;
+              this.dispatchEvent('showCloseButtonChange');
+            }
+        }
+    }
+});