Matt,
Here's my chain map:
BEGIN_MSG_MAP(CInterface)
CHAIN_MSG_MAP(CComControl<CInterface>)
DEFAULT_REFLECTION_HANDLER()
MESSAGE_HANDLER(WM_SIZE, OnSize)
MESSAGE_HANDLER(WM_CREATE, OnCreate)
MESSAGE_HANDLER(WM_SETCURSOR, OnSetCursor)
MESSAGE_HANDLER(WM_ERASEBKGND, OnEraseBkgnd)
END_MSG_MAP()
And I can definately state that OnCreate is called prior to Init as here is what I do:
LRESULT CInterface::OnCreate(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled)
{
AFX_MANAGE_STATE( AfxGetStaticModuleState() );
// Store the hWnd
AlbumView::m_hWnd = m_hWndCD;
// Are we on Windows XP?
OSVERSIONINFO vi;
vi.dwOSVersionInfoSize = sizeof( vi );
GetVersionEx( &vi );
m_bIsXPOrGreater = ( vi.dwMajorVersion > 5 || (vi.dwMajorVersion == 5 && vi.dwMinorVersion >= 1) );
m_hAppIcon = AfxGetApp()->LoadIcon( IDI_APP_ICON );
// TODO : Add Code for message handler. Call DefWindowProc if necessary.
return DefWindowProc( uMsg, wParam, lParam );
}
And in Init I use AlbumView::m_hWnd as the parent hWnd for all my top level controls.
I will download the latest version of v9 tomorrow and try it again but nothing has changed from my end so it must be something within MJ.
As a test do you have a version of sleep timer converted to work under MJ9? Maybe we could use that to identify the issue?