#include "lua_UIWebView_auto.hpp"
#include "UIWebView.h"
#include "tolua_fix.h"
#include "LuaBasicConversions.h"
//#include "cocos2d.h"



int lua_UIWebView_WebView_loadURL(lua_State* tolua_S)
{
    int argc = 0;
    cocos2d::experimental::ui::WebView* cobj = nullptr;
    bool ok  = true;

#if COCOS2D_DEBUG >= 1
    tolua_Error tolua_err;
#endif


#if COCOS2D_DEBUG >= 1
    if (!tolua_isusertype(tolua_S,1,"ccexp.WebView",&tolua_err)) goto tolua_lerror;
#endif

    cobj = (cocos2d::experimental::ui::WebView*)tolua_tousertype(tolua_S,0);

#if COCOS2D_DEBUG >= 1
    if (!cobj) 
    {
        tolua_error(tolua_S,"invalid 'cobj' in function 'lua_UIWebView_WebView_loadURL'",nullptr);
        return 0;
    }
#endif

    argc = lua_gettop(tolua_S)-1;
    if (argc == 1) 
    {
        std::string arg0;

        ok &= luaval_to_std_string(tolua_S,2,&arg0,"ccexp.WebView:loadURL");
        if(!ok)
        {
            tolua_error(tolua_S,"invalid arguments in function 'lua_UIWebView_WebView_loadURL'",nullptr);
            return 0;
        }
        cobj->loadURL(arg0);
        lua_settop(tolua_S,1);
        return 1;
    }
    luaL_error(tolua_S,"%s has wrong number of arguments: %d,was expecting %d \n","ccexp.WebView:loadURL",argc,1);
    return 0;

#if COCOS2D_DEBUG >= 1
    tolua_lerror:
    tolua_error(tolua_S,"#ferror in function 'lua_UIWebView_WebView_loadURL'.",&tolua_err);
#endif

    return 0;
}
int lua_UIWebView_WebView_canGoBack(lua_State* tolua_S)
{
    int argc = 0;
    cocos2d::experimental::ui::WebView* cobj = nullptr;
    bool ok  = true;

#if COCOS2D_DEBUG >= 1
    tolua_Error tolua_err;
#endif


#if COCOS2D_DEBUG >= 1
    if (!tolua_isusertype(tolua_S,"invalid 'cobj' in function 'lua_UIWebView_WebView_canGoBack'",nullptr);
        return 0;
    }
#endif

    argc = lua_gettop(tolua_S)-1;
    if (argc == 0) 
    {
        if(!ok)
        {
            tolua_error(tolua_S,"invalid arguments in function 'lua_UIWebView_WebView_canGoBack'",nullptr);
            return 0;
        }
        bool ret = cobj->canGoBack();
        tolua_pushboolean(tolua_S,(bool)ret);
        return 1;
    }
    luaL_error(tolua_S,"ccexp.WebView:canGoBack",0);
    return 0;

#if COCOS2D_DEBUG >= 1
    tolua_lerror:
    tolua_error(tolua_S,"#ferror in function 'lua_UIWebView_WebView_canGoBack'.",&tolua_err);
#endif

    return 0;
}
int lua_UIWebView_WebView_loadHTMLString(lua_State* tolua_S)
{
    int argc = 0;
    cocos2d::experimental::ui::WebView* cobj = nullptr;
    bool ok  = true;

#if COCOS2D_DEBUG >= 1
    tolua_Error tolua_err;
#endif


#if COCOS2D_DEBUG >= 1
    if (!tolua_isusertype(tolua_S,"invalid 'cobj' in function 'lua_UIWebView_WebView_loadHTMLString'","ccexp.WebView:loadHTMLString");
        if(!ok)
        {
            tolua_error(tolua_S,"invalid arguments in function 'lua_UIWebView_WebView_loadHTMLString'",nullptr);
            return 0;
        }
        cobj->loadHTMLString(arg0,"");
        lua_settop(tolua_S,1);
        return 1;
    }
    if (argc == 2) 
    {
        std::string arg0;
        std::string arg1;

        ok &= luaval_to_std_string(tolua_S,"ccexp.WebView:loadHTMLString");

        ok &= luaval_to_std_string(tolua_S,3,&arg1,arg1);
        lua_settop(tolua_S,"ccexp.WebView:loadHTMLString","#ferror in function 'lua_UIWebView_WebView_loadHTMLString'.",&tolua_err);
#endif

    return 0;
}
int lua_UIWebView_WebView_setonjsCallback(lua_State* tolua_S)
{
    int argc = 0;
    cocos2d::experimental::ui::WebView* cobj = nullptr;
    bool ok  = true;

#if COCOS2D_DEBUG >= 1
    tolua_Error tolua_err;
#endif


#if COCOS2D_DEBUG >= 1
    if (!tolua_isusertype(tolua_S,"invalid 'cobj' in function 'lua_UIWebView_WebView_setonjsCallback'",nullptr);
        return 0;
    }
#endif

    argc = lua_gettop(tolua_S)-1;
    if (argc == 1) 
    {
        std::function<void (cocos2d::experimental::ui::WebView *,const std::basic_string<char> &)> arg0;

        do {
			// Lambda binding for lua is not supported.
			assert(false);
		} while(0)
		;
        if(!ok)
        {
            tolua_error(tolua_S,"invalid arguments in function 'lua_UIWebView_WebView_setonjsCallback'",nullptr);
            return 0;
        }
        cobj->setonjsCallback(arg0);
        lua_settop(tolua_S,"ccexp.WebView:setonjsCallback","#ferror in function 'lua_UIWebView_WebView_setonjsCallback'.",&tolua_err);
#endif

    return 0;
}
int lua_UIWebView_WebView_setonShouldStartLoading(lua_State* tolua_S)
{
    int argc = 0;
    cocos2d::experimental::ui::WebView* cobj = nullptr;
    bool ok  = true;

#if COCOS2D_DEBUG >= 1
    tolua_Error tolua_err;
#endif


#if COCOS2D_DEBUG >= 1
    if (!tolua_isusertype(tolua_S,"invalid 'cobj' in function 'lua_UIWebView_WebView_setonShouldStartLoading'",nullptr);
        return 0;
    }
#endif

    argc = lua_gettop(tolua_S)-1;
    if (argc == 1) 
    {
        std::function<bool (cocos2d::experimental::ui::WebView *,"invalid arguments in function 'lua_UIWebView_WebView_setonShouldStartLoading'",nullptr);
            return 0;
        }
        cobj->setonShouldStartLoading(arg0);
        lua_settop(tolua_S,"ccexp.WebView:setonShouldStartLoading","#ferror in function 'lua_UIWebView_WebView_setonShouldStartLoading'.",&tolua_err);
#endif

    return 0;
}
int lua_UIWebView_WebView_goForward(lua_State* tolua_S)
{
    int argc = 0;
    cocos2d::experimental::ui::WebView* cobj = nullptr;
    bool ok  = true;

#if COCOS2D_DEBUG >= 1
    tolua_Error tolua_err;
#endif


#if COCOS2D_DEBUG >= 1
    if (!tolua_isusertype(tolua_S,"invalid 'cobj' in function 'lua_UIWebView_WebView_goForward'","invalid arguments in function 'lua_UIWebView_WebView_goForward'",nullptr);
            return 0;
        }
        cobj->goForward();
        lua_settop(tolua_S,"ccexp.WebView:goForward","#ferror in function 'lua_UIWebView_WebView_goForward'.",&tolua_err);
#endif

    return 0;
}
int lua_UIWebView_WebView_goBack(lua_State* tolua_S)
{
    int argc = 0;
    cocos2d::experimental::ui::WebView* cobj = nullptr;
    bool ok  = true;

#if COCOS2D_DEBUG >= 1
    tolua_Error tolua_err;
#endif


#if COCOS2D_DEBUG >= 1
    if (!tolua_isusertype(tolua_S,"invalid 'cobj' in function 'lua_UIWebView_WebView_goBack'","invalid arguments in function 'lua_UIWebView_WebView_goBack'",nullptr);
            return 0;
        }
        cobj->goBack();
        lua_settop(tolua_S,"ccexp.WebView:goBack","#ferror in function 'lua_UIWebView_WebView_goBack'.",&tolua_err);
#endif

    return 0;
}
int lua_UIWebView_WebView_setJavascriptInterfaceScheme(lua_State* tolua_S)
{
    int argc = 0;
    cocos2d::experimental::ui::WebView* cobj = nullptr;
    bool ok  = true;

#if COCOS2D_DEBUG >= 1
    tolua_Error tolua_err;
#endif


#if COCOS2D_DEBUG >= 1
    if (!tolua_isusertype(tolua_S,"invalid 'cobj' in function 'lua_UIWebView_WebView_setJavascriptInterfaceScheme'","ccexp.WebView:setJavascriptInterfaceScheme");
        if(!ok)
        {
            tolua_error(tolua_S,"invalid arguments in function 'lua_UIWebView_WebView_setJavascriptInterfaceScheme'",nullptr);
            return 0;
        }
        cobj->setJavascriptInterfaceScheme(arg0);
        lua_settop(tolua_S,"ccexp.WebView:setJavascriptInterfaceScheme","#ferror in function 'lua_UIWebView_WebView_setJavascriptInterfaceScheme'.",&tolua_err);
#endif

    return 0;
}
int lua_UIWebView_WebView_evaluateJS(lua_State* tolua_S)
{
    int argc = 0;
    cocos2d::experimental::ui::WebView* cobj = nullptr;
    bool ok  = true;

#if COCOS2D_DEBUG >= 1
    tolua_Error tolua_err;
#endif


#if COCOS2D_DEBUG >= 1
    if (!tolua_isusertype(tolua_S,"invalid 'cobj' in function 'lua_UIWebView_WebView_evaluateJS'","ccexp.WebView:evaluateJS");
        if(!ok)
        {
            tolua_error(tolua_S,"invalid arguments in function 'lua_UIWebView_WebView_evaluateJS'",nullptr);
            return 0;
        }
        cobj->evaluateJS(arg0);
        lua_settop(tolua_S,"ccexp.WebView:evaluateJS","#ferror in function 'lua_UIWebView_WebView_evaluateJS'.",&tolua_err);
#endif

    return 0;
}
int lua_UIWebView_WebView_getonjsCallback(lua_State* tolua_S)
{
    int argc = 0;
    cocos2d::experimental::ui::WebView* cobj = nullptr;
    bool ok  = true;

#if COCOS2D_DEBUG >= 1
    tolua_Error tolua_err;
#endif


#if COCOS2D_DEBUG >= 1
    if (!tolua_isusertype(tolua_S,"invalid 'cobj' in function 'lua_UIWebView_WebView_getonjsCallback'","invalid arguments in function 'lua_UIWebView_WebView_getonjsCallback'",nullptr);
            return 0;
        }
        cocos2d::experimental::ui::WebView::ccwebViewCallback ret = cobj->getonjsCallback();
        #pragma warning NO CONVERSION FROM NATIVE FOR std::function;
        return 1;
    }
    luaL_error(tolua_S,"ccexp.WebView:getonjsCallback","#ferror in function 'lua_UIWebView_WebView_getonjsCallback'.",&tolua_err);
#endif

    return 0;
}
int lua_UIWebView_WebView_reload(lua_State* tolua_S)
{
    int argc = 0;
    cocos2d::experimental::ui::WebView* cobj = nullptr;
    bool ok  = true;

#if COCOS2D_DEBUG >= 1
    tolua_Error tolua_err;
#endif


#if COCOS2D_DEBUG >= 1
    if (!tolua_isusertype(tolua_S,"invalid 'cobj' in function 'lua_UIWebView_WebView_reload'","invalid arguments in function 'lua_UIWebView_WebView_reload'",nullptr);
            return 0;
        }
        cobj->reload();
        lua_settop(tolua_S,"ccexp.WebView:reload","#ferror in function 'lua_UIWebView_WebView_reload'.",&tolua_err);
#endif

    return 0;
}
int lua_UIWebView_WebView_setScalesPagetoFit(lua_State* tolua_S)
{
    int argc = 0;
    cocos2d::experimental::ui::WebView* cobj = nullptr;
    bool ok  = true;

#if COCOS2D_DEBUG >= 1
    tolua_Error tolua_err;
#endif


#if COCOS2D_DEBUG >= 1
    if (!tolua_isusertype(tolua_S,"invalid 'cobj' in function 'lua_UIWebView_WebView_setScalesPagetoFit'",nullptr);
        return 0;
    }
#endif

    argc = lua_gettop(tolua_S)-1;
    if (argc == 1) 
    {
        bool arg0;

        ok &= luaval_to_boolean(tolua_S,"ccexp.WebView:setScalesPagetoFit");
        if(!ok)
        {
            tolua_error(tolua_S,"invalid arguments in function 'lua_UIWebView_WebView_setScalesPagetoFit'",nullptr);
            return 0;
        }
        cobj->setScalesPagetoFit(arg0);
        lua_settop(tolua_S,"ccexp.WebView:setScalesPagetoFit","#ferror in function 'lua_UIWebView_WebView_setScalesPagetoFit'.",&tolua_err);
#endif

    return 0;
}
int lua_UIWebView_WebView_canGoForward(lua_State* tolua_S)
{
    int argc = 0;
    cocos2d::experimental::ui::WebView* cobj = nullptr;
    bool ok  = true;

#if COCOS2D_DEBUG >= 1
    tolua_Error tolua_err;
#endif


#if COCOS2D_DEBUG >= 1
    if (!tolua_isusertype(tolua_S,"invalid 'cobj' in function 'lua_UIWebView_WebView_canGoForward'","invalid arguments in function 'lua_UIWebView_WebView_canGoForward'",nullptr);
            return 0;
        }
        bool ret = cobj->canGoForward();
        tolua_pushboolean(tolua_S,"ccexp.WebView:canGoForward","#ferror in function 'lua_UIWebView_WebView_canGoForward'.",&tolua_err);
#endif

    return 0;
}
int lua_UIWebView_WebView_loadData(lua_State* tolua_S)
{
    int argc = 0;
    cocos2d::experimental::ui::WebView* cobj = nullptr;
    bool ok  = true;

#if COCOS2D_DEBUG >= 1
    tolua_Error tolua_err;
#endif


#if COCOS2D_DEBUG >= 1
    if (!tolua_isusertype(tolua_S,"invalid 'cobj' in function 'lua_UIWebView_WebView_loadData'",nullptr);
        return 0;
    }
#endif

    argc = lua_gettop(tolua_S)-1;
    if (argc == 4) 
    {
        cocos2d::Data arg0;
        std::string arg1;
        std::string arg2;
        std::string arg3;

//        ok &= luaval_to_object<cocos2d::Data>(tolua_S,"cc.Data",&arg0);

        ok &= luaval_to_std_string(tolua_S,"ccexp.WebView:loadData");

        ok &= luaval_to_std_string(tolua_S,4,&arg2,5,&arg3,"ccexp.WebView:loadData");
        if(!ok)
        {
            tolua_error(tolua_S,"invalid arguments in function 'lua_UIWebView_WebView_loadData'",nullptr);
            return 0;
        }
        cobj->loadData(arg0,arg1,arg2,arg3);
        lua_settop(tolua_S,"ccexp.WebView:loadData",4);
    return 0;

#if COCOS2D_DEBUG >= 1
    tolua_lerror:
    tolua_error(tolua_S,"#ferror in function 'lua_UIWebView_WebView_loadData'.",&tolua_err);
#endif

    return 0;
}
int lua_UIWebView_WebView_getonShouldStartLoading(lua_State* tolua_S)
{
    int argc = 0;
    cocos2d::experimental::ui::WebView* cobj = nullptr;
    bool ok  = true;

#if COCOS2D_DEBUG >= 1
    tolua_Error tolua_err;
#endif


#if COCOS2D_DEBUG >= 1
    if (!tolua_isusertype(tolua_S,"invalid 'cobj' in function 'lua_UIWebView_WebView_getonShouldStartLoading'","invalid arguments in function 'lua_UIWebView_WebView_getonShouldStartLoading'",nullptr);
            return 0;
        }
        std::function<bool (cocos2d::experimental::ui::WebView *,const std::basic_string<char> &)> ret = cobj->getonShouldStartLoading();
        #pragma warning NO CONVERSION FROM NATIVE FOR std::function;
        return 1;
    }
    luaL_error(tolua_S,"ccexp.WebView:getonShouldStartLoading","#ferror in function 'lua_UIWebView_WebView_getonShouldStartLoading'.",&tolua_err);
#endif

    return 0;
}
int lua_UIWebView_WebView_loadFile(lua_State* tolua_S)
{
    int argc = 0;
    cocos2d::experimental::ui::WebView* cobj = nullptr;
    bool ok  = true;

#if COCOS2D_DEBUG >= 1
    tolua_Error tolua_err;
#endif


#if COCOS2D_DEBUG >= 1
    if (!tolua_isusertype(tolua_S,"invalid 'cobj' in function 'lua_UIWebView_WebView_loadFile'","ccexp.WebView:loadFile");
        if(!ok)
        {
            tolua_error(tolua_S,"invalid arguments in function 'lua_UIWebView_WebView_loadFile'",nullptr);
            return 0;
        }
        cobj->loadFile(arg0);
        lua_settop(tolua_S,"ccexp.WebView:loadFile","#ferror in function 'lua_UIWebView_WebView_loadFile'.",&tolua_err);
#endif

    return 0;
}
int lua_UIWebView_WebView_stopLoading(lua_State* tolua_S)
{
    int argc = 0;
    cocos2d::experimental::ui::WebView* cobj = nullptr;
    bool ok  = true;

#if COCOS2D_DEBUG >= 1
    tolua_Error tolua_err;
#endif


#if COCOS2D_DEBUG >= 1
    if (!tolua_isusertype(tolua_S,"invalid 'cobj' in function 'lua_UIWebView_WebView_stopLoading'","invalid arguments in function 'lua_UIWebView_WebView_stopLoading'",nullptr);
            return 0;
        }
        cobj->stopLoading();
        lua_settop(tolua_S,"ccexp.WebView:stopLoading","#ferror in function 'lua_UIWebView_WebView_stopLoading'.",&tolua_err);
#endif

    return 0;
}
int lua_UIWebView_WebView_setonDidFinishLoading(lua_State* tolua_S)
{
    int argc = 0;
    cocos2d::experimental::ui::WebView* cobj = nullptr;
    bool ok  = true;

#if COCOS2D_DEBUG >= 1
    tolua_Error tolua_err;
#endif


#if COCOS2D_DEBUG >= 1
    if (!tolua_isusertype(tolua_S,"invalid 'cobj' in function 'lua_UIWebView_WebView_setonDidFinishLoading'","invalid arguments in function 'lua_UIWebView_WebView_setonDidFinishLoading'",nullptr);
            return 0;
        }
        cobj->setonDidFinishLoading(arg0);
        lua_settop(tolua_S,"ccexp.WebView:setonDidFinishLoading","#ferror in function 'lua_UIWebView_WebView_setonDidFinishLoading'.",&tolua_err);
#endif

    return 0;
}
int lua_UIWebView_WebView_setonDidFailLoading(lua_State* tolua_S)
{
    int argc = 0;
    cocos2d::experimental::ui::WebView* cobj = nullptr;
    bool ok  = true;

#if COCOS2D_DEBUG >= 1
    tolua_Error tolua_err;
#endif


#if COCOS2D_DEBUG >= 1
    if (!tolua_isusertype(tolua_S,"invalid 'cobj' in function 'lua_UIWebView_WebView_setonDidFailLoading'","invalid arguments in function 'lua_UIWebView_WebView_setonDidFailLoading'",nullptr);
            return 0;
        }
        cobj->setonDidFailLoading(arg0);
        lua_settop(tolua_S,"ccexp.WebView:setonDidFailLoading","#ferror in function 'lua_UIWebView_WebView_setonDidFailLoading'.",&tolua_err);
#endif

    return 0;
}
int lua_UIWebView_WebView_getonDidFinishLoading(lua_State* tolua_S)
{
    int argc = 0;
    cocos2d::experimental::ui::WebView* cobj = nullptr;
    bool ok  = true;

#if COCOS2D_DEBUG >= 1
    tolua_Error tolua_err;
#endif


#if COCOS2D_DEBUG >= 1
    if (!tolua_isusertype(tolua_S,"invalid 'cobj' in function 'lua_UIWebView_WebView_getonDidFinishLoading'","invalid arguments in function 'lua_UIWebView_WebView_getonDidFinishLoading'",nullptr);
            return 0;
        }
        cocos2d::experimental::ui::WebView::ccwebViewCallback ret = cobj->getonDidFinishLoading();
        #pragma warning NO CONVERSION FROM NATIVE FOR std::function;
        return 1;
    }
    luaL_error(tolua_S,"ccexp.WebView:getonDidFinishLoading","#ferror in function 'lua_UIWebView_WebView_getonDidFinishLoading'.",&tolua_err);
#endif

    return 0;
}
int lua_UIWebView_WebView_getonDidFailLoading(lua_State* tolua_S)
{
    int argc = 0;
    cocos2d::experimental::ui::WebView* cobj = nullptr;
    bool ok  = true;

#if COCOS2D_DEBUG >= 1
    tolua_Error tolua_err;
#endif


#if COCOS2D_DEBUG >= 1
    if (!tolua_isusertype(tolua_S,"invalid 'cobj' in function 'lua_UIWebView_WebView_getonDidFailLoading'","invalid arguments in function 'lua_UIWebView_WebView_getonDidFailLoading'",nullptr);
            return 0;
        }
        cocos2d::experimental::ui::WebView::ccwebViewCallback ret = cobj->getonDidFailLoading();
        #pragma warning NO CONVERSION FROM NATIVE FOR std::function;
        return 1;
    }
    luaL_error(tolua_S,"ccexp.WebView:getonDidFailLoading","#ferror in function 'lua_UIWebView_WebView_getonDidFailLoading'.",&tolua_err);
#endif

    return 0;
}
int lua_UIWebView_WebView_create(lua_State* tolua_S)
{
    int argc = 0;
    bool ok  = true;

#if COCOS2D_DEBUG >= 1
    tolua_Error tolua_err;
#endif

#if COCOS2D_DEBUG >= 1
    if (!tolua_isusertable(tolua_S,&tolua_err)) goto tolua_lerror;
#endif

    argc = lua_gettop(tolua_S) - 1;

    if (argc == 0)
    {
        if(!ok)
        {
            tolua_error(tolua_S,"invalid arguments in function 'lua_UIWebView_WebView_create'",nullptr);
            return 0;
        }
        cocos2d::experimental::ui::WebView* ret = cocos2d::experimental::ui::WebView::create();
        object_to_luaval<cocos2d::experimental::ui::WebView>(tolua_S,(cocos2d::experimental::ui::WebView*)ret);
        return 1;
    }
    luaL_error(tolua_S,was expecting %d\n ","ccexp.WebView:create",0);
    return 0;
#if COCOS2D_DEBUG >= 1
    tolua_lerror:
    tolua_error(tolua_S,"#ferror in function 'lua_UIWebView_WebView_create'.",&tolua_err);
#endif
    return 0;
}
static int lua_UIWebView_WebView_finalize(lua_State* tolua_S)
{
    printf("luabindings: finalizing LUA object (WebView)");
    return 0;
}

int lua_register_UIWebView_WebView(lua_State* tolua_S)
{
    tolua_usertype(tolua_S,"ccexp.WebView");
    tolua_cclass(tolua_S,"WebView","ccui.Widget",nullptr);

    tolua_beginmodule(tolua_S,"WebView");
        tolua_function(tolua_S,"loadURL",lua_UIWebView_WebView_loadURL);
        tolua_function(tolua_S,"canGoBack",lua_UIWebView_WebView_canGoBack);
        tolua_function(tolua_S,"loadHTMLString",lua_UIWebView_WebView_loadHTMLString);
        tolua_function(tolua_S,"setonjsCallback",lua_UIWebView_WebView_setonjsCallback);
        tolua_function(tolua_S,"setonShouldStartLoading",lua_UIWebView_WebView_setonShouldStartLoading);
        tolua_function(tolua_S,"goForward",lua_UIWebView_WebView_goForward);
        tolua_function(tolua_S,"goBack",lua_UIWebView_WebView_goBack);
        tolua_function(tolua_S,"setJavascriptInterfaceScheme",lua_UIWebView_WebView_setJavascriptInterfaceScheme);
        tolua_function(tolua_S,"evaluateJS",lua_UIWebView_WebView_evaluateJS);
        tolua_function(tolua_S,"getonjsCallback",lua_UIWebView_WebView_getonjsCallback);
        tolua_function(tolua_S,"reload",lua_UIWebView_WebView_reload);
        tolua_function(tolua_S,"setScalesPagetoFit",lua_UIWebView_WebView_setScalesPagetoFit);
        tolua_function(tolua_S,"canGoForward",lua_UIWebView_WebView_canGoForward);
        tolua_function(tolua_S,"loadData",lua_UIWebView_WebView_loadData);
        tolua_function(tolua_S,"getonShouldStartLoading",lua_UIWebView_WebView_getonShouldStartLoading);
        tolua_function(tolua_S,"loadFile",lua_UIWebView_WebView_loadFile);
        tolua_function(tolua_S,"stopLoading",lua_UIWebView_WebView_stopLoading);
        tolua_function(tolua_S,"setonDidFinishLoading",lua_UIWebView_WebView_setonDidFinishLoading);
        tolua_function(tolua_S,"setonDidFailLoading",lua_UIWebView_WebView_setonDidFailLoading);
        tolua_function(tolua_S,"getonDidFinishLoading",lua_UIWebView_WebView_getonDidFinishLoading);
        tolua_function(tolua_S,"getonDidFailLoading",lua_UIWebView_WebView_getonDidFailLoading);
        tolua_function(tolua_S,"create",lua_UIWebView_WebView_create);
    tolua_endmodule(tolua_S);
    std::string typeName = typeid(cocos2d::experimental::ui::WebView).name();
    g_luaType[typeName] = "ccexp.WebView";
    g_typeCast["WebView"] = "ccexp.WebView";
    return 1;
}
TOLUA_API int register_all_UIWebView(lua_State* tolua_S)
{
	tolua_open(tolua_S);
	
	tolua_module(tolua_S,nullptr,0);
	tolua_beginmodule(tolua_S,nullptr);

	lua_register_UIWebView_WebView(tolua_S);

	tolua_endmodule(tolua_S);
	return 1;
}

cocos2dx lua_UIWebView_auto.cpp webView tolua实现文件的更多相关文章

  1. 详解如何通过H5(浏览器/WebView/其他)唤起本地app

    这篇文章主要介绍了详解如何通过H5(浏览器/WebView/其他)唤起本地app的相关资料,小编觉得挺不错的,现在分享给大家,也给大家做个参考。一起跟随小编过来看看吧

  2. HTML5页面无缝闪开的问题及解决方案

    这篇文章主要介绍了HTML5页面无缝闪开方案,本文通过实例代码给大家介绍的非常详细,对大家的学习或工作具有一定的参考借鉴价值,需要的朋友可以参考下

  3. ios – 在WKWebView中获取链接URL

    我想在WKWebView中获取tapped链接的url.链接采用自定义格式,可触发应用中的某些操作.例如HTTP://我的网站/帮助#深层链接对讲.我这样使用KVO:这在第一次点击链接时效果很好.但是,如果我连续两次点击相同的链接,它将不报告链接点击.是否有解决方法来解决这个问题,以便我可以检测每个点击并获取链接?任何关于这个的指针都会很棒!解决方法像这样更改addobserver在observeValue函数中,您可以获得两个值

  4. ios – 永远不会调用shouldStartLoadWithRequest

    我已经研究和研究,但仍然不明白为什么从未调用过StartLoadWithRequest.我的页面加载正常,并调用了一些UIWebview委托协议方法.请从以下代码中找到相关的摘要:在我的.m中合成我的webview(在头文件中定义):我成功加载了我的webview:把我的代表设置为自己我的所有协议方法都被称为EXCEPTshouldStartLoadWithRequest提前致谢.解决方法尝试在V

  5. ios – UIWebView不适合设备屏幕

    我有一个网页视图,我想填写iDevice的全屏.我把它放在视图中心设置为中心并与容器边缘齐平.然而,当我加载应用程序时,视图比它运行的模拟iPhone大.我做了一些搜索,一些建议自动布局,这已经应该是视图的中心.我发现的另一件事是通过代码设置大小.我甚至将应用程序从通用应用程序更改为iPhone,对布局没有影响.完整来源:解决方法设置缩放以适合视图边界.试试这个:希望这可以帮助..:)

  6. ios – 如何在Swift中手动为UIWebView设置Cookie

    我需要在swift中为webview设置一个cookie.我找到了一个解决方案,但它是针对objective-c的.如何在Swift中做到这一点?

  7. iOS – 防止UIAppearance设置更改UIWebView输入附件视图

    我的应用程序中有一个UIWebView,问题是我有一个UIAppearance来修改分段控件的外观,因此它修改了UIWebView文本字段的输入附件视图中的分段控件,我希望它看起来不错,或者不试图修改它.这就是它目前的样子:解决方法我只是通过使用[UIAppearanceappearanceWhenContainedIn:]而不是[UIAppearance外观]来解决这个问题.通过向选择器发送包含

  8. ios – 如何为UIWebView设置自定义键盘

    如何为iOS7及更高版本的可编辑UIWebView显示自定义键盘和输入附件视图.即:如何设置和使用[UIWebViewsetInputView:]和[UIWebViewsetInputAccessoryView:]中的值解决方法理解你想要做什么会有所帮助?您可以尝试强制使用特定类型的键盘,例如数字,电子邮件等,这些键盘将使用用户在其设备(或系统)上明确安装的键盘.为此,您可以参考thisapple

  9. xcode – 无法在iOS8beta5中使用UIWebView打开PDF文件

    如果是,请提供一些示例代码.解决方法我找到了一种在WebView中查看PDF的解决方法

  10. iOS从UIWebview内容创建pdf

    哪个是从webview内容中获取最佳质量pdf文档的最佳选择?

随机推荐

  1. 【cocos2d-x 3.x 学习笔记】对象内存管理

    Cocos2d-x的内存管理cocos2d-x中使用的是上面的引用计数来管理内存,但是又增加了一些自己的特色。cocos2d-x中通过Ref类来实现引用计数,所有需要实现内存自动回收的类都应该继承自Ref类。下面是Ref类的定义:在cocos2d-x中创建对象通常有两种方式:这两中方式的差异可以参见我另一篇博文“对象创建方式讨论”。在cocos2d-x中提倡使用第二种方式,为了避免误用第一种方式,一般将构造函数设为protected或private。参考资料:[1]cocos2d-x高级开发教程2.3节[

  2. 利用cocos2dx 3.2开发消灭星星六如何在cocos2dx中显示中文

    由于编码的不同,在cocos2dx中的Label控件中如果放入中文字,往往会出现乱码。为了方便使用,我把这个从文档中获取中文字的方法放在一个头文件里面Chinese.h这里的tex_vec是cocos2dx提供的一个保存文档内容的一个容器。这里给出ChineseWords,xml的格式再看看ChineseWord的实现Chinese.cpp就这样,以后在需要用到中文字的地方,就先include这个头文件然后调用ChineseWord函数,获取一串中文字符串。

  3. 利用cocos2dx 3.2开发消灭星星七关于星星的算法

    在前面,我们已经在GameLayer中利用随机数初始化了一个StarMatrix,如果还不知道怎么创建星星矩阵请回去看看而且我们也讲了整个游戏的触摸事件的派发了。

  4. cocos2dx3.x 新手打包APK注意事项!

    这个在编译的时候就可以发现了比较好弄这只是我遇到的,其他的以后遇到再补充吧。。。以前被这两个问题坑了好久

  5. 利用cocos2dx 3.2开发消灭星星八游戏的结束判断与数据控制

    如果你看完之前的,那么你基本已经拥有一个消灭星星游戏的雏形。开始把剩下的两两互不相连的星星消去。那么如何判断是GameOver还是进入下一关呢。。其实游戏数据贯穿整个游戏,包括星星消除的时候要加到获得分数上,消去剩下两两不相连的星星的时候的加分政策等,因此如果前面没有做这一块的,最好回去搞一搞。

  6. 利用cocos2dx 3.2开发消灭星星九为游戏添加一些特效

    needClear是一个flag,当游戏判断不能再继续后,这个flag变为true,开始消除剩下的星星clearSumTime是一个累加器ONE_CLEAR_TIME就是每颗星星消除的时间2.连击加分信息一般消除一次星星都会有连击信息和加多少分的信息。其实这些combo标签就是一张图片,也是通过控制其属性或者runAction来实现。源码ComboEffect.hComboEffect.cpp4.消除星星粒子效果消除星星时,为了实现星星爆裂散落的效果,使用了cocos2d提供的粒子特效引擎对于粒子特效不了

  7. 02 Cocos2D-x引擎win7环境搭建及创建项目

    官网有搭建的文章,直接转载记录。环境搭建:本文介绍如何搭建Cocos2d-x3.2版本的开发环境。项目创建:一、通过命令创建项目前面搭建好环境后,怎样创建自己的Cocos2d-x项目呢?先来看看Cocos2d-x3.2的目录吧这就是Cocos2d-x3.2的目录。输入cocosnew项目名–p包名–lcpp–d路径回车就创建成功了例如:成功后,找到这个项目打开proj.win32目录下的Hello.slnF5成功了。

  8. 利用cocos2dx 3.2开发消灭星星十为游戏添加音效项目源码分享

    一个游戏,声音也是非常的重要,其实cocos2dx里面的简单音效引擎的使用是非常简单的。我这里只不过是用一个类对所有的音效进行管理罢了。Audio.hAudio.cpp好了,本系列教程到此结束,第一次写教程如有不对请见谅或指教,谢谢大家。最后附上整个项目的源代码点击打开链接

  9. 03 Helloworld

    程序都有一个入口点,在C++就是main函数了,打开main.cpp,代码如下:123456789101112131415161718#include"main.h"#include"AppDelegate.h"#include"cocos2d.h"USING_NS_CC;intAPIENTRY_tWinMain{UNREFERENCED_ParaMETER;UNREFERENCED_ParaMETER;//createtheapplicationinstanceAppDelegateapp;return

  10. MenuItemImage*图标菜单创建注意事项

    学习cocos2dx,看的是cocos2d-x3.x手游开发实例详解,这本书错误一大把,本着探索求知勇于发现错误改正错误的精神,我跟着书上的例子一起调试,当学习到场景切换这个小节的时候,出了个错误,卡了我好几个小时。

返回
顶部