Exploiting Polymorphism
Exploiting Polymorphism
- Widgets react differently to input events depending on their types:
- Mouse click on a button activates it
- Mouse click on a menu bar pops the menu
- Derived classes override the virtual functions declared in the abstract base class