/** * @brief Called when new dirdoc is created. */ BOOL CDirDoc::OnNewDocument() { if (!CDocument::OnNewDocument()) return FALSE; GetMainView()->GetParentFrame()->SetClosableCallback(&DocClosableCallback, this); return TRUE; }
BOOL CSolarSystemDoc::OnNewDocument() { if (!CDocument::OnNewDocument()) return FALSE; // TODO: add reinitialization code here // (SDI documents will reuse this document) LoadFile(CString(L"SolarSystem.xml")); GetMainView()->Setup(); StartThread(); return TRUE; }