Bitmap on statusbarPane
Posted on 1998-02-08
I want to put bitmaps on two of my status bar panes. I have included two Ids in my mainframe.cpp file as follows:
static UINT indicators =
ID_SEPARATOR, // status line indicator
ID_INDICATOR_ACCESS, // Needs bitmap
ID_INDICATOR_ALARM // Needs bitmap
I set the style of my last two panes to "SBT_OWNERDRAWN", by calling "SetPaneStyle".
I derived a class "CMyStatusBar" from CStatusBar, and am overriding "OnDrawItem". But the control doesnt come to "OnDrawItem". The data member "m_wndStatusBar" is now a member of "CMyStatusBar". The control goes to the constructor of "CMyStatusBar", but the "OnDrawItem" is not called. Hence I am unable to put the bitmap on the status bar panes. Can any of you let me know the possible causes?
Thanks in advance