예제 #1
0
    static int LoadAndCacheImage(IntPtr L)
    {
        try
        {
            int count = LuaDLL.lua_gettop(L);

            if (count == 3)
            {
                LuaFramework.WWWManager obj = (LuaFramework.WWWManager)ToLua.CheckObject <LuaFramework.WWWManager>(L, 1);
                string      arg0            = ToLua.CheckString(L, 2);
                LuaFunction arg1            = ToLua.CheckLuaFunction(L, 3);
                obj.LoadAndCacheImage(arg0, arg1);
                return(0);
            }
            else if (count == 4)
            {
                LuaFramework.WWWManager obj = (LuaFramework.WWWManager)ToLua.CheckObject <LuaFramework.WWWManager>(L, 1);
                string      arg0            = ToLua.CheckString(L, 2);
                LuaFunction arg1            = ToLua.CheckLuaFunction(L, 3);
                bool        arg2            = LuaDLL.luaL_checkboolean(L, 4);
                obj.LoadAndCacheImage(arg0, arg1, arg2);
                return(0);
            }
            else
            {
                return(LuaDLL.luaL_throw(L, "invalid arguments to method: LuaFramework.WWWManager.LoadAndCacheImage"));
            }
        }
        catch (Exception e)
        {
            return(LuaDLL.toluaL_exception(L, e));
        }
    }
예제 #2
0
 static int StopHttp(IntPtr L)
 {
     try
     {
         ToLua.CheckArgsCount(L, 1);
         LuaFramework.WWWManager obj = (LuaFramework.WWWManager)ToLua.CheckObject <LuaFramework.WWWManager>(L, 1);
         obj.StopHttp();
         return(0);
     }
     catch (Exception e)
     {
         return(LuaDLL.toluaL_exception(L, e));
     }
 }
예제 #3
0
 static int GetWWWManager(IntPtr L)
 {
     try
     {
         ToLua.CheckArgsCount(L, 0);
         LuaFramework.WWWManager o = LuaFramework.LuaHelper.GetWWWManager();
         ToLua.Push(L, o);
         return(1);
     }
     catch (Exception e)
     {
         return(LuaDLL.toluaL_exception(L, e));
     }
 }
예제 #4
0
 static int InstallAPK(IntPtr L)
 {
     try
     {
         ToLua.CheckArgsCount(L, 2);
         LuaFramework.WWWManager obj = (LuaFramework.WWWManager)ToLua.CheckObject <LuaFramework.WWWManager>(L, 1);
         string arg0 = ToLua.CheckString(L, 2);
         obj.InstallAPK(arg0);
         return(0);
     }
     catch (Exception e)
     {
         return(LuaDLL.toluaL_exception(L, e));
     }
 }
예제 #5
0
 static int CreatFile(IntPtr L)
 {
     try
     {
         ToLua.CheckArgsCount(L, 2);
         LuaFramework.WWWManager obj = (LuaFramework.WWWManager)ToLua.CheckObject <LuaFramework.WWWManager>(L, 1);
         byte[] arg0 = ToLua.CheckByteBuffer(L, 2);
         obj.CreatFile(arg0);
         return(0);
     }
     catch (Exception e)
     {
         return(LuaDLL.toluaL_exception(L, e));
     }
 }
예제 #6
0
 static int LoadImage(IntPtr L)
 {
     try
     {
         ToLua.CheckArgsCount(L, 3);
         LuaFramework.WWWManager obj = (LuaFramework.WWWManager)ToLua.CheckObject <LuaFramework.WWWManager>(L, 1);
         string      arg0            = ToLua.CheckString(L, 2);
         LuaFunction arg1            = ToLua.CheckLuaFunction(L, 3);
         obj.LoadImage(arg0, arg1);
         return(0);
     }
     catch (Exception e)
     {
         return(LuaDLL.toluaL_exception(L, e));
     }
 }
예제 #7
0
 static int LoadImageFromPath(IntPtr L)
 {
     try
     {
         ToLua.CheckArgsCount(L, 3);
         LuaFramework.WWWManager obj      = (LuaFramework.WWWManager)ToLua.CheckObject <LuaFramework.WWWManager>(L, 1);
         string      arg0                 = ToLua.CheckString(L, 2);
         LuaFunction arg1                 = ToLua.CheckLuaFunction(L, 3);
         System.Collections.IEnumerator o = obj.LoadImageFromPath(arg0, arg1);
         ToLua.Push(L, o);
         return(1);
     }
     catch (Exception e)
     {
         return(LuaDLL.toluaL_exception(L, e));
     }
 }
예제 #8
0
 static int RequestHttpPOST(IntPtr L)
 {
     try
     {
         ToLua.CheckArgsCount(L, 4);
         LuaFramework.WWWManager obj = (LuaFramework.WWWManager)ToLua.CheckObject <LuaFramework.WWWManager>(L, 1);
         string arg0 = ToLua.CheckString(L, 2);
         UnityEngine.WWWForm arg1 = (UnityEngine.WWWForm)ToLua.CheckObject <UnityEngine.WWWForm>(L, 3);
         LuaFunction         arg2 = ToLua.CheckLuaFunction(L, 4);
         obj.RequestHttpPOST(arg0, arg1, arg2);
         return(0);
     }
     catch (Exception e)
     {
         return(LuaDLL.toluaL_exception(L, e));
     }
 }
예제 #9
0
 static int StartHTTPPOST(IntPtr L)
 {
     try
     {
         ToLua.CheckArgsCount(L, 4);
         LuaFramework.WWWManager obj = (LuaFramework.WWWManager)ToLua.CheckObject <LuaFramework.WWWManager>(L, 1);
         string arg0 = ToLua.CheckString(L, 2);
         UnityEngine.WWWForm            arg1 = (UnityEngine.WWWForm)ToLua.CheckObject <UnityEngine.WWWForm>(L, 3);
         LuaFunction                    arg2 = ToLua.CheckLuaFunction(L, 4);
         System.Collections.IEnumerator o    = obj.StartHTTPPOST(arg0, arg1, arg2);
         ToLua.Push(L, o);
         return(1);
     }
     catch (Exception e)
     {
         return(LuaDLL.toluaL_exception(L, e));
     }
 }