versiondlg.cpp

来自「Smartphone手机阅读软件」· C++ 代码 · 共 64 行

CPP
64
字号
// VersionDlg.cpp: implementation of the CVersionDlg class.
//
//////////////////////////////////////////////////////////////////////

#include "stdafx.h"
#include "VersionDlg.h"

#ifdef _DEBUG
#undef THIS_FILE
static char THIS_FILE[]=__FILE__;
#define new DEBUG_NEW
#endif

//////////////////////////////////////////////////////////////////////
// Construction/Destruction
//////////////////////////////////////////////////////////////////////

CVersionDlg::CVersionDlg()
{

}

CVersionDlg::~CVersionDlg()
{

}

LRESULT CVersionDlg::OnInitDialog(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled)
{
	g_hWndLast = m_hWnd;
	LoadSHMenuBar(MAKEINTRESOURCE(IDR_OKMENU));
	m_Titles.Attach(GetDlgItem(IDC_COPYRIGHT));
	return 0;
}
LRESULT CVersionDlg::OnCancel(WORD wNotifyCode, WORD wID, HWND hWndCtl, BOOL& bHandled)
{
	g_hWndLast = NULL;
	EndDialog(IDCANCEL);  
	return 0;
}
LRESULT CVersionDlg::OnOk(WORD wNotifyCode, WORD wID, HWND hWndCtl, BOOL& bHandled)
{
	g_hWndLast = NULL;
	EndDialog(IDOK); 	
	return 0;
}

LRESULT CVersionDlg::OnPaint(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled)
{
	// TODO : Add Code for message handler. Call DefWindowProc if necessary.
	CPaintDC dc(m_hWnd);
	LOGFONT lf;
	ZeroMemory(&lf,sizeof(lf));
	lstrcpy(lf.lfFaceName, _T("Arial"));
	lf.lfWeight = 600;
	lf.lfHeight = 16;
	CFont NewFont;
	NewFont.CreateFontIndirect(&lf);
	m_Titles.SetFont(NewFont.m_hFont);
	NewFont.DeleteObject();
	
	return 0;
}

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?