Fix to the toggle view, implemented the click listener