Select
Extends:
DOMElement → Select
Class used to handle select elements (<select>).
Example:
// Given the following HTML select element:
// <select id="fx" name="fx">
// <option value="1">Option 1</option>
// <option value="2">Option 2</option>
// <option value="3">Option 3</option>
// </select>
var fx = new Select("fx", function(val) {
console.log(val);
});
Constructor Summary
Public Constructor | ||
public |
constructor(id: string, onChange: function) |
Member Summary
Public Members | ||
public |
Callback function for when the selected option changes. |
|
public |
Current option selected. |
Method Summary
Public Methods | ||
public |
setOptions(options: Object, select: Number) Sets the options for the select element. |
Inherited Summary
From class DOMElement | ||
public |
Stores if the element is enabled or disabled. |
|
public |
jQuery reference to the element. |
|
public |
Enable or disable the DOM element. |