📄 cwizard.hpp
字号:
// A Wizard
#ifndef _CWIZARD_HPP
#define _CWIZARD_HPP
#include "CWizardPage.hpp"
#include "CPtrArray.hpp"
class CWizard {
protected:
static CWizard* Current; // Current wizard executing
CPtrArray<CWizardPage,false> Pages; // Our array of pages
PROPSHEETHEADER psh; // A property sheet header
public:
// Constructors
CWizard( LPTSTR Caption = TEXT("Wizard"), LPTSTR Icon = NULL);
// Function to add a new page to a wizard
CWizard& operator+=( CWizardPage& pg) {
Pages.Add(&pg);
return *this;
}
bool Add(CWizardPage& pg) { return Pages.Add(&pg); }
bool Remove(CWizardPage& pg) { return Pages.Delete(&pg); }
bool SetCaption(LPTSTR Caption) {
psh.pszCaption = (LPSTR) Caption;
return true;
}
// This will execute the wizard
bool Execute(
HINSTANCE Instance,
const CWnd& parent);
private:
static INT APIENTRY Proc(
HWND hWnd, // window handle
UINT message, // type of message
WPARAM wParam, // additional information
LPARAM lParam); // additional information
};
#endif
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -