Added onAttach onDetach hook to ViewImpl

Good point.