added "install" instruction
[Leditor.git] / src / lqt_bind_QMainWindow.cpp
blobe29366e12279dd36dee5092786b2fd24521a0171
1 #include "lqt_bind_QMainWindow.hpp"
3 int LuaBinder< QMainWindow >::__LuaWrapCall__splitDockWidget (lua_State *L) {
4 QMainWindow *& __lua__obj = *static_cast<QMainWindow**>(lqtL_checkudata(L, 1, "QMainWindow*"));
5 if (__lua__obj==0) {
6 lua_pushstring(L, "trying to reference deleted pointer");
7 lua_error(L);
8 return 0;
10 QDockWidget * arg1 = *static_cast<QDockWidget**>(lqtL_checkudata(L, 2, "QDockWidget*"));
11 QDockWidget * arg2 = *static_cast<QDockWidget**>(lqtL_checkudata(L, 3, "QDockWidget*"));
12 Qt::Orientation arg3 = static_cast<Qt::Orientation>(lqtL_toenum(L, 4, "Qt::Orientation"));
13 __lua__obj->QMainWindow::splitDockWidget(arg1, arg2, arg3);
14 return 0;
16 int LuaBinder< QMainWindow >::__LuaWrapCall__toolBarBreak (lua_State *L) {
17 QMainWindow *& __lua__obj = *static_cast<QMainWindow**>(lqtL_checkudata(L, 1, "QMainWindow*"));
18 if (__lua__obj==0) {
19 lua_pushstring(L, "trying to reference deleted pointer");
20 lua_error(L);
21 return 0;
23 QToolBar * arg1 = *static_cast<QToolBar**>(lqtL_checkudata(L, 2, "QToolBar*"));
24 bool ret = __lua__obj->QMainWindow::toolBarBreak(arg1);
25 lua_pushboolean(L, ret);
26 return 1;
28 int LuaBinder< QMainWindow >::__LuaWrapCall__saveState (lua_State *L) {
29 QMainWindow *& __lua__obj = *static_cast<QMainWindow**>(lqtL_checkudata(L, 1, "QMainWindow*"));
30 if (__lua__obj==0) {
31 lua_pushstring(L, "trying to reference deleted pointer");
32 lua_error(L);
33 return 0;
35 int arg1 = lua_isnumber(L, 2)?lua_tointeger(L, 2):static_cast< int >(0);
36 QByteArray ret = __lua__obj->QMainWindow::saveState(arg1);
37 lua_pushlstring(L, ret.data(), ret.size());
38 return 1;
40 int LuaBinder< QMainWindow >::__LuaWrapCall__addToolBarBreak (lua_State *L) {
41 QMainWindow *& __lua__obj = *static_cast<QMainWindow**>(lqtL_checkudata(L, 1, "QMainWindow*"));
42 if (__lua__obj==0) {
43 lua_pushstring(L, "trying to reference deleted pointer");
44 lua_error(L);
45 return 0;
47 Qt::ToolBarArea arg1 = lqtL_isenum(L, 2, "Qt::ToolBarArea")?static_cast<Qt::ToolBarArea>(lqtL_toenum(L, 2, "Qt::ToolBarArea")):Qt::TopToolBarArea;
48 __lua__obj->QMainWindow::addToolBarBreak(arg1);
49 return 0;
51 int LuaBinder< QMainWindow >::__LuaWrapCall__createPopupMenu (lua_State *L) {
52 QMainWindow *& __lua__obj = *static_cast<QMainWindow**>(lqtL_checkudata(L, 1, "QMainWindow*"));
53 if (__lua__obj==0) {
54 lua_pushstring(L, "trying to reference deleted pointer");
55 lua_error(L);
56 return 0;
58 QMenu * ret = __lua__obj->QMainWindow::createPopupMenu();
59 lqtL_pushudata(L, ret, "QMenu*");
60 return 1;
62 int LuaBinder< QMainWindow >::__LuaWrapCall__insertToolBar (lua_State *L) {
63 QMainWindow *& __lua__obj = *static_cast<QMainWindow**>(lqtL_checkudata(L, 1, "QMainWindow*"));
64 if (__lua__obj==0) {
65 lua_pushstring(L, "trying to reference deleted pointer");
66 lua_error(L);
67 return 0;
69 QToolBar * arg1 = *static_cast<QToolBar**>(lqtL_checkudata(L, 2, "QToolBar*"));
70 QToolBar * arg2 = *static_cast<QToolBar**>(lqtL_checkudata(L, 3, "QToolBar*"));
71 __lua__obj->QMainWindow::insertToolBar(arg1, arg2);
72 return 0;
74 int LuaBinder< QMainWindow >::__LuaWrapCall__removeToolBarBreak (lua_State *L) {
75 QMainWindow *& __lua__obj = *static_cast<QMainWindow**>(lqtL_checkudata(L, 1, "QMainWindow*"));
76 if (__lua__obj==0) {
77 lua_pushstring(L, "trying to reference deleted pointer");
78 lua_error(L);
79 return 0;
81 QToolBar * arg1 = *static_cast<QToolBar**>(lqtL_checkudata(L, 2, "QToolBar*"));
82 __lua__obj->QMainWindow::removeToolBarBreak(arg1);
83 return 0;
85 int LuaBinder< QMainWindow >::__LuaWrapCall__setAnimated (lua_State *L) {
86 QMainWindow *& __lua__obj = *static_cast<QMainWindow**>(lqtL_checkudata(L, 1, "QMainWindow*"));
87 if (__lua__obj==0) {
88 lua_pushstring(L, "trying to reference deleted pointer");
89 lua_error(L);
90 return 0;
92 bool arg1 = (bool)lua_toboolean(L, 2);
93 __lua__obj->QMainWindow::setAnimated(arg1);
94 return 0;
96 int LuaBinder< QMainWindow >::__LuaWrapCall__trUtf8__OverloadedVersion__1 (lua_State *L) {
97 const char * arg1 = lua_tostring(L, 1);
98 const char * arg2 = (lua_type(L, 2)==LUA_TSTRING)?lua_tostring(L, 2):static_cast< const char * >(0);
99 QString ret = QMainWindow::trUtf8(arg1, arg2);
100 lua_pushlstring(L, ret.toAscii().data(), ret.toAscii().size());
101 return 1;
103 int LuaBinder< QMainWindow >::__LuaWrapCall__trUtf8__OverloadedVersion__2 (lua_State *L) {
104 const char * arg1 = lua_tostring(L, 1);
105 const char * arg2 = lua_tostring(L, 2);
106 int arg3 = lua_tointeger(L, 3);
107 QString ret = QMainWindow::trUtf8(arg1, arg2, arg3);
108 lua_pushlstring(L, ret.toAscii().data(), ret.toAscii().size());
109 return 1;
111 int LuaBinder< QMainWindow >::__LuaWrapCall__trUtf8 (lua_State *L) {
112 int score[3];
113 const int premium = 11+lua_gettop(L);
114 score[1] = 0;
115 if ((lua_type(L, 1)==LUA_TSTRING)) {
116 score[1] += premium;
117 } else if (false) {
118 score[1] += premium-1; // table: 0x12f67a0;
119 } else {
120 score[1] -= premium*premium;
122 if ((lua_type(L, 2)==LUA_TSTRING)) {
123 score[1] += premium;
124 } else if (true) {
125 score[1] += premium-1; // table: 0x12f6300;
126 } else {
127 score[1] -= premium*premium;
129 score[2] = 0;
130 if ((lua_type(L, 1)==LUA_TSTRING)) {
131 score[2] += premium;
132 } else if (false) {
133 score[2] += premium-1; // table: 0x12f8590;
134 } else {
135 score[2] -= premium*premium;
137 if ((lua_type(L, 2)==LUA_TSTRING)) {
138 score[2] += premium;
139 } else if (false) {
140 score[2] += premium-1; // table: 0x12f7cc0;
141 } else {
142 score[2] -= premium*premium;
144 if (lua_isnumber(L, 3)) {
145 score[2] += premium;
146 } else if (false) {
147 score[2] += premium-1; // table: 0x12f8a20;
148 } else {
149 score[2] -= premium*premium;
151 int best = 1;
152 for (int i=1;i<=2;i++) {
153 if (score[best] < score[i]) { best = i; }
155 switch (best) {
156 case 1: return __LuaWrapCall__trUtf8__OverloadedVersion__1(L); break;
157 case 2: return __LuaWrapCall__trUtf8__OverloadedVersion__2(L); break;
159 lua_pushstring(L, "no overload of function __LuaWrapCall__trUtf8 matching arguments");
160 lua_error(L);
161 return 0;
163 int LuaBinder< QMainWindow >::__LuaWrapCall__setUnifiedTitleAndToolBarOnMac (lua_State *L) {
164 QMainWindow *& __lua__obj = *static_cast<QMainWindow**>(lqtL_checkudata(L, 1, "QMainWindow*"));
165 if (__lua__obj==0) {
166 lua_pushstring(L, "trying to reference deleted pointer");
167 lua_error(L);
168 return 0;
170 bool arg1 = (bool)lua_toboolean(L, 2);
171 __lua__obj->QMainWindow::setUnifiedTitleAndToolBarOnMac(arg1);
172 return 0;
174 int LuaBinder< QMainWindow >::__LuaWrapCall__tr__OverloadedVersion__1 (lua_State *L) {
175 const char * arg1 = lua_tostring(L, 1);
176 const char * arg2 = (lua_type(L, 2)==LUA_TSTRING)?lua_tostring(L, 2):static_cast< const char * >(0);
177 QString ret = QMainWindow::tr(arg1, arg2);
178 lua_pushlstring(L, ret.toAscii().data(), ret.toAscii().size());
179 return 1;
181 int LuaBinder< QMainWindow >::__LuaWrapCall__tr__OverloadedVersion__2 (lua_State *L) {
182 const char * arg1 = lua_tostring(L, 1);
183 const char * arg2 = lua_tostring(L, 2);
184 int arg3 = lua_tointeger(L, 3);
185 QString ret = QMainWindow::tr(arg1, arg2, arg3);
186 lua_pushlstring(L, ret.toAscii().data(), ret.toAscii().size());
187 return 1;
189 int LuaBinder< QMainWindow >::__LuaWrapCall__tr (lua_State *L) {
190 int score[3];
191 const int premium = 11+lua_gettop(L);
192 score[1] = 0;
193 if ((lua_type(L, 1)==LUA_TSTRING)) {
194 score[1] += premium;
195 } else if (false) {
196 score[1] += premium-1; // table: 0x12f5a40;
197 } else {
198 score[1] -= premium*premium;
200 if ((lua_type(L, 2)==LUA_TSTRING)) {
201 score[1] += premium;
202 } else if (true) {
203 score[1] += premium-1; // table: 0x12f57a0;
204 } else {
205 score[1] -= premium*premium;
207 score[2] = 0;
208 if ((lua_type(L, 1)==LUA_TSTRING)) {
209 score[2] += premium;
210 } else if (false) {
211 score[2] += premium-1; // table: 0x12f7480;
212 } else {
213 score[2] -= premium*premium;
215 if ((lua_type(L, 2)==LUA_TSTRING)) {
216 score[2] += premium;
217 } else if (false) {
218 score[2] += premium-1; // table: 0x12f7970;
219 } else {
220 score[2] -= premium*premium;
222 if (lua_isnumber(L, 3)) {
223 score[2] += premium;
224 } else if (false) {
225 score[2] += premium-1; // table: 0x12f7d20;
226 } else {
227 score[2] -= premium*premium;
229 int best = 1;
230 for (int i=1;i<=2;i++) {
231 if (score[best] < score[i]) { best = i; }
233 switch (best) {
234 case 1: return __LuaWrapCall__tr__OverloadedVersion__1(L); break;
235 case 2: return __LuaWrapCall__tr__OverloadedVersion__2(L); break;
237 lua_pushstring(L, "no overload of function __LuaWrapCall__tr matching arguments");
238 lua_error(L);
239 return 0;
241 int LuaBinder< QMainWindow >::__LuaWrapCall__menuWidget (lua_State *L) {
242 QMainWindow *& __lua__obj = *static_cast<QMainWindow**>(lqtL_checkudata(L, 1, "QMainWindow*"));
243 if (__lua__obj==0) {
244 lua_pushstring(L, "trying to reference deleted pointer");
245 lua_error(L);
246 return 0;
248 QWidget * ret = __lua__obj->QMainWindow::menuWidget();
249 lqtL_pushudata(L, ret, "QWidget*");
250 return 1;
252 int LuaBinder< QMainWindow >::__LuaWrapCall__removeDockWidget (lua_State *L) {
253 QMainWindow *& __lua__obj = *static_cast<QMainWindow**>(lqtL_checkudata(L, 1, "QMainWindow*"));
254 if (__lua__obj==0) {
255 lua_pushstring(L, "trying to reference deleted pointer");
256 lua_error(L);
257 return 0;
259 QDockWidget * arg1 = *static_cast<QDockWidget**>(lqtL_checkudata(L, 2, "QDockWidget*"));
260 __lua__obj->QMainWindow::removeDockWidget(arg1);
261 return 0;
263 int LuaBinder< QMainWindow >::__LuaWrapCall__setCentralWidget (lua_State *L) {
264 QMainWindow *& __lua__obj = *static_cast<QMainWindow**>(lqtL_checkudata(L, 1, "QMainWindow*"));
265 if (__lua__obj==0) {
266 lua_pushstring(L, "trying to reference deleted pointer");
267 lua_error(L);
268 return 0;
270 QWidget * arg1 = *static_cast<QWidget**>(lqtL_checkudata(L, 2, "QWidget*"));
271 __lua__obj->QMainWindow::setCentralWidget(arg1);
272 return 0;
274 int LuaBinder< QMainWindow >::__LuaWrapCall__setDockOptions (lua_State *L) {
275 QMainWindow *& __lua__obj = *static_cast<QMainWindow**>(lqtL_checkudata(L, 1, "QMainWindow*"));
276 if (__lua__obj==0) {
277 lua_pushstring(L, "trying to reference deleted pointer");
278 lua_error(L);
279 return 0;
281 QFlags<QMainWindow::DockOption> arg1 = **static_cast<QFlags<QMainWindow::DockOption>**>(lqtL_checkudata(L, 2, "QFlags<QMainWindow::DockOption>*"));
282 __lua__obj->QMainWindow::setDockOptions(arg1);
283 return 0;
285 int LuaBinder< QMainWindow >::__LuaWrapCall__setStatusBar (lua_State *L) {
286 QMainWindow *& __lua__obj = *static_cast<QMainWindow**>(lqtL_checkudata(L, 1, "QMainWindow*"));
287 if (__lua__obj==0) {
288 lua_pushstring(L, "trying to reference deleted pointer");
289 lua_error(L);
290 return 0;
292 QStatusBar * arg1 = *static_cast<QStatusBar**>(lqtL_checkudata(L, 2, "QStatusBar*"));
293 __lua__obj->QMainWindow::setStatusBar(arg1);
294 return 0;
296 int LuaBinder< QMainWindow >::__LuaWrapCall__insertToolBarBreak (lua_State *L) {
297 QMainWindow *& __lua__obj = *static_cast<QMainWindow**>(lqtL_checkudata(L, 1, "QMainWindow*"));
298 if (__lua__obj==0) {
299 lua_pushstring(L, "trying to reference deleted pointer");
300 lua_error(L);
301 return 0;
303 QToolBar * arg1 = *static_cast<QToolBar**>(lqtL_checkudata(L, 2, "QToolBar*"));
304 __lua__obj->QMainWindow::insertToolBarBreak(arg1);
305 return 0;
307 int LuaBinder< QMainWindow >::__LuaWrapCall__setMenuWidget (lua_State *L) {
308 QMainWindow *& __lua__obj = *static_cast<QMainWindow**>(lqtL_checkudata(L, 1, "QMainWindow*"));
309 if (__lua__obj==0) {
310 lua_pushstring(L, "trying to reference deleted pointer");
311 lua_error(L);
312 return 0;
314 QWidget * arg1 = *static_cast<QWidget**>(lqtL_checkudata(L, 2, "QWidget*"));
315 __lua__obj->QMainWindow::setMenuWidget(arg1);
316 return 0;
318 int LuaBinder< QMainWindow >::__LuaWrapCall__setMenuBar (lua_State *L) {
319 QMainWindow *& __lua__obj = *static_cast<QMainWindow**>(lqtL_checkudata(L, 1, "QMainWindow*"));
320 if (__lua__obj==0) {
321 lua_pushstring(L, "trying to reference deleted pointer");
322 lua_error(L);
323 return 0;
325 QMenuBar * arg1 = *static_cast<QMenuBar**>(lqtL_checkudata(L, 2, "QMenuBar*"));
326 __lua__obj->QMainWindow::setMenuBar(arg1);
327 return 0;
329 int LuaBinder< QMainWindow >::__LuaWrapCall__isAnimated (lua_State *L) {
330 QMainWindow *& __lua__obj = *static_cast<QMainWindow**>(lqtL_checkudata(L, 1, "QMainWindow*"));
331 if (__lua__obj==0) {
332 lua_pushstring(L, "trying to reference deleted pointer");
333 lua_error(L);
334 return 0;
336 bool ret = __lua__obj->QMainWindow::isAnimated();
337 lua_pushboolean(L, ret);
338 return 1;
340 int LuaBinder< QMainWindow >::__LuaWrapCall__statusBar (lua_State *L) {
341 QMainWindow *& __lua__obj = *static_cast<QMainWindow**>(lqtL_checkudata(L, 1, "QMainWindow*"));
342 if (__lua__obj==0) {
343 lua_pushstring(L, "trying to reference deleted pointer");
344 lua_error(L);
345 return 0;
347 QStatusBar * ret = __lua__obj->QMainWindow::statusBar();
348 lqtL_pushudata(L, ret, "QStatusBar*");
349 return 1;
351 int LuaBinder< QMainWindow >::__LuaWrapCall__menuBar (lua_State *L) {
352 QMainWindow *& __lua__obj = *static_cast<QMainWindow**>(lqtL_checkudata(L, 1, "QMainWindow*"));
353 if (__lua__obj==0) {
354 lua_pushstring(L, "trying to reference deleted pointer");
355 lua_error(L);
356 return 0;
358 QMenuBar * ret = __lua__obj->QMainWindow::menuBar();
359 lqtL_pushudata(L, ret, "QMenuBar*");
360 return 1;
362 int LuaBinder< QMainWindow >::__LuaWrapCall__setDockNestingEnabled (lua_State *L) {
363 QMainWindow *& __lua__obj = *static_cast<QMainWindow**>(lqtL_checkudata(L, 1, "QMainWindow*"));
364 if (__lua__obj==0) {
365 lua_pushstring(L, "trying to reference deleted pointer");
366 lua_error(L);
367 return 0;
369 bool arg1 = (bool)lua_toboolean(L, 2);
370 __lua__obj->QMainWindow::setDockNestingEnabled(arg1);
371 return 0;
373 int LuaBinder< QMainWindow >::__LuaWrapCall__setIconSize (lua_State *L) {
374 QMainWindow *& __lua__obj = *static_cast<QMainWindow**>(lqtL_checkudata(L, 1, "QMainWindow*"));
375 if (__lua__obj==0) {
376 lua_pushstring(L, "trying to reference deleted pointer");
377 lua_error(L);
378 return 0;
380 const QSize& arg1 = **static_cast<QSize**>(lqtL_checkudata(L, 2, "QSize*"));
381 __lua__obj->QMainWindow::setIconSize(arg1);
382 return 0;
384 int LuaBinder< QMainWindow >::__LuaWrapCall__iconSize (lua_State *L) {
385 QMainWindow *& __lua__obj = *static_cast<QMainWindow**>(lqtL_checkudata(L, 1, "QMainWindow*"));
386 if (__lua__obj==0) {
387 lua_pushstring(L, "trying to reference deleted pointer");
388 lua_error(L);
389 return 0;
391 QSize ret = __lua__obj->QMainWindow::iconSize();
392 lqtL_passudata(L, new QSize(ret), "QSize*");
393 return 1;
395 int LuaBinder< QMainWindow >::__LuaWrapCall__dockWidgetArea (lua_State *L) {
396 QMainWindow *& __lua__obj = *static_cast<QMainWindow**>(lqtL_checkudata(L, 1, "QMainWindow*"));
397 if (__lua__obj==0) {
398 lua_pushstring(L, "trying to reference deleted pointer");
399 lua_error(L);
400 return 0;
402 QDockWidget * arg1 = *static_cast<QDockWidget**>(lqtL_checkudata(L, 2, "QDockWidget*"));
403 Qt::DockWidgetArea ret = __lua__obj->QMainWindow::dockWidgetArea(arg1);
404 lqtL_pushenum(L, ret, "Qt::DockWidgetArea");
405 return 1;
407 int LuaBinder< QMainWindow >::__LuaWrapCall__metaObject (lua_State *L) {
408 QMainWindow *& __lua__obj = *static_cast<QMainWindow**>(lqtL_checkudata(L, 1, "QMainWindow*"));
409 if (__lua__obj==0) {
410 lua_pushstring(L, "trying to reference deleted pointer");
411 lua_error(L);
412 return 0;
414 const QMetaObject * ret = __lua__obj->QMainWindow::metaObject();
415 lqtL_pushudata(L, ret, "QMetaObject*");
416 return 1;
418 int LuaBinder< QMainWindow >::__LuaWrapCall__new (lua_State *L) {
419 QWidget * arg1 = lqtL_testudata(L, 1, "QWidget*")?*static_cast<QWidget**>(lqtL_checkudata(L, 1, "QWidget*")):static_cast< QWidget * >(0);
420 QFlags<Qt::WindowType> arg2 = lqtL_testudata(L, 2, "QFlags<Qt::WindowType>*")?**static_cast<QFlags<Qt::WindowType>**>(lqtL_checkudata(L, 2, "QFlags<Qt::WindowType>*")):static_cast< QFlags<Qt::WindowType> >(0);
421 QMainWindow * ret = new LuaBinder< QMainWindow >(L, arg1, arg2);
422 lqtL_passudata(L, ret, "QMainWindow*");
423 return 1;
425 int LuaBinder< QMainWindow >::__LuaWrapCall__unifiedTitleAndToolBarOnMac (lua_State *L) {
426 QMainWindow *& __lua__obj = *static_cast<QMainWindow**>(lqtL_checkudata(L, 1, "QMainWindow*"));
427 if (__lua__obj==0) {
428 lua_pushstring(L, "trying to reference deleted pointer");
429 lua_error(L);
430 return 0;
432 bool ret = __lua__obj->QMainWindow::unifiedTitleAndToolBarOnMac();
433 lua_pushboolean(L, ret);
434 return 1;
436 int LuaBinder< QMainWindow >::__LuaWrapCall__delete (lua_State *L) {
437 QMainWindow *& __lua__obj = *static_cast<QMainWindow**>(lqtL_checkudata(L, 1, "QMainWindow*"));
438 if (__lua__obj==0) {
439 lua_pushstring(L, "trying to reference deleted pointer");
440 lua_error(L);
441 return 0;
443 delete __lua__obj;
444 __lua__obj = 0;
445 return 0;
447 int LuaBinder< QMainWindow >::__LuaWrapCall__setCorner (lua_State *L) {
448 QMainWindow *& __lua__obj = *static_cast<QMainWindow**>(lqtL_checkudata(L, 1, "QMainWindow*"));
449 if (__lua__obj==0) {
450 lua_pushstring(L, "trying to reference deleted pointer");
451 lua_error(L);
452 return 0;
454 Qt::Corner arg1 = static_cast<Qt::Corner>(lqtL_toenum(L, 2, "Qt::Corner"));
455 Qt::DockWidgetArea arg2 = static_cast<Qt::DockWidgetArea>(lqtL_toenum(L, 3, "Qt::DockWidgetArea"));
456 __lua__obj->QMainWindow::setCorner(arg1, arg2);
457 return 0;
459 int LuaBinder< QMainWindow >::__LuaWrapCall__corner (lua_State *L) {
460 QMainWindow *& __lua__obj = *static_cast<QMainWindow**>(lqtL_checkudata(L, 1, "QMainWindow*"));
461 if (__lua__obj==0) {
462 lua_pushstring(L, "trying to reference deleted pointer");
463 lua_error(L);
464 return 0;
466 Qt::Corner arg1 = static_cast<Qt::Corner>(lqtL_toenum(L, 2, "Qt::Corner"));
467 Qt::DockWidgetArea ret = __lua__obj->QMainWindow::corner(arg1);
468 lqtL_pushenum(L, ret, "Qt::DockWidgetArea");
469 return 1;
471 int LuaBinder< QMainWindow >::__LuaWrapCall__addToolBar__OverloadedVersion__1 (lua_State *L) {
472 QMainWindow *& __lua__obj = *static_cast<QMainWindow**>(lqtL_checkudata(L, 1, "QMainWindow*"));
473 if (__lua__obj==0) {
474 lua_pushstring(L, "trying to reference deleted pointer");
475 lua_error(L);
476 return 0;
478 Qt::ToolBarArea arg1 = static_cast<Qt::ToolBarArea>(lqtL_toenum(L, 2, "Qt::ToolBarArea"));
479 QToolBar * arg2 = *static_cast<QToolBar**>(lqtL_checkudata(L, 3, "QToolBar*"));
480 __lua__obj->QMainWindow::addToolBar(arg1, arg2);
481 return 0;
483 int LuaBinder< QMainWindow >::__LuaWrapCall__addToolBar__OverloadedVersion__2 (lua_State *L) {
484 QMainWindow *& __lua__obj = *static_cast<QMainWindow**>(lqtL_checkudata(L, 1, "QMainWindow*"));
485 if (__lua__obj==0) {
486 lua_pushstring(L, "trying to reference deleted pointer");
487 lua_error(L);
488 return 0;
490 QToolBar * arg1 = *static_cast<QToolBar**>(lqtL_checkudata(L, 2, "QToolBar*"));
491 __lua__obj->QMainWindow::addToolBar(arg1);
492 return 0;
494 int LuaBinder< QMainWindow >::__LuaWrapCall__addToolBar__OverloadedVersion__3 (lua_State *L) {
495 QMainWindow *& __lua__obj = *static_cast<QMainWindow**>(lqtL_checkudata(L, 1, "QMainWindow*"));
496 if (__lua__obj==0) {
497 lua_pushstring(L, "trying to reference deleted pointer");
498 lua_error(L);
499 return 0;
501 const QString& arg1 = QString::fromAscii(lua_tostring(L, 2), lua_objlen(L, 2));
502 QToolBar * ret = __lua__obj->QMainWindow::addToolBar(arg1);
503 lqtL_pushudata(L, ret, "QToolBar*");
504 return 1;
506 int LuaBinder< QMainWindow >::__LuaWrapCall__addToolBar (lua_State *L) {
507 int score[4];
508 const int premium = 11+lua_gettop(L);
509 score[1] = 0;
510 score[1] += lqtL_testudata(L, 1, "QMainWindow*")?premium:-premium*premium;
511 if (lqtL_isenum(L, 2, "Qt::ToolBarArea")) {
512 score[1] += premium;
513 } else if (false) {
514 score[1] += premium-1; // table: 0x1308640;
515 } else {
516 score[1] -= premium*premium;
518 if (lqtL_testudata(L, 3, "QToolBar*")) {
519 score[1] += premium;
520 } else if (false) {
521 score[1] += premium-1; // table: 0x1308030;
522 } else {
523 score[1] -= premium*premium;
525 score[2] = 0;
526 score[2] += lqtL_testudata(L, 1, "QMainWindow*")?premium:-premium*premium;
527 if (lqtL_testudata(L, 2, "QToolBar*")) {
528 score[2] += premium;
529 } else if (false) {
530 score[2] += premium-1; // table: 0x13094e0;
531 } else {
532 score[2] -= premium*premium;
534 score[3] = 0;
535 score[3] += lqtL_testudata(L, 1, "QMainWindow*")?premium:-premium*premium;
536 if ((lua_type(L, 2)==LUA_TSTRING)) {
537 score[3] += premium;
538 } else if (false) {
539 score[3] += premium-1; // table: 0x1309f30;
540 } else {
541 score[3] -= premium*premium;
543 int best = 1;
544 for (int i=1;i<=3;i++) {
545 if (score[best] < score[i]) { best = i; }
547 switch (best) {
548 case 1: return __LuaWrapCall__addToolBar__OverloadedVersion__1(L); break;
549 case 2: return __LuaWrapCall__addToolBar__OverloadedVersion__2(L); break;
550 case 3: return __LuaWrapCall__addToolBar__OverloadedVersion__3(L); break;
552 lua_pushstring(L, "no overload of function __LuaWrapCall__addToolBar matching arguments");
553 lua_error(L);
554 return 0;
556 int LuaBinder< QMainWindow >::__LuaWrapCall__removeToolBar (lua_State *L) {
557 QMainWindow *& __lua__obj = *static_cast<QMainWindow**>(lqtL_checkudata(L, 1, "QMainWindow*"));
558 if (__lua__obj==0) {
559 lua_pushstring(L, "trying to reference deleted pointer");
560 lua_error(L);
561 return 0;
563 QToolBar * arg1 = *static_cast<QToolBar**>(lqtL_checkudata(L, 2, "QToolBar*"));
564 __lua__obj->QMainWindow::removeToolBar(arg1);
565 return 0;
567 int LuaBinder< QMainWindow >::__LuaWrapCall__dockOptions (lua_State *L) {
568 QMainWindow *& __lua__obj = *static_cast<QMainWindow**>(lqtL_checkudata(L, 1, "QMainWindow*"));
569 if (__lua__obj==0) {
570 lua_pushstring(L, "trying to reference deleted pointer");
571 lua_error(L);
572 return 0;
574 QFlags<QMainWindow::DockOption> ret = __lua__obj->QMainWindow::dockOptions();
575 lqtL_passudata(L, new QFlags<QMainWindow::DockOption>(ret), "QFlags<QMainWindow::DockOption>*");
576 return 1;
578 int LuaBinder< QMainWindow >::__LuaWrapCall__restoreState (lua_State *L) {
579 QMainWindow *& __lua__obj = *static_cast<QMainWindow**>(lqtL_checkudata(L, 1, "QMainWindow*"));
580 if (__lua__obj==0) {
581 lua_pushstring(L, "trying to reference deleted pointer");
582 lua_error(L);
583 return 0;
585 const QByteArray& arg1 = QByteArray(lua_tostring(L, 2), lua_objlen(L, 2));
586 int arg2 = lua_isnumber(L, 3)?lua_tointeger(L, 3):static_cast< int >(0);
587 bool ret = __lua__obj->QMainWindow::restoreState(arg1, arg2);
588 lua_pushboolean(L, ret);
589 return 1;
591 int LuaBinder< QMainWindow >::__LuaWrapCall__toolButtonStyle (lua_State *L) {
592 QMainWindow *& __lua__obj = *static_cast<QMainWindow**>(lqtL_checkudata(L, 1, "QMainWindow*"));
593 if (__lua__obj==0) {
594 lua_pushstring(L, "trying to reference deleted pointer");
595 lua_error(L);
596 return 0;
598 Qt::ToolButtonStyle ret = __lua__obj->QMainWindow::toolButtonStyle();
599 lqtL_pushenum(L, ret, "Qt::ToolButtonStyle");
600 return 1;
602 int LuaBinder< QMainWindow >::__LuaWrapCall__tabifyDockWidget (lua_State *L) {
603 QMainWindow *& __lua__obj = *static_cast<QMainWindow**>(lqtL_checkudata(L, 1, "QMainWindow*"));
604 if (__lua__obj==0) {
605 lua_pushstring(L, "trying to reference deleted pointer");
606 lua_error(L);
607 return 0;
609 QDockWidget * arg1 = *static_cast<QDockWidget**>(lqtL_checkudata(L, 2, "QDockWidget*"));
610 QDockWidget * arg2 = *static_cast<QDockWidget**>(lqtL_checkudata(L, 3, "QDockWidget*"));
611 __lua__obj->QMainWindow::tabifyDockWidget(arg1, arg2);
612 return 0;
614 int LuaBinder< QMainWindow >::__LuaWrapCall__isDockNestingEnabled (lua_State *L) {
615 QMainWindow *& __lua__obj = *static_cast<QMainWindow**>(lqtL_checkudata(L, 1, "QMainWindow*"));
616 if (__lua__obj==0) {
617 lua_pushstring(L, "trying to reference deleted pointer");
618 lua_error(L);
619 return 0;
621 bool ret = __lua__obj->QMainWindow::isDockNestingEnabled();
622 lua_pushboolean(L, ret);
623 return 1;
625 int LuaBinder< QMainWindow >::__LuaWrapCall__isSeparator (lua_State *L) {
626 QMainWindow *& __lua__obj = *static_cast<QMainWindow**>(lqtL_checkudata(L, 1, "QMainWindow*"));
627 if (__lua__obj==0) {
628 lua_pushstring(L, "trying to reference deleted pointer");
629 lua_error(L);
630 return 0;
632 const QPoint& arg1 = **static_cast<QPoint**>(lqtL_checkudata(L, 2, "QPoint*"));
633 bool ret = __lua__obj->QMainWindow::isSeparator(arg1);
634 lua_pushboolean(L, ret);
635 return 1;
637 int LuaBinder< QMainWindow >::__LuaWrapCall__addDockWidget__OverloadedVersion__1 (lua_State *L) {
638 QMainWindow *& __lua__obj = *static_cast<QMainWindow**>(lqtL_checkudata(L, 1, "QMainWindow*"));
639 if (__lua__obj==0) {
640 lua_pushstring(L, "trying to reference deleted pointer");
641 lua_error(L);
642 return 0;
644 Qt::DockWidgetArea arg1 = static_cast<Qt::DockWidgetArea>(lqtL_toenum(L, 2, "Qt::DockWidgetArea"));
645 QDockWidget * arg2 = *static_cast<QDockWidget**>(lqtL_checkudata(L, 3, "QDockWidget*"));
646 __lua__obj->QMainWindow::addDockWidget(arg1, arg2);
647 return 0;
649 int LuaBinder< QMainWindow >::__LuaWrapCall__addDockWidget__OverloadedVersion__2 (lua_State *L) {
650 QMainWindow *& __lua__obj = *static_cast<QMainWindow**>(lqtL_checkudata(L, 1, "QMainWindow*"));
651 if (__lua__obj==0) {
652 lua_pushstring(L, "trying to reference deleted pointer");
653 lua_error(L);
654 return 0;
656 Qt::DockWidgetArea arg1 = static_cast<Qt::DockWidgetArea>(lqtL_toenum(L, 2, "Qt::DockWidgetArea"));
657 QDockWidget * arg2 = *static_cast<QDockWidget**>(lqtL_checkudata(L, 3, "QDockWidget*"));
658 Qt::Orientation arg3 = static_cast<Qt::Orientation>(lqtL_toenum(L, 4, "Qt::Orientation"));
659 __lua__obj->QMainWindow::addDockWidget(arg1, arg2, arg3);
660 return 0;
662 int LuaBinder< QMainWindow >::__LuaWrapCall__addDockWidget (lua_State *L) {
663 int score[3];
664 const int premium = 11+lua_gettop(L);
665 score[1] = 0;
666 score[1] += lqtL_testudata(L, 1, "QMainWindow*")?premium:-premium*premium;
667 if (lqtL_isenum(L, 2, "Qt::DockWidgetArea")) {
668 score[1] += premium;
669 } else if (false) {
670 score[1] += premium-1; // table: 0x130f820;
671 } else {
672 score[1] -= premium*premium;
674 if (lqtL_testudata(L, 3, "QDockWidget*")) {
675 score[1] += premium;
676 } else if (false) {
677 score[1] += premium-1; // table: 0x130f230;
678 } else {
679 score[1] -= premium*premium;
681 score[2] = 0;
682 score[2] += lqtL_testudata(L, 1, "QMainWindow*")?premium:-premium*premium;
683 if (lqtL_isenum(L, 2, "Qt::DockWidgetArea")) {
684 score[2] += premium;
685 } else if (false) {
686 score[2] += premium-1; // table: 0x13107e0;
687 } else {
688 score[2] -= premium*premium;
690 if (lqtL_testudata(L, 3, "QDockWidget*")) {
691 score[2] += premium;
692 } else if (false) {
693 score[2] += premium-1; // table: 0x1310d30;
694 } else {
695 score[2] -= premium*premium;
697 if (lqtL_isenum(L, 4, "Qt::Orientation")) {
698 score[2] += premium;
699 } else if (false) {
700 score[2] += premium-1; // table: 0x1310cd0;
701 } else {
702 score[2] -= premium*premium;
704 int best = 1;
705 for (int i=1;i<=2;i++) {
706 if (score[best] < score[i]) { best = i; }
708 switch (best) {
709 case 1: return __LuaWrapCall__addDockWidget__OverloadedVersion__1(L); break;
710 case 2: return __LuaWrapCall__addDockWidget__OverloadedVersion__2(L); break;
712 lua_pushstring(L, "no overload of function __LuaWrapCall__addDockWidget matching arguments");
713 lua_error(L);
714 return 0;
716 int LuaBinder< QMainWindow >::__LuaWrapCall__setToolButtonStyle (lua_State *L) {
717 QMainWindow *& __lua__obj = *static_cast<QMainWindow**>(lqtL_checkudata(L, 1, "QMainWindow*"));
718 if (__lua__obj==0) {
719 lua_pushstring(L, "trying to reference deleted pointer");
720 lua_error(L);
721 return 0;
723 Qt::ToolButtonStyle arg1 = static_cast<Qt::ToolButtonStyle>(lqtL_toenum(L, 2, "Qt::ToolButtonStyle"));
724 __lua__obj->QMainWindow::setToolButtonStyle(arg1);
725 return 0;
727 int LuaBinder< QMainWindow >::__LuaWrapCall__toolBarArea (lua_State *L) {
728 QMainWindow *& __lua__obj = *static_cast<QMainWindow**>(lqtL_checkudata(L, 1, "QMainWindow*"));
729 if (__lua__obj==0) {
730 lua_pushstring(L, "trying to reference deleted pointer");
731 lua_error(L);
732 return 0;
734 QToolBar * arg1 = *static_cast<QToolBar**>(lqtL_checkudata(L, 2, "QToolBar*"));
735 Qt::ToolBarArea ret = __lua__obj->QMainWindow::toolBarArea(arg1);
736 lqtL_pushenum(L, ret, "Qt::ToolBarArea");
737 return 1;
739 int LuaBinder< QMainWindow >::__LuaWrapCall__centralWidget (lua_State *L) {
740 QMainWindow *& __lua__obj = *static_cast<QMainWindow**>(lqtL_checkudata(L, 1, "QMainWindow*"));
741 if (__lua__obj==0) {
742 lua_pushstring(L, "trying to reference deleted pointer");
743 lua_error(L);
744 return 0;
746 QWidget * ret = __lua__obj->QMainWindow::centralWidget();
747 lqtL_pushudata(L, ret, "QWidget*");
748 return 1;
750 void LuaBinder< QMainWindow >::styleChange (QStyle& arg1) {
751 bool absorbed = false;
752 int oldtop = lua_gettop(L);
753 lqtL_pushudata(L, this, "QMainWindow*");
754 if (lua_getmetatable(L, -1)) {
755 lua_getfield(L, -1, "styleChange");
756 lua_remove(L, -2);
757 } else {
758 lua_pushnil(L);
760 lua_insert(L, -2);
761 lqtL_pushudata(L, &(arg1), "QStyle*");
762 if (lua_isfunction(L, -1-2)) {
763 lua_pcall(L, 1+1, 2, 0);
764 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
765 lua_pop(L, 1);
767 if (!absorbed) {
768 lua_settop(L, oldtop);
769 this->QWidget::styleChange(arg1);
771 lua_settop(L, oldtop);
773 void LuaBinder< QMainWindow >::focusInEvent (QFocusEvent * arg1) {
774 bool absorbed = false;
775 int oldtop = lua_gettop(L);
776 lqtL_pushudata(L, this, "QMainWindow*");
777 if (lua_getmetatable(L, -1)) {
778 lua_getfield(L, -1, "focusInEvent");
779 lua_remove(L, -2);
780 } else {
781 lua_pushnil(L);
783 lua_insert(L, -2);
784 lqtL_pushudata(L, arg1, "QFocusEvent*");
785 if (lua_isfunction(L, -1-2)) {
786 lua_pcall(L, 1+1, 2, 0);
787 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
788 lua_pop(L, 1);
790 if (!absorbed) {
791 lua_settop(L, oldtop);
792 this->QWidget::focusInEvent(arg1);
794 lua_settop(L, oldtop);
796 void LuaBinder< QMainWindow >::keyPressEvent (QKeyEvent * arg1) {
797 bool absorbed = false;
798 int oldtop = lua_gettop(L);
799 lqtL_pushudata(L, this, "QMainWindow*");
800 if (lua_getmetatable(L, -1)) {
801 lua_getfield(L, -1, "keyPressEvent");
802 lua_remove(L, -2);
803 } else {
804 lua_pushnil(L);
806 lua_insert(L, -2);
807 lqtL_pushudata(L, arg1, "QKeyEvent*");
808 if (lua_isfunction(L, -1-2)) {
809 lua_pcall(L, 1+1, 2, 0);
810 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
811 lua_pop(L, 1);
813 if (!absorbed) {
814 lua_settop(L, oldtop);
815 this->QWidget::keyPressEvent(arg1);
817 lua_settop(L, oldtop);
819 const QMetaObject * LuaBinder< QMainWindow >::metaObject () const {
820 bool absorbed = false;
821 int oldtop = lua_gettop(L);
822 lqtL_pushudata(L, this, "QMainWindow*");
823 if (lua_getmetatable(L, -1)) {
824 lua_getfield(L, -1, "metaObject");
825 lua_remove(L, -2);
826 } else {
827 lua_pushnil(L);
829 lua_insert(L, -2);
830 if (lua_isfunction(L, -0-2)) {
831 lua_pcall(L, 0+1, 2, 0);
832 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
833 lua_pop(L, 1);
835 if (!absorbed) {
836 lua_settop(L, oldtop);
837 return this->QMainWindow::metaObject();
839 const QMetaObject * ret = *static_cast<QMetaObject**>(lqtL_checkudata(L, -1, "QMetaObject*"));
840 lua_settop(L, oldtop);
841 return ret;
843 int LuaBinder< QMainWindow >::devType () const {
844 bool absorbed = false;
845 int oldtop = lua_gettop(L);
846 lqtL_pushudata(L, this, "QMainWindow*");
847 if (lua_getmetatable(L, -1)) {
848 lua_getfield(L, -1, "devType");
849 lua_remove(L, -2);
850 } else {
851 lua_pushnil(L);
853 lua_insert(L, -2);
854 if (lua_isfunction(L, -0-2)) {
855 lua_pcall(L, 0+1, 2, 0);
856 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
857 lua_pop(L, 1);
859 if (!absorbed) {
860 lua_settop(L, oldtop);
861 return this->QWidget::devType();
863 int ret = lua_tointeger(L, -1);
864 lua_settop(L, oldtop);
865 return ret;
867 void LuaBinder< QMainWindow >::setVisible (bool arg1) {
868 bool absorbed = false;
869 int oldtop = lua_gettop(L);
870 lqtL_pushudata(L, this, "QMainWindow*");
871 if (lua_getmetatable(L, -1)) {
872 lua_getfield(L, -1, "setVisible");
873 lua_remove(L, -2);
874 } else {
875 lua_pushnil(L);
877 lua_insert(L, -2);
878 lua_pushboolean(L, arg1);
879 if (lua_isfunction(L, -1-2)) {
880 lua_pcall(L, 1+1, 2, 0);
881 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
882 lua_pop(L, 1);
884 if (!absorbed) {
885 lua_settop(L, oldtop);
886 this->QWidget::setVisible(arg1);
888 lua_settop(L, oldtop);
890 QVariant LuaBinder< QMainWindow >::inputMethodQuery (Qt::InputMethodQuery arg1) const {
891 bool absorbed = false;
892 int oldtop = lua_gettop(L);
893 lqtL_pushudata(L, this, "QMainWindow*");
894 if (lua_getmetatable(L, -1)) {
895 lua_getfield(L, -1, "inputMethodQuery");
896 lua_remove(L, -2);
897 } else {
898 lua_pushnil(L);
900 lua_insert(L, -2);
901 lqtL_pushenum(L, arg1, "Qt::InputMethodQuery");
902 if (lua_isfunction(L, -1-2)) {
903 lua_pcall(L, 1+1, 2, 0);
904 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
905 lua_pop(L, 1);
907 if (!absorbed) {
908 lua_settop(L, oldtop);
909 return this->QWidget::inputMethodQuery(arg1);
911 QVariant ret = **static_cast<QVariant**>(lqtL_checkudata(L, -1, "QVariant*"));
912 lua_settop(L, oldtop);
913 return ret;
915 QPaintEngine * LuaBinder< QMainWindow >::paintEngine () const {
916 bool absorbed = false;
917 int oldtop = lua_gettop(L);
918 lqtL_pushudata(L, this, "QMainWindow*");
919 if (lua_getmetatable(L, -1)) {
920 lua_getfield(L, -1, "paintEngine");
921 lua_remove(L, -2);
922 } else {
923 lua_pushnil(L);
925 lua_insert(L, -2);
926 if (lua_isfunction(L, -0-2)) {
927 lua_pcall(L, 0+1, 2, 0);
928 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
929 lua_pop(L, 1);
931 if (!absorbed) {
932 lua_settop(L, oldtop);
933 return this->QWidget::paintEngine();
935 QPaintEngine * ret = *static_cast<QPaintEngine**>(lqtL_checkudata(L, -1, "QPaintEngine*"));
936 lua_settop(L, oldtop);
937 return ret;
939 void LuaBinder< QMainWindow >::dragLeaveEvent (QDragLeaveEvent * arg1) {
940 bool absorbed = false;
941 int oldtop = lua_gettop(L);
942 lqtL_pushudata(L, this, "QMainWindow*");
943 if (lua_getmetatable(L, -1)) {
944 lua_getfield(L, -1, "dragLeaveEvent");
945 lua_remove(L, -2);
946 } else {
947 lua_pushnil(L);
949 lua_insert(L, -2);
950 lqtL_pushudata(L, arg1, "QDragLeaveEvent*");
951 if (lua_isfunction(L, -1-2)) {
952 lua_pcall(L, 1+1, 2, 0);
953 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
954 lua_pop(L, 1);
956 if (!absorbed) {
957 lua_settop(L, oldtop);
958 this->QWidget::dragLeaveEvent(arg1);
960 lua_settop(L, oldtop);
962 void LuaBinder< QMainWindow >::mousePressEvent (QMouseEvent * arg1) {
963 bool absorbed = false;
964 int oldtop = lua_gettop(L);
965 lqtL_pushudata(L, this, "QMainWindow*");
966 if (lua_getmetatable(L, -1)) {
967 lua_getfield(L, -1, "mousePressEvent");
968 lua_remove(L, -2);
969 } else {
970 lua_pushnil(L);
972 lua_insert(L, -2);
973 lqtL_pushudata(L, arg1, "QMouseEvent*");
974 if (lua_isfunction(L, -1-2)) {
975 lua_pcall(L, 1+1, 2, 0);
976 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
977 lua_pop(L, 1);
979 if (!absorbed) {
980 lua_settop(L, oldtop);
981 this->QWidget::mousePressEvent(arg1);
983 lua_settop(L, oldtop);
985 QSize LuaBinder< QMainWindow >::sizeHint () const {
986 bool absorbed = false;
987 int oldtop = lua_gettop(L);
988 lqtL_pushudata(L, this, "QMainWindow*");
989 if (lua_getmetatable(L, -1)) {
990 lua_getfield(L, -1, "sizeHint");
991 lua_remove(L, -2);
992 } else {
993 lua_pushnil(L);
995 lua_insert(L, -2);
996 if (lua_isfunction(L, -0-2)) {
997 lua_pcall(L, 0+1, 2, 0);
998 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
999 lua_pop(L, 1);
1001 if (!absorbed) {
1002 lua_settop(L, oldtop);
1003 return this->QWidget::sizeHint();
1005 QSize ret = **static_cast<QSize**>(lqtL_checkudata(L, -1, "QSize*"));
1006 lua_settop(L, oldtop);
1007 return ret;
1009 void LuaBinder< QMainWindow >::moveEvent (QMoveEvent * arg1) {
1010 bool absorbed = false;
1011 int oldtop = lua_gettop(L);
1012 lqtL_pushudata(L, this, "QMainWindow*");
1013 if (lua_getmetatable(L, -1)) {
1014 lua_getfield(L, -1, "moveEvent");
1015 lua_remove(L, -2);
1016 } else {
1017 lua_pushnil(L);
1019 lua_insert(L, -2);
1020 lqtL_pushudata(L, arg1, "QMoveEvent*");
1021 if (lua_isfunction(L, -1-2)) {
1022 lua_pcall(L, 1+1, 2, 0);
1023 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
1024 lua_pop(L, 1);
1026 if (!absorbed) {
1027 lua_settop(L, oldtop);
1028 this->QWidget::moveEvent(arg1);
1030 lua_settop(L, oldtop);
1032 void LuaBinder< QMainWindow >::tabletEvent (QTabletEvent * arg1) {
1033 bool absorbed = false;
1034 int oldtop = lua_gettop(L);
1035 lqtL_pushudata(L, this, "QMainWindow*");
1036 if (lua_getmetatable(L, -1)) {
1037 lua_getfield(L, -1, "tabletEvent");
1038 lua_remove(L, -2);
1039 } else {
1040 lua_pushnil(L);
1042 lua_insert(L, -2);
1043 lqtL_pushudata(L, arg1, "QTabletEvent*");
1044 if (lua_isfunction(L, -1-2)) {
1045 lua_pcall(L, 1+1, 2, 0);
1046 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
1047 lua_pop(L, 1);
1049 if (!absorbed) {
1050 lua_settop(L, oldtop);
1051 this->QWidget::tabletEvent(arg1);
1053 lua_settop(L, oldtop);
1055 void LuaBinder< QMainWindow >::enterEvent (QEvent * arg1) {
1056 bool absorbed = false;
1057 int oldtop = lua_gettop(L);
1058 lqtL_pushudata(L, this, "QMainWindow*");
1059 if (lua_getmetatable(L, -1)) {
1060 lua_getfield(L, -1, "enterEvent");
1061 lua_remove(L, -2);
1062 } else {
1063 lua_pushnil(L);
1065 lua_insert(L, -2);
1066 lqtL_pushudata(L, arg1, "QEvent*");
1067 if (lua_isfunction(L, -1-2)) {
1068 lua_pcall(L, 1+1, 2, 0);
1069 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
1070 lua_pop(L, 1);
1072 if (!absorbed) {
1073 lua_settop(L, oldtop);
1074 this->QWidget::enterEvent(arg1);
1076 lua_settop(L, oldtop);
1078 void LuaBinder< QMainWindow >::closeEvent (QCloseEvent * arg1) {
1079 bool absorbed = false;
1080 int oldtop = lua_gettop(L);
1081 lqtL_pushudata(L, this, "QMainWindow*");
1082 if (lua_getmetatable(L, -1)) {
1083 lua_getfield(L, -1, "closeEvent");
1084 lua_remove(L, -2);
1085 } else {
1086 lua_pushnil(L);
1088 lua_insert(L, -2);
1089 lqtL_pushudata(L, arg1, "QCloseEvent*");
1090 if (lua_isfunction(L, -1-2)) {
1091 lua_pcall(L, 1+1, 2, 0);
1092 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
1093 lua_pop(L, 1);
1095 if (!absorbed) {
1096 lua_settop(L, oldtop);
1097 this->QWidget::closeEvent(arg1);
1099 lua_settop(L, oldtop);
1101 void LuaBinder< QMainWindow >::dropEvent (QDropEvent * arg1) {
1102 bool absorbed = false;
1103 int oldtop = lua_gettop(L);
1104 lqtL_pushudata(L, this, "QMainWindow*");
1105 if (lua_getmetatable(L, -1)) {
1106 lua_getfield(L, -1, "dropEvent");
1107 lua_remove(L, -2);
1108 } else {
1109 lua_pushnil(L);
1111 lua_insert(L, -2);
1112 lqtL_pushudata(L, arg1, "QDropEvent*");
1113 if (lua_isfunction(L, -1-2)) {
1114 lua_pcall(L, 1+1, 2, 0);
1115 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
1116 lua_pop(L, 1);
1118 if (!absorbed) {
1119 lua_settop(L, oldtop);
1120 this->QWidget::dropEvent(arg1);
1122 lua_settop(L, oldtop);
1124 QSize LuaBinder< QMainWindow >::minimumSizeHint () const {
1125 bool absorbed = false;
1126 int oldtop = lua_gettop(L);
1127 lqtL_pushudata(L, this, "QMainWindow*");
1128 if (lua_getmetatable(L, -1)) {
1129 lua_getfield(L, -1, "minimumSizeHint");
1130 lua_remove(L, -2);
1131 } else {
1132 lua_pushnil(L);
1134 lua_insert(L, -2);
1135 if (lua_isfunction(L, -0-2)) {
1136 lua_pcall(L, 0+1, 2, 0);
1137 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
1138 lua_pop(L, 1);
1140 if (!absorbed) {
1141 lua_settop(L, oldtop);
1142 return this->QWidget::minimumSizeHint();
1144 QSize ret = **static_cast<QSize**>(lqtL_checkudata(L, -1, "QSize*"));
1145 lua_settop(L, oldtop);
1146 return ret;
1148 QMenu * LuaBinder< QMainWindow >::createPopupMenu () {
1149 bool absorbed = false;
1150 int oldtop = lua_gettop(L);
1151 lqtL_pushudata(L, this, "QMainWindow*");
1152 if (lua_getmetatable(L, -1)) {
1153 lua_getfield(L, -1, "createPopupMenu");
1154 lua_remove(L, -2);
1155 } else {
1156 lua_pushnil(L);
1158 lua_insert(L, -2);
1159 if (lua_isfunction(L, -0-2)) {
1160 lua_pcall(L, 0+1, 2, 0);
1161 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
1162 lua_pop(L, 1);
1164 if (!absorbed) {
1165 lua_settop(L, oldtop);
1166 return this->QMainWindow::createPopupMenu();
1168 QMenu * ret = *static_cast<QMenu**>(lqtL_checkudata(L, -1, "QMenu*"));
1169 lua_settop(L, oldtop);
1170 return ret;
1172 void LuaBinder< QMainWindow >::actionEvent (QActionEvent * arg1) {
1173 bool absorbed = false;
1174 int oldtop = lua_gettop(L);
1175 lqtL_pushudata(L, this, "QMainWindow*");
1176 if (lua_getmetatable(L, -1)) {
1177 lua_getfield(L, -1, "actionEvent");
1178 lua_remove(L, -2);
1179 } else {
1180 lua_pushnil(L);
1182 lua_insert(L, -2);
1183 lqtL_pushudata(L, arg1, "QActionEvent*");
1184 if (lua_isfunction(L, -1-2)) {
1185 lua_pcall(L, 1+1, 2, 0);
1186 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
1187 lua_pop(L, 1);
1189 if (!absorbed) {
1190 lua_settop(L, oldtop);
1191 this->QWidget::actionEvent(arg1);
1193 lua_settop(L, oldtop);
1195 void LuaBinder< QMainWindow >::showEvent (QShowEvent * arg1) {
1196 bool absorbed = false;
1197 int oldtop = lua_gettop(L);
1198 lqtL_pushudata(L, this, "QMainWindow*");
1199 if (lua_getmetatable(L, -1)) {
1200 lua_getfield(L, -1, "showEvent");
1201 lua_remove(L, -2);
1202 } else {
1203 lua_pushnil(L);
1205 lua_insert(L, -2);
1206 lqtL_pushudata(L, arg1, "QShowEvent*");
1207 if (lua_isfunction(L, -1-2)) {
1208 lua_pcall(L, 1+1, 2, 0);
1209 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
1210 lua_pop(L, 1);
1212 if (!absorbed) {
1213 lua_settop(L, oldtop);
1214 this->QWidget::showEvent(arg1);
1216 lua_settop(L, oldtop);
1218 void LuaBinder< QMainWindow >::dragEnterEvent (QDragEnterEvent * arg1) {
1219 bool absorbed = false;
1220 int oldtop = lua_gettop(L);
1221 lqtL_pushudata(L, this, "QMainWindow*");
1222 if (lua_getmetatable(L, -1)) {
1223 lua_getfield(L, -1, "dragEnterEvent");
1224 lua_remove(L, -2);
1225 } else {
1226 lua_pushnil(L);
1228 lua_insert(L, -2);
1229 lqtL_pushudata(L, arg1, "QDragEnterEvent*");
1230 if (lua_isfunction(L, -1-2)) {
1231 lua_pcall(L, 1+1, 2, 0);
1232 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
1233 lua_pop(L, 1);
1235 if (!absorbed) {
1236 lua_settop(L, oldtop);
1237 this->QWidget::dragEnterEvent(arg1);
1239 lua_settop(L, oldtop);
1241 void LuaBinder< QMainWindow >::paintEvent (QPaintEvent * arg1) {
1242 bool absorbed = false;
1243 int oldtop = lua_gettop(L);
1244 lqtL_pushudata(L, this, "QMainWindow*");
1245 if (lua_getmetatable(L, -1)) {
1246 lua_getfield(L, -1, "paintEvent");
1247 lua_remove(L, -2);
1248 } else {
1249 lua_pushnil(L);
1251 lua_insert(L, -2);
1252 lqtL_pushudata(L, arg1, "QPaintEvent*");
1253 if (lua_isfunction(L, -1-2)) {
1254 lua_pcall(L, 1+1, 2, 0);
1255 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
1256 lua_pop(L, 1);
1258 if (!absorbed) {
1259 lua_settop(L, oldtop);
1260 this->QWidget::paintEvent(arg1);
1262 lua_settop(L, oldtop);
1264 void LuaBinder< QMainWindow >::dragMoveEvent (QDragMoveEvent * arg1) {
1265 bool absorbed = false;
1266 int oldtop = lua_gettop(L);
1267 lqtL_pushudata(L, this, "QMainWindow*");
1268 if (lua_getmetatable(L, -1)) {
1269 lua_getfield(L, -1, "dragMoveEvent");
1270 lua_remove(L, -2);
1271 } else {
1272 lua_pushnil(L);
1274 lua_insert(L, -2);
1275 lqtL_pushudata(L, arg1, "QDragMoveEvent*");
1276 if (lua_isfunction(L, -1-2)) {
1277 lua_pcall(L, 1+1, 2, 0);
1278 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
1279 lua_pop(L, 1);
1281 if (!absorbed) {
1282 lua_settop(L, oldtop);
1283 this->QWidget::dragMoveEvent(arg1);
1285 lua_settop(L, oldtop);
1287 void LuaBinder< QMainWindow >::contextMenuEvent (QContextMenuEvent * arg1) {
1288 bool absorbed = false;
1289 int oldtop = lua_gettop(L);
1290 lqtL_pushudata(L, this, "QMainWindow*");
1291 if (lua_getmetatable(L, -1)) {
1292 lua_getfield(L, -1, "contextMenuEvent");
1293 lua_remove(L, -2);
1294 } else {
1295 lua_pushnil(L);
1297 lua_insert(L, -2);
1298 lqtL_pushudata(L, arg1, "QContextMenuEvent*");
1299 if (lua_isfunction(L, -1-2)) {
1300 lua_pcall(L, 1+1, 2, 0);
1301 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
1302 lua_pop(L, 1);
1304 if (!absorbed) {
1305 lua_settop(L, oldtop);
1306 this->QMainWindow::contextMenuEvent(arg1);
1308 lua_settop(L, oldtop);
1310 void LuaBinder< QMainWindow >::enabledChange (bool arg1) {
1311 bool absorbed = false;
1312 int oldtop = lua_gettop(L);
1313 lqtL_pushudata(L, this, "QMainWindow*");
1314 if (lua_getmetatable(L, -1)) {
1315 lua_getfield(L, -1, "enabledChange");
1316 lua_remove(L, -2);
1317 } else {
1318 lua_pushnil(L);
1320 lua_insert(L, -2);
1321 lua_pushboolean(L, arg1);
1322 if (lua_isfunction(L, -1-2)) {
1323 lua_pcall(L, 1+1, 2, 0);
1324 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
1325 lua_pop(L, 1);
1327 if (!absorbed) {
1328 lua_settop(L, oldtop);
1329 this->QWidget::enabledChange(arg1);
1331 lua_settop(L, oldtop);
1333 void LuaBinder< QMainWindow >::disconnectNotify (const char * arg1) {
1334 bool absorbed = false;
1335 int oldtop = lua_gettop(L);
1336 lqtL_pushudata(L, this, "QMainWindow*");
1337 if (lua_getmetatable(L, -1)) {
1338 lua_getfield(L, -1, "disconnectNotify");
1339 lua_remove(L, -2);
1340 } else {
1341 lua_pushnil(L);
1343 lua_insert(L, -2);
1344 lua_pushstring(L, arg1);
1345 if (lua_isfunction(L, -1-2)) {
1346 lua_pcall(L, 1+1, 2, 0);
1347 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
1348 lua_pop(L, 1);
1350 if (!absorbed) {
1351 lua_settop(L, oldtop);
1352 this->QObject::disconnectNotify(arg1);
1354 lua_settop(L, oldtop);
1356 int LuaBinder< QMainWindow >::heightForWidth (int arg1) const {
1357 bool absorbed = false;
1358 int oldtop = lua_gettop(L);
1359 lqtL_pushudata(L, this, "QMainWindow*");
1360 if (lua_getmetatable(L, -1)) {
1361 lua_getfield(L, -1, "heightForWidth");
1362 lua_remove(L, -2);
1363 } else {
1364 lua_pushnil(L);
1366 lua_insert(L, -2);
1367 lua_pushinteger(L, arg1);
1368 if (lua_isfunction(L, -1-2)) {
1369 lua_pcall(L, 1+1, 2, 0);
1370 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
1371 lua_pop(L, 1);
1373 if (!absorbed) {
1374 lua_settop(L, oldtop);
1375 return this->QWidget::heightForWidth(arg1);
1377 int ret = lua_tointeger(L, -1);
1378 lua_settop(L, oldtop);
1379 return ret;
1381 void LuaBinder< QMainWindow >::fontChange (const QFont& arg1) {
1382 bool absorbed = false;
1383 int oldtop = lua_gettop(L);
1384 lqtL_pushudata(L, this, "QMainWindow*");
1385 if (lua_getmetatable(L, -1)) {
1386 lua_getfield(L, -1, "fontChange");
1387 lua_remove(L, -2);
1388 } else {
1389 lua_pushnil(L);
1391 lua_insert(L, -2);
1392 lqtL_pushudata(L, &(arg1), "QFont*");
1393 if (lua_isfunction(L, -1-2)) {
1394 lua_pcall(L, 1+1, 2, 0);
1395 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
1396 lua_pop(L, 1);
1398 if (!absorbed) {
1399 lua_settop(L, oldtop);
1400 this->QWidget::fontChange(arg1);
1402 lua_settop(L, oldtop);
1404 bool LuaBinder< QMainWindow >::focusNextPrevChild (bool arg1) {
1405 bool absorbed = false;
1406 int oldtop = lua_gettop(L);
1407 lqtL_pushudata(L, this, "QMainWindow*");
1408 if (lua_getmetatable(L, -1)) {
1409 lua_getfield(L, -1, "focusNextPrevChild");
1410 lua_remove(L, -2);
1411 } else {
1412 lua_pushnil(L);
1414 lua_insert(L, -2);
1415 lua_pushboolean(L, arg1);
1416 if (lua_isfunction(L, -1-2)) {
1417 lua_pcall(L, 1+1, 2, 0);
1418 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
1419 lua_pop(L, 1);
1421 if (!absorbed) {
1422 lua_settop(L, oldtop);
1423 return this->QWidget::focusNextPrevChild(arg1);
1425 bool ret = (bool)lua_toboolean(L, -1);
1426 lua_settop(L, oldtop);
1427 return ret;
1429 void LuaBinder< QMainWindow >::timerEvent (QTimerEvent * arg1) {
1430 bool absorbed = false;
1431 int oldtop = lua_gettop(L);
1432 lqtL_pushudata(L, this, "QMainWindow*");
1433 if (lua_getmetatable(L, -1)) {
1434 lua_getfield(L, -1, "timerEvent");
1435 lua_remove(L, -2);
1436 } else {
1437 lua_pushnil(L);
1439 lua_insert(L, -2);
1440 lqtL_pushudata(L, arg1, "QTimerEvent*");
1441 if (lua_isfunction(L, -1-2)) {
1442 lua_pcall(L, 1+1, 2, 0);
1443 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
1444 lua_pop(L, 1);
1446 if (!absorbed) {
1447 lua_settop(L, oldtop);
1448 this->QObject::timerEvent(arg1);
1450 lua_settop(L, oldtop);
1452 void LuaBinder< QMainWindow >::mouseMoveEvent (QMouseEvent * arg1) {
1453 bool absorbed = false;
1454 int oldtop = lua_gettop(L);
1455 lqtL_pushudata(L, this, "QMainWindow*");
1456 if (lua_getmetatable(L, -1)) {
1457 lua_getfield(L, -1, "mouseMoveEvent");
1458 lua_remove(L, -2);
1459 } else {
1460 lua_pushnil(L);
1462 lua_insert(L, -2);
1463 lqtL_pushudata(L, arg1, "QMouseEvent*");
1464 if (lua_isfunction(L, -1-2)) {
1465 lua_pcall(L, 1+1, 2, 0);
1466 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
1467 lua_pop(L, 1);
1469 if (!absorbed) {
1470 lua_settop(L, oldtop);
1471 this->QWidget::mouseMoveEvent(arg1);
1473 lua_settop(L, oldtop);
1475 void LuaBinder< QMainWindow >::focusOutEvent (QFocusEvent * arg1) {
1476 bool absorbed = false;
1477 int oldtop = lua_gettop(L);
1478 lqtL_pushudata(L, this, "QMainWindow*");
1479 if (lua_getmetatable(L, -1)) {
1480 lua_getfield(L, -1, "focusOutEvent");
1481 lua_remove(L, -2);
1482 } else {
1483 lua_pushnil(L);
1485 lua_insert(L, -2);
1486 lqtL_pushudata(L, arg1, "QFocusEvent*");
1487 if (lua_isfunction(L, -1-2)) {
1488 lua_pcall(L, 1+1, 2, 0);
1489 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
1490 lua_pop(L, 1);
1492 if (!absorbed) {
1493 lua_settop(L, oldtop);
1494 this->QWidget::focusOutEvent(arg1);
1496 lua_settop(L, oldtop);
1498 void LuaBinder< QMainWindow >::childEvent (QChildEvent * arg1) {
1499 bool absorbed = false;
1500 int oldtop = lua_gettop(L);
1501 lqtL_pushudata(L, this, "QMainWindow*");
1502 if (lua_getmetatable(L, -1)) {
1503 lua_getfield(L, -1, "childEvent");
1504 lua_remove(L, -2);
1505 } else {
1506 lua_pushnil(L);
1508 lua_insert(L, -2);
1509 lqtL_pushudata(L, arg1, "QChildEvent*");
1510 if (lua_isfunction(L, -1-2)) {
1511 lua_pcall(L, 1+1, 2, 0);
1512 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
1513 lua_pop(L, 1);
1515 if (!absorbed) {
1516 lua_settop(L, oldtop);
1517 this->QObject::childEvent(arg1);
1519 lua_settop(L, oldtop);
1521 void LuaBinder< QMainWindow >::connectNotify (const char * arg1) {
1522 bool absorbed = false;
1523 int oldtop = lua_gettop(L);
1524 lqtL_pushudata(L, this, "QMainWindow*");
1525 if (lua_getmetatable(L, -1)) {
1526 lua_getfield(L, -1, "connectNotify");
1527 lua_remove(L, -2);
1528 } else {
1529 lua_pushnil(L);
1531 lua_insert(L, -2);
1532 lua_pushstring(L, arg1);
1533 if (lua_isfunction(L, -1-2)) {
1534 lua_pcall(L, 1+1, 2, 0);
1535 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
1536 lua_pop(L, 1);
1538 if (!absorbed) {
1539 lua_settop(L, oldtop);
1540 this->QObject::connectNotify(arg1);
1542 lua_settop(L, oldtop);
1544 void LuaBinder< QMainWindow >::mouseReleaseEvent (QMouseEvent * arg1) {
1545 bool absorbed = false;
1546 int oldtop = lua_gettop(L);
1547 lqtL_pushudata(L, this, "QMainWindow*");
1548 if (lua_getmetatable(L, -1)) {
1549 lua_getfield(L, -1, "mouseReleaseEvent");
1550 lua_remove(L, -2);
1551 } else {
1552 lua_pushnil(L);
1554 lua_insert(L, -2);
1555 lqtL_pushudata(L, arg1, "QMouseEvent*");
1556 if (lua_isfunction(L, -1-2)) {
1557 lua_pcall(L, 1+1, 2, 0);
1558 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
1559 lua_pop(L, 1);
1561 if (!absorbed) {
1562 lua_settop(L, oldtop);
1563 this->QWidget::mouseReleaseEvent(arg1);
1565 lua_settop(L, oldtop);
1567 int LuaBinder< QMainWindow >::metric (QPaintDevice::PaintDeviceMetric arg1) const {
1568 bool absorbed = false;
1569 int oldtop = lua_gettop(L);
1570 lqtL_pushudata(L, this, "QMainWindow*");
1571 if (lua_getmetatable(L, -1)) {
1572 lua_getfield(L, -1, "metric");
1573 lua_remove(L, -2);
1574 } else {
1575 lua_pushnil(L);
1577 lua_insert(L, -2);
1578 lqtL_pushenum(L, arg1, "QPaintDevice::PaintDeviceMetric");
1579 if (lua_isfunction(L, -1-2)) {
1580 lua_pcall(L, 1+1, 2, 0);
1581 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
1582 lua_pop(L, 1);
1584 if (!absorbed) {
1585 lua_settop(L, oldtop);
1586 return this->QWidget::metric(arg1);
1588 int ret = lua_tointeger(L, -1);
1589 lua_settop(L, oldtop);
1590 return ret;
1592 bool LuaBinder< QMainWindow >::eventFilter (QObject * arg1, QEvent * arg2) {
1593 bool absorbed = false;
1594 int oldtop = lua_gettop(L);
1595 lqtL_pushudata(L, this, "QMainWindow*");
1596 if (lua_getmetatable(L, -1)) {
1597 lua_getfield(L, -1, "eventFilter");
1598 lua_remove(L, -2);
1599 } else {
1600 lua_pushnil(L);
1602 lua_insert(L, -2);
1603 lqtL_pushudata(L, arg1, "QObject*");
1604 lqtL_pushudata(L, arg2, "QEvent*");
1605 if (lua_isfunction(L, -2-2)) {
1606 lua_pcall(L, 2+1, 2, 0);
1607 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
1608 lua_pop(L, 1);
1610 if (!absorbed) {
1611 lua_settop(L, oldtop);
1612 return this->QObject::eventFilter(arg1, arg2);
1614 bool ret = (bool)lua_toboolean(L, -1);
1615 lua_settop(L, oldtop);
1616 return ret;
1618 void LuaBinder< QMainWindow >::inputMethodEvent (QInputMethodEvent * arg1) {
1619 bool absorbed = false;
1620 int oldtop = lua_gettop(L);
1621 lqtL_pushudata(L, this, "QMainWindow*");
1622 if (lua_getmetatable(L, -1)) {
1623 lua_getfield(L, -1, "inputMethodEvent");
1624 lua_remove(L, -2);
1625 } else {
1626 lua_pushnil(L);
1628 lua_insert(L, -2);
1629 lqtL_pushudata(L, arg1, "QInputMethodEvent*");
1630 if (lua_isfunction(L, -1-2)) {
1631 lua_pcall(L, 1+1, 2, 0);
1632 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
1633 lua_pop(L, 1);
1635 if (!absorbed) {
1636 lua_settop(L, oldtop);
1637 this->QWidget::inputMethodEvent(arg1);
1639 lua_settop(L, oldtop);
1641 void LuaBinder< QMainWindow >::wheelEvent (QWheelEvent * arg1) {
1642 bool absorbed = false;
1643 int oldtop = lua_gettop(L);
1644 lqtL_pushudata(L, this, "QMainWindow*");
1645 if (lua_getmetatable(L, -1)) {
1646 lua_getfield(L, -1, "wheelEvent");
1647 lua_remove(L, -2);
1648 } else {
1649 lua_pushnil(L);
1651 lua_insert(L, -2);
1652 lqtL_pushudata(L, arg1, "QWheelEvent*");
1653 if (lua_isfunction(L, -1-2)) {
1654 lua_pcall(L, 1+1, 2, 0);
1655 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
1656 lua_pop(L, 1);
1658 if (!absorbed) {
1659 lua_settop(L, oldtop);
1660 this->QWidget::wheelEvent(arg1);
1662 lua_settop(L, oldtop);
1664 void LuaBinder< QMainWindow >::resizeEvent (QResizeEvent * arg1) {
1665 bool absorbed = false;
1666 int oldtop = lua_gettop(L);
1667 lqtL_pushudata(L, this, "QMainWindow*");
1668 if (lua_getmetatable(L, -1)) {
1669 lua_getfield(L, -1, "resizeEvent");
1670 lua_remove(L, -2);
1671 } else {
1672 lua_pushnil(L);
1674 lua_insert(L, -2);
1675 lqtL_pushudata(L, arg1, "QResizeEvent*");
1676 if (lua_isfunction(L, -1-2)) {
1677 lua_pcall(L, 1+1, 2, 0);
1678 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
1679 lua_pop(L, 1);
1681 if (!absorbed) {
1682 lua_settop(L, oldtop);
1683 this->QWidget::resizeEvent(arg1);
1685 lua_settop(L, oldtop);
1687 void LuaBinder< QMainWindow >::paletteChange (const QPalette& arg1) {
1688 bool absorbed = false;
1689 int oldtop = lua_gettop(L);
1690 lqtL_pushudata(L, this, "QMainWindow*");
1691 if (lua_getmetatable(L, -1)) {
1692 lua_getfield(L, -1, "paletteChange");
1693 lua_remove(L, -2);
1694 } else {
1695 lua_pushnil(L);
1697 lua_insert(L, -2);
1698 lqtL_pushudata(L, &(arg1), "QPalette*");
1699 if (lua_isfunction(L, -1-2)) {
1700 lua_pcall(L, 1+1, 2, 0);
1701 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
1702 lua_pop(L, 1);
1704 if (!absorbed) {
1705 lua_settop(L, oldtop);
1706 this->QWidget::paletteChange(arg1);
1708 lua_settop(L, oldtop);
1710 void LuaBinder< QMainWindow >::languageChange () {
1711 bool absorbed = false;
1712 int oldtop = lua_gettop(L);
1713 lqtL_pushudata(L, this, "QMainWindow*");
1714 if (lua_getmetatable(L, -1)) {
1715 lua_getfield(L, -1, "languageChange");
1716 lua_remove(L, -2);
1717 } else {
1718 lua_pushnil(L);
1720 lua_insert(L, -2);
1721 if (lua_isfunction(L, -0-2)) {
1722 lua_pcall(L, 0+1, 2, 0);
1723 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
1724 lua_pop(L, 1);
1726 if (!absorbed) {
1727 lua_settop(L, oldtop);
1728 this->QWidget::languageChange();
1730 lua_settop(L, oldtop);
1732 bool LuaBinder< QMainWindow >::event (QEvent * arg1) {
1733 bool absorbed = false;
1734 int oldtop = lua_gettop(L);
1735 lqtL_pushudata(L, this, "QMainWindow*");
1736 if (lua_getmetatable(L, -1)) {
1737 lua_getfield(L, -1, "event");
1738 lua_remove(L, -2);
1739 } else {
1740 lua_pushnil(L);
1742 lua_insert(L, -2);
1743 lqtL_pushudata(L, arg1, "QEvent*");
1744 if (lua_isfunction(L, -1-2)) {
1745 lua_pcall(L, 1+1, 2, 0);
1746 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
1747 lua_pop(L, 1);
1749 if (!absorbed) {
1750 lua_settop(L, oldtop);
1751 return this->QMainWindow::event(arg1);
1753 bool ret = (bool)lua_toboolean(L, -1);
1754 lua_settop(L, oldtop);
1755 return ret;
1757 void LuaBinder< QMainWindow >::hideEvent (QHideEvent * arg1) {
1758 bool absorbed = false;
1759 int oldtop = lua_gettop(L);
1760 lqtL_pushudata(L, this, "QMainWindow*");
1761 if (lua_getmetatable(L, -1)) {
1762 lua_getfield(L, -1, "hideEvent");
1763 lua_remove(L, -2);
1764 } else {
1765 lua_pushnil(L);
1767 lua_insert(L, -2);
1768 lqtL_pushudata(L, arg1, "QHideEvent*");
1769 if (lua_isfunction(L, -1-2)) {
1770 lua_pcall(L, 1+1, 2, 0);
1771 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
1772 lua_pop(L, 1);
1774 if (!absorbed) {
1775 lua_settop(L, oldtop);
1776 this->QWidget::hideEvent(arg1);
1778 lua_settop(L, oldtop);
1780 void LuaBinder< QMainWindow >::mouseDoubleClickEvent (QMouseEvent * arg1) {
1781 bool absorbed = false;
1782 int oldtop = lua_gettop(L);
1783 lqtL_pushudata(L, this, "QMainWindow*");
1784 if (lua_getmetatable(L, -1)) {
1785 lua_getfield(L, -1, "mouseDoubleClickEvent");
1786 lua_remove(L, -2);
1787 } else {
1788 lua_pushnil(L);
1790 lua_insert(L, -2);
1791 lqtL_pushudata(L, arg1, "QMouseEvent*");
1792 if (lua_isfunction(L, -1-2)) {
1793 lua_pcall(L, 1+1, 2, 0);
1794 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
1795 lua_pop(L, 1);
1797 if (!absorbed) {
1798 lua_settop(L, oldtop);
1799 this->QWidget::mouseDoubleClickEvent(arg1);
1801 lua_settop(L, oldtop);
1803 void LuaBinder< QMainWindow >::keyReleaseEvent (QKeyEvent * arg1) {
1804 bool absorbed = false;
1805 int oldtop = lua_gettop(L);
1806 lqtL_pushudata(L, this, "QMainWindow*");
1807 if (lua_getmetatable(L, -1)) {
1808 lua_getfield(L, -1, "keyReleaseEvent");
1809 lua_remove(L, -2);
1810 } else {
1811 lua_pushnil(L);
1813 lua_insert(L, -2);
1814 lqtL_pushudata(L, arg1, "QKeyEvent*");
1815 if (lua_isfunction(L, -1-2)) {
1816 lua_pcall(L, 1+1, 2, 0);
1817 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
1818 lua_pop(L, 1);
1820 if (!absorbed) {
1821 lua_settop(L, oldtop);
1822 this->QWidget::keyReleaseEvent(arg1);
1824 lua_settop(L, oldtop);
1826 void LuaBinder< QMainWindow >::windowActivationChange (bool arg1) {
1827 bool absorbed = false;
1828 int oldtop = lua_gettop(L);
1829 lqtL_pushudata(L, this, "QMainWindow*");
1830 if (lua_getmetatable(L, -1)) {
1831 lua_getfield(L, -1, "windowActivationChange");
1832 lua_remove(L, -2);
1833 } else {
1834 lua_pushnil(L);
1836 lua_insert(L, -2);
1837 lua_pushboolean(L, arg1);
1838 if (lua_isfunction(L, -1-2)) {
1839 lua_pcall(L, 1+1, 2, 0);
1840 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
1841 lua_pop(L, 1);
1843 if (!absorbed) {
1844 lua_settop(L, oldtop);
1845 this->QWidget::windowActivationChange(arg1);
1847 lua_settop(L, oldtop);
1849 void LuaBinder< QMainWindow >::leaveEvent (QEvent * arg1) {
1850 bool absorbed = false;
1851 int oldtop = lua_gettop(L);
1852 lqtL_pushudata(L, this, "QMainWindow*");
1853 if (lua_getmetatable(L, -1)) {
1854 lua_getfield(L, -1, "leaveEvent");
1855 lua_remove(L, -2);
1856 } else {
1857 lua_pushnil(L);
1859 lua_insert(L, -2);
1860 lqtL_pushudata(L, arg1, "QEvent*");
1861 if (lua_isfunction(L, -1-2)) {
1862 lua_pcall(L, 1+1, 2, 0);
1863 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
1864 lua_pop(L, 1);
1866 if (!absorbed) {
1867 lua_settop(L, oldtop);
1868 this->QWidget::leaveEvent(arg1);
1870 lua_settop(L, oldtop);
1872 void LuaBinder< QMainWindow >::changeEvent (QEvent * arg1) {
1873 bool absorbed = false;
1874 int oldtop = lua_gettop(L);
1875 lqtL_pushudata(L, this, "QMainWindow*");
1876 if (lua_getmetatable(L, -1)) {
1877 lua_getfield(L, -1, "changeEvent");
1878 lua_remove(L, -2);
1879 } else {
1880 lua_pushnil(L);
1882 lua_insert(L, -2);
1883 lqtL_pushudata(L, arg1, "QEvent*");
1884 if (lua_isfunction(L, -1-2)) {
1885 lua_pcall(L, 1+1, 2, 0);
1886 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
1887 lua_pop(L, 1);
1889 if (!absorbed) {
1890 lua_settop(L, oldtop);
1891 this->QWidget::changeEvent(arg1);
1893 lua_settop(L, oldtop);
1895 void LuaBinder< QMainWindow >::customEvent (QEvent * arg1) {
1896 bool absorbed = false;
1897 int oldtop = lua_gettop(L);
1898 lqtL_pushudata(L, this, "QMainWindow*");
1899 if (lua_getmetatable(L, -1)) {
1900 lua_getfield(L, -1, "customEvent");
1901 lua_remove(L, -2);
1902 } else {
1903 lua_pushnil(L);
1905 lua_insert(L, -2);
1906 lqtL_pushudata(L, arg1, "QEvent*");
1907 if (lua_isfunction(L, -1-2)) {
1908 lua_pcall(L, 1+1, 2, 0);
1909 absorbed = (bool)lua_toboolean(L, -1) || (bool)lua_toboolean(L, -2);
1910 lua_pop(L, 1);
1912 if (!absorbed) {
1913 lua_settop(L, oldtop);
1914 this->QObject::customEvent(arg1);
1916 lua_settop(L, oldtop);
1918 LuaBinder< QMainWindow >:: ~LuaBinder< QMainWindow > () {
1919 int oldtop = lua_gettop(L);
1920 lqtL_pushudata(L, this, "QMainWindow*");
1921 lua_getfield(L, -1, "~QMainWindow");
1923 if (lua_isfunction(L, -1)) {
1924 lua_insert(L, -2);
1925 lua_pcall(L, 1, 1, 0);
1926 } else {
1928 lua_settop(L, oldtop);
1930 int LuaBinder< QMainWindow >::lqt_pushenum_DockOption (lua_State *L) {
1931 int enum_table = 0;
1932 lua_getfield(L, LUA_REGISTRYINDEX, LQT_ENUMS);
1933 if (!lua_istable(L, -1)) {
1934 lua_pop(L, 1);
1935 lua_newtable(L);
1936 lua_pushvalue(L, -1);
1937 lua_setfield(L, LUA_REGISTRYINDEX, LQT_ENUMS);
1939 lua_newtable(L);
1940 enum_table = lua_gettop(L);
1941 lua_pushstring(L, "AnimatedDocks");
1942 lua_rawseti(L, enum_table, 1);
1943 lua_pushinteger(L, 1);
1944 lua_setfield(L, enum_table, "AnimatedDocks");
1945 lua_pushstring(L, "AllowNestedDocks");
1946 lua_rawseti(L, enum_table, 2);
1947 lua_pushinteger(L, 2);
1948 lua_setfield(L, enum_table, "AllowNestedDocks");
1949 lua_pushstring(L, "AllowTabbedDocks");
1950 lua_rawseti(L, enum_table, 4);
1951 lua_pushinteger(L, 4);
1952 lua_setfield(L, enum_table, "AllowTabbedDocks");
1953 lua_pushstring(L, "ForceTabbedDocks");
1954 lua_rawseti(L, enum_table, 8);
1955 lua_pushinteger(L, 8);
1956 lua_setfield(L, enum_table, "ForceTabbedDocks");
1957 lua_pushstring(L, "VerticalTabs");
1958 lua_rawseti(L, enum_table, 16);
1959 lua_pushinteger(L, 16);
1960 lua_setfield(L, enum_table, "VerticalTabs");
1961 lua_pushcfunction(L, LuaBinder< QMainWindow >::lqt_pushenum_DockOption_QFLAGS_CREATOR);
1962 lua_setfield(L, enum_table, "QFlags");
1963 lua_pushvalue(L, -1);
1964 lua_setfield(L, -3, "QMainWindow::DockOption");
1965 lua_remove(L, -2);
1966 return 1;
1968 int LuaBinder< QMainWindow >::lqt_pushenum_DockOption_QFLAGS_CREATOR (lua_State *L) {
1969 int argn = lua_gettop(L);
1970 int i = 0;
1971 void *p = lua_newuserdata(L, sizeof(QFlags<QMainWindow::DockOption>*) + sizeof(QFlags<QMainWindow::DockOption>));
1972 QFlags<QMainWindow::DockOption> *fl = static_cast<QFlags<QMainWindow::DockOption>*>( static_cast<void*>(&static_cast<QFlags<QMainWindow::DockOption>**>(p)[1]) );
1973 *(void**)p = fl;
1974 for (i=1;i<=argn;i++) {
1975 *fl |= static_cast<QMainWindow::DockOption>(lqtL_toenum(L, i, "QMainWindow::DockOption"));
1977 if (luaL_newmetatable(L, "QFlags<QMainWindow::DockOption>*")) {
1978 lua_pushstring(L, "QFlags<QMainWindow::DockOption>*");
1979 lua_setfield(L, -2, "__qtype");
1981 lua_setmetatable(L, -2);
1982 return 1;
1984 int luaopen_QMainWindow (lua_State *L) {
1985 if (luaL_newmetatable(L, "QMainWindow*")) {
1986 lua_pushcfunction(L, LuaBinder< QMainWindow >::__LuaWrapCall__splitDockWidget);
1987 lua_setfield(L, -2, "splitDockWidget");
1988 lua_pushcfunction(L, LuaBinder< QMainWindow >::__LuaWrapCall__toolBarBreak);
1989 lua_setfield(L, -2, "toolBarBreak");
1990 lua_pushcfunction(L, LuaBinder< QMainWindow >::__LuaWrapCall__saveState);
1991 lua_setfield(L, -2, "saveState");
1992 lua_pushcfunction(L, LuaBinder< QMainWindow >::__LuaWrapCall__addToolBarBreak);
1993 lua_setfield(L, -2, "addToolBarBreak");
1994 lua_pushcfunction(L, LuaBinder< QMainWindow >::__LuaWrapCall__createPopupMenu);
1995 lua_setfield(L, -2, "createPopupMenu");
1996 lua_pushcfunction(L, LuaBinder< QMainWindow >::__LuaWrapCall__insertToolBar);
1997 lua_setfield(L, -2, "insertToolBar");
1998 lua_pushcfunction(L, LuaBinder< QMainWindow >::__LuaWrapCall__removeToolBarBreak);
1999 lua_setfield(L, -2, "removeToolBarBreak");
2000 lua_pushcfunction(L, LuaBinder< QMainWindow >::__LuaWrapCall__setAnimated);
2001 lua_setfield(L, -2, "setAnimated");
2002 lua_pushcfunction(L, LuaBinder< QMainWindow >::__LuaWrapCall__trUtf8);
2003 lua_setfield(L, -2, "trUtf8");
2004 lua_pushcfunction(L, LuaBinder< QMainWindow >::__LuaWrapCall__setUnifiedTitleAndToolBarOnMac);
2005 lua_setfield(L, -2, "setUnifiedTitleAndToolBarOnMac");
2006 lua_pushcfunction(L, LuaBinder< QMainWindow >::__LuaWrapCall__tr);
2007 lua_setfield(L, -2, "tr");
2008 lua_pushcfunction(L, LuaBinder< QMainWindow >::__LuaWrapCall__menuWidget);
2009 lua_setfield(L, -2, "menuWidget");
2010 lua_pushcfunction(L, LuaBinder< QMainWindow >::__LuaWrapCall__removeDockWidget);
2011 lua_setfield(L, -2, "removeDockWidget");
2012 lua_pushcfunction(L, LuaBinder< QMainWindow >::__LuaWrapCall__setCentralWidget);
2013 lua_setfield(L, -2, "setCentralWidget");
2014 lua_pushcfunction(L, LuaBinder< QMainWindow >::__LuaWrapCall__setDockOptions);
2015 lua_setfield(L, -2, "setDockOptions");
2016 lua_pushcfunction(L, LuaBinder< QMainWindow >::__LuaWrapCall__setStatusBar);
2017 lua_setfield(L, -2, "setStatusBar");
2018 lua_pushcfunction(L, LuaBinder< QMainWindow >::__LuaWrapCall__insertToolBarBreak);
2019 lua_setfield(L, -2, "insertToolBarBreak");
2020 lua_pushcfunction(L, LuaBinder< QMainWindow >::__LuaWrapCall__setMenuWidget);
2021 lua_setfield(L, -2, "setMenuWidget");
2022 lua_pushcfunction(L, LuaBinder< QMainWindow >::__LuaWrapCall__setMenuBar);
2023 lua_setfield(L, -2, "setMenuBar");
2024 lua_pushcfunction(L, LuaBinder< QMainWindow >::__LuaWrapCall__isAnimated);
2025 lua_setfield(L, -2, "isAnimated");
2026 lua_pushcfunction(L, LuaBinder< QMainWindow >::__LuaWrapCall__statusBar);
2027 lua_setfield(L, -2, "statusBar");
2028 lua_pushcfunction(L, LuaBinder< QMainWindow >::__LuaWrapCall__menuBar);
2029 lua_setfield(L, -2, "menuBar");
2030 lua_pushcfunction(L, LuaBinder< QMainWindow >::__LuaWrapCall__setDockNestingEnabled);
2031 lua_setfield(L, -2, "setDockNestingEnabled");
2032 lua_pushcfunction(L, LuaBinder< QMainWindow >::__LuaWrapCall__setIconSize);
2033 lua_setfield(L, -2, "setIconSize");
2034 lua_pushcfunction(L, LuaBinder< QMainWindow >::__LuaWrapCall__iconSize);
2035 lua_setfield(L, -2, "iconSize");
2036 lua_pushcfunction(L, LuaBinder< QMainWindow >::__LuaWrapCall__dockWidgetArea);
2037 lua_setfield(L, -2, "dockWidgetArea");
2038 lua_pushcfunction(L, LuaBinder< QMainWindow >::__LuaWrapCall__metaObject);
2039 lua_setfield(L, -2, "metaObject");
2040 lua_pushcfunction(L, LuaBinder< QMainWindow >::__LuaWrapCall__new);
2041 lua_setfield(L, -2, "new");
2042 lua_pushcfunction(L, LuaBinder< QMainWindow >::__LuaWrapCall__unifiedTitleAndToolBarOnMac);
2043 lua_setfield(L, -2, "unifiedTitleAndToolBarOnMac");
2044 lua_pushcfunction(L, LuaBinder< QMainWindow >::__LuaWrapCall__delete);
2045 lua_setfield(L, -2, "delete");
2046 lua_pushcfunction(L, LuaBinder< QMainWindow >::__LuaWrapCall__setCorner);
2047 lua_setfield(L, -2, "setCorner");
2048 lua_pushcfunction(L, LuaBinder< QMainWindow >::__LuaWrapCall__corner);
2049 lua_setfield(L, -2, "corner");
2050 lua_pushcfunction(L, LuaBinder< QMainWindow >::__LuaWrapCall__addToolBar);
2051 lua_setfield(L, -2, "addToolBar");
2052 lua_pushcfunction(L, LuaBinder< QMainWindow >::__LuaWrapCall__removeToolBar);
2053 lua_setfield(L, -2, "removeToolBar");
2054 lua_pushcfunction(L, LuaBinder< QMainWindow >::__LuaWrapCall__dockOptions);
2055 lua_setfield(L, -2, "dockOptions");
2056 lua_pushcfunction(L, LuaBinder< QMainWindow >::__LuaWrapCall__restoreState);
2057 lua_setfield(L, -2, "restoreState");
2058 lua_pushcfunction(L, LuaBinder< QMainWindow >::__LuaWrapCall__toolButtonStyle);
2059 lua_setfield(L, -2, "toolButtonStyle");
2060 lua_pushcfunction(L, LuaBinder< QMainWindow >::__LuaWrapCall__tabifyDockWidget);
2061 lua_setfield(L, -2, "tabifyDockWidget");
2062 lua_pushcfunction(L, LuaBinder< QMainWindow >::__LuaWrapCall__isDockNestingEnabled);
2063 lua_setfield(L, -2, "isDockNestingEnabled");
2064 lua_pushcfunction(L, LuaBinder< QMainWindow >::__LuaWrapCall__isSeparator);
2065 lua_setfield(L, -2, "isSeparator");
2066 lua_pushcfunction(L, LuaBinder< QMainWindow >::__LuaWrapCall__addDockWidget);
2067 lua_setfield(L, -2, "addDockWidget");
2068 lua_pushcfunction(L, LuaBinder< QMainWindow >::__LuaWrapCall__setToolButtonStyle);
2069 lua_setfield(L, -2, "setToolButtonStyle");
2070 lua_pushcfunction(L, LuaBinder< QMainWindow >::__LuaWrapCall__toolBarArea);
2071 lua_setfield(L, -2, "toolBarArea");
2072 lua_pushcfunction(L, LuaBinder< QMainWindow >::__LuaWrapCall__centralWidget);
2073 lua_setfield(L, -2, "centralWidget");
2074 LuaBinder< QMainWindow >::lqt_pushenum_DockOption(L);
2075 lua_setfield(L, -2, "DockOption");
2076 lua_newtable(L);
2077 lua_pushboolean(L, 1);
2078 lua_setfield(L, -2, "QWidget*");
2079 lua_pushboolean(L, 0);
2080 lua_setfield(L, -2, "QObject*");
2081 lua_pushboolean(L, 0);
2082 lua_setfield(L, -2, "QPaintDevice*");
2083 lua_setfield(L, -2, "__base");
2084 lua_pushcfunction(L, lqtL_newindex);
2085 lua_setfield(L, -2, "__newindex");
2086 lua_pushcfunction(L, lqtL_index);
2087 lua_setfield(L, -2, "__index");
2088 lua_pushcfunction(L, lqtL_gc);
2089 lua_setfield(L, -2, "__gc");
2090 lua_pushstring(L, "QMainWindow");
2091 lua_setfield(L, -2, "__qtype");
2092 lua_setglobal(L, "QMainWindow");
2093 } else {
2094 lua_pop(L, 1);
2096 return 0;