1370b324cSopenharmony_ci// Windows/Control/PropertyPage.h 2370b324cSopenharmony_ci 3370b324cSopenharmony_ci#ifndef ZIP7_INC_WINDOWS_CONTROL_PROPERTYPAGE_H 4370b324cSopenharmony_ci#define ZIP7_INC_WINDOWS_CONTROL_PROPERTYPAGE_H 5370b324cSopenharmony_ci 6370b324cSopenharmony_ci#include "../../Common/MyWindows.h" 7370b324cSopenharmony_ci 8370b324cSopenharmony_ci#include <prsht.h> 9370b324cSopenharmony_ci 10370b324cSopenharmony_ci#include "Dialog.h" 11370b324cSopenharmony_ci 12370b324cSopenharmony_cinamespace NWindows { 13370b324cSopenharmony_cinamespace NControl { 14370b324cSopenharmony_ci 15370b324cSopenharmony_ciINT_PTR APIENTRY ProperyPageProcedure(HWND dialogHWND, UINT message, WPARAM wParam, LPARAM lParam); 16370b324cSopenharmony_ci 17370b324cSopenharmony_ciclass CPropertyPage: public CDialog 18370b324cSopenharmony_ci{ 19370b324cSopenharmony_cipublic: 20370b324cSopenharmony_ci CPropertyPage(HWND window = NULL): CDialog(window) {} 21370b324cSopenharmony_ci 22370b324cSopenharmony_ci void Changed() { PropSheet_Changed(GetParent(), (HWND)*this); } 23370b324cSopenharmony_ci void UnChanged() { PropSheet_UnChanged(GetParent(), (HWND)*this); } 24370b324cSopenharmony_ci 25370b324cSopenharmony_ci virtual bool OnNotify(UINT controlID, LPNMHDR lParam) Z7_override; 26370b324cSopenharmony_ci 27370b324cSopenharmony_ci virtual bool OnKillActive() { return false; } // false = OK 28370b324cSopenharmony_ci virtual bool OnKillActive2(const PSHNOTIFY *) { return OnKillActive(); } 29370b324cSopenharmony_ci virtual LONG OnSetActive() { return false; } // false = OK 30370b324cSopenharmony_ci virtual LONG OnSetActive2(const PSHNOTIFY *) { return OnSetActive(); } 31370b324cSopenharmony_ci virtual LONG OnApply() { return PSNRET_NOERROR; } 32370b324cSopenharmony_ci virtual LONG OnApply2(const PSHNOTIFY *) { return OnApply(); } 33370b324cSopenharmony_ci virtual void OnNotifyHelp() {} 34370b324cSopenharmony_ci virtual void OnNotifyHelp2(const PSHNOTIFY *) { OnNotifyHelp(); } 35370b324cSopenharmony_ci virtual void OnReset() {} 36370b324cSopenharmony_ci virtual void OnReset2(const PSHNOTIFY *) { OnReset(); } 37370b324cSopenharmony_ci}; 38370b324cSopenharmony_ci 39370b324cSopenharmony_cistruct CPageInfo 40370b324cSopenharmony_ci{ 41370b324cSopenharmony_ci CPropertyPage *Page; 42370b324cSopenharmony_ci UString Title; 43370b324cSopenharmony_ci UINT ID; 44370b324cSopenharmony_ci}; 45370b324cSopenharmony_ci 46370b324cSopenharmony_ciINT_PTR MyPropertySheet(const CObjectVector<CPageInfo> &pagesInfo, HWND hwndParent, const UString &title); 47370b324cSopenharmony_ci 48370b324cSopenharmony_ci}} 49370b324cSopenharmony_ci 50370b324cSopenharmony_ci#endif 51