资源简介

挺不错的CTreeCtrl自绘类 找了很久才找到 含滚动条自绘 分享一下

资源截图

代码片段和文件信息

// CustomCTreeCtrl.cpp : 定义应用程序的类行为。
//

#include “stdafx.h“
#include “CustomCTreeCtrl.h“
#include “CustomCTreeCtrlDlg.h“

#ifdef _DEBUG
#define new DEBUG_NEW
#endif


// CCustomCTreeCtrlApp

BEGIN_MESSAGE_MAP(CCustomCTreeCtrlApp CWinApp)
ON_COMMAND(ID_HELP &CWinApp::onhelp)
END_MESSAGE_MAP()


// CCustomCTreeCtrlApp 构造

CCustomCTreeCtrlApp::CCustomCTreeCtrlApp()
{
// TODO: 在此处添加构造代码,
// 将所有重要的初始化放置在 InitInstance 中
}


// 唯一的一个 CCustomCTreeCtrlApp 对象

CCustomCTreeCtrlApp theApp;


// CCustomCTreeCtrlApp 初始化

BOOL CCustomCTreeCtrlApp::InitInstance()
{
// 如果一个运行在 Windows XP 上的应用程序清单指定要
// 使用 ComCtl32.dll 版本 6 或更高版本来启用可视化方式,
//则需要 InitCommonControlsEx()。否则,将无法创建窗口。
INITCOMMONCONTROLSEX InitCtrls;
InitCtrls.dwSize = sizeof(InitCtrls);
// 将它设置为包括所有要在应用程序中使用的
// 公共控件类。
InitCtrls.dwICC = ICC_WIN95_CLASSES;
InitCommonControlsEx(&InitCtrls);

CWinApp::InitInstance();

AfxEnableControlContainer();

// 标准初始化
// 如果未使用这些功能并希望减小
// 最终可执行文件的大小,则应移除下列
// 不需要的特定初始化例程
// 更改用于存储设置的注册表项
// TODO: 应适当修改该字符串,
// 例如修改为公司或组织名
SetRegistryKey(_T(“应用程序向导生成的本地应用程序“));

CCustomCTreeCtrlDlg dlg;
m_pMainWnd = &dlg;
INT_PTR nResponse = dlg.DoModal();
if (nResponse == IDOK)
{
// TODO: 在此处放置处理何时用“确定”来关闭
//  对话框的代码
}
else if (nResponse == IDCANCEL)
{
// TODO: 在此放置处理何时用“取消”来关闭
//  对话框的代码
}

// 由于对话框已关闭,所以将返回 FALSE 以便退出应用程序,
//  而不是启动应用程序的消息泵。
return FALSE;
}

 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----
     目录           0  2014-10-20 23:05  CustomCTreeCtrl 自绘\
     文件         450  2010-04-09 10:45  CustomCTreeCtrl 自绘\Add.bmp
     文件      293662  2012-04-13 12:37  CustomCTreeCtrl 自绘\bk.bmp
     文件        1766  2012-04-13 09:29  CustomCTreeCtrl 自绘\CustomCTreeCtrl.cpp
     文件         495  2012-04-13 09:29  CustomCTreeCtrl 自绘\CustomCTreeCtrl.h
     文件        5353  2012-04-15 18:15  CustomCTreeCtrl 自绘\CustomCTreeCtrl.rc
     文件        6265  2014-10-20 23:00  CustomCTreeCtrl 自绘\CustomCTreeCtrl.vcproj
     文件        4856  2012-04-15 16:53  CustomCTreeCtrl 自绘\CustomCTreeCtrlDlg.cpp
     文件         780  2012-04-15 15:49  CustomCTreeCtrl 自绘\CustomCTreeCtrlDlg.h
     文件       30287  2012-04-08 16:33  CustomCTreeCtrl 自绘\GDIPlusEx.cpp
     文件       14056  2012-11-29 14:48  CustomCTreeCtrl 自绘\GDIPlusEx.h
     文件       12892  2014-10-20 23:03  CustomCTreeCtrl 自绘\MyCtreeCtrl.cpp
     文件        4390  2014-10-20 23:01  CustomCTreeCtrl 自绘\MyCtreeCtrl.h
     文件       23514  2012-04-13 09:34  CustomCTreeCtrl 自绘\no.bmp
     文件        3035  2012-04-13 09:29  CustomCTreeCtrl 自绘\ReadMe.txt
     目录           0  2012-04-13 09:29  CustomCTreeCtrl 自绘\res\
     文件         823  2012-04-15 15:49  CustomCTreeCtrl 自绘\resource.h
     文件       21630  2005-12-08 14:56  CustomCTreeCtrl 自绘\res\CustomCTreeCtrl.ico
     文件         371  2012-04-13 09:29  CustomCTreeCtrl 自绘\res\CustomCTreeCtrl.rc2
     文件       16898  2007-01-23 16:10  CustomCTreeCtrl 自绘\skinscrollbar.cpp
     文件        2152  2011-11-17 00:26  CustomCTreeCtrl 自绘\skinscrollbar.h
     文件       10206  2012-11-21 13:28  CustomCTreeCtrl 自绘\skinscrollwnd.cpp
     文件        1814  2011-11-16 23:46  CustomCTreeCtrl 自绘\skinscrollwnd.h
     文件         146  2012-04-13 09:29  CustomCTreeCtrl 自绘\stdafx.cpp
     文件        2489  2012-04-13 09:29  CustomCTreeCtrl 自绘\stdafx.h
     文件         450  2010-04-09 10:45  CustomCTreeCtrl 自绘\Sun.bmp
     文件        5686  2012-04-08 14:13  CustomCTreeCtrl 自绘\tree_item_icon2.bmp

评论

共有 条评论