-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathFAHRPVW.H
149 lines (132 loc) · 5.48 KB
/
FAHRPVW.H
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
// fahrpvw.h : interface of the CDrawView class
//
// This is a part of the Microsoft Foundation Classes C++ library.
// Copyright (C) 1992-1993 Microsoft Corporation
// All rights reserved.
//
// This source code is only intended as a supplement to the
// Microsoft Foundation Classes Reference and Microsoft
// QuickHelp and/or WinHelp documentation provided with the library.
// See these sources for detailed information regarding the
// Microsoft Foundation Classes product.
// Hints for UpdateAllViews/OnUpdate
#define HINT_UPDATE_WINDOW 0
#define HINT_UPDATE_DRAWOBJ 1
#define HINT_UPDATE_SELECTION 2
#define HINT_DELETE_SELECTION 3
#define HINT_UPDATE_OLE_ITEMS 4
class CDrawObj;
class CFahrplanView : public CScrollView
{
protected: // create from serialization only
CFahrplanView();
DECLARE_DYNCREATE(CFahrplanView)
// Attributes
public:
CDrawDoc* GetDocument()
{ return (CDrawDoc*)m_pDocument; }
void SetPageSize(CSize size);
CRect GetInitialPosition();
// Operations
public:
void DocToClient(CRect& rect);
void DocToClient(CPoint& point);
void ClientToDoc(CPoint& point);
void ClientToDoc(CRect& rect);
void Select(CDrawObj* pObj, BOOL bAdd = FALSE);
void SelectWithinRect(CRect rect, BOOL bAdd = FALSE);
void Deselect(CDrawObj* pObj);
void CloneSelection();
void UpdateActiveItem();
void InvalObj(CDrawObj* pObj);
void Remove(CDrawObj* pObj);
void PasteNative(COleDataObject& dataObject);
void PasteEmbedded(COleDataObject& dataObject);
// Implementation
public:
virtual ~CFahrplanView();
#ifdef _DEBUG
virtual void AssertValid() const;
virtual void Dump(CDumpContext& dc) const;
#endif
virtual void OnDraw(CDC* pDC); // overridden to draw this view
virtual void OnActivateView(BOOL bActivate, CView* pActiveView, CView* pDeactiveView);
virtual void OnUpdate(CView* pSender, LPARAM lHint, CObject* pHint);
virtual void OnPrepareDC(CDC* pDC, CPrintInfo* pInfo);
virtual BOOL OnScrollBy(CSize sizeScroll, BOOL bDoScroll);
virtual BOOL PreCreateWindow(CREATESTRUCT& cs);
void DrawGrid(CDC* pDC);
static CLIPFORMAT m_cfDraw; // custom clipboard format
CObList m_selection;
BOOL m_bGrid;
COLORREF m_gridColor;
BOOL m_bActive; // is the view active?
protected:
virtual void OnInitialUpdate(); // called first time after construct
// Printing support
virtual BOOL OnPreparePrinting(CPrintInfo* pInfo);
virtual void OnBeginPrinting(CDC* pDC, CPrintInfo* pInfo);
virtual void OnEndPrinting(CDC* pDC, CPrintInfo* pInfo);
// OLE Container support
public:
virtual BOOL IsSelected(const CObject* pDocItem) const;
// Generated message map functions
protected:
//{{AFX_MSG(CDrawView)
afx_msg void OnInsertObject();
afx_msg void OnCancelEdit();
afx_msg void OnLButtonDown(UINT nFlags, CPoint point);
afx_msg void OnLButtonUp(UINT nFlags, CPoint point);
afx_msg void OnMouseMove(UINT nFlags, CPoint point);
afx_msg void OnLButtonDblClk(UINT nFlags, CPoint point);
afx_msg void OnDrawSelect();
afx_msg void OnDrawRoundRect();
afx_msg void OnDrawRect();
afx_msg void OnDrawLine();
afx_msg void OnDrawEllipse();
afx_msg void OnDrawBahnhof();
afx_msg void OnUpdateDrawBahnhof(CCmdUI* pCmdUI);
afx_msg void OnConnectBahnhof();
afx_msg void OnUpdateConnectBahnhof(CCmdUI* pCmdUI);
afx_msg void OnUpdateDrawEllipse(CCmdUI* pCmdUI);
afx_msg void OnUpdateDrawLine(CCmdUI* pCmdUI);
afx_msg void OnUpdateDrawRect(CCmdUI* pCmdUI);
afx_msg void OnUpdateDrawRoundRect(CCmdUI* pCmdUI);
afx_msg void OnUpdateDrawSelect(CCmdUI* pCmdUI);
afx_msg void OnUpdateSingleSelect(CCmdUI* pCmdUI);
afx_msg void OnEditSelectAll();
afx_msg void OnEditClear();
afx_msg void OnUpdateAnySelect(CCmdUI* pCmdUI);
afx_msg void OnDrawPolygon();
afx_msg void OnUpdateDrawPolygon(CCmdUI* pCmdUI);
afx_msg void OnSize(UINT nType, int cx, int cy);
afx_msg void OnViewGrid();
afx_msg void OnUpdateViewGrid(CCmdUI* pCmdUI);
afx_msg BOOL OnEraseBkgnd(CDC* pDC);
afx_msg void OnObjectFillColor();
afx_msg void OnObjectLineColor();
afx_msg void OnObjectMoveBack();
afx_msg void OnObjectMoveForward();
afx_msg void OnObjectMoveToBack();
afx_msg void OnObjectMoveToFront();
afx_msg void OnViewPaperColor();
afx_msg void OnDrawBitmap();
afx_msg void OnUpdateDrawBitmap(CCmdUI* pCmdUI);
afx_msg void OnEditCopy();
afx_msg void OnUpdateEditCopy(CCmdUI* pCmdUI);
afx_msg void OnEditCut();
afx_msg void OnUpdateEditCut(CCmdUI* pCmdUI);
afx_msg void OnEditPaste();
afx_msg void OnUpdateEditPaste(CCmdUI* pCmdUI);
afx_msg void OnFilePrint();
afx_msg void OnSetFocus(CWnd* pOldWnd);
afx_msg void OnViewShowObjects();
afx_msg void OnUpdateViewShowObjects(CCmdUI* pCmdUI);
afx_msg void OnEditProperties();
afx_msg void OnUpdateEditProperties(CCmdUI* pCmdUI);
afx_msg void OnDestroy();
afx_msg void OnUpdateEditSelectAll(CCmdUI* pCmdUI);
//}}AFX_MSG
DECLARE_MESSAGE_MAP()
};
/////////////////////////////////////////////////////////////////////////////