Getting Started
BCGControlBar Library Professional Edition installation:
整个库的源代码安装在<install dir>/BCGCBPro 目录下面.可执行文件(*.dll)安装在 <install dir>/Bin (for VisualStudio 6.0) 或<install dir>/Bin7 (for VisualStudio .NET)下面。
请在你的源代码中做如下的改变:
- 在应用程序的Include路径中加入BCGCBPro目录,具体添加办法如下:vs2005下面打开菜单工具的Option项,选择项目解决方案-〉vc++目录,然后将包含文件<install dir>/BCGCBPro 添加进去。
- 确信在你的应用程序的 InitInstance() 方法中调用了AfxOleInit() 。
- 在stdafx.h中加入下面的包含文件:
class CMyApp : public CWinApp, public CBCGPWorkspace |
- 第一步,你需要定义一个 在注册表里保存个性化数据的项并且鼠标,键盘和上下文菜单都需要。为了实现这一点,CMyApp::InitInstance set registry entry and initialize customization managers:
SetRegistryBase (_T("Settings"));
// Initialize customization managers: InitMouseManager(); InitContextMenuManager(); InitKeyboardManager(); |
class CMyApp .... {
... virtual void PreLoadState(); ... };
void CMyApp::PreLoadState() {
// Associate mouse event with specific view(s): GetMouseMa |