src/aria/widgets/form/list/ListController.js
function (newlySelectedIndexes, newlyUnselectedIndexes) {
            var data = this._data;
            if (newlySelectedIndexes.length === 0 && data.selectedCount === 0) {
                var preselect = this._checkPreselect();
                if (preselect != null) {
                    newlySelectedIndexes = [preselect];
                    this.json.setValue(data.itemsView.items[preselect].value, "selected", true);
                    this.json.setValue(data, "selectedIndex", preselect);
                    this.json.setValue(data, "selectedCount", 1);
                }
            }

            this.$raiseEvent({
                name : "onChange",
                selectedIndexes : newlySelectedIndexes,
                unselectedIndexes : newlyUnselectedIndexes
            });
        }
function (newlySelectedIndexes, newlyUnselectedIndexes) {
            var data = this._data;
            if (newlySelectedIndexes.length === 0 && data.selectedCount === 0) {
                var preselect = this._checkPreselect();
                if (preselect != null) {
                    newlySelectedIndexes = [preselect];
                    this.json.setValue(data.itemsView.items[preselect].value, "selected", true);
                    this.json.setValue(data, "selectedIndex", preselect);
                    this.json.setValue(data, "selectedCount", 1);
                }
            }

            this.$raiseEvent({
                name : "onChange",
                selectedIndexes : newlySelectedIndexes,
                unselectedIndexes : newlyUnselectedIndexes
            });
        }
function ( newlySelectedIndexes , newlyUnselectedIndexes ) { var data = this . _data ; if ( newlySelectedIndexes . length === 0 && data . selectedCount === 0 ) { var preselect = this . _checkPreselect ( ) ; if ( preselect != null ) { newlySelectedIndexes = [ preselect ] ; this . json . setValue ( data . itemsView . items [ preselect ] . value , "selected" , true ) ; this . json . setValue ( data , "selectedIndex" , preselect ) ; this . json . setValue ( data , "selectedCount" , 1 ) ; } } this . $raiseEvent ( { name : "onChange" , selectedIndexes : newlySelectedIndexes , unselectedIndexes : newlyUnselectedIndexes } ) ; }
Raises the onChange event
@protected
@param {Array} newlySelectedIndexes array of newly selected indexes
@param {Array} newlyUnselectedIndexes array of newly unselected indexes
Raises the onChange event