2 * Copyright (c) 2001, 2002, 2003 Gary R. Van Sickle.
4 * This program is free software; you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License as published by
6 * the Free Software Foundation; either version 2 of the License, or
7 * (at your option) any later version.
9 * A copy of the GNU General Public License can be found at
12 * Written by Gary R. Van Sickle <g.r.vansickle@worldnet.att.net>
16 #ifndef SETUP_PROPSHEET_H
17 #define SETUP_PROPSHEET_H
19 // This is the header for the PropSheet class. This class encapsulates
20 // a Windows property sheet / wizard and interfaces with the PropertyPage class.
21 // It's named PropSheet instead of PropertySheet because the latter conflicts with
22 // the Windows function of the same name.
34 class PropSheet
: public Window
36 typedef std::vector
< PropertyPage
* > PageContainer
;
37 PageContainer PropertyPages
;
39 HPROPSHEETPAGE
*PageHandles
;
40 HPROPSHEETPAGE
*CreatePages ();
44 virtual ~ PropSheet ();
46 // Should be private and friended to PropertyPage
47 void SetHWNDFromPage (HWND h
);
48 void AdjustPageSize (HWND page
);
50 bool Create (const Window
* Parent
= NULL
,
51 DWORD Style
= WS_OVERLAPPEDWINDOW
| WS_VISIBLE
| WS_CLIPCHILDREN
);
53 void AddPage (PropertyPage
* p
);
55 bool SetActivePage (int i
);
56 bool SetActivePageByID (int resource_id
);
57 void SetButtons (DWORD flags
);
58 void PressButton (int button
);
61 #endif /* SETUP_PROPSHEET_H */