Skip to content
This repository has been archived by the owner on Feb 22, 2018. It is now read-only.

Commit

Permalink
fix(NgModel): Read the view value in the flush phase
Browse files Browse the repository at this point in the history
This code was originally authored by @mhevery in the
DirectiveInjector change.
  • Loading branch information
jbdeboer committed Jul 9, 2014
1 parent 6f3587d commit 75c2f17
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion lib/directive/ng_model_select.dart
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,9 @@ class InputSelect implements AttachAware {
_model.watchCollection = true;
_mode = new _MultipleSelectionMode(expando, _selectElement, _model);
}
_mode.onModelChange(_model.viewValue);
_scope.rootScope.domRead(() {
_mode.onModelChange(_model.viewValue);
});
});

_selectElement.onChange.listen((event) => _mode.onViewChange(event));
Expand Down

0 comments on commit 75c2f17

Please sign in to comment.