X-Git-Url: http://git.kpe.io/?p=ctsim.git;a=blobdiff_plain;f=src%2Fviews.h;h=ddc1d0a9b26b053ae00302d99fbcac570f95762c;hp=0bec2e6bf2660832ba6d95413e6abad18e730ada;hb=cbcb02ba9b76a82c9a09ce1c7712431bb215575a;hpb=9538989b04262388ea2cb9315939fb801cc8eae2 diff --git a/src/views.h b/src/views.h index 0bec2e6..ddc1d0a 100644 --- a/src/views.h +++ b/src/views.h @@ -9,7 +9,7 @@ ** This is part of the CTSim program ** Copyright (c) 1983-2001 Kevin Rosenberg ** -** $Id: views.h,v 1.36 2001/01/28 03:48:55 kevin Exp $ +** $Id: views.h,v 1.40 2001/01/30 02:20:50 kevin Exp $ ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License (version 2) as @@ -44,8 +44,9 @@ private: wxMemoryDC m_memoryDC; wxBitmap m_bitmap; + wxMenu* m_pMenuAnalyze; - ImageFileCanvas *CreateCanvas(wxView *view, wxFrame *parent); + ImageFileCanvas *CreateCanvas (wxFrame* parent); #if CTSIM_MDI wxDocMDIChildFrame* m_pFrame; wxDocMDIChildFrame* CreateChildFrame(wxDocument *doc, wxView *view); @@ -135,7 +136,9 @@ public: #else wxDocChildFrame* getFrame() { return m_pFrame; } #endif - + + wxMenu* getMenuAnalyze() { return m_pMenuAnalyze; } + ImageFileDocument* GetDocument() { return dynamic_cast(wxView::GetDocument()); } @@ -146,6 +149,7 @@ class ImageFileCanvas: public wxScrolledWindow { private: ImageFileView* m_pView; + int m_xCursor; int m_yCursor; @@ -154,6 +158,7 @@ public: virtual ~ImageFileCanvas(); virtual void OnDraw(wxDC& dc); + void OnChar(wxKeyEvent& event); void OnMouseEvent(wxMouseEvent& event); void DrawRubberBandCursor (wxDC& dc, int x, int y); bool GetCurrentCursor (int& x, int& y); @@ -176,7 +181,7 @@ class ProjectionFileView : public wxView wxBitmap m_bitmap; private: - ProjectionFileCanvas *CreateCanvas(wxView *view, wxFrame *parent); + ProjectionFileCanvas *CreateCanvas (wxFrame* parent); #if CTSIM_MDI wxDocMDIChildFrame* m_pFrame; wxDocMDIChildFrame* CreateChildFrame(wxDocument *doc, wxView *view); @@ -233,6 +238,8 @@ public: #else wxDocChildFrame* getFrame() { return m_pFrame; } #endif + ProjectionFileCanvas* getCanvas() { return m_pCanvas; } + wxMenu* getFileMenu() { return m_pFileMenu; } ProjectionFileDocument* GetDocument() @@ -263,7 +270,7 @@ private: DECLARE_DYNAMIC_CLASS(PhantomFileView) DECLARE_EVENT_TABLE() - PhantomCanvas *CreateCanvas(wxView *view, wxFrame *parent); + PhantomCanvas *CreateCanvas (wxFrame* parent); #if CTSIM_MDI wxDocMDIChildFrame* m_pFrame; wxDocMDIChildFrame* CreateChildFrame(wxDocument *doc, wxView *view); @@ -358,7 +365,7 @@ private: double m_dMaxPixel; double m_dAutoScaleFactor; - PlotFileCanvas *CreateCanvas(wxView *view, wxFrame *parent); + PlotFileCanvas *CreateCanvas (wxFrame* parent); wxWindow* getFrameForChild() #if CTSIM_MDI { return theApp->getMainFrame(); } @@ -440,6 +447,9 @@ public: void OnUpdate (wxView *sender, wxObject *hint = (wxObject *) NULL); bool OnClose (bool deleteWindow = TRUE); + TextFileDocument* GetDocument() + { return dynamic_cast(wxView::GetDocument()); } + TextFileCanvas* getTextCtrl() { return m_pCanvas; } wxMenu* getFileMenu() { return m_pFileMenu; } #if CTSIM_MDI