/**
 * Generated by Apache Royale Compiler from org\apache\royale\html\supportClasses\MXMLItemRenderer.as
 * org.apache.royale.html.supportClasses.MXMLItemRenderer
 *
 * @fileoverview
 *
 * @suppress {checkTypes|accessControls}
 */

goog.provide('org.apache.royale.html.supportClasses.MXMLItemRenderer');

goog.require('org.apache.royale.core.IBeadLayout');
goog.require('org.apache.royale.core.ILayoutHost');
goog.require('org.apache.royale.core.ILayoutView');
goog.require('org.apache.royale.events.Event');
goog.require('org.apache.royale.html.supportClasses.DataItemRenderer');
goog.require('org.apache.royale.core.ILayoutParent');
goog.require('org.apache.royale.core.IStrand');
goog.require('org.apache.royale.utils.Language');



/**
 *  constructor.
 *
 *  @langversion 3.0
 *  @playerversion Flash 10.2
 *  @playerversion AIR 2.6
 *  @productversion Royale 0.0
 * @constructor
 * @extends {org.apache.royale.html.supportClasses.DataItemRenderer}
 * @implements {org.apache.royale.core.ILayoutParent}
 * @implements {org.apache.royale.core.ILayoutHost}
 * @implements {org.apache.royale.core.IStrand}
 * @implements {org.apache.royale.core.ILayoutView}
 */
org.apache.royale.html.supportClasses.MXMLItemRenderer = function() {
  org.apache.royale.html.supportClasses.MXMLItemRenderer.base(this, 'constructor');
  this.typeNames = "MXMLItemRenderer";
};
goog.inherits(org.apache.royale.html.supportClasses.MXMLItemRenderer, org.apache.royale.html.supportClasses.DataItemRenderer);


/**
 * Prevent renaming of class. Needed for reflection.
 */
goog.exportSymbol('org.apache.royale.html.supportClasses.MXMLItemRenderer', org.apache.royale.html.supportClasses.MXMLItemRenderer);


/**
 * @export
 * @return {org.apache.royale.core.ILayoutHost}
 */
org.apache.royale.html.supportClasses.MXMLItemRenderer.prototype.getLayoutHost = function() {
  return this;
};


/**
 * @export
 * @override
 */
org.apache.royale.html.supportClasses.MXMLItemRenderer.prototype.adjustSize = function() {
  var /** @type {org.apache.royale.core.IBeadLayout} */ layout = org.apache.royale.utils.Language.as(this.getBeadByType(org.apache.royale.core.IBeadLayout), org.apache.royale.core.IBeadLayout);
  if (layout != null) {
    layout.layout();
  }
};


/**
 * @export
 */
org.apache.royale.html.supportClasses.MXMLItemRenderer.prototype.beforeLayout = function() {
};


/**
 * @export
 */
org.apache.royale.html.supportClasses.MXMLItemRenderer.prototype.afterLayout = function() {
};


org.apache.royale.html.supportClasses.MXMLItemRenderer.prototype.set__data = function(value) {
  if (value != this.data) {
    org.apache.royale.html.supportClasses.MXMLItemRenderer.superClass_.set__data.apply(this, [ value] );
    this.dispatchEvent(new org.apache.royale.events.Event("dataChange"));
  }
};


org.apache.royale.html.supportClasses.MXMLItemRenderer.prototype.get__contentView = function() {
  return this;
};


Object.defineProperties(org.apache.royale.html.supportClasses.MXMLItemRenderer.prototype, /** @lends {org.apache.royale.html.supportClasses.MXMLItemRenderer.prototype} */ {
/**
  * @export
  * @type {Object} */
data: {
get: org.apache.royale.html.supportClasses.UIItemRendererBase.prototype.get__data,
set: org.apache.royale.html.supportClasses.MXMLItemRenderer.prototype.set__data},
/**
  * @export
  * @type {org.apache.royale.core.ILayoutView} */
contentView: {
get: org.apache.royale.html.supportClasses.MXMLItemRenderer.prototype.get__contentView}}
);


/**
 * Metadata
 *
 * @type {Object.<string, Array.<Object>>}
 */
org.apache.royale.html.supportClasses.MXMLItemRenderer.prototype.ROYALE_CLASS_INFO = { names: [{ name: 'MXMLItemRenderer', qName: 'org.apache.royale.html.supportClasses.MXMLItemRenderer', kind: 'class' }], interfaces: [org.apache.royale.core.ILayoutParent, org.apache.royale.core.ILayoutHost, org.apache.royale.core.IStrand, org.apache.royale.core.ILayoutView] };



/**
 * Reflection
 *
 * @return {Object.<string, Function>}
 */
org.apache.royale.html.supportClasses.MXMLItemRenderer.prototype.ROYALE_REFLECTION_INFO = function () {
  return {
    variables: function () {return {};},
    accessors: function () {
      return {
        'data': { type: 'Object', access: 'writeonly', declaredBy: 'org.apache.royale.html.supportClasses.MXMLItemRenderer', metadata: function () { return [ { name: 'Bindable', args: [ { key: '', value: 'dataChange' } ] } ]; }},
        'contentView': { type: 'org.apache.royale.core.ILayoutView', access: 'readonly', declaredBy: 'org.apache.royale.html.supportClasses.MXMLItemRenderer'}
      };
    },
    methods: function () {
      return {
        'MXMLItemRenderer': { type: '', declaredBy: 'org.apache.royale.html.supportClasses.MXMLItemRenderer'},
        'getLayoutHost': { type: 'org.apache.royale.core.ILayoutHost', declaredBy: 'org.apache.royale.html.supportClasses.MXMLItemRenderer'},
        'adjustSize': { type: 'void', declaredBy: 'org.apache.royale.html.supportClasses.MXMLItemRenderer'},
        'beforeLayout': { type: 'void', declaredBy: 'org.apache.royale.html.supportClasses.MXMLItemRenderer'},
        'afterLayout': { type: 'void', declaredBy: 'org.apache.royale.html.supportClasses.MXMLItemRenderer'}
      };
    }
  };
};