forked from OpenTibiaArchives/TibiaMapViewer
-
Notifications
You must be signed in to change notification settings - Fork 0
/
ChildView.h
141 lines (125 loc) · 4.68 KB
/
ChildView.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
/*
This file is part of Tibia Map Viewer.
Copyright (c) 2001-2006 by Yury Sidorov.
Tibia Map Viewer is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
Tibia Map Viewer is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with Tibia Map Viewer; if not, write to the Free Software
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
// ChildView.h : interface of the CChildView class
//
/////////////////////////////////////////////////////////////////////////////
#if !defined(AFX_CHILDVIEW_H__2DAA641F_4905_4DE9_B9C3_A185EDED41C5__INCLUDED_)
#define AFX_CHILDVIEW_H__2DAA641F_4905_4DE9_B9C3_A185EDED41C5__INCLUDED_
#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000
/////////////////////////////////////////////////////////////////////////////
// CChildView window
class CChildView : public CWnd
{
// Construction
public:
CChildView();
// Attributes
public:
// Operations
public:
// Overrides
// ClassWizard generated virtual function overrides
//{{AFX_VIRTUAL(CChildView)
protected:
virtual BOOL PreCreateWindow(CREATESTRUCT& cs);
//}}AFX_VIRTUAL
// Implementation
public:
int m_ObjSelCount;
void UpdateCursor();
void HideMarkDescriptions();
void InvalidateObj(CContentObj *obj);
void ActivateDefStyle();
void SelectAll(BOOL Select = TRUE);
int m_DefStyleIdx;
void SetViewerMode();
void SetArrowCursor();
void MapToScreenRect(CRect *rect);
void ScreenToMapRect(CRect* rect);
CRect m_Selection;
BOOL m_Moving;
void SetEditorMode();
CPoint MapToScreen(const CPoint &point);
void InvalidateMapRect(CRect& rect);
CPoint ScreenToMap(const CPoint& point);
BOOL m_EditorMode;
HCURSOR m_DefCur;
HCURSOR m_DragHand2Cur;
HCURSOR m_MagnifyCur;
HCURSOR m_MagnifyCur2;
HCURSOR SetViewCursor(HCURSOR cur);
void UpdateCurrentStyle();
virtual ~CChildView();
// Generated message map functions
protected:
void ChangeZoom(CPoint point, int NewIdx);
//{{AFX_MSG(CChildView)
afx_msg void OnPaint();
afx_msg void OnLButtonDown(UINT nFlags, CPoint point);
afx_msg void OnMouseMove(UINT nFlags, CPoint point);
afx_msg void OnLButtonUp(UINT nFlags, CPoint point);
afx_msg void OnSize(UINT nType, int cx, int cy);
afx_msg void OnVScroll(UINT nSBCode, UINT nPos, CScrollBar* pScrollBar);
afx_msg void OnHScroll(UINT nSBCode, UINT nPos, CScrollBar* pScrollBar);
afx_msg void OnKeyDown(UINT nChar, UINT nRepCnt, UINT nFlags);
afx_msg void OnKeyUp(UINT nChar, UINT nRepCnt, UINT nFlags);
afx_msg void OnKillFocus(CWnd* pNewWnd);
afx_msg void OnRButtonDown(UINT nFlags, CPoint point);
afx_msg void OnDelete();
afx_msg void OnInsertText();
afx_msg void OnLButtonDblClk(UINT nFlags, CPoint point);
afx_msg void OnSelectMode();
afx_msg void OnUpdateInsertText(CCmdUI* pCmdUI);
afx_msg void OnUpdateSelectMode(CCmdUI* pCmdUI);
afx_msg void OnEditStyles();
afx_msg void OnUpdateEditStyles(CCmdUI* pCmdUI);
afx_msg void OnUpdateDelete(CCmdUI* pCmdUI);
afx_msg void OnInsertMark();
afx_msg void OnUpdateInsertMark(CCmdUI* pCmdUI);
afx_msg BOOL OnSetCursor(CWnd* pWnd, UINT nHitTest, UINT message);
afx_msg void OnRButtonDblClk(UINT nFlags, CPoint point);
afx_msg void OnHideunexploredsymbols();
afx_msg void OnUpdateHideunexploredsymbols(CCmdUI* pCmdUI);
afx_msg void OnProperties();
afx_msg void OnUpdateProperties(CCmdUI* pCmdUI);
afx_msg void OnContextMenu(CWnd* pWnd, CPoint point);
afx_msg void OnToFront();
afx_msg void OnUpdateToFront(CCmdUI* pCmdUI);
afx_msg void OnToBack();
afx_msg void OnUpdateToBack(CCmdUI* pCmdUI);
//}}AFX_MSG
afx_msg void OnUpdateStatusBar(CCmdUI* pCmdUI);
afx_msg void OnUpdateStatusBarFileName(CCmdUI* pCmdUI);
DECLARE_MESSAGE_MAP()
private:
BOOL m_InPopup;
void EditObject(CContentObj* obj);
void SelClick(CPoint point);
CMenu* m_Popup;
BOOL m_CurHideUnexplored;
int m_LastZoomIdx;
BYTE m_NewObjectType;
void DrawSelectionRect(CDC& dc);
CPoint m_ptClick;
CBitmap m_MemBmp;
CDC m_MemDC;
};
/////////////////////////////////////////////////////////////////////////////
//{{AFX_INSERT_LOCATION}}
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
#endif // !defined(AFX_CHILDVIEW_H__2DAA641F_4905_4DE9_B9C3_A185EDED41C5__INCLUDED_)