void CMainFrame::ActivateFrame(int nCmdShow) { // filter the first time of ActivateFrame,which be called // in CTApp::InitInstance() during following code // OnFileNew(); // bring a flash on screen,so filter it here. static BOOL bFirstTime = TRUE; if(bFirstTime) { bFirstTime = FALSE; return; } CFrameWnd::ActivateFrame(nCmdShow); }
{
// filter the first time of ActivateFrame,which be called
// in CTApp::InitInstance() during following code
// OnFileNew();
// bring a flash on screen,so filter it here. static BOOL bFirstTime = TRUE;
if(bFirstTime)
{
bFirstTime = FALSE;
return;
} CFrameWnd::ActivateFrame(nCmdShow);
}