Added documentation, fixed view update