Committing genbindings changes [skip ci]

This commit is contained in:
halx99 2022-04-28 04:20:11 +00:00 committed by GitHub Actions
parent 111df39a7d
commit a6dbeb029e
2 changed files with 52 additions and 0 deletions

View File

@ -338,6 +338,56 @@ int lua_cocos2dx_video_VideoPlayer_setFullScreenEnabled(lua_State* tolua_S)
return 0; return 0;
} }
int lua_cocos2dx_video_VideoPlayer_setPlayRate(lua_State* tolua_S)
{
int argc = 0;
cocos2d::ui::VideoPlayer* cobj = nullptr;
bool ok = true;
#if COCOS2D_DEBUG >= 1
tolua_Error tolua_err;
#endif
#if COCOS2D_DEBUG >= 1
if (!tolua_isusertype(tolua_S,1,"ccui.VideoPlayer",0,&tolua_err)) goto tolua_lerror;
#endif
cobj = (cocos2d::ui::VideoPlayer*)tolua_tousertype(tolua_S,1,0);
#if COCOS2D_DEBUG >= 1
if (!cobj)
{
tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_video_VideoPlayer_setPlayRate'", nullptr);
return 0;
}
#endif
argc = lua_gettop(tolua_S)-1;
if (argc == 1)
{
double arg0;
ok &= luaval_to_number(tolua_S, 2,&arg0, "ccui.VideoPlayer:setPlayRate");
if(!ok)
{
tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_video_VideoPlayer_setPlayRate'", nullptr);
return 0;
}
cobj->setPlayRate(arg0);
lua_settop(tolua_S, 1);
return 1;
}
luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "ccui.VideoPlayer:setPlayRate",argc, 1);
return 0;
#if COCOS2D_DEBUG >= 1
tolua_lerror:
tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_video_VideoPlayer_setPlayRate'.",&tolua_err);
#endif
return 0;
}
int lua_cocos2dx_video_VideoPlayer_setFileName(lua_State* tolua_S) int lua_cocos2dx_video_VideoPlayer_setFileName(lua_State* tolua_S)
{ {
int argc = 0; int argc = 0;
@ -967,6 +1017,7 @@ int lua_register_cocos2dx_video_VideoPlayer(lua_State* tolua_S)
tolua_function(tolua_S,"setKeepAspectRatioEnabled",lua_cocos2dx_video_VideoPlayer_setKeepAspectRatioEnabled); tolua_function(tolua_S,"setKeepAspectRatioEnabled",lua_cocos2dx_video_VideoPlayer_setKeepAspectRatioEnabled);
tolua_function(tolua_S,"stop",lua_cocos2dx_video_VideoPlayer_stop); tolua_function(tolua_S,"stop",lua_cocos2dx_video_VideoPlayer_stop);
tolua_function(tolua_S,"setFullScreenEnabled",lua_cocos2dx_video_VideoPlayer_setFullScreenEnabled); tolua_function(tolua_S,"setFullScreenEnabled",lua_cocos2dx_video_VideoPlayer_setFullScreenEnabled);
tolua_function(tolua_S,"setPlayRate",lua_cocos2dx_video_VideoPlayer_setPlayRate);
tolua_function(tolua_S,"setFileName",lua_cocos2dx_video_VideoPlayer_setFileName); tolua_function(tolua_S,"setFileName",lua_cocos2dx_video_VideoPlayer_setFileName);
tolua_function(tolua_S,"setURL",lua_cocos2dx_video_VideoPlayer_setURL); tolua_function(tolua_S,"setURL",lua_cocos2dx_video_VideoPlayer_setURL);
tolua_function(tolua_S,"setStyle",lua_cocos2dx_video_VideoPlayer_setStyle); tolua_function(tolua_S,"setStyle",lua_cocos2dx_video_VideoPlayer_setStyle);

View File

@ -31,6 +31,7 @@ int register_all_cocos2dx_video(lua_State* tolua_S);
#endif // __cocos2dx_video_h__ #endif // __cocos2dx_video_h__