MCPcopy Index your code
hub / github.com/angular-ui/ui-grid / setOptionSelectedStatus

Function setOptionSelectedStatus

lib/test/angular/1.7.0/angular.js:33663–33673  ·  view source on GitHub ↗
(optionEl, value)

Source from the content-addressed store, hash-verified

33661var noopNgModelController = { $setViewValue: noop, $render: noop };
33662
33663function setOptionSelectedStatus(optionEl, value) {
33664 optionEl.prop('selected', value);
33665 /**
33666 * When unselecting an option, setting the property to null / false should be enough
33667 * However, screenreaders might react to the selected attribute instead, see
33668 * https://github.com/angular/angular.js/issues/14419
33669 * Note: "selected" is a boolean attr and will be removed when the "value" arg in attr() is false
33670 * or null
33671 */
33672 optionEl.attr('selected', value);
33673}
33674
33675/**
33676 * @ngdoc type

Callers 2

angular.jsFile · 0.70
selectPreLinkFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected