⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 dialogv.cpp

📁 斗地主记牌器java
💻 CPP
字号:
// DialogV.cpp : implementation file
//

#include "stdafx.h"
#include "j_shk.h"
#include "DialogV.h"

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

/////////////////////////////////////////////////////////////////////////////
// CDialogV dialog


CDialogV::CDialogV(CWnd* pParent /*=NULL*/)
	: CDialog(CDialogV::IDD, pParent)
{
	//{{AFX_DATA_INIT(CDialogV)
	m_cs = _T("");
	//}}AFX_DATA_INIT
}


void CDialogV::DoDataExchange(CDataExchange* pDX)
{
	CDialog::DoDataExchange(pDX);
	//{{AFX_DATA_MAP(CDialogV)
	DDX_Text(pDX, IDC_HEDIT, m_cs);
	//}}AFX_DATA_MAP
}


BEGIN_MESSAGE_MAP(CDialogV, CDialog)
	//{{AFX_MSG_MAP(CDialogV)
	ON_WM_NCHITTEST()
	//}}AFX_MSG_MAP
//	ON_MESSAGE(WM_DRIGH,OnRighLeft)
//	ON_MESSAGE(WM_DLEFT,OnRighLeft)
END_MESSAGE_MAP()

/////////////////////////////////////////////////////////////////////////////
// CDialogV message handlers

bool CDialogV::PutMs(LPCSTR ms)
{
	m_cs+=ms;
	m_cs+="\r\n";//进行换行;
	UpdateData(false);
	return 0;
}

BOOL CDialogV::OnInitDialog() 
{
	SETLAYEREDWINDOWATTRIBUTES SetLayeredWindowAttributes;
	HMODULE hMod =GetModuleHandle("user32");
	if(hMod) SetLayeredWindowAttributes =(SETLAYEREDWINDOWATTRIBUTES)GetProcAddress(hMod, "SetLayeredWindowAttributes");

	CDialog::OnInitDialog();
	
	::SetWindowPos(m_hWnd,HWND_TOPMOST, -1,-1,-1,-1,SWP_NOMOVE|SWP_NOSIZE); 
	SetWindowLong(m_hWnd,GWL_EXSTYLE,GetWindowLong(m_hWnd,GWL_EXSTYLE)^WS_EX_LAYERED);
	SetLayeredWindowAttributes(m_hWnd,RGB(0,0,0),200,LWA_ALPHA);
	
	return TRUE;  // return TRUE unless you set the focus to a control
	              // EXCEPTION: OCX Property Pages should return FALSE
}

UINT CDialogV::OnNcHitTest(CPoint point) 
{
	// TODO: Add your message handler code here and/or call default
	
	return CDialog::OnNcHitTest(point);
}
int CDialogV::OnRighLeft(WPARAM wParam,LPARAM lParam)
{
	//PutMs(LPCSTR(lParam));
	UpdateData(false);
	return 0;
}

⌨️ 快捷键说明

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