Added methods to get next and previous view.