-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathMainFrm.h
169 lines (146 loc) · 5.36 KB
/
MainFrm.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
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
/*
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
*/
// MainFrm.h : interface of the CMainFrame class
//
/////////////////////////////////////////////////////////////////////////////
#if !defined(AFX_MAINFRM_H__1F484E14_CD49_4296_8F7E_7005AE25F271__INCLUDED_)
#define AFX_MAINFRM_H__1F484E14_CD49_4296_8F7E_7005AE25F271__INCLUDED_
#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000
#include "ChildView.h"
#include "Mapper.h" // Added by ClassView
#include <afxadv.h>
//----------------------------------------------------------------------------------
#define iniToolBars "ToolBars"
#define iniOptions "Options"
#define iniMapsPath "MapsPath"
#define iniZoom "Zoom"
#define iniLevel "Level"
#define iniWindow "Window"
#define iniPosX "PosX"
#define iniPosY "PosY"
#define iniVersion "Version"
#define iniFiltering "Filtering"
#define iniOverlayMode "OverlayMode"
#define iniShading "Shading"
#define iniLastDescFile "LastDescFile"
/*------------------------------------------------------------------------------------*/
class CViewerToolBar : public CToolBar
{
//{{AFX_MSG(CViewerToolbar)
afx_msg void OnHScroll(UINT nSBCode, UINT nPos, CScrollBar* pScrollBar);
//}}AFX_MSG
DECLARE_MESSAGE_MAP()
};
/*------------------------------------------------------------------------------------*/
class CMainFrame : public CFrameWnd
{
public:
CMainFrame();
protected:
DECLARE_DYNAMIC(CMainFrame)
// Attributes
public:
// Operations
public:
// Overrides
// ClassWizard generated virtual function overrides
//{{AFX_VIRTUAL(CMainFrame)
virtual BOOL PreCreateWindow(CREATESTRUCT& cs);
virtual BOOL OnCmdMsg(UINT nID, int nCode, void* pExtra, AFX_CMDHANDLERINFO* pHandlerInfo);
//}}AFX_VIRTUAL
// Implementation
public:
virtual ~CMainFrame();
#ifdef _DEBUG
virtual void AssertValid() const;
virtual void Dump(CDumpContext& dc) const;
#endif
protected: // control bar embedded members
public:
CStatusBar m_wndStatusBar;
CToolBar m_MarksTB;
void CreateMarksTB();
BOOL CheckModified();
void FillStylesCombo();
CToolBar m_EditorTB;
CViewerToolBar m_ViewerTB;
void SetShading(int ShadingVal);
CSliderCtrl m_ShadingSlider;
CStatic m_IntensityText;
void SetMapInfo(int Zoom, int Level);
CComboBox m_cbZoom;
CStatic m_ZoomText;
CStatic m_ZoomPercText;
CComboBox m_cbLevel;
CStatic m_LevelText;
CComboBox m_cbStyles;
CChildView m_wndView;
BOOL NoFiltering;
CFont m_BaseFont;
// Generated message map functions
protected:
//{{AFX_MSG(CMainFrame)
afx_msg int OnCreate(LPCREATESTRUCT lpCreateStruct);
afx_msg void OnSetFocus(CWnd *pOldWnd);
afx_msg void OnSelchangeCbZoom();
afx_msg void OnSelchangeCbLevel();
afx_msg void OnSelchangeCbStyle();
afx_msg void OnDestroy();
afx_msg void OnKeyDown(UINT nChar, UINT nRepCnt, UINT nFlags);
afx_msg void OnKeyUp(UINT nChar, UINT nRepCnt, UINT nFlags);
afx_msg void OnUpdateViewNavigation(CCmdUI* pCmdUI);
afx_msg void OnViewNavigation();
afx_msg void OnClose();
afx_msg void OnHelpViewreadme();
afx_msg void OnFileExporttobmp();
afx_msg void OnCheckOverlay();
afx_msg void OnUpdateCheckOverlay(CCmdUI* pCmdUI);
afx_msg void OnViewFiltering();
afx_msg void OnUpdateViewFiltering(CCmdUI* pCmdUI);
afx_msg void OnUpdateFileExporttobmp(CCmdUI* pCmdUI);
afx_msg void OnSizing(UINT fwSide, LPRECT pRect);
afx_msg void OnEditorMode();
afx_msg void OnUpdateEditorMode(CCmdUI* pCmdUI);
afx_msg void OnMarkcategories();
afx_msg void OnUpdateMarkcategories(CCmdUI* pCmdUI);
afx_msg void OnViewHideallsymbols();
afx_msg void OnUpdateViewHideallsymbols(CCmdUI* pCmdUI);
afx_msg void OnShowAllMarks();
afx_msg void OnUpdateShowAllMarks(CCmdUI* pCmdUI);
afx_msg void OnHideAllMarks();
afx_msg void OnUpdateHideAllMarks(CCmdUI* pCmdUI);
afx_msg void OnViewTextlabels();
afx_msg void OnUpdateViewTextlabels(CCmdUI* pCmdUI);
afx_msg void OnViewMarks();
afx_msg void OnUpdateViewMarks(CCmdUI* pCmdUI);
//}}AFX_MSG
afx_msg BOOL OnToolTipNotify( UINT id, NMHDR * pNMHDR, LRESULT * pResult );
afx_msg void OnToggleCategory(UINT id);
afx_msg void OnUpdateToggleCategory(CCmdUI* pCmdUI);
DECLARE_MESSAGE_MAP()
private:
DWORD m_TBStyle;
CImageList m_MarksTB_Images;
};
extern CMainFrame* g_pMainFrame;
CString ExtractPath(const CString FileName);
CString GetAppFileName();
/////////////////////////////////////////////////////////////////////////////
//{{AFX_INSERT_LOCATION}}
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
#endif // !defined(AFX_MAINFRM_H__1F484E14_CD49_4296_8F7E_7005AE25F271__INCLUDED_)