This interface is used to notify a SELECT when OPTION
 elements are added and removed from its subtree.
 Note that the nsIDOMHTMLSelectElement and nsIContent 
 interfaces are the ones to use to access and enumerate
 OPTIONs within a SELECT element.
[scriptable, uuid(35bd8ed5-5f34-4126-8c4f-38ba01681836)]
interface nsISelectElement : nsISupports

Attributes

 Whether or not there are optgroups in this select */
readonly attribute boolean hasOptGroups

Methods

 Finds the index of a given option element

 @param aOption the option to get the index of
 @param aStartIndex the index to start looking at
 @param aForward TRUE to look forward, FALSE to look backward
 @return the option index
long getOptionIndex(in nsIDOMHTMLOptionElement aOption, in long aStartIndex, in boolean aForward)
 Checks whether an option is disabled (even if it's part of an optgroup)

 @param aIndex the index of the option to check
 @return whether the option is disabled
boolean isOptionDisabled(in long aIndex)
 Sets multiple options (or just sets startIndex if select is single)
 and handles notifications and cleanup and everything under the sun.
 When this method exits, the select will be in a consistent state.  i.e.
 if you set the last option to false, it will select an option anyway.

 @param aStartIndex the first index to set
 @param aEndIndex the last index to set (set same as first index for one
        option)
 @param aIsSelected whether to set the option(s) to true or false
 @param aClearAll whether to clear all other options (for example, if you
        are normal-clicking on the current option)
 @param aSetDisabled whether it is permissible to set disabled options
        (for JavaScript)
 @param aNotify whether to notify frames and such
 @return whether any options were actually changed
boolean setOptionsSelectedByIndex(in long aStartIndex, in long aEndIndex, in boolean aIsSelected, in boolean aClearAll, in boolean aSetDisabled, in boolean aNotify)
 To be called when stuff is added under a child of the select--but *before*
 they are actually added.

 @param aOptions the content that was added (usually just an option, but
        could be an optgroup node with many child options)
 @param aParent the parent the options were added to (could be an optgroup)
 @param aContentIndex the index where the options are being added within the
        parent (if the parent is an optgroup, the index within the optgroup)
[noscript] void willAddOptions(in nsIContent aOptions, in nsIContent aParent, in long aContentIndex)
 To be called when stuff is removed under a child of the select--but
 *before* they are actually removed.

 @param aParent the parent the option(s) are being removed from
 @param aContentIndex the index of the option(s) within the parent (if the
        parent is an optgroup, the index within the optgroup)
[noscript] void willRemoveOptions(in nsIContent aParent, in long aContentIndex)