2 #include "BehaviorSettingsPage.h"
7 CBehaviorSettingsPage::CBehaviorSettingsPage(
void)
8 : CToolTipDialog(TTS_NOPREFIX)
9 , start_behavior_button(&scope_controller.StartBehaviorButton)
10 , framecount_edit(&scope_controller.FrameCounter[0])
11 , totaltime_edit(&scope_controller.TotalTime)
12 , trialcount_edit(&scope_controller.TrialCounter) {
23 std::wostringstream stream;
24 for ( uint32_t a = 0 ; a < SCOPE_NAREAS ; a++ ) {
26 stream << L
"FastZ " << a+1;
27 planes_list.InsertColumn(1+2*a, stream.str().c_str(), 0, 60);
29 stream << L
"Pockels " << a+1;
30 planes_list.InsertColumn(2+2*a, stream.str().c_str(), 0, 60);
38 LRESULT CBehaviorSettingsPage::OnAddPlane(WORD wNotifyCode, WORD wID, HWND hWndCtl, BOOL& bHandled) {
39 DBOUT(L
"CTimeSeriesSettingsPage::OnAddPlane");
42 std::array<parameters::PlaneProperties, SCOPE_NAREAS> planes;
43 for ( uint32_t a = 0 ; a < SCOPE_NAREAS ; a++ ) {
54 LRESULT CBehaviorSettingsPage::OnDeletePlane(WORD wNotifyCode, WORD wID, HWND hWndCtl, BOOL& bHandled) {
66 std::wostringstream stream;
70 stream << L
"Plane " << n;
71 planes_list.InsertItem(n, stream.str().c_str(), NULL);
74 planes_list.SetItemText(n, 0, stream.str().c_str());
76 for (
const auto& p : pa ) {
78 stream << std::setprecision(1) << p.position();
79 planes_list.SetItemText(n, 2*a + 1, stream.str().c_str());
81 stream << std::setprecision(2) << p.pockels();
82 planes_list.SetItemText(n, 2*a + 2, stream.str().c_str());
CListViewCtrl planes_list
list box for all planes
bool AttachToDlgItem(HWND hWnd)
Attach the control to a dialog item.
std::array< std::unique_ptr< Area >, SCOPE_NAREAS > areas
holds AreaParameters for all areas.
void UpdatePlanesList()
updates the list view ctrl on add/delete plane
Behavior behavior
the BehaviorParameters
This is the include file for standard system include files, or project specific include files that ar...
CScopeEditCtrl< double > framecount_edit
Edit control (disabled) that displays current framecount of curren trial.
#define DBOUT(s)
A debug output to the debug console.
scope::ScopeController scope_controller
a scope controller
CScopeEditCtrl< double > trialcount_edit
Edit control (disabled) that displays current trial number.
BOOL OnInitDialog(CWindow wndFocus, LPARAM lInitParam)
Handles dialog initialization.
CScopeButtonCtrl start_behavior_button
start behavior triggered scanning
std::vector< std::array< PlaneProperties, SCOPE_NAREAS > > planes
vector with properties for all planes, for alternating planes on alternating repeats, one for each area
static parameters::Scope GuiParameters
The complete pseudo-global parameter set of the microscope.
CScopeEditCtrl< double > totaltime_edit
Edit control (disabled) that displays elapsed total time since start of first trial.