BOOL CMainFrame::PreCreateWindow(CREATESTRUCT& cs)
{
if( !CFrameWnd::PreCreateWindow(cs) )
return FALSE;
// TODO: Modify the Window class or styles here by modifying
// the CREATESTRUCT cs
cs.style = WS_OVERLAPPEDWINDOW | WS_SYSMENU | WS_BORDER;
// Size the window to 1/3 screen size and center it
cs.cy =::GetSystemMetrics(SM_CYSCREEN) * 4/5;
cs.cx =::GetSystemMetrics(SM_CXSCREEN) * 4/5;
cs.y = (GetSystemMetrics(SM_CYSCREEN) - cs.cy) / 2;
cs.x = (GetSystemMetrics(SM_CXSCREEN) - cs.cx) / 2;
cs.dwExStyle= cs.dwExStyle | WS_EX_TOPMOST ;
return TRUE;
}