added the select and deselect methods to display.cpp