posts - 13,comments - 0,trackbacks - 0

          //調用這個函數
          void CMainFrame::OnFullScreen()
          {	
          	// TODO: Add your command handler code here	
          	CRect WindowRect;
          	GetWindowRect(&WindowRect);
          	
          	CRect ClientRect;		
          	RepositionBars(0,0xffff,AFX_IDW_PANE_FIRST,reposQuery,&ClientRect);		
          	ClientToScreen(&ClientRect);
          		
          	//獲取屏幕的分辨率	
          	int nFullWidth=GetSystemMetrics(SM_CXSCREEN);		
          	int nFullHeight=GetSystemMetrics(SM_CYSCREEN);
          		
          	CRect m_FullScreenRect;
          	m_FullScreenRect.left=WindowRect.left-ClientRect.left;	
          	m_FullScreenRect.top=WindowRect.top-ClientRect.top;
          	m_FullScreenRect.right=WindowRect.right-ClientRect.right+nFullWidth;		
          	m_FullScreenRect.bottom=WindowRect.bottom-ClientRect.bottom+nFullHeight;
          	
          	//進入全屏顯示狀態		
          	WINDOWPLACEMENT wndpl;		
          	wndpl.rcNormalPosition=m_FullScreenRect;		
          	SetWindowPlacement(&wndpl);		
          }
          posted on 2010-12-31 13:45 CrackRen 閱讀(86) 評論(0)  編輯  收藏 所屬分類: VC

          只有注冊用戶登錄后才能發表評論。


          網站導航:
           
          主站蜘蛛池模板: 泰宁县| 沙坪坝区| 吉木乃县| 安阳县| 黄平县| 徐州市| 客服| 色达县| 额尔古纳市| 绍兴县| 株洲县| 大兴区| 漳平市| 峡江县| 丽江市| 筠连县| 灌南县| 武平县| 塔河县| 霍城县| 天峻县| 云浮市| 冷水江市| 中方县| 泗洪县| 普定县| 郧西县| 扬州市| 望都县| 醴陵市| 肃宁县| 江门市| 临沂市| 岗巴县| 绍兴县| 钟山县| 区。| 屏东县| 房山区| 手游| 凤阳县|