Cafu Engine
LivePreview.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_GUIEDITOR_LIVE_PREVIEW_HPP_INCLUDED
8 #define CAFU_GUIEDITOR_LIVE_PREVIEW_HPP_INCLUDED
9 
10 #include "Templates/Pointer.hpp"
11 #include "wx/wx.h"
12 
13 
14 namespace cf { class UniScriptStateT; }
15 namespace cf { namespace GuiSys { class GuiImplT; } }
16 
17 
18 namespace GuiEditor
19 {
20  class PreviewCanvasT;
21 
22 
23  class LivePreviewT : public wxDialog
24  {
25  public:
26 
27  LivePreviewT(wxWindow* Parent, cf::UniScriptStateT* ScriptState, IntrusivePtrT<cf::GuiSys::GuiImplT> Gui, const wxString& ScriptFileName);
28  ~LivePreviewT();
29 
30  cf::UniScriptStateT* GetScriptState() { return m_ScriptState; }
31  IntrusivePtrT<cf::GuiSys::GuiImplT> GetGui() { return m_Gui; }
32 
33 
34  private:
35 
36  cf::UniScriptStateT* m_ScriptState;
38  PreviewCanvasT* m_Canvas;
39 
40  void OnClose(wxCloseEvent& CE);
41 
42  DECLARE_EVENT_TABLE()
43  };
44 }
45 
46 #endif
Definition: LivePreview.hpp:23
This class represents the state of a script: the underlying Lua state, pending coroutines, metatables for C++ class hierarchies, etc.
Definition: UniScriptState.hpp:214
Definition: LivePreview.cpp:27