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

📄 clistview.cpp

📁 PGP8.0源码 请认真阅读您的文件包然后写出其具体功能
💻 CPP
字号:
/*____________________________________________________________________________
		Copyright (C) 2002 PGP Corporation
        All rights reserved.

        $Id: CListView.cpp,v 1.2 2002/08/06 20:10:46 dallen Exp $
____________________________________________________________________________*/

#include "pgpClassesConfig.h"

#include "CListView.h"
#include "UModuleInstance.h"

_USING_PGP

// Class CListView member functions

PGPBoolean 
CListView::GetItemRect(PGPInt32 i, RECT *pRect, PGPInt32 code) const
{
	pRect->left = code;

	return static_cast<PGPBoolean>(SendMessage(LVM_GETITEMRECT, i, 
		reinterpret_cast<LPARAM>(pRect)));
}

PGPBoolean 
CListView::SetItemState(PGPInt32 i, PGPUInt32 state, PGPUInt32 mask)
{
	LVITEM	lvItem;

	lvItem.state = state;
	lvItem.stateMask = mask;

	return static_cast<PGPBoolean>(SendMessage(LVM_SETITEMSTATE, i, 
		reinterpret_cast<LPARAM>(&lvItem)));
}

void 
CListView::Create(
	HWND		parent, 
	PGPUInt32	id, 
	PGPUInt32	style, 
	PGPUInt32	exStyle, 
	PGPInt32	xOffset, 
	PGPInt32	yOffset, 
	PGPInt32	width, 
	PGPInt32	height)
{
	pgpAssert(!WeSubclassed());
	pgpAssert(CWindow::IsWindow(parent));

	HWND	hWnd	= ::CreateWindowEx(exStyle, WC_LISTVIEW, NULL, 
		WS_CHILD | WS_CLIPCHILDREN | WS_CLIPSIBLINGS | style, xOffset, 
		yOffset, width, height, parent, reinterpret_cast<HMENU>(id), 
		UModuleInstance::Get(), NULL);

	if (IsNull(hWnd))
		THROW_ERRORS(kPGPError_Win32WindowOpFailed, GetLastError());

	Subclass(hWnd);
}

⌨️ 快捷键说明

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