Skip to content

Commit

Permalink
feat(edit): raise beginCellEdit in timeout
Browse files Browse the repository at this point in the history
allows complex editors time to render so they can properly attach to the beginCellEdit event
  • Loading branch information
swalters committed Jul 31, 2015
1 parent 708231f commit 6b5807f
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/features/edit/js/gridEdit.js
Original file line number Diff line number Diff line change
Expand Up @@ -774,7 +774,10 @@
});

$scope.$broadcast(uiGridEditConstants.events.BEGIN_CELL_EDIT, triggerEvent);
$scope.grid.api.edit.raise.beginCellEdit($scope.row.entity, $scope.col.colDef, triggerEvent);
$timeout(function () {
//execute in a timeout to give any complex editor templates a cycle to completely render
$scope.grid.api.edit.raise.beginCellEdit($scope.row.entity, $scope.col.colDef, triggerEvent);
});
}

function endEdit() {
Expand Down

0 comments on commit 6b5807f

Please sign in to comment.