First of all, lets me thank you for you good work. It's a very good contral for me, but when i use it, I found that
even a item has been disabled but it still could send the item selected changed message to the parent window, so I rewrite the OnLButtonDown function to fix this question.
Nice class, but you forgot to release the CDC in CListBoxST::MeasureItem(...)! This leads to huge resource leaks when you call CListBoxST::AddString(...) many times for huge lists! To avoid this, just add the last line to CListBoxST::MeasureItem(...) :