Cafu Engine
DialogMapCheck.hpp
1 /*
2 Cafu Engine, http://www.cafu.de/
3 Copyright (c) Carsten Fuchs and other contributors.
4 This project is licensed under the terms of the MIT license.
5 */
6 
7 #ifndef CAFU_DIALOG_MAPCHECK_HPP_INCLUDED
8 #define CAFU_DIALOG_MAPCHECK_HPP_INCLUDED
9 
10 #include "Templates/Array.hpp"
11 #include "wx/wx.h"
12 
13 
14 class MapCheckerT;
15 class MapDocumentT;
16 
17 
18 class MapCheckDialogT : public wxDialog
19 {
20  public:
21 
22  /// The constructor.
23  MapCheckDialogT(wxWindow* Parent, MapDocumentT& MapDoc);
24 
25  /// The destructor.
27 
28 
29  private:
30 
31  void UpdateProblems();
32 
33  MapDocumentT& m_MapDoc; ///< The map document that this dialog is for.
34  ArrayT<MapCheckerT*> m_Problems; ///< The list of current problems.
35  wxListBox* ListBoxProblems;
36  wxStaticText* StaticTextProblemDescription;
37  wxButton* ButtonGoToError;
38  wxButton* ButtonFix;
39  wxButton* ButtonFixAll;
40 
41  // Event handlers.
42  void OnListBoxProblemsSelChange(wxCommandEvent& Event);
43  void OnButtonGoToError(wxCommandEvent& Event);
44  void OnButtonFix(wxCommandEvent& Event);
45  void OnButtonFixAll(wxCommandEvent& Event);
46 
47  // IDs for the controls in whose events we are interested.
48  enum
49  {
50  ID_LISTBOX_PROBLEMS=wxID_HIGHEST+1,
51  ID_BUTTON_GOTO_ERROR,
52  ID_BUTTON_FIX,
53  ID_BUTTON_FIXALL
54  };
55 
56  DECLARE_EVENT_TABLE()
57 };
58 
59 #endif
Definition: DialogMapCheck.hpp:18
This class represents a CaWE "map" document.
Definition: MapDocument.hpp:45
MapCheckDialogT(wxWindow *Parent, MapDocumentT &MapDoc)
The constructor.
Definition: DialogMapCheck.cpp:119
The common base class for concrete map checkers.
Definition: DialogMapCheck.cpp:32
~MapCheckDialogT()
The destructor.
Definition: DialogMapCheck.cpp:166