2 #include "ExperimentSettingsSheet.h"
8 ATLASSERT(m_hWnd == NULL);
17 m_psh.dwFlags = PSH_NOAPPLYNOW | PSH_MODELESS | PSH_USECALLBACK;
18 m_psh.hwndParent = hWndParent;
19 m_psh.phpage = (HPROPSHEETPAGE*)m_arrPages.GetData();
20 m_psh.nPages = m_arrPages.GetSize();
21 m_psh.pfnCallback = CExperimentSettingsSheet::PropSheetCallback;
23 _Module.AddCreateWndData(&m_thunk.cd,
this);
25 HWND hWnd = (HWND)::PropertySheet(&m_psh);
28 ATLASSERT(m_hWnd == hWnd);
31 int nAdjX = GetSystemMetrics(SM_CXDLGFRAME) * 2;
32 int nAdjY = GetSystemMetrics(SM_CYDLGFRAME) * 2;
33 SetWindowPos(NULL, rc.left - nAdjX, rc.top - nAdjY, rc.Width(), rc.Height(),
34 SWP_NOZORDER|SWP_NOACTIVATE);
37 SetActivePage(nStartPage);
41 int CALLBACK CExperimentSettingsSheet::PropSheetCallback(HWND hWnd, UINT uMsg, LPARAM lParam) {
44 if (uMsg == PSCB_INITIALIZED) {
45 ATLASSERT(hWnd != NULL);
47 pT->SubclassWindow(hWnd);
50 else if (uMsg == PSCB_PRECREATE) {
51 LPDLGTEMPLATE pTemplate = (LPDLGTEMPLATE)lParam;
54 DWORD dwRemove = WS_POPUP|WS_SYSMENU|WS_CAPTION|DS_MODALFRAME;
55 DWORD dwAdd = WS_CHILD|WS_VISIBLE|WS_TABSTOP|DS_CONTEXTHELP|DS_3DLOOK|DS_CONTROL;
57 pTemplate->style = (pTemplate->style & ~dwRemove) | dwAdd;
58 pTemplate->dwExtendedStyle |= WS_EX_CONTROLPARENT;
65 LRESULT CExperimentSettingsSheet::OnSelChange(WPARAM wParam, LPNMHDR pnmHdr, BOOL & bHandled) {
66 return DefWindowProc(WM_NOTIFY, wParam, (LPARAM)pnmHdr);
CTimeSeriesSettingsPage pageTimeSeriesSettings
Page for timeseries stuff.
CStackSettingsPage pageStackSettings
Page for stack stuff.
CScanModesSettingsPage pageScanModesSettings
Page for selecting different scan modes.
This is the include file for standard system include files, or project specific include files that ar...
HWND Create(const HWND hWndParent, const int nStartPage, const CRect &rc)
Adds the pages and do some magic.
Settings sheet for the various property sheets dealing with different experiment types.
CAppModule _Module
The ATL application module.
CBehaviorSettingsPage pageBehaviorSettings
Page for behavior triggered acquisition stuff.