void Subclassed::Subclass(WNDPROC wndProc) { ::SetWindowLong(hwnd, GWL_USERDATA, (LONG) this); oldProc = (WNDPROC) ::SetWindowLong(hwnd, GWL_WNDPROC, (LONG) wndProc); OnSubclass(); }
LRESULT C_Edit::OnCreate(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled) { C_STLException::install(); try { OnSubclass(); } catch (C_STLNonStackException const &exception) { exception.Log(_T("Exception in C_Edit::OnCreate")); } return S_OK; }