Object Oriented Programming and Tabs

this is not such a great OOP approach as your class depends on the display instance to exist... You should pass a reference to the display to your constructor