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

goog.provide('org.apache.royale.html.beads.UnselectableElementBead');

goog.require('org.apache.royale.core.IStrand');
goog.require('org.apache.royale.core.IUIBase');
goog.require('org.apache.royale.core.IBead');
goog.require('org.apache.royale.utils.Language');



/**
 *  constructor.
 *
 *  @langversion 3.0
 *  @playerversion Flash 10.2
 *  @playerversion AIR 2.6
 *  @productversion Royale 0.8
 * @constructor
 * @implements {org.apache.royale.core.IBead}
 */
org.apache.royale.html.beads.UnselectableElementBead = function() {
};


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


/**
 * @royaleignorecoercion HTMLStyleElement
 * @private
 */
org.apache.royale.html.beads.UnselectableElementBead.org_apache_royale_html_beads_UnselectableElementBead_insertRule = function() {
  if (org.apache.royale.html.beads.UnselectableElementBead.org_apache_royale_html_beads_UnselectableElementBead_ruleInserted)
    return;
  org.apache.royale.html.beads.UnselectableElementBead.org_apache_royale_html_beads_UnselectableElementBead_ruleInserted = true;
  var /** @type {HTMLStyleElement} */ style = document.createElement('style');
  style.type = 'text/css';
  style.innerHTML = '.unselectable {-moz-user-select: none;-webkit-user-select: none;-ms-user-select: none;user-select: none;}';
  document.getElementsByTagName('head')[0].appendChild(style);
};


/**
 * @private
 * @type {boolean}
 */
org.apache.royale.html.beads.UnselectableElementBead.org_apache_royale_html_beads_UnselectableElementBead_ruleInserted;


/**
 * @private
 * @type {org.apache.royale.core.IStrand}
 */
org.apache.royale.html.beads.UnselectableElementBead.prototype.org_apache_royale_html_beads_UnselectableElementBead__strand;


org.apache.royale.html.beads.UnselectableElementBead.prototype.set__strand = function(value) {
  org.apache.royale.html.beads.UnselectableElementBead.org_apache_royale_html_beads_UnselectableElementBead_insertRule();
  this.org_apache_royale_html_beads_UnselectableElementBead__strand = value;
  var /** @type {org.apache.royale.core.IUIBase} */ host = org.apache.royale.utils.Language.as(value, org.apache.royale.core.IUIBase);
  host.element.classList.add("unselectable");
};


Object.defineProperties(org.apache.royale.html.beads.UnselectableElementBead.prototype, /** @lends {org.apache.royale.html.beads.UnselectableElementBead.prototype} */ {
/**
  * @export
  * @type {org.apache.royale.core.IStrand} */
strand: {
set: org.apache.royale.html.beads.UnselectableElementBead.prototype.set__strand}}
);


/**
 * Metadata
 *
 * @type {Object.<string, Array.<Object>>}
 */
org.apache.royale.html.beads.UnselectableElementBead.prototype.ROYALE_CLASS_INFO = { names: [{ name: 'UnselectableElementBead', qName: 'org.apache.royale.html.beads.UnselectableElementBead', kind: 'class' }], interfaces: [org.apache.royale.core.IBead] };



/**
 * Reflection
 *
 * @return {Object.<string, Function>}
 */
org.apache.royale.html.beads.UnselectableElementBead.prototype.ROYALE_REFLECTION_INFO = function () {
  return {
    variables: function () {return {};},
    accessors: function () {
      return {
        'strand': { type: 'org.apache.royale.core.IStrand', access: 'writeonly', declaredBy: 'org.apache.royale.html.beads.UnselectableElementBead'}
      };
    },
    methods: function () {
      return {
        'UnselectableElementBead': { type: '', declaredBy: 'org.apache.royale.html.beads.UnselectableElementBead'}
      };
    }
  };
};