?? gn1dlg.cpp
字號:
// GN1Dlg.cpp : implementation file
//
#include "stdafx.h"
#include "student.h"
#include "GN1Dlg.h"
#include "studentview.h"
#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif
/////////////////////////////////////////////////////////////////////////////
// CGN1Dlg dialog
CGN1Dlg::CGN1Dlg(CWnd* pParent /*=NULL*/)
: CDialog(CGN1Dlg::IDD, pParent)
{
//{{AFX_DATA_INIT(CGN1Dlg)
// NOTE: the ClassWizard will add member initialization here
//}}AFX_DATA_INIT
}
void CGN1Dlg::DoDataExchange(CDataExchange* pDX)
{
CDialog::DoDataExchange(pDX);
//{{AFX_DATA_MAP(CGN1Dlg)
// NOTE: the ClassWizard will add DDX and DDV calls here
//}}AFX_DATA_MAP
CRect rect1,rect2;
this->m_parent->GetClientRect(&rect1);
this->GetClientRect(&rect2);
int x = (rect1.Width()-104 - rect2.Width())/2;
if(x<0)
{
x=0;
}
x +=104;
int y = (rect1.Height()-61-rect2.Height())/2;
if(y<0)
{
y=0;
}
y +=61;
this->MoveWindow(x,y,rect2.Width(),rect2.Height());
}
BEGIN_MESSAGE_MAP(CGN1Dlg, CDialog)
//{{AFX_MSG_MAP(CGN1Dlg)
ON_BN_CLICKED(IDC_QUIT, OnQuit)
//}}AFX_MSG_MAP
END_MESSAGE_MAP()
/////////////////////////////////////////////////////////////////////////////
// CGN1Dlg message handlers
void CGN1Dlg::OnQuit()
{
// TODO: Add your control notification handler code here
this->m_parent->gn1Dlg = NULL;
this->CloseWindow();
}
?? 快捷鍵說明
復(fù)制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -