Changed listener implementation for before and after view change
Optimized imports