IMPL_LUA_FUNC(LuaWindowExport, IsValid) { try { CLuaWindow* self; self = static_cast<CLuaWindow*>(LuaStatic::CheckUserData(l, 1)); lua_op_t<bool>::push_stack(l, self->IsValid() ? true : false); return 1; } catch (...) { DuiException(_T("LuaWindowExport::IsValid")); return 0; } }
IMPL_LUA_FUNC(LuaWindowExport, GetPaintMgr) { try { CLuaWindow* self; self = static_cast<CLuaWindow*>(LuaStatic::CheckUserData(l, 1)); LuaStatic::AddObject2Lua(l, self->PaintMgr(), METATABLE_NAME(self->PaintMgr())); return 1; } catch(...) { DuiException(_T("LuaWindowExport::GetPaintMgr")); return 0; } }
IMPL_LUA_FUNC(LuaWindowExport, GetClassStyle) { try { CLuaWindow* self; self = static_cast<CLuaWindow*>(LuaStatic::CheckUserData(l, 1)); lua_pushnumber(l,self->GetClassStyle()); return 1; } catch(...) { DuiException(_T("LuaWindowExport::GetClassStyle")); return 0; } }
IMPL_LUA_FUNC(LuaCDialogBuilder, Create2) { try { CDialogBuilder* self; self = static_cast<CDialogBuilder*>(LuaStatic::CheckUserData(l, 1)); return 1; } catch (...) { DuiException(_T("LuaCDialogBuilder::Create2")); return 0; } }
IMPL_LUA_FUNC(LuaCDialogBuilder, GetLastErrorLocation) { try { CDialogBuilder* self; self = static_cast<CDialogBuilder*>(LuaStatic::CheckUserData(l, 1)); return 0; } catch (...) { DuiException(_T("LuaCDialogBuilder::GetLastErrorLocation")); return 0; } }
IMPL_LUA_FUNC(LuaWindowExport, IsWindowVisible) { try { CLuaWindow* self; self = static_cast<CLuaWindow*>(LuaStatic::CheckUserData(l, 1)); lua_pushboolean(l,self->IsWindowVisible() ? 1 : 0); return 1; } catch(...) { DuiException(_T("LuaWindowExport::IsWindowVisible")); return 0; } }
IMPL_LUA_FUNC(LuaWindowExport, AddNotifier) { try { CLuaWindow* self; self = static_cast<CLuaWindow*>(LuaStatic::CheckUserData(l, 1)); self->PaintMgr()->AddNotifier(self); return 0; } catch (...) { DuiException(_T("LuaWindowExport::AddNotifier")); return 0; } }
IMPL_LUA_FUNC(LuaWindowExport, BringWindowToTop) { try { CLuaWindow* self; self = static_cast<CLuaWindow*>(LuaStatic::CheckUserData(l, 1)); lua_pushboolean(l,self->BringWindowToTop() ? 1 : 0); return 1; } catch(...) { DuiException(_T("LuaWindowExport::BringWindowToTop")); return 0; } }
IMPL_LUA_FUNC(LuaWindowExport, ForegroundWindow) { try { CLuaWindow* self; self = static_cast<CLuaWindow*>(LuaStatic::CheckUserData(l, 1)); lua_pushboolean(l,self->ForegroundWindow() ? 1 : 0); return 1; } catch(...) { DuiException(_T("LuaWindowExport::ForegroundWindow")); return 0; } }
IMPL_LUA_FUNC(LuaWindowExport, ArrangeIconicWindows) { try { CLuaWindow* self; self = static_cast<CLuaWindow*>(LuaStatic::CheckUserData(l, 1)); lua_pushnumber(l,self->ArrangeIconicWindows()); return 1; } catch(...) { DuiException(_T("LuaWindowExport::ArrangeIconicWindows")); return 0; } }
IMPL_LUA_FUNC(LuaCNotifyPump, LoopDispatch) { try { CNotifyPump* self; self = static_cast<CNotifyPump*>(LuaStatic::CheckUserData(l, 1)); TNotifyUI* pMsg = static_cast<TNotifyUI*>(LuaStatic::CheckUserData(l, 2)); lua_pushboolean(l, self->LoopDispatch(*pMsg) ? 1 : 0); return 1; } catch(...) { DuiException(_T("LuaCNotifyPump::LoopDispatch")); return 0; } }
IMPL_LUA_FUNC(LuaCWindowWnd, SetIcon) { try { CWindowWnd* self; self = static_cast<CWindowWnd*>(LuaStatic::CheckUserData(l, 1)); UINT nRes = (UINT)lua_tonumber(l,2); self->SetIcon(nRes); return 0; } catch(...) { DuiException(_T("LuaCWindowWnd::SetIcon")); return 0; } }
IMPL_LUA_FUNC(LuaCNotifyPump, NotifyPump) { try { CNotifyPump* self; self = static_cast<CNotifyPump*>(LuaStatic::CheckUserData(l, 1)); TNotifyUI* pMsg = static_cast<TNotifyUI*>(LuaStatic::CheckUserData(l, 2)); self->NotifyPump(*pMsg); return 0; } catch(...) { DuiException(_T("LuaCNotifyPump::NotifyPump")); return 0; } }
LUA_METHOD_IMPL(CDateTimeUI,SetReadOnly) { try { CDateTimeUI* self; self = static_cast<CDateTimeUI*>(LuaStatic::CheckUserData(l, 1)); bool bReadOnly = lua_toboolean(l,2) != 0; self->SetReadOnly(bReadOnly); return 0; } catch (...) { DuiException(_T("LuaCDateTimeUI::SetReadOnly")); return 0; } }
IMPL_LUA_FUNC(LuaWindowExport, MoveWindowToPoint) { try { CLuaWindow* self; self = static_cast<CLuaWindow*>(LuaStatic::CheckUserData(l, 1)); POINT pt = LuaStatic::ReadPointFromLua(l,2); lua_pushboolean(l,self->MoveWindowToPoint(&pt) ? 1 : 0); return 1; } catch(...) { DuiException(_T("LuaWindowExport::MoveWindowToPoint")); return 0; } }
IMPL_LUA_FUNC(LuaCTreeViewUI, SetItemMinWidth) { try { CTreeViewUI* self; self = static_cast<CTreeViewUI*>(LuaStatic::CheckUserData(l, 1)); int nVal = lua_tointeger(l,2); self->SetItemMinWidth(nVal); return 0; } catch (...) { DuiException(_T("LuaCTreeViewUI::SetItemMinWidth")); return 0; } }
IMPL_LUA_FUNC(LuaWindowExport, ValidateRgn) { try { CLuaWindow* self; self = static_cast<CLuaWindow*>(LuaStatic::CheckUserData(l, 1)); HRGN hRgn = static_cast<HRGN>(LuaStatic::CheckUserData(l, 2)); self->ValidateRgn(hRgn); return 0; } catch(...) { DuiException(_T("LuaWindowExport::ValidateRgn")); return 0; } }
IMPL_LUA_FUNC(LuaWindowExport, ValidateRect) { try { CLuaWindow* self; self = static_cast<CLuaWindow*>(LuaStatic::CheckUserData(l, 1)); RECT rc = LuaStatic::ReadRectFromLua(l,2); self->ValidateRect(&rc); return 0; } catch(...) { DuiException(_T("LuaWindowExport::ValidateRect")); return 0; } }
IMPL_LUA_FUNC(LuaWindowExport, UpdateWindow) { try { CLuaWindow* self; self = static_cast<CLuaWindow*>(LuaStatic::CheckUserData(l, 1)); BOOL bRet = self->UpdateWindow(); lua_pushboolean(l,bRet ? 1 : 0); return 1; } catch(...) { DuiException(_T("LuaWindowExport::UpdateWindow")); return 0; } }
IMPL_LUA_FUNC(LuaWindowExport, GetWindowClassName) { try { CLuaWindow* self; self = static_cast<CLuaWindow*>(LuaStatic::CheckUserData(l, 1)); CDuiString pstrText = self->GetWindowClassName(); lua_op_t<CDuiString>::push_stack(l, pstrText); return 1; } catch(...) { DuiException(_T("LuaWindowExport::GetWindowClassName")); return 0; } }
LUA_METHOD_IMPL(CWebBrowserUI, Refresh2) { try { CWebBrowserUI* self; self = static_cast<CWebBrowserUI*>(LuaStatic::CheckUserData(l, 1)); int nLevel = lua_tointeger(l,2); self->Refresh2(nLevel); return 0; } catch (...) { DuiException(_T("LuaCWebBrowserUI::Refresh2")); return 0; } }
LUA_METHOD_IMPL(CLabelUI, GetFont) { try { CLabelUI* self; self = static_cast<CLabelUI*>(LuaStatic::CheckUserData(l, 1)); int iFont = self->GetFont(); lua_pushinteger(l, (lua_Integer)iFont); return 1; } catch (...) { DuiException(_T("LuaCLabelUI::GetFont")); return 0; } }
IMPL_LUA_FUNC(LuaCTreeNodeUI, GetTreeLevel) { try { CTreeNodeUI* self; self = static_cast<CTreeNodeUI*>(LuaStatic::CheckUserData(l, 1)); long nLevel = self->GetTreeLevel(); lua_pushnumber(l, (lua_Number)nLevel); return 1; } catch (...) { DuiException(_T("LuaCTreeNodeUI::GetTreeLevel")); return 0; } }
LUA_METHOD_IMPL(CLabelUI, GetGradientAngle) { try { CLabelUI* self; self = static_cast<CLabelUI*>(LuaStatic::CheckUserData(l, 1)); int _SetGradientAngle = self->GetGradientAngle(); lua_pushinteger(l, (lua_Integer)_SetGradientAngle); return 1; } catch (...) { DuiException(_T("LuaCLabelUI::GetGradientAngle")); return 0; } }
IMPL_LUA_FUNC(LuaCTreeViewUI, SetSelItemHotTextColor) { try { CTreeViewUI* self; self = static_cast<CTreeViewUI*>(LuaStatic::CheckUserData(l, 1)); DWORD dwCor = LuaStatic::ReadRGBAFromLua(l, 2); self->SetSelItemHotTextColor(dwCor); return 0; } catch (...) { DuiException(_T("LuaCTreeViewUI::SetSelItemHotTextColor")); return 0; } }
IMPL_LUA_FUNC(LuaWindowExport, ListenUIDestroy) { try { CLuaWindow* self; self = static_cast<CLuaWindow*>(LuaStatic::CheckUserData(l, 1)); CControlUI* pControl = static_cast<CControlUI*>(LuaStatic::CheckUserData(l, 2)); pControl->OnDestroy += MakeDelegate(self, &CLuaWindow::onUIDestroy); return 0; } catch (...) { DuiException(_T("LuaWindowExport::ListenUIEvent")); return 0; } }
LUA_METHOD_IMPL(CLabelUI, IsShowHtml) { try { CLabelUI* self; self = static_cast<CLabelUI*>(LuaStatic::CheckUserData(l, 1)); lua_pushboolean(l, self->IsShowHtml() ? 1 : 0); return 1; } catch (...) { DuiException(_T("LuaCLabelUI::IsShowHtml")); return 0; } }
IMPL_LUA_FUNC(LuaWindowExport, KillTimer) { try { CLuaWindow* self; self = static_cast<CLuaWindow*>(LuaStatic::CheckUserData(l, 1)); long nID = (long)lua_tonumber(l, 2); self->KillTimer(nID); return 0; } catch(...) { DuiException(_T("LuaWindowExport::MapWindowPoints2")); return 0; } }
LUA_METHOD_IMPL(CLabelUI, GetEnabledShadow) { try { CLabelUI* self; self = static_cast<CLabelUI*>(LuaStatic::CheckUserData(l, 1)); lua_pushboolean(l, self->GetEnabledShadow() ? 1 : 0); return 1; } catch (...) { DuiException(_T("LuaCLabelUI::GetEnabledShadow")); return 0; } }
IMPL_LUA_FUNC(LuaWindowExport, SetListCallback) { try { CLuaWindow* self; self = static_cast<CLuaWindow*>(LuaStatic::CheckUserData(l, 1)); CListUI* pList = static_cast<CListUI*>(LuaStatic::CheckUserData(l, 2)); pList->SetTextCallback(self); return 0; } catch (...) { DuiException(_T("LuaWindowExport::SetListCallback")); return 0; } }