| home | |||
|
|||
| links |
|
||
|
developer's mag main page article part 1 part 2 part 3 part 4 part 5 part 6 |
3 - Parents and ChildrenThis array of CBaseObject class objects is, well, the base the objects are created out of. This virtual class is inherited by each child class to become something different. For example, CObjRadioButton is the radio button, CObjTextEdit is the text edit control, and so on. The base class is also where most of the code lies, which the children classes only change (override) when necessary, such as when drawing.For instance, all visual objects have a size associated with them, so the base class can be in charge of the setting and getting of size information safely. In a few exceptions, such as the scrollbar and progress bar (which can only adjust their height or width, but not both), the child class overrides the function, and defines its own implementation. Previous Section Next Section |
||
| Copyright © 2001-2006 ebmDevMag.com - Legal Notice | |||