1$#include "UI/MessageBox.h"
2
3class MessageBox : public Object
4{
5    MessageBox(const String messageString = String::EMPTY, const String titleString = String::EMPTY, XMLFile* layoutFile = 0, XMLFile* styleFile = 0);
6    virtual ~MessageBox();
7
8    void SetTitle(const String text);
9    void SetMessage(const String text);
10
11    const String GetTitle() const;
12    const String GetMessage() const;
13    UIElement* GetWindow() const;
14
15    tolua_property__get_set String title;
16    tolua_property__get_set String message;
17    tolua_readonly tolua_property__get_set UIElement* window;
18};
19
20${
21#define TOLUA_DISABLE_tolua_UILuaAPI_MessageBox_new00
22static int tolua_UILuaAPI_MessageBox_new00(lua_State* tolua_S)
23{
24#ifndef TOLUA_RELEASE
25 tolua_Error tolua_err;
26 if (
27 !tolua_isusertable(tolua_S,1,"MessageBox",0,&tolua_err) ||
28 !tolua_isurho3dstring(tolua_S,2,1,&tolua_err) ||
29 !tolua_isurho3dstring(tolua_S,3,1,&tolua_err) ||
30 !tolua_isusertype(tolua_S,4,"XMLFile",1,&tolua_err) ||
31 !tolua_isusertype(tolua_S,5,"XMLFile",1,&tolua_err) ||
32 !tolua_isnoobj(tolua_S,6,&tolua_err)
33 )
34 goto tolua_lerror;
35 else
36#endif
37 {
38  const String messageString = ((const String)  tolua_tourho3dstring(tolua_S,2,String::EMPTY));
39  const String titleString = ((const String)  tolua_tourho3dstring(tolua_S,3,String::EMPTY));
40  XMLFile* layoutFile = ((XMLFile*)  tolua_tousertype(tolua_S,4,0));
41  XMLFile* styleFile = ((XMLFile*)  tolua_tousertype(tolua_S,5,0));
42 {
43  MessageBox* tolua_ret = (MessageBox*)  Mtolua_new((MessageBox)(GetContext(tolua_S),messageString,titleString,layoutFile,styleFile));
44  tolua_pushusertype(tolua_S,(void*)tolua_ret,"MessageBox");
45 }
46 }
47 return 1;
48#ifndef TOLUA_RELEASE
49 tolua_lerror:
50 tolua_error(tolua_S,"#ferror in function 'new'.",&tolua_err);
51 return 0;
52#endif
53}
54
55#define TOLUA_DISABLE_tolua_UILuaAPI_MessageBox_new00_local
56static int tolua_UILuaAPI_MessageBox_new00_local(lua_State* tolua_S)
57{
58#ifndef TOLUA_RELEASE
59 tolua_Error tolua_err;
60 if (
61 !tolua_isusertable(tolua_S,1,"MessageBox",0,&tolua_err) ||
62 !tolua_isurho3dstring(tolua_S,2,1,&tolua_err) ||
63 !tolua_isurho3dstring(tolua_S,3,1,&tolua_err) ||
64 !tolua_isusertype(tolua_S,4,"XMLFile",1,&tolua_err) ||
65 !tolua_isusertype(tolua_S,5,"XMLFile",1,&tolua_err) ||
66 !tolua_isnoobj(tolua_S,6,&tolua_err)
67 )
68 goto tolua_lerror;
69 else
70#endif
71 {
72  const String messageString = ((const String)  tolua_tourho3dstring(tolua_S,2,String::EMPTY));
73  const String titleString = ((const String)  tolua_tourho3dstring(tolua_S,3,String::EMPTY));
74  XMLFile* layoutFile = ((XMLFile*)  tolua_tousertype(tolua_S,4,0));
75  XMLFile* styleFile = ((XMLFile*)  tolua_tousertype(tolua_S,5,0));
76 {
77  MessageBox* tolua_ret = (MessageBox*)  Mtolua_new((MessageBox)(GetContext(tolua_S),messageString,titleString,layoutFile,styleFile));
78  tolua_pushusertype(tolua_S,(void*)tolua_ret,"MessageBox");
79 tolua_register_gc(tolua_S,lua_gettop(tolua_S));
80 }
81 }
82 return 1;
83#ifndef TOLUA_RELEASE
84 tolua_lerror:
85 tolua_error(tolua_S,"#ferror in function 'new'.",&tolua_err);
86 return 0;
87#endif
88}
89$}