summaryrefslogtreecommitdiff
path: root/Source/Asura.Editor/System/ContainerWindow.h
blob: 06a7b8266143f680dd0d2eb2405b2d7af95d07c0 (plain)
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
#ifndef _ASURA_EDITOR_WINDOW_H_
#define _ASURA_EDITOR_WINDOW_H_

#include <windows.h>
#include <string.h>

#include <asura-base/Scripting/Scripting.h>
#include <asura-base/Classes.h>

#include "../Type.h"

namespace_begin(AsuraEditor)

/// ༭ڵnativeڣΪmenuûmenuģGUIWindow
class ContainerWindow : public AEScripting::Portable<ContainerWindow>
{
public:

	enum WindowStyle
	{
		WINDOW_STYLE_BASIC,   ///< 
		WINDOW_STYLE_TOOL,    ///< 
		WINDOW_STYLE_CONFIRM, ///< ȷϴ
	};

	struct WindowConfig
	{
		std::string title;  ///< 
		uint x, y;          ///< 
		uint width, height; ///< С
		WindowStyle style;  ///< 
	};

	ContainerWindow();
	~ContainerWindow();

	bool Init(WindowConfig& config);
        
private: 

	WindowStyle m_Style;
	HWND        m_HWND;
	HDC         m_HDC;

luaxport:

	LUAX_DECL_FACTORY(ContainerWindow);

	LUAX_DECL_ENUM(WindowStyle);

	LUAX_DECL_METHOD(_New);
	LUAX_DECL_METHOD(_Init);
	LUAX_DECL_METHOD(_SetPosition);

};

// GUIWindowĿ
using ContainerFrame = ContainerWindow;

namespace_end

#endif