• Topic
  • Discussion
  • OATWikiWeb.OATDOCcombobox(Last) -- Owiki? , 2016-08-19 14:58:50 Edit owiki 2016-08-19 14:58:50


    Creates a combobox, an enhanced <select> which allows richer options.



    Creates a combobox with a value of defaultValue. Its main div is accessible as OAT.Combobox::div. Onchange callback may be set via OAT.Combobox::onchange property.


    OAT.Combobox::addOption(element, textValue)

    Adds a new option, represented by element with a value of textValue.

    CSS classes


    CSS class of the main combo box div.


    CSS class of options list div.


    CSS class of the currently selected option.


    CSS class of the dropdown clicker image.


    var cb = new OAT.Combobox("[choose here]");
    document.body.appendChild( cb.div );
    cb.addOption(someElement, "option 1");
    cb.addOption(someOtherElement, "option 2");

    Referenced by...