FullScreenDialog.cpp
资源名称:视频会议系统.rar [点击查看]
上传用户:popouu88
上传日期:2013-02-11
资源大小:2894k
文件大小:2k
源码类别:
IP电话/视频会议
开发平台:
Visual C++
- // FullScreenDialog.cpp : implementation file
- //
- #include "stdafx.h"
- #include "Share.h"
- #include "FullScreenDialog.h"
- #ifdef _DEBUG
- #define new DEBUG_NEW
- #undef THIS_FILE
- static char THIS_FILE[] = __FILE__;
- #endif
- /////////////////////////////////////////////////////////////////////////////
- // CFullScreenDialog dialog
- CFullScreenDialog::CFullScreenDialog(CWnd * pFullWnd , CWnd* pParent /*=NULL*/)
- : CDialog(CFullScreenDialog::IDD, pParent)
- {
- //{{AFX_DATA_INIT(CFullScreenDialog)
- //}}AFX_DATA_INIT
- this->pFullWnd = pFullWnd;
- }
- void CFullScreenDialog::DoDataExchange(CDataExchange* pDX)
- {
- CDialog::DoDataExchange(pDX);
- //{{AFX_DATA_MAP(CFullScreenDialog)
- //}}AFX_DATA_MAP
- }
- BEGIN_MESSAGE_MAP(CFullScreenDialog, CDialog)
- //{{AFX_MSG_MAP(CFullScreenDialog)
- ON_WM_SIZE()
- ON_WM_DESTROY()
- ON_WM_NCHITTEST()
- //}}AFX_MSG_MAP
- END_MESSAGE_MAP()
- /////////////////////////////////////////////////////////////////////////////
- // CFullScreenDialog message handlers
- BOOL CFullScreenDialog::OnInitDialog()
- {
- CDialog::OnInitDialog( );
- //删除系统菜单的移动项
- this->GetSystemMenu( FALSE )->RemoveMenu( 1 , MF_BYPOSITION );
- this->pFullWnd->SetParent( this );
- this->MoveWindow( 0 , 0 , ::GetSystemMetrics( SM_CXSCREEN ) , ::GetSystemMetrics( SM_CYSCREEN ) );
- return TRUE;
- }
- void CFullScreenDialog::OnSize(UINT nType, int cx, int cy)
- {
- CDialog::OnSize(nType, cx, cy);
- if( ::IsWindow( this->pFullWnd->GetSafeHwnd( ) ) )
- this->pFullWnd->MoveWindow( 0 , 0 , cx , cy );
- }
- void CFullScreenDialog::OnDestroy()
- {
- CFrameWnd * frame = ( CFrameWnd * )this->GetOwner( );
- if( frame )
- {
- this->pFullWnd->SetParent( frame );
- frame->RecalcLayout( );
- this->pFullWnd = NULL;
- }
- CDialog::OnDestroy( );
- }
- UINT CFullScreenDialog::OnNcHitTest(CPoint point)
- {
- UINT hitTest = CDialog::OnNcHitTest( point );
- return hitTest == HTCAPTION ? HTCLIENT : hitTest;
- }