通常没有见到过普通窗口大小状态下实现的。
从CView继承过来的试图类可以做到。做法是将其他部分隐藏,将需要的部分全屏
void CMainFrame::OnScreenFull()
{
// TODO: Add your command handler code here
RECT DesktopRect;
WINDOWPLACEMENT WPNew;
//m_FullScreen = m_FullScreen ? TRUE : FALSE;
if(!m_FullScreen)
{
// need to hide all status bars
m_wndStatusBar.ShowWindow(SW_HIDE);
m_wndToolBar.ShowWindow(SW_HIDE);
//Adjust RECT to new size of window
::GetWindowRect(::GetDesktopWindow(), &DesktopRect);
m_wndSplitter.GetPane(0,0)->ShowWindow(SW_HIDE);
m_wndSplitter2.GetPane(1,0)->ShowWindow(SW_HIDE);
m_wndSplitter.GetColumnInfo(0,x,x1);
m_wndSplitter2.GetRowInfo(0,y,y1);
CRect tabrect;
CPeerOperatorTabCtrl *tabctrl;
tabctrl=(CPeerOperatorTabCtrl *)m_wndSplitter2.GetPane(0,0);
tabctrl->GetItemRect(0,&tabrect);
// We'll need these to restore the original state.
GetWindowPlacement (&m_WPPrev);
m_wndSplitter.SetColumnInfo( 0,0,0);
m_wndSplitter2.SetRowInfo( 0,DesktopRect.bottom-DesktopRect.top+tabrect.Height()+44,0);