The Shortcut Bar Classes
The Shortcut bar is implemented in the SECShortcutBar class, which is derived from CWnd. SECShortcutBar utilizes the classes SECBar or SECListBar and SECShortcutListCtrl to display the bars and windows that it contains.
Figure 98 – Objective Toolkit shortcut bar class hierarchy
SECShortcutBar
The SECShortcutBar class derives from CWnd, and it acts as a container class for other CWnd-derived objects. Because it is CWnd-derived, SECShortcutBar can also be held by other CWnd-derived objects.
The bars that are displayed in the SECShortcutBar window are either instantiations of SECBar or SECListBar, or a combination, depending on the overload of AddBar(), which was called to create them. If the SECShortcutBar is acting as a container for an arbitrary CWnd object, the bar is of type SECBar. If the SECShortcutBar is a container for a Microsoft Outlook Bar™-like list of icons, the bar is of type SECListBar and the window that displays the list of icons is of type SECShortcutListCtrl. The following figures are of these contained bars and windows.
Figure 99 – Containment of SECBar in SECShortcutBar
Figure 100 – Containment of SECListBar and SECShortcutListCtrl in SECShortcutBar
SECBar
An SECBar object represents a single bar window that a user can select. It is displayed inside the SECShortcutBar window. An SECBar object is created when the version of AddBar() that accepts a CWnd parameter is called. A bar that contains the embedded CWnd object is added to the shortcut bar.
SECListBar
The SECListBar class derives from SECBar and represents a single bar window that a user can select. It is displayed inside the SECShortcutBar window. Every time a bar that contains an embedded SECShortcutListCtrl (displays icons like the Microsoft Outlook Bar™) is added, an SECListBar is created.
If you use an SECBar derivative class, you can mix bars of different types in the shortcut bar. For example, one bar can contain an SECListBar and another can contain an SECBar with an SECTreeCtrl associated with it.
SECShortcutListCtrl
The SECShortcutListCtrl contains the list of labeled icons that will appear in a pane in the Shortcut bar.