コード例 #1
0
    static int set_HandleOnLoadIcon(IntPtr L)
    {
        object o = null;

        try
        {
            o = ToLua.ToObject(L, 1);
            UIPopupListExtended            obj  = (UIPopupListExtended)o;
            UIPopupListExtended.OnLoadIcon arg0 = null;
            LuaTypes funcType2 = LuaDLL.lua_type(L, 2);

            if (funcType2 != LuaTypes.LUA_TFUNCTION)
            {
                arg0 = (UIPopupListExtended.OnLoadIcon)ToLua.CheckObject(L, 2, typeof(UIPopupListExtended.OnLoadIcon));
            }
            else
            {
                LuaFunction func = ToLua.ToLuaFunction(L, 2);
                arg0 = DelegateFactory.CreateDelegate(typeof(UIPopupListExtended.OnLoadIcon), func) as UIPopupListExtended.OnLoadIcon;
            }

            obj.HandleOnLoadIcon = arg0;
            return(0);
        }
        catch (Exception e)
        {
            return(LuaDLL.toluaL_exception(L, e, o == null ? "attempt to index HandleOnLoadIcon on a nil value" : e.Message));
        }
    }
コード例 #2
0
    static int get_HandleOnLoadIcon(IntPtr L)
    {
        object o = null;

        try
        {
            o = ToLua.ToObject(L, 1);
            UIPopupListExtended            obj = (UIPopupListExtended)o;
            UIPopupListExtended.OnLoadIcon ret = obj.HandleOnLoadIcon;
            ToLua.Push(L, ret);
            return(1);
        }
        catch (Exception e)
        {
            return(LuaDLL.toluaL_exception(L, e, o == null ? "attempt to index HandleOnLoadIcon on a nil value" : e.Message));
        }
    }