4#include "Stroika/Frameworks/StroikaPreComp.h"
12using namespace Stroika::Frameworks;
13using namespace Stroika::Frameworks::Led;
20SimpleLedWordProcessor::SimpleLedWordProcessor ()
22 , fCommandHandler (kMaxUndoLevels)
25#if !qCannotSafelyCallLotsOfComplexVirtMethodCallsInsideCTORDTOR
26 SpecifyTextStore (&fTextStore);
27 SetCommandHandler (&fCommandHandler);
31SimpleLedWordProcessor::~SimpleLedWordProcessor ()
33#if !qCannotSafelyCallLotsOfComplexVirtMethodCallsInsideCTORDTOR
34 SetCommandHandler (NULL);
35 SpecifyTextStore (NULL);
39#if qCannotSafelyCallLotsOfComplexVirtMethodCallsInsideCTORDTOR
41void SimpleLedWordProcessor::OnInitialUpdate ()
43 SpecifyTextStore (&fTextStore);
44 SetCommandHandler (&fCommandHandler);
45 inherited::OnInitialUpdate ();
48void SimpleLedWordProcessor::PostNcDestroy ()
50 SetCommandHandler (NULL);
51 SpecifyTextStore (NULL);
52 inherited::PostNcDestroy ();
55LRESULT SimpleLedWordProcessor::OnCreate_Msg (LPCREATESTRUCT createStruct)
57 SpecifyTextStore (&fTextStore);
58 SetCommandHandler (&fCommandHandler);
59 return inherited::OnCreate_Msg (createStruct);
62void SimpleLedWordProcessor::OnNCDestroy_Msg ()
64 SetCommandHandler (NULL);
65 SpecifyTextStore (NULL);
66 inherited::OnNCDestroy_Msg ();
72IMPLEMENT_DYNCREATE (SimpleLedWordProcessor, CView)
73BEGIN_MESSAGE_MAP (SimpleLedWordProcessor, SimpleLedWordProcessor::inherited)
82SimpleLedLineEditor::SimpleLedLineEditor ()
84 , fCommandHandler (kMaxUndoLevels)
87#if !qCannotSafelyCallLotsOfComplexVirtMethodCallsInsideCTORDTOR
88 SpecifyTextStore (&fTextStore);
89 SetCommandHandler (&fCommandHandler);
90 SetScrollBarType (h, eScrollBarAlways);
91 SetScrollBarType (v, eScrollBarAlways);
95SimpleLedLineEditor::~SimpleLedLineEditor ()
97#if !qCannotSafelyCallLotsOfComplexVirtMethodCallsInsideCTORDTOR
98 SpecifyTextStore (NULL);
102#if qCannotSafelyCallLotsOfComplexVirtMethodCallsInsideCTORDTOR
104void SimpleLedLineEditor::OnInitialUpdate ()
106 SpecifyTextStore (&fTextStore);
107 SetCommandHandler (&fCommandHandler);
108 inherited::OnInitialUpdate ();
111void SimpleLedLineEditor::PostNcDestroy ()
113 SetCommandHandler (NULL);
114 SpecifyTextStore (NULL);
115 inherited::PostNcDestroy ();
118LRESULT SimpleLedLineEditor::OnCreate_Msg (LPCREATESTRUCT createStruct)
120 SpecifyTextStore (&fTextStore);
121 SetCommandHandler (&fCommandHandler);
122 return inherited::OnCreate_Msg (createStruct);
125void SimpleLedLineEditor::OnNCDestroy_Msg ()
127 SetCommandHandler (NULL);
128 SpecifyTextStore (NULL);
129 inherited::OnNCDestroy_Msg ();
135IMPLEMENT_DYNCREATE (SimpleLedLineEditor, CView)
136BEGIN_MESSAGE_MAP (SimpleLedLineEditor, SimpleLedLineEditor::inherited)
146LedDialogText::LedDialogText ()
151#if qStroika_Foundation_Common_Platform_Windows && defined(_MFC_VER)
152void LedDialogText::PostNcDestroy ()
155 CWnd::PostNcDestroy ();
157int LedDialogText::OnMouseActivate (CWnd* pDesktopWnd, UINT nHitTest, UINT message)
161 int nResult = CWnd::OnMouseActivate (pDesktopWnd, nHitTest, message);
166#if qStroika_Foundation_Common_Platform_Windows && defined(_MFC_VER)
167IMPLEMENT_DYNCREATE (LedDialogText, CView)
168BEGIN_MESSAGE_MAP (LedDialogText, LedDialogText::inherited)
169ON_WM_MOUSEACTIVATE ()