()
| 1017 | } |
| 1018 | |
| 1019 | private _initializeSelection(): void { |
| 1020 | // Defer setting the value in order to avoid the "Expression |
| 1021 | // has changed after it was checked" errors from Angular. |
| 1022 | Promise.resolve().then(() => { |
| 1023 | if (this.ngControl) { |
| 1024 | this._value = this.ngControl.value; |
| 1025 | } |
| 1026 | |
| 1027 | this._setSelectionByValue(this._value); |
| 1028 | this.stateChanges.next(); |
| 1029 | }); |
| 1030 | } |
| 1031 | |
| 1032 | /** |
| 1033 | * Sets the selected option based on a value. If no option can be |
no test coverage detected