C++ ListModel Manager for ComboBox and ListBox Hook Classes

For many years we have written dialog item hook functions using procedural code.  You can continue that way with MicroStation CONNECT, but the MicroStationAPI offers a better way: dialog and dialog item hook classes.

The hook classes replace the MDL switch decision tree with the DialogHookHandler and DialogItemHookHandler classes that provides virtual event handler methods such as _OnCreate().  The ListModelManager class goes one step further: it provides dialog item specific methods to assign and deallocate the ListModel using by ComboBox and ListBox dialog items.

ListModelManager is a template class.  It offers specialised handlers for ComboBox and ListBox dialog items.  They improve your code by using the correct set/get methods and by always destroying the ListModel in the _OnDestroy() event.