diff --git a/AUTHORS b/AUTHORS index 41ba3dac1a..ba8e4686d9 100644 --- a/AUTHORS +++ b/AUTHORS @@ -989,6 +989,9 @@ Developers: xiangxw Fixed the bug that Console::sendPrompt() will send extra `\0` + + kaishiqi + Fixed a but that cursor postion is wrong on desktop. Retired Core Developers: WenSheng Yang diff --git a/CHANGELOG b/CHANGELOG index 78a3a19328..bfe066429f 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -3,6 +3,7 @@ cocos2d-x-3.3?? ?? [NEW] Node: added stopAllActionsByTag() [NEW] UI: added `WebView` on iOS and Android + [FIX] EditBox: moved to ui:EditBox [FIX] Node: create unneeded temple `Vec2` object in `setPosition(int, int)`, `setPositionX()` and `setPositionY()` [FIX] Node: skew effect is wrong [FIX] TextureAtlas: may crash if only drawing part of it diff --git a/build/cocos2d_libs.xcodeproj/project.pbxproj b/build/cocos2d_libs.xcodeproj/project.pbxproj index c49581a417..dcf250b68c 100644 --- a/build/cocos2d_libs.xcodeproj/project.pbxproj +++ b/build/cocos2d_libs.xcodeproj/project.pbxproj @@ -969,8 +969,6 @@ 15AE1BDD19AAE01E00C27E9E /* CCControlUtils.h in Headers */ = {isa = PBXBuildFile; fileRef = 46A168491807AF4E005B8026 /* CCControlUtils.h */; }; 15AE1BDE19AAE01E00C27E9E /* CCInvocation.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46A1684A1807AF4E005B8026 /* CCInvocation.cpp */; }; 15AE1BDF19AAE01E00C27E9E /* CCInvocation.h in Headers */ = {isa = PBXBuildFile; fileRef = 46A1684B1807AF4E005B8026 /* CCInvocation.h */; }; - 15AE1BE019AAE01E00C27E9E /* CCScale9Sprite.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46A1684C1807AF4E005B8026 /* CCScale9Sprite.cpp */; }; - 15AE1BE119AAE01E00C27E9E /* CCScale9Sprite.h in Headers */ = {isa = PBXBuildFile; fileRef = 46A1684D1807AF4E005B8026 /* CCScale9Sprite.h */; }; 15AE1BE219AAE01E00C27E9E /* CCScrollView.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46A1685E1807AF4E005B8026 /* CCScrollView.cpp */; }; 15AE1BE319AAE01E00C27E9E /* CCScrollView.h in Headers */ = {isa = PBXBuildFile; fileRef = 46A1685F1807AF4E005B8026 /* CCScrollView.h */; }; 15AE1BE419AAE01E00C27E9E /* CCTableView.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46A168621807AF4E005B8026 /* CCTableView.cpp */; }; @@ -1000,24 +998,12 @@ 15AE1BFC19AAE01E00C27E9E /* CCControlUtils.h in Headers */ = {isa = PBXBuildFile; fileRef = 46A168491807AF4E005B8026 /* CCControlUtils.h */; }; 15AE1BFD19AAE01E00C27E9E /* CCInvocation.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46A1684A1807AF4E005B8026 /* CCInvocation.cpp */; }; 15AE1BFE19AAE01E00C27E9E /* CCInvocation.h in Headers */ = {isa = PBXBuildFile; fileRef = 46A1684B1807AF4E005B8026 /* CCInvocation.h */; }; - 15AE1BFF19AAE01E00C27E9E /* CCScale9Sprite.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46A1684C1807AF4E005B8026 /* CCScale9Sprite.cpp */; }; - 15AE1C0019AAE01E00C27E9E /* CCScale9Sprite.h in Headers */ = {isa = PBXBuildFile; fileRef = 46A1684D1807AF4E005B8026 /* CCScale9Sprite.h */; }; 15AE1C0119AAE01E00C27E9E /* CCScrollView.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46A1685E1807AF4E005B8026 /* CCScrollView.cpp */; }; 15AE1C0219AAE01E00C27E9E /* CCScrollView.h in Headers */ = {isa = PBXBuildFile; fileRef = 46A1685F1807AF4E005B8026 /* CCScrollView.h */; }; 15AE1C0319AAE01E00C27E9E /* CCTableView.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46A168621807AF4E005B8026 /* CCTableView.cpp */; }; 15AE1C0419AAE01E00C27E9E /* CCTableView.h in Headers */ = {isa = PBXBuildFile; fileRef = 46A168631807AF4E005B8026 /* CCTableView.h */; }; 15AE1C0519AAE01E00C27E9E /* CCTableViewCell.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46A168641807AF4E005B8026 /* CCTableViewCell.cpp */; }; 15AE1C0619AAE01E00C27E9E /* CCTableViewCell.h in Headers */ = {isa = PBXBuildFile; fileRef = 46A168651807AF4E005B8026 /* CCTableViewCell.h */; }; - 15AE1C0719AAE02500C27E9E /* CCEditBox.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46A1684F1807AF4E005B8026 /* CCEditBox.cpp */; }; - 15AE1C0819AAE02500C27E9E /* CCEditBox.h in Headers */ = {isa = PBXBuildFile; fileRef = 46A168501807AF4E005B8026 /* CCEditBox.h */; }; - 15AE1C0919AAE02500C27E9E /* CCEditBox.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 46A1684F1807AF4E005B8026 /* CCEditBox.cpp */; }; - 15AE1C0A19AAE02500C27E9E /* CCEditBox.h in Headers */ = {isa = PBXBuildFile; fileRef = 46A168501807AF4E005B8026 /* CCEditBox.h */; }; - 15AE1C0B19AAE02D00C27E9E /* CCEditBoxImpl.h in Headers */ = {isa = PBXBuildFile; fileRef = 46A168511807AF4E005B8026 /* CCEditBoxImpl.h */; }; - 15AE1C0C19AAE02D00C27E9E /* CCEditBoxImpl.h in Headers */ = {isa = PBXBuildFile; fileRef = 46A168511807AF4E005B8026 /* CCEditBoxImpl.h */; }; - 15AE1C0D19AAE03400C27E9E /* CCEditBoxImplMac.mm in Sources */ = {isa = PBXBuildFile; fileRef = B282B47C1980E02B00666787 /* CCEditBoxImplMac.mm */; }; - 15AE1C0E19AAE03400C27E9E /* CCEditBoxImplMac.h in Headers */ = {isa = PBXBuildFile; fileRef = B282B47D1980E02B00666787 /* CCEditBoxImplMac.h */; }; - 15AE1C0F19AAE03E00C27E9E /* CCEditBoxImplIOS.h in Headers */ = {isa = PBXBuildFile; fileRef = 46A168541807AF4E005B8026 /* CCEditBoxImplIOS.h */; }; - 15AE1C1019AAE03E00C27E9E /* CCEditBoxImplIOS.mm in Sources */ = {isa = PBXBuildFile; fileRef = 46A168551807AF4E005B8026 /* CCEditBoxImplIOS.mm */; }; 15AE1C1119AAE2C600C27E9E /* CCPhysicsDebugNode.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1AD71EEC180E27CF00808F54 /* CCPhysicsDebugNode.cpp */; }; 15AE1C1219AAE2C600C27E9E /* CCPhysicsDebugNode.h in Headers */ = {isa = PBXBuildFile; fileRef = 1AD71EED180E27CF00808F54 /* CCPhysicsDebugNode.h */; }; 15AE1C1319AAE2C600C27E9E /* CCPhysicsSprite.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1AD71EEE180E27CF00808F54 /* CCPhysicsSprite.cpp */; }; @@ -1350,6 +1336,30 @@ 1ABA68B11888D700007D1BB4 /* CCFontCharMap.h in Headers */ = {isa = PBXBuildFile; fileRef = 1ABA68AD1888D700007D1BB4 /* CCFontCharMap.h */; }; 1AC0269C1914068200FA920D /* ConvertUTF.h in Headers */ = {isa = PBXBuildFile; fileRef = 1AC026991914068200FA920D /* ConvertUTF.h */; }; 1AC0269D1914068200FA920D /* ConvertUTF.h in Headers */ = {isa = PBXBuildFile; fileRef = 1AC026991914068200FA920D /* ConvertUTF.h */; }; + 292DB13D19B4574100A80320 /* UIEditBox.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 292DB12F19B4574100A80320 /* UIEditBox.cpp */; }; + 292DB13E19B4574100A80320 /* UIEditBox.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 292DB12F19B4574100A80320 /* UIEditBox.cpp */; }; + 292DB13F19B4574100A80320 /* UIEditBox.h in Headers */ = {isa = PBXBuildFile; fileRef = 292DB13019B4574100A80320 /* UIEditBox.h */; }; + 292DB14019B4574100A80320 /* UIEditBox.h in Headers */ = {isa = PBXBuildFile; fileRef = 292DB13019B4574100A80320 /* UIEditBox.h */; }; + 292DB14119B4574100A80320 /* UIEditBoxImpl.h in Headers */ = {isa = PBXBuildFile; fileRef = 292DB13119B4574100A80320 /* UIEditBoxImpl.h */; }; + 292DB14219B4574100A80320 /* UIEditBoxImpl.h in Headers */ = {isa = PBXBuildFile; fileRef = 292DB13119B4574100A80320 /* UIEditBoxImpl.h */; }; + 292DB14319B4574100A80320 /* UIEditBoxImplAndroid.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 292DB13219B4574100A80320 /* UIEditBoxImplAndroid.cpp */; }; + 292DB14419B4574100A80320 /* UIEditBoxImplAndroid.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 292DB13219B4574100A80320 /* UIEditBoxImplAndroid.cpp */; }; + 292DB14519B4574100A80320 /* UIEditBoxImplAndroid.h in Headers */ = {isa = PBXBuildFile; fileRef = 292DB13319B4574100A80320 /* UIEditBoxImplAndroid.h */; }; + 292DB14619B4574100A80320 /* UIEditBoxImplAndroid.h in Headers */ = {isa = PBXBuildFile; fileRef = 292DB13319B4574100A80320 /* UIEditBoxImplAndroid.h */; }; + 292DB14719B4574100A80320 /* UIEditBoxImplIOS.h in Headers */ = {isa = PBXBuildFile; fileRef = 292DB13419B4574100A80320 /* UIEditBoxImplIOS.h */; }; + 292DB14819B4574100A80320 /* UIEditBoxImplIOS.h in Headers */ = {isa = PBXBuildFile; fileRef = 292DB13419B4574100A80320 /* UIEditBoxImplIOS.h */; }; + 292DB14919B4574100A80320 /* UIEditBoxImplIOS.mm in Sources */ = {isa = PBXBuildFile; fileRef = 292DB13519B4574100A80320 /* UIEditBoxImplIOS.mm */; }; + 292DB14A19B4574100A80320 /* UIEditBoxImplIOS.mm in Sources */ = {isa = PBXBuildFile; fileRef = 292DB13519B4574100A80320 /* UIEditBoxImplIOS.mm */; }; + 292DB14B19B4574100A80320 /* UIEditBoxImplMac.h in Headers */ = {isa = PBXBuildFile; fileRef = 292DB13619B4574100A80320 /* UIEditBoxImplMac.h */; }; + 292DB14C19B4574100A80320 /* UIEditBoxImplMac.h in Headers */ = {isa = PBXBuildFile; fileRef = 292DB13619B4574100A80320 /* UIEditBoxImplMac.h */; }; + 292DB14D19B4574100A80320 /* UIEditBoxImplMac.mm in Sources */ = {isa = PBXBuildFile; fileRef = 292DB13719B4574100A80320 /* UIEditBoxImplMac.mm */; }; + 292DB14E19B4574100A80320 /* UIEditBoxImplMac.mm in Sources */ = {isa = PBXBuildFile; fileRef = 292DB13719B4574100A80320 /* UIEditBoxImplMac.mm */; }; + 292DB14F19B4574100A80320 /* UIEditBoxImplNone.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 292DB13819B4574100A80320 /* UIEditBoxImplNone.cpp */; }; + 292DB15019B4574100A80320 /* UIEditBoxImplNone.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 292DB13819B4574100A80320 /* UIEditBoxImplNone.cpp */; }; + 292DB15F19B461CA00A80320 /* ExtensionDeprecated.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 292DB15D19B461CA00A80320 /* ExtensionDeprecated.cpp */; }; + 292DB16019B461CA00A80320 /* ExtensionDeprecated.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 292DB15D19B461CA00A80320 /* ExtensionDeprecated.cpp */; }; + 292DB16119B461CA00A80320 /* ExtensionDeprecated.h in Headers */ = {isa = PBXBuildFile; fileRef = 292DB15E19B461CA00A80320 /* ExtensionDeprecated.h */; }; + 292DB16219B461CA00A80320 /* ExtensionDeprecated.h in Headers */ = {isa = PBXBuildFile; fileRef = 292DB15E19B461CA00A80320 /* ExtensionDeprecated.h */; }; 29394CF019B01DBA00D2DE1A /* UIWebView.h in Headers */ = {isa = PBXBuildFile; fileRef = 29394CEC19B01DBA00D2DE1A /* UIWebView.h */; }; 29394CF119B01DBA00D2DE1A /* UIWebView.h in Headers */ = {isa = PBXBuildFile; fileRef = 29394CEC19B01DBA00D2DE1A /* UIWebView.h */; }; 29394CF219B01DBA00D2DE1A /* UIWebView.mm in Sources */ = {isa = PBXBuildFile; fileRef = 29394CED19B01DBA00D2DE1A /* UIWebView.mm */; }; @@ -2304,6 +2314,18 @@ 2905FA1318CF08D100240AA3 /* UIWidget.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = UIWidget.cpp; sourceTree = ""; }; 2905FA1418CF08D100240AA3 /* UIWidget.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UIWidget.h; sourceTree = ""; }; 29080DEB191B82CE0066F8DF /* UIDeprecated.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = UIDeprecated.h; sourceTree = ""; }; + 292DB12F19B4574100A80320 /* UIEditBox.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = UIEditBox.cpp; sourceTree = ""; }; + 292DB13019B4574100A80320 /* UIEditBox.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UIEditBox.h; sourceTree = ""; }; + 292DB13119B4574100A80320 /* UIEditBoxImpl.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UIEditBoxImpl.h; sourceTree = ""; }; + 292DB13219B4574100A80320 /* UIEditBoxImplAndroid.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = UIEditBoxImplAndroid.cpp; sourceTree = ""; }; + 292DB13319B4574100A80320 /* UIEditBoxImplAndroid.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UIEditBoxImplAndroid.h; sourceTree = ""; }; + 292DB13419B4574100A80320 /* UIEditBoxImplIOS.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UIEditBoxImplIOS.h; sourceTree = ""; }; + 292DB13519B4574100A80320 /* UIEditBoxImplIOS.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = UIEditBoxImplIOS.mm; sourceTree = ""; }; + 292DB13619B4574100A80320 /* UIEditBoxImplMac.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UIEditBoxImplMac.h; sourceTree = ""; }; + 292DB13719B4574100A80320 /* UIEditBoxImplMac.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = UIEditBoxImplMac.mm; sourceTree = ""; }; + 292DB13819B4574100A80320 /* UIEditBoxImplNone.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = UIEditBoxImplNone.cpp; sourceTree = ""; }; + 292DB15D19B461CA00A80320 /* ExtensionDeprecated.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ExtensionDeprecated.cpp; sourceTree = ""; }; + 292DB15E19B461CA00A80320 /* ExtensionDeprecated.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ExtensionDeprecated.h; sourceTree = ""; }; 29394CEC19B01DBA00D2DE1A /* UIWebView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UIWebView.h; sourceTree = ""; }; 29394CED19B01DBA00D2DE1A /* UIWebView.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = UIWebView.mm; sourceTree = ""; }; 29394CEE19B01DBA00D2DE1A /* UIWebViewImpl_iOS.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UIWebViewImpl_iOS.h; sourceTree = ""; }; @@ -2405,18 +2427,6 @@ 46A168491807AF4E005B8026 /* CCControlUtils.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = CCControlUtils.h; sourceTree = ""; }; 46A1684A1807AF4E005B8026 /* CCInvocation.cpp */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; path = CCInvocation.cpp; sourceTree = ""; }; 46A1684B1807AF4E005B8026 /* CCInvocation.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = CCInvocation.h; sourceTree = ""; }; - 46A1684C1807AF4E005B8026 /* CCScale9Sprite.cpp */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; path = CCScale9Sprite.cpp; sourceTree = ""; }; - 46A1684D1807AF4E005B8026 /* CCScale9Sprite.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = CCScale9Sprite.h; sourceTree = ""; }; - 46A1684F1807AF4E005B8026 /* CCEditBox.cpp */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; path = CCEditBox.cpp; sourceTree = ""; }; - 46A168501807AF4E005B8026 /* CCEditBox.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = CCEditBox.h; sourceTree = ""; }; - 46A168511807AF4E005B8026 /* CCEditBoxImpl.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = CCEditBoxImpl.h; sourceTree = ""; }; - 46A168521807AF4E005B8026 /* CCEditBoxImplAndroid.cpp */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; path = CCEditBoxImplAndroid.cpp; sourceTree = ""; }; - 46A168531807AF4E005B8026 /* CCEditBoxImplAndroid.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = CCEditBoxImplAndroid.h; sourceTree = ""; }; - 46A168541807AF4E005B8026 /* CCEditBoxImplIOS.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = CCEditBoxImplIOS.h; sourceTree = ""; }; - 46A168551807AF4E005B8026 /* CCEditBoxImplIOS.mm */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.objcpp; path = CCEditBoxImplIOS.mm; sourceTree = ""; }; - 46A168581807AF4E005B8026 /* CCEditBoxImplNone.cpp */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; path = CCEditBoxImplNone.cpp; sourceTree = ""; }; - 46A1685B1807AF4E005B8026 /* CCEditBoxImplWin.cpp */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; path = CCEditBoxImplWin.cpp; sourceTree = ""; }; - 46A1685C1807AF4E005B8026 /* CCEditBoxImplWin.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = CCEditBoxImplWin.h; sourceTree = ""; }; 46A1685E1807AF4E005B8026 /* CCScrollView.cpp */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; lineEnding = 0; path = CCScrollView.cpp; sourceTree = ""; xcLanguageSpecificationIdentifier = xcode.lang.cpp; }; 46A1685F1807AF4E005B8026 /* CCScrollView.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = CCScrollView.h; sourceTree = ""; }; 46A168621807AF4E005B8026 /* CCTableView.cpp */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; path = CCTableView.cpp; sourceTree = ""; }; @@ -2867,8 +2877,6 @@ B276EF5C1988D1D500CD400F /* CCVertexIndexData.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCVertexIndexData.cpp; sourceTree = ""; }; B276EF5D1988D1D500CD400F /* CCVertexIndexBuffer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCVertexIndexBuffer.h; sourceTree = ""; }; B276EF5E1988D1D500CD400F /* CCVertexIndexBuffer.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCVertexIndexBuffer.cpp; sourceTree = ""; }; - B282B47C1980E02B00666787 /* CCEditBoxImplMac.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = CCEditBoxImplMac.mm; sourceTree = ""; }; - B282B47D1980E02B00666787 /* CCEditBoxImplMac.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCEditBoxImplMac.h; sourceTree = ""; }; B29594AF1926D5D9003EEF37 /* ccShader_3D_Color.frag */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.glsl; path = ccShader_3D_Color.frag; sourceTree = ""; }; B29594B01926D5D9003EEF37 /* ccShader_3D_ColorTex.frag */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.glsl; path = ccShader_3D_ColorTex.frag; sourceTree = ""; }; B29594B11926D5D9003EEF37 /* ccShader_3D_PositionTex.vert */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.glsl; path = ccShader_3D_PositionTex.vert; sourceTree = ""; }; @@ -3979,6 +3987,23 @@ path = ../cocos/ui; sourceTree = ""; }; + 292DB12E19B4574100A80320 /* UIEditBox */ = { + isa = PBXGroup; + children = ( + 292DB12F19B4574100A80320 /* UIEditBox.cpp */, + 292DB13019B4574100A80320 /* UIEditBox.h */, + 292DB13119B4574100A80320 /* UIEditBoxImpl.h */, + 292DB13219B4574100A80320 /* UIEditBoxImplAndroid.cpp */, + 292DB13319B4574100A80320 /* UIEditBoxImplAndroid.h */, + 292DB13419B4574100A80320 /* UIEditBoxImplIOS.h */, + 292DB13519B4574100A80320 /* UIEditBoxImplIOS.mm */, + 292DB13619B4574100A80320 /* UIEditBoxImplMac.h */, + 292DB13719B4574100A80320 /* UIEditBoxImplMac.mm */, + 292DB13819B4574100A80320 /* UIEditBoxImplNone.cpp */, + ); + path = UIEditBox; + sourceTree = ""; + }; 29CB8F501929D63600C841D6 /* layout */ = { isa = PBXGroup; children = ( @@ -4030,6 +4055,7 @@ 29CB8F531929D67D00C841D6 /* widgets */ = { isa = PBXGroup; children = ( + 292DB12E19B4574100A80320 /* UIEditBox */, 2905F9FE18CF08D000240AA3 /* UIListView.cpp */, 2905F9FF18CF08D000240AA3 /* UIListView.h */, 2905FA0018CF08D000240AA3 /* UILoadingBar.cpp */, @@ -4129,6 +4155,8 @@ 46A167981807AF4D005B8026 /* extensions */ = { isa = PBXGroup; children = ( + 292DB15D19B461CA00A80320 /* ExtensionDeprecated.cpp */, + 292DB15E19B461CA00A80320 /* ExtensionDeprecated.h */, 46A167D21807AF4D005B8026 /* cocos-ext.h */, 46A168321807AF4E005B8026 /* ExtensionMacros.h */, 1AAF5350180E305F000584C8 /* assets-manager */, @@ -4143,7 +4171,6 @@ isa = PBXGroup; children = ( 46A168341807AF4E005B8026 /* CCControlExtension */, - 46A1684E1807AF4E005B8026 /* CCEditBox */, 46A1685D1807AF4E005B8026 /* CCScrollView */, ); path = GUI; @@ -4175,31 +4202,10 @@ 46A168491807AF4E005B8026 /* CCControlUtils.h */, 46A1684A1807AF4E005B8026 /* CCInvocation.cpp */, 46A1684B1807AF4E005B8026 /* CCInvocation.h */, - 46A1684C1807AF4E005B8026 /* CCScale9Sprite.cpp */, - 46A1684D1807AF4E005B8026 /* CCScale9Sprite.h */, ); path = CCControlExtension; sourceTree = ""; }; - 46A1684E1807AF4E005B8026 /* CCEditBox */ = { - isa = PBXGroup; - children = ( - B282B47C1980E02B00666787 /* CCEditBoxImplMac.mm */, - B282B47D1980E02B00666787 /* CCEditBoxImplMac.h */, - 46A1684F1807AF4E005B8026 /* CCEditBox.cpp */, - 46A168501807AF4E005B8026 /* CCEditBox.h */, - 46A168511807AF4E005B8026 /* CCEditBoxImpl.h */, - 46A168521807AF4E005B8026 /* CCEditBoxImplAndroid.cpp */, - 46A168531807AF4E005B8026 /* CCEditBoxImplAndroid.h */, - 46A168541807AF4E005B8026 /* CCEditBoxImplIOS.h */, - 46A168551807AF4E005B8026 /* CCEditBoxImplIOS.mm */, - 46A168581807AF4E005B8026 /* CCEditBoxImplNone.cpp */, - 46A1685B1807AF4E005B8026 /* CCEditBoxImplWin.cpp */, - 46A1685C1807AF4E005B8026 /* CCEditBoxImplWin.h */, - ); - path = CCEditBox; - sourceTree = ""; - }; 46A1685D1807AF4E005B8026 /* CCScrollView */ = { isa = PBXGroup; children = ( @@ -4943,9 +4949,11 @@ 50ABBE851925AB6F00A911A9 /* ccFPSImages.h in Headers */, 15AE1A5319AAD40300C27E9E /* b2Draw.h in Headers */, 5034CA39191D591100CE6051 /* ccShader_PositionColorLengthTexture.frag in Headers */, + 292DB14B19B4574100A80320 /* UIEditBoxImplMac.h in Headers */, 50ABBE891925AB6F00A911A9 /* CCMap.h in Headers */, 50ABBE8D1925AB6F00A911A9 /* CCNS.h in Headers */, 50ABBEA51925AB6F00A911A9 /* CCScriptSupport.h in Headers */, + 292DB14519B4574100A80320 /* UIEditBoxImplAndroid.h in Headers */, 15AE1B9A19AADFDF00C27E9E /* UIHBox.h in Headers */, 15AE18EB19AAD35000C27E9E /* CCActionNode.h in Headers */, 15AE1A3819AAD3D500C27E9E /* b2Shape.h in Headers */, @@ -5020,7 +5028,6 @@ 15AE199919AAD39600C27E9E /* LoadingBarReader.h in Headers */, 15AE1A8F19AAD40300C27E9E /* b2RopeJoint.h in Headers */, 15AE18ED19AAD35000C27E9E /* CCActionObject.h in Headers */, - 15AE1C0C19AAE02D00C27E9E /* CCEditBoxImpl.h in Headers */, ED9C6A9618599AD8000A5232 /* CCNodeGrid.h in Headers */, 15AE18A719AAD33D00C27E9E /* CCScrollViewLoader.h in Headers */, 15AE184819AAD2F700C27E9E /* cocos3d.h in Headers */, @@ -5030,7 +5037,6 @@ 50ABBEA11925AB6F00A911A9 /* CCScheduler.h in Headers */, 15AE1B6219AADA9900C27E9E /* UIButton.h in Headers */, 50ABBDB71925AB4100A911A9 /* CCTexture2D.h in Headers */, - 15AE1BE119AAE01E00C27E9E /* CCScale9Sprite.h in Headers */, 50ABBE811925AB6F00A911A9 /* CCEventType.h in Headers */, 1A57008F180BC5A10088DEC7 /* CCActionTiledGrid.h in Headers */, 15AE19A319AAD39600C27E9E /* TextBMFontReader.h in Headers */, @@ -5175,6 +5181,7 @@ 15AE188519AAD33D00C27E9E /* CCBSequence.h in Headers */, 15AE1AE219AAD42500C27E9E /* cpDampedRotarySpring.h in Headers */, 5034CA49191D591100CE6051 /* ccShader_Label_df.frag in Headers */, + 292DB14119B4574100A80320 /* UIEditBoxImpl.h in Headers */, 1A01C68C18F57BE800EFE3A6 /* CCDeprecated.h in Headers */, 50ABBD561925AB0000A911A9 /* TransformUtils.h in Headers */, 299754F6193EC95400A54AC3 /* ObjectFactory.h in Headers */, @@ -5183,6 +5190,7 @@ 15AE18FB19AAD35000C27E9E /* CCColliderDetector.h in Headers */, 15AE19E119AAD3A700C27E9E /* Skeleton.h in Headers */, 1A570280180BCC900088DEC7 /* CCSprite.h in Headers */, + 292DB14719B4574100A80320 /* UIEditBoxImplIOS.h in Headers */, 15AE1A9119AAD40300C27E9E /* b2WeldJoint.h in Headers */, 15AE1A5419AAD40300C27E9E /* b2GrowableStack.h in Headers */, 15AE1B4E19AADA9900C27E9E /* UIListView.h in Headers */, @@ -5286,7 +5294,6 @@ 15AE1BCA19AAE01E00C27E9E /* CCControl.h in Headers */, 50ABBDBF1925AB4100A911A9 /* CCTextureCache.h in Headers */, 15AE186719AAD31D00C27E9E /* CDXMacOSXSupport.h in Headers */, - 15AE1C0A19AAE02500C27E9E /* CCEditBox.h in Headers */, B37510741823AC9F00B3BA6A /* CCPhysicsContactInfo_chipmunk.h in Headers */, 15AE1ADF19AAD42500C27E9E /* chipmunk_types.h in Headers */, 5034CA35191D591100CE6051 /* ccShader_PositionTexture.frag in Headers */, @@ -5336,6 +5343,7 @@ 15AE18A919AAD33D00C27E9E /* CCSpriteLoader.h in Headers */, 15AE198419AAD36400C27E9E /* WidgetReaderProtocol.h in Headers */, 50ABBEC91925AB6F00A911A9 /* firePngData.h in Headers */, + 292DB16119B461CA00A80320 /* ExtensionDeprecated.h in Headers */, 503DD8F51926B0DB00CD74DD /* CCIMEDelegate.h in Headers */, 50ABBD5A1925AB0000A911A9 /* Vec2.h in Headers */, 15AE1BDB19AAE01E00C27E9E /* CCControlSwitch.h in Headers */, @@ -5365,6 +5373,7 @@ 15AE1AEC19AAD42500C27E9E /* util.h in Headers */, 15AE19DD19AAD3A700C27E9E /* Json.h in Headers */, 15AE191A19AAD35000C27E9E /* CCSSceneReader.h in Headers */, + 292DB13F19B4574100A80320 /* UIEditBox.h in Headers */, 50ABBE671925AB6F00A911A9 /* CCEventListenerCustom.h in Headers */, 15AE18E219AAD35000C27E9E /* TriggerMng.h in Headers */, 15AE1B2B19AAD43700C27E9E /* prime.h in Headers */, @@ -5417,7 +5426,6 @@ 50ABBE771925AB6F00A911A9 /* CCEventListenerTouch.h in Headers */, 5034CA33191D591100CE6051 /* ccShader_PositionTexture_uColor.frag in Headers */, 50ABC0171926664800A911A9 /* CCImage.h in Headers */, - 15AE1C0E19AAE03400C27E9E /* CCEditBoxImplMac.h in Headers */, 15AE1AED19AAD42500C27E9E /* cpArbiter.h in Headers */, 50ABBDA91925AB4100A911A9 /* CCRenderCommand.h in Headers */, 50ABBD951925AB4100A911A9 /* CCGLProgramState.h in Headers */, @@ -5448,6 +5456,7 @@ 15AE183319AAD2F700C27E9E /* CCOBB.h in Headers */, 15AE18B119AAD33D00C27E9E /* CCBMemberVariableAssigner.h in Headers */, 15AE1AFA19AAD42500C27E9E /* cpConstraint.h in Headers */, + 292DB14019B4574100A80320 /* UIEditBox.h in Headers */, 50ABBD3B1925AB0000A911A9 /* CCAffineTransform.h in Headers */, 15AE1A0A19AAD3A700C27E9E /* CCSkeleton.h in Headers */, 5034CA38191D591100CE6051 /* ccShader_PositionColorLengthTexture.vert in Headers */, @@ -5456,6 +5465,7 @@ 46A171011807CECB005B8026 /* CCPhysicsJoint.h in Headers */, 46A170FD1807CECB005B8026 /* CCPhysicsBody.h in Headers */, 50ABBE9C1925AB6F00A911A9 /* CCRef.h in Headers */, + 292DB16219B461CA00A80320 /* ExtensionDeprecated.h in Headers */, 50ABBD961925AB4100A911A9 /* CCGLProgramState.h in Headers */, 46A171061807CECB005B8026 /* CCPhysicsWorld.h in Headers */, 50ABBDB41925AB4100A911A9 /* ccShaders.h in Headers */, @@ -5543,6 +5553,7 @@ 15AE19F819AAD3A700C27E9E /* Animation.h in Headers */, 1A5700A1180BC5D20088DEC7 /* CCNode.h in Headers */, 15AE181919AAD2F700C27E9E /* CCAttachNode.h in Headers */, + 292DB14C19B4574100A80320 /* UIEditBoxImplMac.h in Headers */, 15AE1BF019AAE01E00C27E9E /* CCControlHuePicker.h in Headers */, 15AE18B819AAD33D00C27E9E /* CCBSequenceProperty.h in Headers */, 503DD8E41926736A00CD74DD /* CCDirectorCaller.h in Headers */, @@ -5572,6 +5583,7 @@ 50ABBD5B1925AB0000A911A9 /* Vec2.h in Headers */, 50ABBD411925AB0000A911A9 /* CCMath.h in Headers */, 1A5701A0180BCB590088DEC7 /* CCFont.h in Headers */, + 292DB14819B4574100A80320 /* UIEditBoxImplIOS.h in Headers */, 15AE1A0819AAD3A700C27E9E /* BoneData.h in Headers */, 50ABBD9A1925AB4100A911A9 /* CCGLProgramStateCache.h in Headers */, 15AE181D19AAD2F700C27E9E /* CCBundle3D.h in Headers */, @@ -5603,6 +5615,7 @@ 15AE196B19AAD35100C27E9E /* DictionaryHelper.h in Headers */, 15AE1AA619AAD40300C27E9E /* b2Fixture.h in Headers */, 15AE1BBA19AADFF000C27E9E /* HttpClient.h in Headers */, + 292DB14619B4574100A80320 /* UIEditBoxImplAndroid.h in Headers */, 15AE1AF819AAD42500C27E9E /* chipmunk_types.h in Headers */, 15AE1B9419AADA9A00C27E9E /* GUIDefine.h in Headers */, 15AE183B19AAD2F700C27E9E /* CCRay.h in Headers */, @@ -5745,6 +5758,7 @@ 15AE1B8D19AADA9A00C27E9E /* UIScale9Sprite.h in Headers */, 15AE18AC19AAD33D00C27E9E /* CCBAnimationManager.h in Headers */, 15AE1A1A19AAD3A700C27E9E /* Skin.h in Headers */, + 292DB14219B4574100A80320 /* UIEditBoxImpl.h in Headers */, 1A570303180BCE890088DEC7 /* CCParallaxNode.h in Headers */, 50ABBE2A1925AB6F00A911A9 /* CCAutoreleasePool.h in Headers */, 1A57030F180BCF190088DEC7 /* CCComponent.h in Headers */, @@ -5766,7 +5780,6 @@ 15AE1BFE19AAE01E00C27E9E /* CCInvocation.h in Headers */, 15AE1A9E19AAD40300C27E9E /* b2StackAllocator.h in Headers */, 1A570357180BD0B00088DEC7 /* ioapi.h in Headers */, - 15AE1C0F19AAE03E00C27E9E /* CCEditBoxImplIOS.h in Headers */, 15AE1A1619AAD3A700C27E9E /* SkeletonData.h in Headers */, 50ABBD4B1925AB0000A911A9 /* Mat4.h in Headers */, 15AE1BBE19AADFF000C27E9E /* SocketIO.h in Headers */, @@ -5827,7 +5840,6 @@ 15AE198019AAD35700C27E9E /* CCTimeLine.h in Headers */, 50ABBD4F1925AB0000A911A9 /* MathUtil.h in Headers */, 1A01C69718F57BE800EFE3A6 /* CCInteger.h in Headers */, - 15AE1C0019AAE01E00C27E9E /* CCScale9Sprite.h in Headers */, 15AE1C0619AAE01E00C27E9E /* CCTableViewCell.h in Headers */, 15AE19AB19AAD39700C27E9E /* ListViewReader.h in Headers */, 50ABBEBE1925AB6F00A911A9 /* ccUtils.h in Headers */, @@ -5883,13 +5895,11 @@ B276EF641988D1D500CD400F /* CCVertexIndexBuffer.h in Headers */, 15AE1A0619AAD3A700C27E9E /* Bone.h in Headers */, ED9C6A9718599AD8000A5232 /* CCNodeGrid.h in Headers */, - 15AE1C0819AAE02500C27E9E /* CCEditBox.h in Headers */, 50ABC0201926664800A911A9 /* CCThread.h in Headers */, 15AE1B8519AADA9A00C27E9E /* UITextField.h in Headers */, 1A01C69318F57BE800EFE3A6 /* CCDouble.h in Headers */, 15AE184B19AAD30500C27E9E /* Export.h in Headers */, 15AE196019AAD35100C27E9E /* CCSpriteFrameCacheHelper.h in Headers */, - 15AE1C0B19AAE02D00C27E9E /* CCEditBoxImpl.h in Headers */, 50ABBE221925AB6F00A911A9 /* atitc.h in Headers */, 15AE1AB719AAD40300C27E9E /* b2ContactSolver.h in Headers */, 15AE193319AAD35100C27E9E /* CCActionNode.h in Headers */, @@ -6002,6 +6012,7 @@ 15AE1B1E19AAD43700C27E9E /* cpBody.c in Sources */, 15AE1BDE19AAE01E00C27E9E /* CCInvocation.cpp in Sources */, 3EA3EDBC1991CDFA00645534 /* CCCamera.cpp in Sources */, + 292DB14F19B4574100A80320 /* UIEditBoxImplNone.cpp in Sources */, 15AE199419AAD39600C27E9E /* LayoutReader.cpp in Sources */, 1A01C68A18F57BE800EFE3A6 /* CCDeprecated.cpp in Sources */, 1A1645B0191B726C008C7C7F /* ConvertUTF.c in Sources */, @@ -6033,7 +6044,6 @@ 15AE186319AAD31D00C27E9E /* CDAudioManager.m in Sources */, 15AE1B2219AAD43700C27E9E /* cpShape.c in Sources */, ED9C6A9418599AD8000A5232 /* CCNodeGrid.cpp in Sources */, - 15AE1C0D19AAE03400C27E9E /* CCEditBoxImplMac.mm in Sources */, 15AE1A2C19AAD3D500C27E9E /* b2DynamicTree.cpp in Sources */, 15AE184019AAD2F700C27E9E /* CCSprite3D.cpp in Sources */, 46A170E61807CECA005B8026 /* CCPhysicsBody.cpp in Sources */, @@ -6045,7 +6055,6 @@ 50ABBEBB1925AB6F00A911A9 /* ccUtils.cpp in Sources */, 15AE186A19AAD31D00C27E9E /* CocosDenshion.m in Sources */, 15AE198C19AAD36E00C27E9E /* CheckBoxReader.cpp in Sources */, - 15AE1C0919AAE02500C27E9E /* CCEditBox.cpp in Sources */, 15AE1B6319AADA9900C27E9E /* UICheckBox.cpp in Sources */, 15EFA211198A2BB5000C57D3 /* CCProtectedNode.cpp in Sources */, 50ABBEB71925AB6F00A911A9 /* ccUTF8.cpp in Sources */, @@ -6122,6 +6131,7 @@ 50ABBE391925AB6F00A911A9 /* CCData.cpp in Sources */, 1A57010E180BC8EE0088DEC7 /* CCDrawingPrimitives.cpp in Sources */, 50ABBED71925AB6F00A911A9 /* ZipUtils.cpp in Sources */, + 292DB14919B4574100A80320 /* UIEditBoxImplIOS.mm in Sources */, 15AE181019AAD2F700C27E9E /* CCAnimation3D.cpp in Sources */, 1A01C68418F57BE800EFE3A6 /* CCArray.cpp in Sources */, 1A570112180BC8EE0088DEC7 /* CCDrawNode.cpp in Sources */, @@ -6152,6 +6162,7 @@ 15AE1B5319AADA9900C27E9E /* UIRichText.cpp in Sources */, 15AE19DC19AAD3A700C27E9E /* Json.cpp in Sources */, 15AE1B2419AAD43700C27E9E /* cpSpaceComponent.c in Sources */, + 292DB13D19B4574100A80320 /* UIEditBox.cpp in Sources */, 50ABBE551925AB6F00A911A9 /* CCEventFocus.cpp in Sources */, 15AE1A8819AAD40300C27E9E /* b2PrismaticJoint.cpp in Sources */, 50ABBE491925AB6F00A911A9 /* CCEventAcceleration.cpp in Sources */, @@ -6200,6 +6211,8 @@ 1A570202180BCBD40088DEC7 /* CCClippingNode.cpp in Sources */, 1A570208180BCBDF0088DEC7 /* CCMotionStreak.cpp in Sources */, 1A570210180BCBF40088DEC7 /* CCProgressTimer.cpp in Sources */, + 292DB15F19B461CA00A80320 /* ExtensionDeprecated.cpp in Sources */, + 292DB14D19B4574100A80320 /* UIEditBoxImplMac.mm in Sources */, 50ABBDB51925AB4100A911A9 /* CCTexture2D.cpp in Sources */, 1A570214180BCBF40088DEC7 /* CCRenderTexture.cpp in Sources */, 15AE1BD019AAE01E00C27E9E /* CCControlHuePicker.cpp in Sources */, @@ -6218,7 +6231,6 @@ 1A570286180BCC900088DEC7 /* CCSpriteFrame.cpp in Sources */, B24AA989195A675C007B4522 /* CCFastTMXTiledMap.cpp in Sources */, 15AE199619AAD39600C27E9E /* ListViewReader.cpp in Sources */, - 15AE1BE019AAE01E00C27E9E /* CCScale9Sprite.cpp in Sources */, 50ABC0191926664800A911A9 /* CCSAXParser.cpp in Sources */, 15AE1B1419AAD43700C27E9E /* cpPinJoint.c in Sources */, 15AE189219AAD33D00C27E9E /* CCLayerGradientLoader.cpp in Sources */, @@ -6338,6 +6350,7 @@ 50ABC0631926664800A911A9 /* CCDevice.mm in Sources */, 15AE1A2819AAD3D500C27E9E /* b2Collision.cpp in Sources */, 15AE1B6719AADA9900C27E9E /* UIScale9Sprite.cpp in Sources */, + 292DB14319B4574100A80320 /* UIEditBoxImplAndroid.cpp in Sources */, 15AE1A5219AAD40300C27E9E /* b2Draw.cpp in Sources */, 50ABBE1F1925AB6F00A911A9 /* atitc.cpp in Sources */, 1A01C69818F57BE800EFE3A6 /* CCSet.cpp in Sources */, @@ -6451,6 +6464,7 @@ 46A171031807CECB005B8026 /* CCPhysicsShape.cpp in Sources */, 50ABC0161926664800A911A9 /* CCImage.cpp in Sources */, 1A01C6A518F58F7500EFE3A6 /* CCNotificationCenter.cpp in Sources */, + 292DB14E19B4574100A80320 /* UIEditBoxImplMac.mm in Sources */, 15AE1BFB19AAE01E00C27E9E /* CCControlUtils.cpp in Sources */, 15AE1B9019AADA9A00C27E9E /* UIWidget.cpp in Sources */, ED9C6A9518599AD8000A5232 /* CCNodeGrid.cpp in Sources */, @@ -6502,6 +6516,7 @@ 15AE198E19AAD36E00C27E9E /* CheckBoxReader.cpp in Sources */, 50ABBE621925AB6F00A911A9 /* CCEventListenerAcceleration.cpp in Sources */, 15AE1AB619AAD40300C27E9E /* b2ContactSolver.cpp in Sources */, + 292DB13E19B4574100A80320 /* UIEditBox.cpp in Sources */, 3E6176681960F89B00DE83F5 /* CCController-iOS.mm in Sources */, 15AE19EF19AAD3A700C27E9E /* SkeletonBounds.cpp in Sources */, 15AE18B219AAD33D00C27E9E /* CCBReader.cpp in Sources */, @@ -6547,6 +6562,7 @@ 15AE1B4319AAD43700C27E9E /* cpSpaceHash.c in Sources */, 15AE1A1D19AAD3A700C27E9E /* SlotData.cpp in Sources */, 50ABBD551925AB0000A911A9 /* TransformUtils.cpp in Sources */, + 292DB14419B4574100A80320 /* UIEditBoxImplAndroid.cpp in Sources */, 15AE193619AAD35100C27E9E /* CCArmature.cpp in Sources */, 1A57007A180BC5A10088DEC7 /* CCActionInstant.cpp in Sources */, 15AE1AC419AAD40300C27E9E /* b2FrictionJoint.cpp in Sources */, @@ -6566,7 +6582,6 @@ 1A570086180BC5A10088DEC7 /* CCActionPageTurn3D.cpp in Sources */, 15AE1AB819AAD40300C27E9E /* b2EdgeAndCircleContact.cpp in Sources */, 15AE19FF19AAD3A700C27E9E /* AtlasAttachmentLoader.cpp in Sources */, - 15AE1C0719AAE02500C27E9E /* CCEditBox.cpp in Sources */, 1A57008A180BC5A10088DEC7 /* CCActionProgressTimer.cpp in Sources */, 15AE18AF19AAD33D00C27E9E /* CCBKeyframe.cpp in Sources */, 15AE19FB19AAD3A700C27E9E /* AnimationStateData.cpp in Sources */, @@ -6596,6 +6611,7 @@ 15AE195F19AAD35100C27E9E /* CCSpriteFrameCacheHelper.cpp in Sources */, 15AE193019AAD35100C27E9E /* CCActionManagerEx.cpp in Sources */, 503DD8E21926736A00CD74DD /* CCCommon.mm in Sources */, + 292DB14A19B4574100A80320 /* UIEditBoxImplIOS.mm in Sources */, 15AE1A9419AAD40300C27E9E /* b2BlockAllocator.cpp in Sources */, 15AE1B4419AAD43700C27E9E /* cpSpaceQuery.c in Sources */, 15AE1A4D19AAD3D500C27E9E /* b2PolygonShape.cpp in Sources */, @@ -6612,6 +6628,7 @@ 15AE1AB019AAD40300C27E9E /* b2ChainAndPolygonContact.cpp in Sources */, 1A5701B2180BCB590088DEC7 /* CCFontFNT.cpp in Sources */, 1A5701B6180BCB590088DEC7 /* CCFontFreeType.cpp in Sources */, + 292DB16019B461CA00A80320 /* ExtensionDeprecated.cpp in Sources */, 50ABBEAC1925AB6F00A911A9 /* ccTypes.cpp in Sources */, 15AE196A19AAD35100C27E9E /* DictionaryHelper.cpp in Sources */, 15AE1A3F19AAD3D500C27E9E /* b2Collision.cpp in Sources */, @@ -6672,6 +6689,7 @@ 15AE194019AAD35100C27E9E /* CCBone.cpp in Sources */, 1A570215180BCBF40088DEC7 /* CCRenderTexture.cpp in Sources */, 1A570222180BCC1A0088DEC7 /* CCParticleBatchNode.cpp in Sources */, + 292DB15019B4574100A80320 /* UIEditBoxImplNone.cpp in Sources */, 15AE19F119AAD3A700C27E9E /* Event.cpp in Sources */, 15AE185F19AAD31200C27E9E /* SimpleAudioEngine.mm in Sources */, 15AE1BE819AAE01E00C27E9E /* CCControl.cpp in Sources */, @@ -6681,7 +6699,6 @@ 15AE182919AAD2F700C27E9E /* CCMeshSkin.cpp in Sources */, 15AE1BBD19AADFF000C27E9E /* SocketIO.cpp in Sources */, 15AE1A4319AAD3D500C27E9E /* b2DynamicTree.cpp in Sources */, - 15AE1BFF19AAE01E00C27E9E /* CCScale9Sprite.cpp in Sources */, 15AE1A3A19AAD3D500C27E9E /* b2BroadPhase.cpp in Sources */, 15AE19B619AAD39700C27E9E /* TextBMFontReader.cpp in Sources */, 15AE1BFD19AAE01E00C27E9E /* CCInvocation.cpp in Sources */, @@ -6715,7 +6732,6 @@ 15AE19AE19AAD39700C27E9E /* PageViewReader.cpp in Sources */, 3EA3EDBD1991CDFA00645534 /* CCCamera.cpp in Sources */, 1A570297180BCCAB0088DEC7 /* CCAnimationCache.cpp in Sources */, - 15AE1C1019AAE03E00C27E9E /* CCEditBoxImplIOS.mm in Sources */, 50ABBE321925AB6F00A911A9 /* CCConfiguration.cpp in Sources */, 15AE1A9F19AAD40300C27E9E /* b2Timer.cpp in Sources */, 15AE1AD419AAD40300C27E9E /* b2WeldJoint.cpp in Sources */, diff --git a/build/cocos2d_tests.xcodeproj/project.pbxproj b/build/cocos2d_tests.xcodeproj/project.pbxproj index 2029a5d0ff..dec67dde2c 100644 --- a/build/cocos2d_tests.xcodeproj/project.pbxproj +++ b/build/cocos2d_tests.xcodeproj/project.pbxproj @@ -472,8 +472,6 @@ 1AC35BEE18CECF0C00F37B72 /* CCControlStepperTest.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1AC35A7318CECF0B00F37B72 /* CCControlStepperTest.cpp */; }; 1AC35BEF18CECF0C00F37B72 /* CCControlSwitchTest.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1AC35A7618CECF0B00F37B72 /* CCControlSwitchTest.cpp */; }; 1AC35BF018CECF0C00F37B72 /* CCControlSwitchTest.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1AC35A7618CECF0B00F37B72 /* CCControlSwitchTest.cpp */; }; - 1AC35BF118CECF0C00F37B72 /* EditBoxTest.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1AC35A7918CECF0B00F37B72 /* EditBoxTest.cpp */; }; - 1AC35BF218CECF0C00F37B72 /* EditBoxTest.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1AC35A7918CECF0B00F37B72 /* EditBoxTest.cpp */; }; 1AC35BF318CECF0C00F37B72 /* ExtensionsTest.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1AC35A7B18CECF0B00F37B72 /* ExtensionsTest.cpp */; }; 1AC35BF418CECF0C00F37B72 /* ExtensionsTest.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1AC35A7B18CECF0B00F37B72 /* ExtensionsTest.cpp */; }; 1AC35BF518CECF0C00F37B72 /* HttpClientTest.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1AC35A7E18CECF0B00F37B72 /* HttpClientTest.cpp */; }; @@ -484,8 +482,6 @@ 1AC35BFA18CECF0C00F37B72 /* WebSocketTest.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1AC35A8218CECF0B00F37B72 /* WebSocketTest.cpp */; }; 1AC35BFB18CECF0C00F37B72 /* NotificationCenterTest.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1AC35A8518CECF0B00F37B72 /* NotificationCenterTest.cpp */; }; 1AC35BFC18CECF0C00F37B72 /* NotificationCenterTest.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1AC35A8518CECF0B00F37B72 /* NotificationCenterTest.cpp */; }; - 1AC35BFD18CECF0C00F37B72 /* Scale9SpriteTest.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1AC35A8818CECF0B00F37B72 /* Scale9SpriteTest.cpp */; }; - 1AC35BFE18CECF0C00F37B72 /* Scale9SpriteTest.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1AC35A8818CECF0B00F37B72 /* Scale9SpriteTest.cpp */; }; 1AC35BFF18CECF0C00F37B72 /* CustomTableViewCell.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1AC35A8B18CECF0B00F37B72 /* CustomTableViewCell.cpp */; }; 1AC35C0018CECF0C00F37B72 /* CustomTableViewCell.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1AC35A8B18CECF0B00F37B72 /* CustomTableViewCell.cpp */; }; 1AC35C0118CECF0C00F37B72 /* TableViewTestScene.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1AC35A8D18CECF0B00F37B72 /* TableViewTestScene.cpp */; }; @@ -863,6 +859,8 @@ 29080DE6191B595E0066F8DF /* UIWidgetAddNodeTest_Editor.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 29080D8B191B595E0066F8DF /* UIWidgetAddNodeTest_Editor.cpp */; }; 290E94B5196FC16900694919 /* CocostudioParserTest.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 290E94B3196FC16900694919 /* CocostudioParserTest.cpp */; }; 290E94B6196FC16900694919 /* CocostudioParserTest.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 290E94B3196FC16900694919 /* CocostudioParserTest.cpp */; }; + 292CF01419A1965E00E8E6A0 /* UIEditBoxTest.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 292CF01219A1965E00E8E6A0 /* UIEditBoxTest.cpp */; }; + 292CF01519A1965E00E8E6A0 /* UIEditBoxTest.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 292CF01219A1965E00E8E6A0 /* UIEditBoxTest.cpp */; }; 295824591987415900F9746D /* UIScale9SpriteTest.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 295824571987415900F9746D /* UIScale9SpriteTest.cpp */; }; 2958245A1987415900F9746D /* UIScale9SpriteTest.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 295824571987415900F9746D /* UIScale9SpriteTest.cpp */; }; 298D7F6F19AC31F300FF096D /* UIWebViewTest.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 298D7F6D19AC31F300FF096D /* UIWebViewTest.cpp */; }; @@ -2555,8 +2553,6 @@ 1AC35A7418CECF0B00F37B72 /* CCControlStepperTest.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCControlStepperTest.h; sourceTree = ""; }; 1AC35A7618CECF0B00F37B72 /* CCControlSwitchTest.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CCControlSwitchTest.cpp; sourceTree = ""; }; 1AC35A7718CECF0B00F37B72 /* CCControlSwitchTest.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CCControlSwitchTest.h; sourceTree = ""; }; - 1AC35A7918CECF0B00F37B72 /* EditBoxTest.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = EditBoxTest.cpp; sourceTree = ""; }; - 1AC35A7A18CECF0B00F37B72 /* EditBoxTest.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = EditBoxTest.h; sourceTree = ""; }; 1AC35A7B18CECF0B00F37B72 /* ExtensionsTest.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ExtensionsTest.cpp; sourceTree = ""; }; 1AC35A7C18CECF0B00F37B72 /* ExtensionsTest.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ExtensionsTest.h; sourceTree = ""; }; 1AC35A7E18CECF0B00F37B72 /* HttpClientTest.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = HttpClientTest.cpp; sourceTree = ""; }; @@ -2567,8 +2563,6 @@ 1AC35A8318CECF0B00F37B72 /* WebSocketTest.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WebSocketTest.h; sourceTree = ""; }; 1AC35A8518CECF0B00F37B72 /* NotificationCenterTest.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = NotificationCenterTest.cpp; sourceTree = ""; }; 1AC35A8618CECF0B00F37B72 /* NotificationCenterTest.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = NotificationCenterTest.h; sourceTree = ""; }; - 1AC35A8818CECF0B00F37B72 /* Scale9SpriteTest.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = Scale9SpriteTest.cpp; sourceTree = ""; }; - 1AC35A8918CECF0B00F37B72 /* Scale9SpriteTest.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Scale9SpriteTest.h; sourceTree = ""; }; 1AC35A8B18CECF0B00F37B72 /* CustomTableViewCell.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CustomTableViewCell.cpp; sourceTree = ""; }; 1AC35A8C18CECF0B00F37B72 /* CustomTableViewCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CustomTableViewCell.h; sourceTree = ""; }; 1AC35A8D18CECF0B00F37B72 /* TableViewTestScene.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = TableViewTestScene.cpp; sourceTree = ""; }; @@ -2886,6 +2880,8 @@ 29080D8C191B595E0066F8DF /* UIWidgetAddNodeTest_Editor.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UIWidgetAddNodeTest_Editor.h; sourceTree = ""; }; 290E94B3196FC16900694919 /* CocostudioParserTest.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = CocostudioParserTest.cpp; path = ../CocostudioParserTest.cpp; sourceTree = ""; }; 290E94B4196FC16900694919 /* CocostudioParserTest.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CocostudioParserTest.h; path = ../CocostudioParserTest.h; sourceTree = ""; }; + 292CF01219A1965E00E8E6A0 /* UIEditBoxTest.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = UIEditBoxTest.cpp; sourceTree = ""; }; + 292CF01319A1965E00E8E6A0 /* UIEditBoxTest.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UIEditBoxTest.h; sourceTree = ""; }; 295824571987415900F9746D /* UIScale9SpriteTest.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = UIScale9SpriteTest.cpp; sourceTree = ""; }; 295824581987415900F9746D /* UIScale9SpriteTest.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UIScale9SpriteTest.h; sourceTree = ""; }; 298D7F6D19AC31F300FF096D /* UIWebViewTest.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = UIWebViewTest.cpp; path = UIWebViewTest/UIWebViewTest.cpp; sourceTree = ""; }; @@ -5773,12 +5769,10 @@ 1AC359DF18CECF0B00F37B72 /* CocoStudioComponentsTest */, 1AC35A5818CECF0B00F37B72 /* CocoStudioSceneTest */, 1AC35A6118CECF0B00F37B72 /* ControlExtensionTest */, - 1AC35A7818CECF0B00F37B72 /* EditBoxTest */, 1AC35A7B18CECF0B00F37B72 /* ExtensionsTest.cpp */, 1AC35A7C18CECF0B00F37B72 /* ExtensionsTest.h */, 1AC35A7D18CECF0B00F37B72 /* NetworkTest */, 1AC35A8418CECF0B00F37B72 /* NotificationCenterTest */, - 1AC35A8718CECF0B00F37B72 /* Scale9SpriteTest */, 1AC35A8A18CECF0B00F37B72 /* TableViewTest */, ); path = ExtensionsTest; @@ -6020,15 +6014,6 @@ path = CCControlSwitchTest; sourceTree = ""; }; - 1AC35A7818CECF0B00F37B72 /* EditBoxTest */ = { - isa = PBXGroup; - children = ( - 1AC35A7918CECF0B00F37B72 /* EditBoxTest.cpp */, - 1AC35A7A18CECF0B00F37B72 /* EditBoxTest.h */, - ); - path = EditBoxTest; - sourceTree = ""; - }; 1AC35A7D18CECF0B00F37B72 /* NetworkTest */ = { isa = PBXGroup; children = ( @@ -6051,15 +6036,6 @@ path = NotificationCenterTest; sourceTree = ""; }; - 1AC35A8718CECF0B00F37B72 /* Scale9SpriteTest */ = { - isa = PBXGroup; - children = ( - 1AC35A8818CECF0B00F37B72 /* Scale9SpriteTest.cpp */, - 1AC35A8918CECF0B00F37B72 /* Scale9SpriteTest.h */, - ); - path = Scale9SpriteTest; - sourceTree = ""; - }; 1AC35A8A18CECF0B00F37B72 /* TableViewTest */ = { isa = PBXGroup; children = ( @@ -7006,6 +6982,8 @@ 298D7F6C19AC31C000FF096D /* UIWebViewTest */, 295824571987415900F9746D /* UIScale9SpriteTest.cpp */, 295824581987415900F9746D /* UIScale9SpriteTest.h */, + 292CF01219A1965E00E8E6A0 /* UIEditBoxTest.cpp */, + 292CF01319A1965E00E8E6A0 /* UIEditBoxTest.h */, 29080D1F191B595E0066F8DF /* CocosGUIScene.cpp */, 29080D20191B595E0066F8DF /* CocosGUIScene.h */, 29080D37191B595E0066F8DF /* GUIEditorTest.cpp */, @@ -7970,7 +7948,6 @@ 1AC35B6718CECF0C00F37B72 /* AnimationsTestLayer.cpp in Sources */, 29080DB7191B595E0066F8DF /* UIListViewTest_Editor.cpp in Sources */, 1AC35BF918CECF0C00F37B72 /* WebSocketTest.cpp in Sources */, - 1AC35BF118CECF0C00F37B72 /* EditBoxTest.cpp in Sources */, 1AC35B3918CECF0C00F37B72 /* Bug-1174.cpp in Sources */, 1AC35BE318CECF0C00F37B72 /* CCControlColourPickerTest.cpp in Sources */, 29080DB1191B595E0066F8DF /* UILayoutTest.cpp in Sources */, @@ -8021,7 +7998,6 @@ 29080DD1191B595E0066F8DF /* UISliderTest_Editor.cpp in Sources */, 1AC35B2718CECF0C00F37B72 /* ActionsTest.cpp in Sources */, 1AC35C4918CECF0C00F37B72 /* ShaderTest.cpp in Sources */, - 1AC35BFD18CECF0C00F37B72 /* Scale9SpriteTest.cpp in Sources */, 1AC35B4318CECF0C00F37B72 /* Bug-624.cpp in Sources */, 1AC35BF718CECF0C00F37B72 /* SocketIOTest.cpp in Sources */, 1AC35C4F18CECF0C00F37B72 /* SpriteTest.cpp in Sources */, @@ -8040,6 +8016,7 @@ 1AC35B7D18CECF0C00F37B72 /* PlayerController.cpp in Sources */, 29080D9F191B595E0066F8DF /* CustomReader.cpp in Sources */, 1AC35BE718CECF0C00F37B72 /* CCControlScene.cpp in Sources */, + 292CF01419A1965E00E8E6A0 /* UIEditBoxTest.cpp in Sources */, 29080DBF191B595E0066F8DF /* UIPageViewTest_Editor.cpp in Sources */, 1AC35B5F18CECF0C00F37B72 /* DataVisitorTest.cpp in Sources */, 1AC35B5D18CECF0C00F37B72 /* CurrentLanguageTest.cpp in Sources */, @@ -8166,7 +8143,6 @@ 1AC35B6818CECF0C00F37B72 /* AnimationsTestLayer.cpp in Sources */, 29080D8E191B595E0066F8DF /* CocosGUIScene.cpp in Sources */, 1AC35BFA18CECF0C00F37B72 /* WebSocketTest.cpp in Sources */, - 1AC35BF218CECF0C00F37B72 /* EditBoxTest.cpp in Sources */, 38FA2E74194AEBE100FF2BE4 /* ActionTimelineTestScene.cpp in Sources */, 2958245A1987415900F9746D /* UIScale9SpriteTest.cpp in Sources */, 1AC35B3A18CECF0C00F37B72 /* Bug-1174.cpp in Sources */, @@ -8221,9 +8197,9 @@ 1AC35C0618CECF0C00F37B72 /* FontTest.cpp in Sources */, 1AC35C3818CECF0C00F37B72 /* PerformanceTest.cpp in Sources */, 1F33635018E37E840074764D /* RefPtrTest.cpp in Sources */, + 292CF01519A1965E00E8E6A0 /* UIEditBoxTest.cpp in Sources */, 1AC35B2818CECF0C00F37B72 /* ActionsTest.cpp in Sources */, 1AC35C4A18CECF0C00F37B72 /* ShaderTest.cpp in Sources */, - 1AC35BFE18CECF0C00F37B72 /* Scale9SpriteTest.cpp in Sources */, C04F935B1941B05400E9FEAB /* TileMapTest2.cpp in Sources */, 1AC35B4418CECF0C00F37B72 /* Bug-624.cpp in Sources */, 1AC35BF818CECF0C00F37B72 /* SocketIOTest.cpp in Sources */, diff --git a/cocos/2d/CCTransition.cpp b/cocos/2d/CCTransition.cpp index ce8fccc533..97f734d6ae 100644 --- a/cocos/2d/CCTransition.cpp +++ b/cocos/2d/CCTransition.cpp @@ -1278,7 +1278,7 @@ void TransitionCrossFade::onEnter() LayerColor* layer = LayerColor::create(color); // create the first render texture for inScene - RenderTexture* inTexture = RenderTexture::create((int)size.width, (int)size.height); + RenderTexture* inTexture = RenderTexture::create((int)size.width, (int)size.height,Texture2D::PixelFormat::RGBA8888,GL_DEPTH24_STENCIL8); if (nullptr == inTexture) { @@ -1295,7 +1295,7 @@ void TransitionCrossFade::onEnter() inTexture->end(); // create the second render texture for outScene - RenderTexture* outTexture = RenderTexture::create((int)size.width, (int)size.height); + RenderTexture* outTexture = RenderTexture::create((int)size.width, (int)size.height,Texture2D::PixelFormat::RGBA8888,GL_DEPTH24_STENCIL8); outTexture->getSprite()->setAnchorPoint( Vec2(0.5f,0.5f) ); outTexture->setPosition(size.width/2, size.height/2); outTexture->setAnchorPoint( Vec2(0.5f,0.5f) ); diff --git a/cocos/2d/CCTransitionProgress.cpp b/cocos/2d/CCTransitionProgress.cpp index de0e7f8ce3..ddd0710af6 100644 --- a/cocos/2d/CCTransitionProgress.cpp +++ b/cocos/2d/CCTransitionProgress.cpp @@ -71,7 +71,7 @@ void TransitionProgress::onEnter() Size size = Director::getInstance()->getWinSize(); // create the second render texture for outScene - RenderTexture *texture = RenderTexture::create((int)size.width, (int)size.height); + RenderTexture *texture = RenderTexture::create((int)size.width, (int)size.height,Texture2D::PixelFormat::RGBA8888,GL_DEPTH24_STENCIL8); texture->getSprite()->setAnchorPoint(Vec2(0.5f,0.5f)); texture->setPosition(size.width/2, size.height/2); texture->setAnchorPoint(Vec2(0.5f,0.5f)); diff --git a/cocos/2d/libcocos2d.vcxproj b/cocos/2d/libcocos2d.vcxproj index 9fdc34eb21..7c61bf42bb 100644 --- a/cocos/2d/libcocos2d.vcxproj +++ b/cocos/2d/libcocos2d.vcxproj @@ -24,7 +24,7 @@ v110 v110_xp v120 - v120_xp + v110_xp DynamicLibrary @@ -33,7 +33,7 @@ v110 v110_xp v120 - v120_xp + v110_xp @@ -192,15 +192,11 @@ xcopy /Y /Q "$(ProjectDir)..\..\external\win32-specific\spine\prebuilt\release-l - - - - @@ -409,9 +405,12 @@ xcopy /Y /Q "$(ProjectDir)..\..\external\win32-specific\spine\prebuilt\release-l + + + @@ -516,16 +515,11 @@ xcopy /Y /Q "$(ProjectDir)..\..\external\win32-specific\spine\prebuilt\release-l - - - - - @@ -786,9 +780,13 @@ xcopy /Y /Q "$(ProjectDir)..\..\external\win32-specific\spine\prebuilt\release-l + + + + diff --git a/cocos/2d/libcocos2d.vcxproj.filters b/cocos/2d/libcocos2d.vcxproj.filters index 1a5d9f9b25..d918da6cc1 100644 --- a/cocos/2d/libcocos2d.vcxproj.filters +++ b/cocos/2d/libcocos2d.vcxproj.filters @@ -76,15 +76,9 @@ {b27aba95-51a2-413c-8570-0aff9adf2b6b} - - {220cf2ee-61b0-40cf-a88a-8627e4e609f1} - {a1f539bc-d5be-4224-a4d2-01c0b6f17d6e} - - {dc45cd54-4576-4401-87b7-a276f91a45bd} - {1de7fce7-0dee-4571-8fcd-43eb617aaf8b} @@ -211,6 +205,12 @@ {8579ed15-b266-4f80-818d-a3a9251c4248} + + {89eb6312-dc7f-4fda-b9b2-ab67c31ddd55} + + + {118d80ca-ccf2-480c-b87d-25220af23440} + @@ -787,42 +787,6 @@ extension\AssetsManager - - extension\GUI\CCControlExtension - - - extension\GUI\CCControlExtension - - - extension\GUI\CCControlExtension - - - extension\GUI\CCControlExtension - - - extension\GUI\CCControlExtension - - - extension\GUI\CCControlExtension - - - extension\GUI\CCControlExtension - - - extension\GUI\CCControlExtension - - - extension\GUI\CCControlExtension - - - extension\GUI\CCControlExtension - - - extension\GUI\CCControlExtension - - - extension\GUI\CCControlExtension - extension\GUI\CCScrollView @@ -832,15 +796,6 @@ extension\GUI\CCScrollView - - extension\GUI\CCEditBox - - - extension\GUI\CCEditBox - - - extension\GUI\CCEditBox - extension\physics_nodes @@ -1165,6 +1120,48 @@ cocosbuilder\Source Files + + ui\UIWidgets\EditBox + + + ui\UIWidgets\EditBox + + + extension\GUI\CCControlExtensions + + + extension\GUI\CCControlExtensions + + + extension\GUI\CCControlExtensions + + + extension\GUI\CCControlExtensions + + + extension\GUI\CCControlExtensions + + + extension\GUI\CCControlExtensions + + + extension\GUI\CCControlExtensions + + + extension\GUI\CCControlExtensions + + + extension\GUI\CCControlExtensions + + + extension\GUI\CCControlExtensions + + + extension\GUI\CCControlExtensions + + + ui\UIWidgets\EditBox + @@ -1825,45 +1822,6 @@ extension\AssetsManager - - extension\GUI\CCControlExtension - - - extension\GUI\CCControlExtension - - - extension\GUI\CCControlExtension - - - extension\GUI\CCControlExtension - - - extension\GUI\CCControlExtension - - - extension\GUI\CCControlExtension - - - extension\GUI\CCControlExtension - - - extension\GUI\CCControlExtension - - - extension\GUI\CCControlExtension - - - extension\GUI\CCControlExtension - - - extension\GUI\CCControlExtension - - - extension\GUI\CCControlExtension - - - extension\GUI\CCControlExtension - extension\GUI\CCScrollView @@ -1873,18 +1831,6 @@ extension\GUI\CCScrollView - - extension\GUI\CCEditBox - - - extension\GUI\CCEditBox - - - extension\GUI\CCEditBox - - - extension\GUI\CCEditBox - extension\physics_nodes @@ -2290,6 +2236,54 @@ cocosbuilder\Header Files + + ui\UIWidgets\EditBox + + + ui\UIWidgets\EditBox + + + ui\UIWidgets\EditBox + + + extension\GUI\CCControlExtensions + + + extension\GUI\CCControlExtensions + + + extension\GUI\CCControlExtensions + + + extension\GUI\CCControlExtensions + + + extension\GUI\CCControlExtensions + + + extension\GUI\CCControlExtensions + + + extension\GUI\CCControlExtensions + + + extension\GUI\CCControlExtensions + + + extension\GUI\CCControlExtensions + + + extension\GUI\CCControlExtensions + + + extension\GUI\CCControlExtensions + + + extension\GUI\CCControlExtensions + + + ui\UIWidgets\EditBox + diff --git a/cocos/CMakeLists.txt b/cocos/CMakeLists.txt index c454b4f63a..ac588ab6a9 100644 --- a/cocos/CMakeLists.txt +++ b/cocos/CMakeLists.txt @@ -90,9 +90,6 @@ list(REMOVE_ITEM cocos2d_source_files "${CMAKE_CURRENT_SOURCE_DIR}/storage/local-storage/LocalStorageAndroid.cpp" "${CMAKE_CURRENT_SOURCE_DIR}/base/CCEventController.cpp" "${CMAKE_CURRENT_SOURCE_DIR}/base/CCEventListenerController.cpp" - "${CMAKE_CURRENT_SOURCE_DIR}/../extensions/GUI/CCEditBox/CCEditBoxImplAndroid.cpp" - "${CMAKE_CURRENT_SOURCE_DIR}/../extensions/GUI/CCEditBox/CCEditBoxImplWin.cpp" - "${CMAKE_CURRENT_SOURCE_DIR}/../extensions/GUI/CCEditBox/CCEditBoxImplWp8.cpp" "${CMAKE_CURRENT_SOURCE_DIR}/editor-support/cocostudio/proj.wp8/pch.cpp" "${CMAKE_CURRENT_SOURCE_DIR}/../extensions/proj.wp8/pch.cpp") diff --git a/cocos/editor-support/cocosbuilder/CCScale9SpriteLoader.cpp b/cocos/editor-support/cocosbuilder/CCScale9SpriteLoader.cpp index 2089898058..186708fc34 100644 --- a/cocos/editor-support/cocosbuilder/CCScale9SpriteLoader.cpp +++ b/cocos/editor-support/cocosbuilder/CCScale9SpriteLoader.cpp @@ -19,7 +19,7 @@ namespace cocosbuilder { void Scale9SpriteLoader::onHandlePropTypeSpriteFrame(Node * pNode, Node * pParent, const char * pPropertyName, SpriteFrame * pSpriteFrame, CCBReader * ccbReader) { if(strcmp(pPropertyName, PROPERTY_SPRITEFRAME) == 0) { - ((Scale9Sprite *)pNode)->setSpriteFrame(pSpriteFrame); + ((cocos2d::ui::Scale9Sprite *)pNode)->setSpriteFrame(pSpriteFrame); } else { NodeLoader::onHandlePropTypeSpriteFrame(pNode, pParent, pPropertyName, pSpriteFrame, ccbReader); } @@ -27,7 +27,7 @@ void Scale9SpriteLoader::onHandlePropTypeSpriteFrame(Node * pNode, Node * pParen void Scale9SpriteLoader::onHandlePropTypeColor3(Node * pNode, Node * pParent, const char * pPropertyName, Color3B pColor3B, CCBReader * ccbReader) { if(strcmp(pPropertyName, PROPERTY_COLOR) == 0) { - ((Scale9Sprite *)pNode)->setColor(pColor3B); + ((cocos2d::ui::Scale9Sprite *)pNode)->setColor(pColor3B); } else { NodeLoader::onHandlePropTypeColor3(pNode, pParent, pPropertyName, pColor3B, ccbReader); } @@ -35,7 +35,7 @@ void Scale9SpriteLoader::onHandlePropTypeColor3(Node * pNode, Node * pParent, co void Scale9SpriteLoader::onHandlePropTypeByte(Node * pNode, Node * pParent, const char * pPropertyName, unsigned char pByte, CCBReader * ccbReader) { if(strcmp(pPropertyName, PROPERTY_OPACITY) == 0) { - ((Scale9Sprite *)pNode)->setOpacity(pByte); + ((cocos2d::ui::Scale9Sprite *)pNode)->setOpacity(pByte); } else { NodeLoader::onHandlePropTypeByte(pNode, pParent, pPropertyName, pByte, ccbReader); } @@ -54,7 +54,7 @@ void Scale9SpriteLoader::onHandlePropTypeSize(Node * pNode, Node * pParent, cons if(strcmp(pPropertyName, PROPERTY_CONTENTSIZE) == 0) { //((Scale9Sprite *)pNode)->setContentSize(pSize); } else if(strcmp(pPropertyName, PROPERTY_PREFEREDSIZE) == 0) { - ((Scale9Sprite *)pNode)->setPreferredSize(pSize); + ((cocos2d::ui::Scale9Sprite *)pNode)->setPreferredSize(pSize); } else { NodeLoader::onHandlePropTypeSize(pNode, pParent, pPropertyName, pSize, ccbReader); } @@ -62,13 +62,13 @@ void Scale9SpriteLoader::onHandlePropTypeSize(Node * pNode, Node * pParent, cons void Scale9SpriteLoader::onHandlePropTypeFloat(Node * pNode, Node * pParent, const char * pPropertyName, float pFloat, CCBReader * ccbReader) { if(strcmp(pPropertyName, PROPERTY_INSETLEFT) == 0) { - ((Scale9Sprite *)pNode)->setInsetLeft(pFloat); + ((cocos2d::ui::Scale9Sprite *)pNode)->setInsetLeft(pFloat); } else if(strcmp(pPropertyName, PROPERTY_INSETTOP) == 0) { - ((Scale9Sprite *)pNode)->setInsetTop(pFloat); + ((cocos2d::ui::Scale9Sprite *)pNode)->setInsetTop(pFloat); } else if(strcmp(pPropertyName, PROPERTY_INSETRIGHT) == 0) { - ((Scale9Sprite *)pNode)->setInsetRight(pFloat); + ((cocos2d::ui::Scale9Sprite *)pNode)->setInsetRight(pFloat); } else if(strcmp(pPropertyName, PROPERTY_INSETBOTTOM) == 0) { - ((Scale9Sprite *)pNode)->setInsetBottom(pFloat); + ((cocos2d::ui::Scale9Sprite *)pNode)->setInsetBottom(pFloat); } else { NodeLoader::onHandlePropTypeFloat(pNode, pParent, pPropertyName, pFloat, ccbReader); } diff --git a/cocos/editor-support/cocosbuilder/CCScale9SpriteLoader.h b/cocos/editor-support/cocosbuilder/CCScale9SpriteLoader.h index 70f7e1816b..35bf229776 100644 --- a/cocos/editor-support/cocosbuilder/CCScale9SpriteLoader.h +++ b/cocos/editor-support/cocosbuilder/CCScale9SpriteLoader.h @@ -3,7 +3,7 @@ #include "CCNodeLoader.h" #include "CCScale9SpriteLoader.h" -#include "extensions/GUI/CCControlExtension/CCScale9Sprite.h" +#include "ui/UIScale9Sprite.h" namespace cocosbuilder { @@ -28,8 +28,8 @@ protected: * @js NA * @lua NA */ - virtual cocos2d::extension::Scale9Sprite * createNode(cocos2d::Node * pParent, cocosbuilder::CCBReader * ccbReader) { - cocos2d::extension::Scale9Sprite* pNode = cocos2d::extension::Scale9Sprite::create(); + virtual cocos2d::ui::Scale9Sprite * createNode(cocos2d::Node * pParent, cocosbuilder::CCBReader * ccbReader) { + cocos2d::ui::Scale9Sprite* pNode = cocos2d::ui::Scale9Sprite::create(); pNode->setAnchorPoint(cocos2d::Vec2::ZERO); diff --git a/cocos/platform/android/java/src/org/cocos2dx/lib/Cocos2dxETCLoader.java b/cocos/platform/android/java/src/org/cocos2dx/lib/Cocos2dxETCLoader.java deleted file mode 100644 index fd4cd81954..0000000000 --- a/cocos/platform/android/java/src/org/cocos2dx/lib/Cocos2dxETCLoader.java +++ /dev/null @@ -1,109 +0,0 @@ -/**************************************************************************** -Copyright (c) 2013 cocos2d-x.org - -http://www.cocos2d-x.org - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. - ****************************************************************************/ -package org.cocos2dx.lib; - -import java.io.FileInputStream; -import java.io.InputStream; -import java.nio.ByteBuffer; -import java.nio.ByteOrder; - -import android.content.Context; -import android.content.res.AssetManager; -import android.opengl.ETC1Util; -import android.util.Log; - -public class Cocos2dxETCLoader { - private static final String ASSETS_PATH = "assets/"; - private static Context context; - - public static boolean loadTexture(String filePath) { - if (! ETC1Util.isETC1Supported()) { - return false; - } - - if (filePath.length() == 0) { - return false; - } - - // Create ETC1Texture - InputStream inputStream = null; - ETC1Util.ETC1Texture texture = null; - AssetManager assetManager = null; - try { - if (filePath.charAt(0) == '/') { - // absolute path - inputStream = new FileInputStream(filePath); - } else { - // remove prefix: "assets/" - if (filePath.startsWith(ASSETS_PATH)) { - filePath = filePath.substring(ASSETS_PATH.length()); - } - assetManager = context.getAssets(); - inputStream = assetManager.open(filePath); - } - - texture = ETC1Util.createTexture(inputStream); - inputStream.close(); - } catch (Exception e) { - Log.d("Cocos2dx", "Unable to create texture for " + filePath); - - texture = null; - } - - if (texture != null) { - boolean ret = true; - - try { - final int width = texture.getWidth(); - final int height = texture.getHeight(); - final int length = texture.getData().remaining(); - - final byte[] data = new byte[length]; - final ByteBuffer buf = ByteBuffer.wrap(data); - buf.order(ByteOrder.nativeOrder()); - buf.put(texture.getData()); - - nativeSetTextureInfo(width, - height, - data, - length); - } catch (Exception e) - { - Log.d("invoke native function error", e.toString()); - ret = false; - } - - return ret; - } else { - return false; - } - } - - public static void setContext(Context context) { - Cocos2dxETCLoader.context = context; - } - - private static native void nativeSetTextureInfo(final int width, final int height, final byte[] data, - final int dataLength); -} diff --git a/cocos/platform/desktop/CCGLViewImpl.cpp b/cocos/platform/desktop/CCGLViewImpl.cpp index 517f99ee2f..90d1767062 100644 --- a/cocos/platform/desktop/CCGLViewImpl.cpp +++ b/cocos/platform/desktop/CCGLViewImpl.cpp @@ -650,8 +650,10 @@ void GLViewImpl::onGLFWMouseScrollCallback(GLFWwindow* window, double x, double { EventMouse event(EventMouse::MouseEventType::MOUSE_SCROLL); //Because OpenGL and cocos2d-x uses different Y axis, we need to convert the coordinate here + float cursorX = (_mouseX - _viewPortRect.origin.x) / _scaleX; + float cursorY = (_viewPortRect.origin.y + _viewPortRect.size.height - _mouseY) / _scaleY; event.setScrollData((float)x, -(float)y); - event.setCursorPosition(_mouseX, this->getViewPortRect().size.height - _mouseY); + event.setCursorPosition(cursorX, cursorY); Director::getInstance()->getEventDispatcher()->dispatchEvent(&event); } diff --git a/cocos/platform/ios/CCEAGLView.mm b/cocos/platform/ios/CCEAGLView.mm index 3c5c1c7b37..87a02a566c 100644 --- a/cocos/platform/ios/CCEAGLView.mm +++ b/cocos/platform/ios/CCEAGLView.mm @@ -374,7 +374,8 @@ Copyright (C) 2008 Apple Inc. All Rights Reserved. for(UIView* view in subviews) { - if([view isKindOfClass:NSClassFromString(@"CCCustomUITextField")]) + if([view isKindOfClass:NSClassFromString(@"CCCustomUITextField")] || + [view isKindOfClass:NSClassFromString(@"UICustomUITextField")]) { if ([view isFirstResponder]) { diff --git a/cocos/scripting/lua-bindings/auto/api/Action.lua b/cocos/scripting/lua-bindings/auto/api/Action.lua index 9502801e63..6d28c6c257 100644 --- a/cocos/scripting/lua-bindings/auto/api/Action.lua +++ b/cocos/scripting/lua-bindings/auto/api/Action.lua @@ -5,65 +5,86 @@ -- @parent_module cc -------------------------------- +-- called before the action start. It will also set the target. -- @function [parent=#Action] startWithTarget -- @param self --- @param #cc.Node node +-- @param #cc.Node target -------------------------------- +-- Set the original target, since target can be nil.
+-- Is the target that were used to run the action. Unless you are doing something complex, like ActionManager, you should NOT call this method.
+-- The target is 'assigned', it is not 'retained'.
+-- since v0.8.2 -- @function [parent=#Action] setOriginalTarget -- @param self --- @param #cc.Node node +-- @param #cc.Node originalTarget -------------------------------- +-- returns a clone of action -- @function [parent=#Action] clone -- @param self -- @return Action#Action ret (return value: cc.Action) -------------------------------- +-- -- @function [parent=#Action] getOriginalTarget -- @param self -- @return Node#Node ret (return value: cc.Node) -------------------------------- +-- called after the action has finished. It will set the 'target' to nil.
+-- IMPORTANT: You should never call "[action stop]" manually. Instead, use: "target->stopAction(action);" -- @function [parent=#Action] stop -- @param self -------------------------------- +-- called once per frame. time a value between 0 and 1
+-- For example:
+-- - 0 means that the action just started
+-- - 0.5 means that the action is in the middle
+-- - 1 means that the action is over -- @function [parent=#Action] update -- @param self --- @param #float float +-- @param #float time -------------------------------- +-- -- @function [parent=#Action] getTarget -- @param self -- @return Node#Node ret (return value: cc.Node) -------------------------------- +-- called every frame with it's delta time. DON'T override unless you know what you are doing. -- @function [parent=#Action] step -- @param self --- @param #float float +-- @param #float dt -------------------------------- +-- -- @function [parent=#Action] setTag -- @param self --- @param #int int +-- @param #int tag -------------------------------- +-- -- @function [parent=#Action] getTag -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- The action will modify the target properties. -- @function [parent=#Action] setTarget -- @param self --- @param #cc.Node node +-- @param #cc.Node target -------------------------------- +-- return true if the action has finished -- @function [parent=#Action] isDone -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- returns a new action that performs the exactly the reverse action -- @function [parent=#Action] reverse -- @param self -- @return Action#Action ret (return value: cc.Action) diff --git a/cocos/scripting/lua-bindings/auto/api/ActionCamera.lua b/cocos/scripting/lua-bindings/auto/api/ActionCamera.lua index 00beabfed2..673fbf6160 100644 --- a/cocos/scripting/lua-bindings/auto/api/ActionCamera.lua +++ b/cocos/scripting/lua-bindings/auto/api/ActionCamera.lua @@ -9,51 +9,60 @@ -- @overload self, vec3_table -- @function [parent=#ActionCamera] setEye -- @param self --- @param #float float --- @param #float float --- @param #float float +-- @param #float x +-- @param #float y +-- @param #float z -------------------------------- +-- -- @function [parent=#ActionCamera] getEye -- @param self -- @return vec3_table#vec3_table ret (return value: vec3_table) -------------------------------- +-- -- @function [parent=#ActionCamera] setUp -- @param self --- @param #vec3_table vec3 +-- @param #vec3_table up -------------------------------- +-- -- @function [parent=#ActionCamera] getCenter -- @param self -- @return vec3_table#vec3_table ret (return value: vec3_table) -------------------------------- +-- -- @function [parent=#ActionCamera] setCenter -- @param self --- @param #vec3_table vec3 +-- @param #vec3_table center -------------------------------- +-- -- @function [parent=#ActionCamera] getUp -- @param self -- @return vec3_table#vec3_table ret (return value: vec3_table) -------------------------------- +-- -- @function [parent=#ActionCamera] startWithTarget -- @param self --- @param #cc.Node node +-- @param #cc.Node target -------------------------------- +-- -- @function [parent=#ActionCamera] clone -- @param self -- @return ActionCamera#ActionCamera ret (return value: cc.ActionCamera) -------------------------------- +-- -- @function [parent=#ActionCamera] reverse -- @param self -- @return ActionCamera#ActionCamera ret (return value: cc.ActionCamera) -------------------------------- +-- js ctor -- @function [parent=#ActionCamera] ActionCamera -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/ActionEase.lua b/cocos/scripting/lua-bindings/auto/api/ActionEase.lua index b5b1ea0bd5..88463b5be3 100644 --- a/cocos/scripting/lua-bindings/auto/api/ActionEase.lua +++ b/cocos/scripting/lua-bindings/auto/api/ActionEase.lua @@ -5,32 +5,38 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#ActionEase] getInnerAction -- @param self -- @return ActionInterval#ActionInterval ret (return value: cc.ActionInterval) -------------------------------- +-- -- @function [parent=#ActionEase] startWithTarget -- @param self --- @param #cc.Node node +-- @param #cc.Node target -------------------------------- +-- -- @function [parent=#ActionEase] clone -- @param self -- @return ActionEase#ActionEase ret (return value: cc.ActionEase) -------------------------------- +-- -- @function [parent=#ActionEase] stop -- @param self -------------------------------- +-- -- @function [parent=#ActionEase] reverse -- @param self -- @return ActionEase#ActionEase ret (return value: cc.ActionEase) -------------------------------- +-- -- @function [parent=#ActionEase] update -- @param self --- @param #float float +-- @param #float time return nil diff --git a/cocos/scripting/lua-bindings/auto/api/ActionFadeFrame.lua b/cocos/scripting/lua-bindings/auto/api/ActionFadeFrame.lua index f713688bf5..7727f649b5 100644 --- a/cocos/scripting/lua-bindings/auto/api/ActionFadeFrame.lua +++ b/cocos/scripting/lua-bindings/auto/api/ActionFadeFrame.lua @@ -5,22 +5,30 @@ -- @parent_module ccs -------------------------------- +-- Gets the fade action opacity.
+-- return the fade action opacity. -- @function [parent=#ActionFadeFrame] getOpacity -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- Gets the ActionInterval of ActionFrame.
+-- parame duration the duration time of ActionFrame
+-- return ActionInterval -- @function [parent=#ActionFadeFrame] getAction -- @param self --- @param #float float +-- @param #float duration -- @return ActionInterval#ActionInterval ret (return value: cc.ActionInterval) -------------------------------- +-- Changes the fade action opacity.
+-- param opacity the fade action opacity -- @function [parent=#ActionFadeFrame] setOpacity -- @param self --- @param #int int +-- @param #int opacity -------------------------------- +-- Default constructor -- @function [parent=#ActionFadeFrame] ActionFadeFrame -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/ActionFrame.lua b/cocos/scripting/lua-bindings/auto/api/ActionFrame.lua index 1be2073a67..0a2637cb6c 100644 --- a/cocos/scripting/lua-bindings/auto/api/ActionFrame.lua +++ b/cocos/scripting/lua-bindings/auto/api/ActionFrame.lua @@ -9,56 +9,75 @@ -- @overload self, float -- @function [parent=#ActionFrame] getAction -- @param self --- @param #float float --- @param #ccs.ActionFrame actionframe +-- @param #float duration +-- @param #ccs.ActionFrame srcFrame -- @return ActionInterval#ActionInterval ret (retunr value: cc.ActionInterval) -------------------------------- +-- Gets the type of action frame
+-- return the type of action frame -- @function [parent=#ActionFrame] getFrameType -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- Changes the time of action frame
+-- param fTime the time of action frame -- @function [parent=#ActionFrame] setFrameTime -- @param self --- @param #float float +-- @param #float fTime -------------------------------- +-- Changes the easing type.
+-- param easingType the easing type. -- @function [parent=#ActionFrame] setEasingType -- @param self --- @param #int int +-- @param #int easingType -------------------------------- +-- Gets the time of action frame
+-- return fTime the time of action frame -- @function [parent=#ActionFrame] getFrameTime -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- Gets the index of action frame
+-- return the index of action frame -- @function [parent=#ActionFrame] getFrameIndex -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- Changes the type of action frame
+-- param frameType the type of action frame -- @function [parent=#ActionFrame] setFrameType -- @param self --- @param #int int +-- @param #int frameType -------------------------------- +-- Changes the index of action frame
+-- param index the index of action frame -- @function [parent=#ActionFrame] setFrameIndex -- @param self --- @param #int int +-- @param #int index -------------------------------- +-- Set the ActionInterval easing parameter.
+-- parame parameter the parameter for frame ease -- @function [parent=#ActionFrame] setEasingParameter -- @param self --- @param #array_table array +-- @param #array_table parameter -------------------------------- +-- Gets the easing type.
+-- return the easing type. -- @function [parent=#ActionFrame] getEasingType -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- Default constructor -- @function [parent=#ActionFrame] ActionFrame -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/ActionInstant.lua b/cocos/scripting/lua-bindings/auto/api/ActionInstant.lua index 0d0fb165a6..0a539e808d 100644 --- a/cocos/scripting/lua-bindings/auto/api/ActionInstant.lua +++ b/cocos/scripting/lua-bindings/auto/api/ActionInstant.lua @@ -5,28 +5,33 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#ActionInstant] step -- @param self --- @param #float float +-- @param #float dt -------------------------------- +-- -- @function [parent=#ActionInstant] clone -- @param self -- @return ActionInstant#ActionInstant ret (return value: cc.ActionInstant) -------------------------------- +-- -- @function [parent=#ActionInstant] reverse -- @param self -- @return ActionInstant#ActionInstant ret (return value: cc.ActionInstant) -------------------------------- +-- -- @function [parent=#ActionInstant] isDone -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#ActionInstant] update -- @param self --- @param #float float +-- @param #float time return nil diff --git a/cocos/scripting/lua-bindings/auto/api/ActionInterval.lua b/cocos/scripting/lua-bindings/auto/api/ActionInterval.lua index a4cfe55038..e0351a5712 100644 --- a/cocos/scripting/lua-bindings/auto/api/ActionInterval.lua +++ b/cocos/scripting/lua-bindings/auto/api/ActionInterval.lua @@ -5,41 +5,49 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#ActionInterval] getAmplitudeRate -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#ActionInterval] setAmplitudeRate -- @param self --- @param #float float +-- @param #float amp -------------------------------- +-- how many seconds had elapsed since the actions started to run. -- @function [parent=#ActionInterval] getElapsed -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#ActionInterval] startWithTarget -- @param self --- @param #cc.Node node +-- @param #cc.Node target -------------------------------- +-- -- @function [parent=#ActionInterval] step -- @param self --- @param #float float +-- @param #float dt -------------------------------- +-- -- @function [parent=#ActionInterval] clone -- @param self -- @return ActionInterval#ActionInterval ret (return value: cc.ActionInterval) -------------------------------- +-- -- @function [parent=#ActionInterval] reverse -- @param self -- @return ActionInterval#ActionInterval ret (return value: cc.ActionInterval) -------------------------------- +-- -- @function [parent=#ActionInterval] isDone -- @param self -- @return bool#bool ret (return value: bool) diff --git a/cocos/scripting/lua-bindings/auto/api/ActionManager.lua b/cocos/scripting/lua-bindings/auto/api/ActionManager.lua index 8597ac46f3..9349a3e536 100644 --- a/cocos/scripting/lua-bindings/auto/api/ActionManager.lua +++ b/cocos/scripting/lua-bindings/auto/api/ActionManager.lua @@ -5,77 +5,99 @@ -- @parent_module cc -------------------------------- +-- Gets an action given its tag an a target
+-- return the Action the with the given tag -- @function [parent=#ActionManager] getActionByTag -- @param self --- @param #int int --- @param #cc.Node node +-- @param #int tag +-- @param #cc.Node target -- @return Action#Action ret (return value: cc.Action) -------------------------------- +-- Removes an action given its tag and the target -- @function [parent=#ActionManager] removeActionByTag -- @param self --- @param #int int --- @param #cc.Node node +-- @param #int tag +-- @param #cc.Node target -------------------------------- +-- Removes all actions from all the targets. -- @function [parent=#ActionManager] removeAllActions -- @param self -------------------------------- +-- Adds an action with a target.
+-- If the target is already present, then the action will be added to the existing target.
+-- If the target is not present, a new instance of this target will be created either paused or not, and the action will be added to the newly created target.
+-- When the target is paused, the queued actions won't be 'ticked'. -- @function [parent=#ActionManager] addAction -- @param self -- @param #cc.Action action --- @param #cc.Node node --- @param #bool bool +-- @param #cc.Node target +-- @param #bool paused -------------------------------- +-- Resumes the target. All queued actions will be resumed. -- @function [parent=#ActionManager] resumeTarget -- @param self --- @param #cc.Node node +-- @param #cc.Node target -------------------------------- +-- -- @function [parent=#ActionManager] update -- @param self --- @param #float float +-- @param #float dt -------------------------------- +-- Pauses the target: all running actions and newly added actions will be paused. -- @function [parent=#ActionManager] pauseTarget -- @param self --- @param #cc.Node node +-- @param #cc.Node target -------------------------------- +-- Returns the numbers of actions that are running in a certain target.
+-- Composable actions are counted as 1 action. Example:
+-- - If you are running 1 Sequence of 7 actions, it will return 1.
+-- - If you are running 7 Sequences of 2 actions, it will return 7. -- @function [parent=#ActionManager] getNumberOfRunningActionsInTarget -- @param self --- @param #cc.Node node +-- @param #cc.Node target -- @return long#long ret (return value: long) -------------------------------- +-- Removes all actions from a certain target.
+-- All the actions that belongs to the target will be removed. -- @function [parent=#ActionManager] removeAllActionsFromTarget -- @param self --- @param #cc.Node node +-- @param #cc.Node target -------------------------------- +-- Resume a set of targets (convenience function to reverse a pauseAllRunningActions call) -- @function [parent=#ActionManager] resumeTargets -- @param self --- @param #array_table array +-- @param #array_table targetsToResume -------------------------------- +-- Removes an action given an action reference. -- @function [parent=#ActionManager] removeAction -- @param self -- @param #cc.Action action -------------------------------- +-- Removes all actions given its tag and the target -- @function [parent=#ActionManager] removeAllActionsByTag -- @param self --- @param #int int --- @param #cc.Node node +-- @param #int tag +-- @param #cc.Node target -------------------------------- +-- Pauses all running actions, returning a list of targets whose actions were paused. -- @function [parent=#ActionManager] pauseAllRunningActions -- @param self -- @return array_table#array_table ret (return value: array_table) -------------------------------- +-- js ctor -- @function [parent=#ActionManager] ActionManager -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/ActionManagerEx.lua b/cocos/scripting/lua-bindings/auto/api/ActionManagerEx.lua index 9d6a8e14b4..0be42e90d1 100644 --- a/cocos/scripting/lua-bindings/auto/api/ActionManagerEx.lua +++ b/cocos/scripting/lua-bindings/auto/api/ActionManagerEx.lua @@ -9,27 +9,38 @@ -- @overload self, char, char -- @function [parent=#ActionManagerEx] playActionByName -- @param self --- @param #char char --- @param #char char --- @param #cc.CallFunc callfunc +-- @param #char jsonName +-- @param #char actionName +-- @param #cc.CallFunc func -- @return ActionObject#ActionObject ret (retunr value: ccs.ActionObject) -------------------------------- +-- Gets an ActionObject with a name.
+-- param jsonName UI file name
+-- param actionName action name in the UI file.
+-- return ActionObject which named as the param name -- @function [parent=#ActionManagerEx] getActionByName -- @param self --- @param #char char --- @param #char char +-- @param #char jsonName +-- @param #char actionName -- @return ActionObject#ActionObject ret (return value: ccs.ActionObject) -------------------------------- +-- Release all actions. -- @function [parent=#ActionManagerEx] releaseActions -- @param self -------------------------------- +-- Purges ActionManager point.
+-- js purge
+-- lua destroyActionManager -- @function [parent=#ActionManagerEx] destroyInstance -- @param self -------------------------------- +-- Gets the static instance of ActionManager.
+-- js getInstance
+-- lua getInstance -- @function [parent=#ActionManagerEx] getInstance -- @param self -- @return ActionManagerEx#ActionManagerEx ret (return value: ccs.ActionManagerEx) diff --git a/cocos/scripting/lua-bindings/auto/api/ActionMoveFrame.lua b/cocos/scripting/lua-bindings/auto/api/ActionMoveFrame.lua index 3afb25896a..64a695be06 100644 --- a/cocos/scripting/lua-bindings/auto/api/ActionMoveFrame.lua +++ b/cocos/scripting/lua-bindings/auto/api/ActionMoveFrame.lua @@ -5,22 +5,30 @@ -- @parent_module ccs -------------------------------- +-- Changes the move action position.
+-- param the move action position. -- @function [parent=#ActionMoveFrame] setPosition -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table pos -------------------------------- +-- Gets the ActionInterval of ActionFrame.
+-- parame duration the duration time of ActionFrame
+-- return ActionInterval -- @function [parent=#ActionMoveFrame] getAction -- @param self --- @param #float float +-- @param #float duration -- @return ActionInterval#ActionInterval ret (return value: cc.ActionInterval) -------------------------------- +-- Gets the move action position.
+-- return the move action position. -- @function [parent=#ActionMoveFrame] getPosition -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- Default constructor -- @function [parent=#ActionMoveFrame] ActionMoveFrame -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/ActionObject.lua b/cocos/scripting/lua-bindings/auto/api/ActionObject.lua index 93f6dec2ec..cd3a1a5bcf 100644 --- a/cocos/scripting/lua-bindings/auto/api/ActionObject.lua +++ b/cocos/scripting/lua-bindings/auto/api/ActionObject.lua @@ -5,35 +5,47 @@ -- @parent_module ccs -------------------------------- +-- Sets the current time of frame.
+-- param fTime the current time of frame -- @function [parent=#ActionObject] setCurrentTime -- @param self --- @param #float float +-- @param #float fTime -------------------------------- +-- Pause the action. -- @function [parent=#ActionObject] pause -- @param self -------------------------------- +-- Sets name for object
+-- param name name of object -- @function [parent=#ActionObject] setName -- @param self --- @param #char char +-- @param #char name -------------------------------- +-- Sets the time interval of frame.
+-- param fTime the time interval of frame -- @function [parent=#ActionObject] setUnitTime -- @param self --- @param #float float +-- @param #float fTime -------------------------------- +-- Gets the total time of frame.
+-- return the total time of frame -- @function [parent=#ActionObject] getTotalTime -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- Gets name of object
+-- return name of object -- @function [parent=#ActionObject] getName -- @param self -- @return char#char ret (return value: char) -------------------------------- +-- Stop the action. -- @function [parent=#ActionObject] stop -- @param self @@ -42,54 +54,71 @@ -- @overload self -- @function [parent=#ActionObject] play -- @param self --- @param #cc.CallFunc callfunc +-- @param #cc.CallFunc func -------------------------------- +-- Gets the current time of frame.
+-- return the current time of frame -- @function [parent=#ActionObject] getCurrentTime -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- Removes a ActionNode which play the action.
+-- param node the ActionNode which play the action -- @function [parent=#ActionObject] removeActionNode -- @param self --- @param #ccs.ActionNode actionnode +-- @param #ccs.ActionNode node -------------------------------- +-- Gets if the action will loop play.
+-- return that if the action will loop play -- @function [parent=#ActionObject] getLoop -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- Adds a ActionNode to play the action.
+-- param node the ActionNode which will play the action -- @function [parent=#ActionObject] addActionNode -- @param self --- @param #ccs.ActionNode actionnode +-- @param #ccs.ActionNode node -------------------------------- +-- Gets the time interval of frame.
+-- return the time interval of frame -- @function [parent=#ActionObject] getUnitTime -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- Return if the action is playing.
+-- return true if the action is playing, false the otherwise -- @function [parent=#ActionObject] isPlaying -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#ActionObject] updateToFrameByTime -- @param self --- @param #float float +-- @param #float fTime -------------------------------- +-- Sets if the action will loop play.
+-- param bLoop that if the action will loop play -- @function [parent=#ActionObject] setLoop -- @param self --- @param #bool bool +-- @param #bool bLoop -------------------------------- +-- -- @function [parent=#ActionObject] simulationActionUpdate -- @param self --- @param #float float +-- @param #float dt -------------------------------- +-- Default constructor -- @function [parent=#ActionObject] ActionObject -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/ActionRotationFrame.lua b/cocos/scripting/lua-bindings/auto/api/ActionRotationFrame.lua index 267c36c133..3e1cf8fb83 100644 --- a/cocos/scripting/lua-bindings/auto/api/ActionRotationFrame.lua +++ b/cocos/scripting/lua-bindings/auto/api/ActionRotationFrame.lua @@ -5,25 +5,30 @@ -- @parent_module ccs -------------------------------- +-- Changes rotate action rotation.
+-- param rotation rotate action rotation. -- @function [parent=#ActionRotationFrame] setRotation -- @param self --- @param #float float +-- @param #float rotation -------------------------------- -- @overload self, float, ccs.ActionFrame -- @overload self, float -- @function [parent=#ActionRotationFrame] getAction -- @param self --- @param #float float --- @param #ccs.ActionFrame actionframe +-- @param #float duration +-- @param #ccs.ActionFrame srcFrame -- @return ActionInterval#ActionInterval ret (retunr value: cc.ActionInterval) -------------------------------- +-- Gets the rotate action rotation.
+-- return the rotate action rotation. -- @function [parent=#ActionRotationFrame] getRotation -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- Default constructor -- @function [parent=#ActionRotationFrame] ActionRotationFrame -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/ActionScaleFrame.lua b/cocos/scripting/lua-bindings/auto/api/ActionScaleFrame.lua index 99c0180572..f9f34cb2de 100644 --- a/cocos/scripting/lua-bindings/auto/api/ActionScaleFrame.lua +++ b/cocos/scripting/lua-bindings/auto/api/ActionScaleFrame.lua @@ -5,32 +5,44 @@ -- @parent_module ccs -------------------------------- +-- Changes the scale action scaleY.
+-- param rotation the scale action scaleY. -- @function [parent=#ActionScaleFrame] setScaleY -- @param self --- @param #float float +-- @param #float scaleY -------------------------------- +-- Changes the scale action scaleX.
+-- param the scale action scaleX. -- @function [parent=#ActionScaleFrame] setScaleX -- @param self --- @param #float float +-- @param #float scaleX -------------------------------- +-- Gets the scale action scaleY.
+-- return the the scale action scaleY. -- @function [parent=#ActionScaleFrame] getScaleY -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- Gets the scale action scaleX.
+-- return the scale action scaleX. -- @function [parent=#ActionScaleFrame] getScaleX -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- Gets the ActionInterval of ActionFrame.
+-- parame duration the duration time of ActionFrame
+-- return ActionInterval -- @function [parent=#ActionScaleFrame] getAction -- @param self --- @param #float float +-- @param #float duration -- @return ActionInterval#ActionInterval ret (return value: cc.ActionInterval) -------------------------------- +-- Default constructor -- @function [parent=#ActionScaleFrame] ActionScaleFrame -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/ActionTimeline.lua b/cocos/scripting/lua-bindings/auto/api/ActionTimeline.lua index 5cc4299820..b04785700d 100644 --- a/cocos/scripting/lua-bindings/auto/api/ActionTimeline.lua +++ b/cocos/scripting/lua-bindings/auto/api/ActionTimeline.lua @@ -5,79 +5,98 @@ -- @parent_module ccs -------------------------------- +-- -- @function [parent=#ActionTimeline] getTimelines -- @param self -- @return array_table#array_table ret (return value: array_table) -------------------------------- +-- Get current frame. -- @function [parent=#ActionTimeline] getCurrentFrame -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- Start frame index of this action -- @function [parent=#ActionTimeline] getStartFrame -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- Pause the animation. -- @function [parent=#ActionTimeline] pause -- @param self -------------------------------- +-- Set ActionTimeline's frame event callback function -- @function [parent=#ActionTimeline] setFrameEventCallFunc -- @param self --- @param #function func +-- @param #function listener -------------------------------- +-- Resume the animation. -- @function [parent=#ActionTimeline] resume -- @param self -------------------------------- +-- -- @function [parent=#ActionTimeline] getDuration -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- add Timeline to ActionTimeline -- @function [parent=#ActionTimeline] addTimeline -- @param self -- @param #ccs.Timeline timeline -------------------------------- +-- End frame of this action.
+-- When action play to this frame, if action is not loop, then it will stop,
+-- or it will play from start frame again. -- @function [parent=#ActionTimeline] getEndFrame -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- Set current frame index, this will cause action plays to this frame. -- @function [parent=#ActionTimeline] setCurrentFrame -- @param self --- @param #int int +-- @param #int frameIndex -------------------------------- +-- Set the animation speed, this will speed up or slow down the speed. -- @function [parent=#ActionTimeline] setTimeSpeed -- @param self --- @param #float float +-- @param #float speed -------------------------------- +-- -- @function [parent=#ActionTimeline] init -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- duration of the whole action -- @function [parent=#ActionTimeline] setDuration -- @param self --- @param #int int +-- @param #int duration -------------------------------- +-- Get current animation speed. -- @function [parent=#ActionTimeline] getTimeSpeed -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- Goto the specified frame index, and pause at this index.
+-- param startIndex The animation will pause at this index. -- @function [parent=#ActionTimeline] gotoFrameAndPause -- @param self --- @param #int int +-- @param #int startIndex -------------------------------- +-- Whether or not Action is playing. -- @function [parent=#ActionTimeline] isPlaying -- @param self -- @return bool#bool ret (return value: bool) @@ -89,51 +108,61 @@ -- @overload self, int, int, int, bool -- @function [parent=#ActionTimeline] gotoFrameAndPlay -- @param self --- @param #int int --- @param #int int --- @param #int int --- @param #bool bool +-- @param #int startIndex +-- @param #int endIndex +-- @param #int currentFrameIndex +-- @param #bool loop -------------------------------- +-- -- @function [parent=#ActionTimeline] removeTimeline -- @param self -- @param #ccs.Timeline timeline -------------------------------- +-- -- @function [parent=#ActionTimeline] clearFrameEventCallFunc -- @param self -------------------------------- +-- -- @function [parent=#ActionTimeline] create -- @param self -- @return ActionTimeline#ActionTimeline ret (return value: ccs.ActionTimeline) -------------------------------- +-- -- @function [parent=#ActionTimeline] step -- @param self --- @param #float float +-- @param #float delta -------------------------------- +-- -- @function [parent=#ActionTimeline] startWithTarget -- @param self --- @param #cc.Node node +-- @param #cc.Node target -------------------------------- +-- Returns a clone of ActionTimeline -- @function [parent=#ActionTimeline] clone -- @param self -- @return ActionTimeline#ActionTimeline ret (return value: ccs.ActionTimeline) -------------------------------- +-- Returns a reverse of ActionTimeline.
+-- Not implement yet. -- @function [parent=#ActionTimeline] reverse -- @param self -- @return ActionTimeline#ActionTimeline ret (return value: ccs.ActionTimeline) -------------------------------- +-- -- @function [parent=#ActionTimeline] isDone -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#ActionTimeline] ActionTimeline -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/ActionTimelineCache.lua b/cocos/scripting/lua-bindings/auto/api/ActionTimelineCache.lua index b983d8bdcf..77e46aa629 100644 --- a/cocos/scripting/lua-bindings/auto/api/ActionTimelineCache.lua +++ b/cocos/scripting/lua-bindings/auto/api/ActionTimelineCache.lua @@ -4,38 +4,45 @@ -- @parent_module ccs -------------------------------- +-- Clone a action with the specified name from the container. -- @function [parent=#ActionTimelineCache] createAction -- @param self --- @param #string str +-- @param #string fileName -- @return ActionTimeline#ActionTimeline ret (return value: ccs.ActionTimeline) -------------------------------- +-- -- @function [parent=#ActionTimelineCache] purge -- @param self -------------------------------- +-- -- @function [parent=#ActionTimelineCache] init -- @param self -------------------------------- +-- -- @function [parent=#ActionTimelineCache] loadAnimationActionWithContent -- @param self --- @param #string str --- @param #string str +-- @param #string fileName +-- @param #string content -- @return ActionTimeline#ActionTimeline ret (return value: ccs.ActionTimeline) -------------------------------- +-- -- @function [parent=#ActionTimelineCache] loadAnimationActionWithFile -- @param self --- @param #string str +-- @param #string fileName -- @return ActionTimeline#ActionTimeline ret (return value: ccs.ActionTimeline) -------------------------------- +-- Remove action with filename, and also remove other resource relate with this file -- @function [parent=#ActionTimelineCache] removeAction -- @param self --- @param #string str +-- @param #string fileName -------------------------------- +-- Destroys the singleton -- @function [parent=#ActionTimelineCache] destroyInstance -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/ActionTimelineData.lua b/cocos/scripting/lua-bindings/auto/api/ActionTimelineData.lua index bda764dad6..46806fa02f 100644 --- a/cocos/scripting/lua-bindings/auto/api/ActionTimelineData.lua +++ b/cocos/scripting/lua-bindings/auto/api/ActionTimelineData.lua @@ -5,19 +5,22 @@ -- @parent_module ccs -------------------------------- +-- -- @function [parent=#ActionTimelineData] setActionTag -- @param self --- @param #int int +-- @param #int actionTag -------------------------------- +-- -- @function [parent=#ActionTimelineData] getActionTag -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- -- @function [parent=#ActionTimelineData] create -- @param self --- @param #int int +-- @param #int actionTag -- @return ActionTimelineData#ActionTimelineData ret (return value: ccs.ActionTimelineData) return nil diff --git a/cocos/scripting/lua-bindings/auto/api/ActionTintFrame.lua b/cocos/scripting/lua-bindings/auto/api/ActionTintFrame.lua index e965b182c8..540cbad47d 100644 --- a/cocos/scripting/lua-bindings/auto/api/ActionTintFrame.lua +++ b/cocos/scripting/lua-bindings/auto/api/ActionTintFrame.lua @@ -5,22 +5,30 @@ -- @parent_module ccs -------------------------------- +-- Gets the tint action color.
+-- return the tint action color. -- @function [parent=#ActionTintFrame] getColor -- @param self -- @return color3b_table#color3b_table ret (return value: color3b_table) -------------------------------- +-- Gets the ActionInterval of ActionFrame.
+-- parame duration the duration time of ActionFrame
+-- return ActionInterval -- @function [parent=#ActionTintFrame] getAction -- @param self --- @param #float float +-- @param #float duration -- @return ActionInterval#ActionInterval ret (return value: cc.ActionInterval) -------------------------------- +-- Changes the tint action color.
+-- param ccolor the tint action color -- @function [parent=#ActionTintFrame] setColor -- @param self --- @param #color3b_table color3b +-- @param #color3b_table ccolor -------------------------------- +-- Default constructor -- @function [parent=#ActionTintFrame] ActionTintFrame -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/ActionTween.lua b/cocos/scripting/lua-bindings/auto/api/ActionTween.lua index 0ff2568643..f221754635 100644 --- a/cocos/scripting/lua-bindings/auto/api/ActionTween.lua +++ b/cocos/scripting/lua-bindings/auto/api/ActionTween.lua @@ -5,30 +5,35 @@ -- @parent_module cc -------------------------------- +-- creates an initializes the action with the property name (key), and the from and to parameters. -- @function [parent=#ActionTween] create -- @param self --- @param #float float --- @param #string str --- @param #float float --- @param #float float +-- @param #float duration +-- @param #string key +-- @param #float from +-- @param #float to -- @return ActionTween#ActionTween ret (return value: cc.ActionTween) -------------------------------- +-- -- @function [parent=#ActionTween] startWithTarget -- @param self --- @param #cc.Node node +-- @param #cc.Node target -------------------------------- +-- -- @function [parent=#ActionTween] clone -- @param self -- @return ActionTween#ActionTween ret (return value: cc.ActionTween) -------------------------------- +-- -- @function [parent=#ActionTween] update -- @param self --- @param #float float +-- @param #float dt -------------------------------- +-- -- @function [parent=#ActionTween] reverse -- @param self -- @return ActionTween#ActionTween ret (return value: cc.ActionTween) diff --git a/cocos/scripting/lua-bindings/auto/api/AnchorPointFrame.lua b/cocos/scripting/lua-bindings/auto/api/AnchorPointFrame.lua index 1e4849c55d..4ad0e5ed07 100644 --- a/cocos/scripting/lua-bindings/auto/api/AnchorPointFrame.lua +++ b/cocos/scripting/lua-bindings/auto/api/AnchorPointFrame.lua @@ -5,26 +5,31 @@ -- @parent_module ccs -------------------------------- +-- -- @function [parent=#AnchorPointFrame] setAnchorPoint -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table point -------------------------------- +-- -- @function [parent=#AnchorPointFrame] getAnchorPoint -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- -- @function [parent=#AnchorPointFrame] create -- @param self -- @return AnchorPointFrame#AnchorPointFrame ret (return value: ccs.AnchorPointFrame) -------------------------------- +-- -- @function [parent=#AnchorPointFrame] clone -- @param self -- @return Frame#Frame ret (return value: ccs.Frame) -------------------------------- +-- -- @function [parent=#AnchorPointFrame] AnchorPointFrame -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/Animate.lua b/cocos/scripting/lua-bindings/auto/api/Animate.lua index de15070b65..f3bf16dc52 100644 --- a/cocos/scripting/lua-bindings/auto/api/Animate.lua +++ b/cocos/scripting/lua-bindings/auto/api/Animate.lua @@ -12,38 +12,45 @@ -- @return Animation#Animation ret (retunr value: cc.Animation) -------------------------------- +-- sets the Animation object to be animated -- @function [parent=#Animate] setAnimation -- @param self -- @param #cc.Animation animation -------------------------------- +-- creates the action with an Animation and will restore the original frame when the animation is over -- @function [parent=#Animate] create -- @param self -- @param #cc.Animation animation -- @return Animate#Animate ret (return value: cc.Animate) -------------------------------- +-- -- @function [parent=#Animate] startWithTarget -- @param self --- @param #cc.Node node +-- @param #cc.Node target -------------------------------- +-- -- @function [parent=#Animate] clone -- @param self -- @return Animate#Animate ret (return value: cc.Animate) -------------------------------- +-- -- @function [parent=#Animate] stop -- @param self -------------------------------- +-- -- @function [parent=#Animate] reverse -- @param self -- @return Animate#Animate ret (return value: cc.Animate) -------------------------------- +-- -- @function [parent=#Animate] update -- @param self --- @param #float float +-- @param #float t return nil diff --git a/cocos/scripting/lua-bindings/auto/api/Animate3D.lua b/cocos/scripting/lua-bindings/auto/api/Animate3D.lua index f49ae32b24..7d8635c012 100644 --- a/cocos/scripting/lua-bindings/auto/api/Animate3D.lua +++ b/cocos/scripting/lua-bindings/auto/api/Animate3D.lua @@ -5,21 +5,25 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#Animate3D] setSpeed -- @param self --- @param #float float +-- @param #float speed -------------------------------- +-- -- @function [parent=#Animate3D] setWeight -- @param self --- @param #float float +-- @param #float weight -------------------------------- +-- get & set speed, negative speed means playing reverse -- @function [parent=#Animate3D] getSpeed -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- get & set blend weight, weight must positive -- @function [parent=#Animate3D] getWeight -- @param self -- @return float#float ret (return value: float) @@ -29,34 +33,39 @@ -- @overload self, cc.Animation3D -- @function [parent=#Animate3D] create -- @param self --- @param #cc.Animation3D animation3d --- @param #float float --- @param #float float +-- @param #cc.Animation3D animation +-- @param #float fromTime +-- @param #float duration -- @return Animate3D#Animate3D ret (retunr value: cc.Animate3D) -------------------------------- +-- -- @function [parent=#Animate3D] startWithTarget -- @param self --- @param #cc.Node node +-- @param #cc.Node target -------------------------------- +-- -- @function [parent=#Animate3D] step -- @param self --- @param #float float +-- @param #float dt -------------------------------- +-- -- @function [parent=#Animate3D] clone -- @param self -- @return Animate3D#Animate3D ret (return value: cc.Animate3D) -------------------------------- +-- -- @function [parent=#Animate3D] reverse -- @param self -- @return Animate3D#Animate3D ret (return value: cc.Animate3D) -------------------------------- +-- -- @function [parent=#Animate3D] update -- @param self --- @param #float float +-- @param #float t return nil diff --git a/cocos/scripting/lua-bindings/auto/api/Animation.lua b/cocos/scripting/lua-bindings/auto/api/Animation.lua index 43b1d28a90..4dc9976680 100644 --- a/cocos/scripting/lua-bindings/auto/api/Animation.lua +++ b/cocos/scripting/lua-bindings/auto/api/Animation.lua @@ -5,74 +5,93 @@ -- @parent_module cc -------------------------------- +-- Gets the times the animation is going to loop. 0 means animation is not animated. 1, animation is executed one time, ... -- @function [parent=#Animation] getLoops -- @param self -- @return unsigned int#unsigned int ret (return value: unsigned int) -------------------------------- +-- Adds a SpriteFrame to a Animation.
+-- The frame will be added with one "delay unit". -- @function [parent=#Animation] addSpriteFrame -- @param self --- @param #cc.SpriteFrame spriteframe +-- @param #cc.SpriteFrame frame -------------------------------- +-- Sets whether to restore the original frame when animation finishes -- @function [parent=#Animation] setRestoreOriginalFrame -- @param self --- @param #bool bool +-- @param #bool restoreOriginalFrame -------------------------------- +-- -- @function [parent=#Animation] clone -- @param self -- @return Animation#Animation ret (return value: cc.Animation) -------------------------------- +-- Gets the duration in seconds of the whole animation. It is the result of totalDelayUnits * delayPerUnit -- @function [parent=#Animation] getDuration -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- Sets the array of AnimationFrames -- @function [parent=#Animation] setFrames -- @param self --- @param #array_table array +-- @param #array_table frames -------------------------------- +-- Gets the array of AnimationFrames -- @function [parent=#Animation] getFrames -- @param self -- @return array_table#array_table ret (return value: array_table) -------------------------------- +-- Sets the times the animation is going to loop. 0 means animation is not animated. 1, animation is executed one time, ... -- @function [parent=#Animation] setLoops -- @param self --- @param #unsigned int int +-- @param #unsigned int loops -------------------------------- +-- Sets the delay in seconds of the "delay unit" -- @function [parent=#Animation] setDelayPerUnit -- @param self --- @param #float float +-- @param #float delayPerUnit -------------------------------- +-- Adds a frame with an image filename. Internally it will create a SpriteFrame and it will add it.
+-- The frame will be added with one "delay unit".
+-- Added to facilitate the migration from v0.8 to v0.9. -- @function [parent=#Animation] addSpriteFrameWithFile -- @param self --- @param #string str +-- @param #string filename -------------------------------- +-- Gets the total Delay units of the Animation. -- @function [parent=#Animation] getTotalDelayUnits -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- Gets the delay in seconds of the "delay unit" -- @function [parent=#Animation] getDelayPerUnit -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- Checks whether to restore the original frame when animation finishes. -- @function [parent=#Animation] getRestoreOriginalFrame -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- Adds a frame with a texture and a rect. Internally it will create a SpriteFrame and it will add it.
+-- The frame will be added with one "delay unit".
+-- Added to facilitate the migration from v0.8 to v0.9. -- @function [parent=#Animation] addSpriteFrameWithTexture -- @param self --- @param #cc.Texture2D texture2d +-- @param #cc.Texture2D pobTexture -- @param #rect_table rect -------------------------------- @@ -80,17 +99,18 @@ -- @overload self -- @function [parent=#Animation] create -- @param self --- @param #array_table array --- @param #float float --- @param #unsigned int int +-- @param #array_table arrayOfAnimationFrameNames +-- @param #float delayPerUnit +-- @param #unsigned int loops -- @return Animation#Animation ret (retunr value: cc.Animation) -------------------------------- +-- -- @function [parent=#Animation] createWithSpriteFrames -- @param self --- @param #array_table array --- @param #float float --- @param #unsigned int int +-- @param #array_table arrayOfSpriteFrameNames +-- @param #float delay +-- @param #unsigned int loops -- @return Animation#Animation ret (return value: cc.Animation) return nil diff --git a/cocos/scripting/lua-bindings/auto/api/Animation3D.lua b/cocos/scripting/lua-bindings/auto/api/Animation3D.lua index 7eacf8e403..c04f1611bf 100644 --- a/cocos/scripting/lua-bindings/auto/api/Animation3D.lua +++ b/cocos/scripting/lua-bindings/auto/api/Animation3D.lua @@ -5,15 +5,17 @@ -- @parent_module cc -------------------------------- +-- get duration -- @function [parent=#Animation3D] getDuration -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- read all animation or only the animation with given animationName? animationName == "" read the first. -- @function [parent=#Animation3D] create -- @param self --- @param #string str --- @param #string str +-- @param #string filename +-- @param #string animationName -- @return Animation3D#Animation3D ret (return value: cc.Animation3D) return nil diff --git a/cocos/scripting/lua-bindings/auto/api/AnimationCache.lua b/cocos/scripting/lua-bindings/auto/api/AnimationCache.lua index 34e8325086..4b8bab06a7 100644 --- a/cocos/scripting/lua-bindings/auto/api/AnimationCache.lua +++ b/cocos/scripting/lua-bindings/auto/api/AnimationCache.lua @@ -5,48 +5,66 @@ -- @parent_module cc -------------------------------- +-- Returns a Animation that was previously added.
+-- If the name is not found it will return nil.
+-- You should retain the returned copy if you are going to use it. -- @function [parent=#AnimationCache] getAnimation -- @param self --- @param #string str +-- @param #string name -- @return Animation#Animation ret (return value: cc.Animation) -------------------------------- +-- Adds a Animation with a name. -- @function [parent=#AnimationCache] addAnimation -- @param self -- @param #cc.Animation animation --- @param #string str +-- @param #string name -------------------------------- +-- -- @function [parent=#AnimationCache] init -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- Adds an animation from an NSDictionary
+-- Make sure that the frames were previously loaded in the SpriteFrameCache.
+-- param plist The path of the relative file,it use to find the plist path for load SpriteFrames.
+-- since v1.1 -- @function [parent=#AnimationCache] addAnimationsWithDictionary -- @param self --- @param #map_table map --- @param #string str +-- @param #map_table dictionary +-- @param #string plist -------------------------------- +-- Deletes a Animation from the cache. -- @function [parent=#AnimationCache] removeAnimation -- @param self --- @param #string str +-- @param #string name -------------------------------- +-- Adds an animation from a plist file.
+-- Make sure that the frames were previously loaded in the SpriteFrameCache.
+-- since v1.1
+-- js addAnimations
+-- lua addAnimations -- @function [parent=#AnimationCache] addAnimationsWithFile -- @param self --- @param #string str +-- @param #string plist -------------------------------- +-- Purges the cache. It releases all the Animation objects and the shared instance. -- @function [parent=#AnimationCache] destroyInstance -- @param self -------------------------------- +-- Returns the shared instance of the Animation cache -- @function [parent=#AnimationCache] getInstance -- @param self -- @return AnimationCache#AnimationCache ret (return value: cc.AnimationCache) -------------------------------- +-- js ctor -- @function [parent=#AnimationCache] AnimationCache -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/AnimationData.lua b/cocos/scripting/lua-bindings/auto/api/AnimationData.lua index f261470ff1..3ed39cf262 100644 --- a/cocos/scripting/lua-bindings/auto/api/AnimationData.lua +++ b/cocos/scripting/lua-bindings/auto/api/AnimationData.lua @@ -5,27 +5,32 @@ -- @parent_module ccs -------------------------------- +-- -- @function [parent=#AnimationData] getMovement -- @param self --- @param #string str +-- @param #string movementName -- @return MovementData#MovementData ret (return value: ccs.MovementData) -------------------------------- +-- -- @function [parent=#AnimationData] getMovementCount -- @param self -- @return long#long ret (return value: long) -------------------------------- +-- -- @function [parent=#AnimationData] addMovement -- @param self --- @param #ccs.MovementData movementdata +-- @param #ccs.MovementData movData -------------------------------- +-- -- @function [parent=#AnimationData] create -- @param self -- @return AnimationData#AnimationData ret (return value: ccs.AnimationData) -------------------------------- +-- js ctor -- @function [parent=#AnimationData] AnimationData -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/AnimationFrame.lua b/cocos/scripting/lua-bindings/auto/api/AnimationFrame.lua index 9bdd79a93c..8a6609349b 100644 --- a/cocos/scripting/lua-bindings/auto/api/AnimationFrame.lua +++ b/cocos/scripting/lua-bindings/auto/api/AnimationFrame.lua @@ -5,9 +5,10 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#AnimationFrame] setSpriteFrame -- @param self --- @param #cc.SpriteFrame spriteframe +-- @param #cc.SpriteFrame frame -------------------------------- -- @overload self @@ -17,36 +18,43 @@ -- @return map_table#map_table ret (retunr value: map_table) -------------------------------- +-- Sets the units of time the frame takes -- @function [parent=#AnimationFrame] setDelayUnits -- @param self --- @param #float float +-- @param #float delayUnits -------------------------------- +-- -- @function [parent=#AnimationFrame] clone -- @param self -- @return AnimationFrame#AnimationFrame ret (return value: cc.AnimationFrame) -------------------------------- +-- -- @function [parent=#AnimationFrame] getSpriteFrame -- @param self -- @return SpriteFrame#SpriteFrame ret (return value: cc.SpriteFrame) -------------------------------- +-- Gets the units of time the frame takes -- @function [parent=#AnimationFrame] getDelayUnits -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- Sets user infomation -- @function [parent=#AnimationFrame] setUserInfo -- @param self --- @param #map_table map +-- @param #map_table userInfo -------------------------------- +-- Creates the animation frame with a spriteframe, number of delay units and a notification user info
+-- since 3.0 -- @function [parent=#AnimationFrame] create -- @param self --- @param #cc.SpriteFrame spriteframe --- @param #float float --- @param #map_table map +-- @param #cc.SpriteFrame spriteFrame +-- @param #float delayUnits +-- @param #map_table userInfo -- @return AnimationFrame#AnimationFrame ret (return value: cc.AnimationFrame) return nil diff --git a/cocos/scripting/lua-bindings/auto/api/Application.lua b/cocos/scripting/lua-bindings/auto/api/Application.lua index ed1bc8e3e4..f458be4bee 100644 --- a/cocos/scripting/lua-bindings/auto/api/Application.lua +++ b/cocos/scripting/lua-bindings/auto/api/Application.lua @@ -4,26 +4,35 @@ -- @parent_module cc -------------------------------- +-- brief Get target platform -- @function [parent=#Application] getTargetPlatform -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- brief Get current language iso 639-1 code
+-- return Current language iso 639-1 code -- @function [parent=#Application] getCurrentLanguageCode -- @param self -- @return char#char ret (return value: char) -------------------------------- +-- brief Get current language config
+-- return Current language config -- @function [parent=#Application] getCurrentLanguage -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- brief Callback by Director to limit FPS.
+-- param interval The time, expressed in seconds, between current frame and next. -- @function [parent=#Application] setAnimationInterval -- @param self --- @param #double double +-- @param #double interval -------------------------------- +-- brief Get current application instance.
+-- return Current application instance pointer. -- @function [parent=#Application] getInstance -- @param self -- @return Application#Application ret (return value: cc.Application) diff --git a/cocos/scripting/lua-bindings/auto/api/Armature.lua b/cocos/scripting/lua-bindings/auto/api/Armature.lua index 3a64f91aad..6aa0fd389f 100644 --- a/cocos/scripting/lua-bindings/auto/api/Armature.lua +++ b/cocos/scripting/lua-bindings/auto/api/Armature.lua @@ -5,55 +5,70 @@ -- @parent_module ccs -------------------------------- +-- Get a bone with the specified name
+-- param name The bone's name you want to get -- @function [parent=#Armature] getBone -- @param self --- @param #string str +-- @param #string name -- @return Bone#Bone ret (return value: ccs.Bone) -------------------------------- +-- Change a bone's parent with the specified parent name.
+-- param bone The bone you want to change parent
+-- param parentName The new parent's name. -- @function [parent=#Armature] changeBoneParent -- @param self -- @param #ccs.Bone bone --- @param #string str +-- @param #string parentName -------------------------------- +-- -- @function [parent=#Armature] setAnimation -- @param self --- @param #ccs.ArmatureAnimation armatureanimation +-- @param #ccs.ArmatureAnimation animation -------------------------------- +-- -- @function [parent=#Armature] getBoneAtPoint -- @param self --- @param #float float --- @param #float float +-- @param #float x +-- @param #float y -- @return Bone#Bone ret (return value: ccs.Bone) -------------------------------- +-- -- @function [parent=#Armature] getArmatureTransformDirty -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#Armature] setVersion -- @param self --- @param #float float +-- @param #float version -------------------------------- +-- Set contentsize and Calculate anchor point. -- @function [parent=#Armature] updateOffsetPoint -- @param self -------------------------------- +-- -- @function [parent=#Armature] getParentBone -- @param self -- @return Bone#Bone ret (return value: ccs.Bone) -------------------------------- +-- Remove a bone with the specified name. If recursion it will also remove child Bone recursionly.
+-- param bone The bone you want to remove
+-- param recursion Determine whether remove the bone's child recursion. -- @function [parent=#Armature] removeBone -- @param self -- @param #ccs.Bone bone --- @param #bool bool +-- @param #bool recursion -------------------------------- +-- -- @function [parent=#Armature] getBatchNode -- @param self -- @return BatchNode#BatchNode ret (return value: ccs.BatchNode) @@ -64,51 +79,63 @@ -- @overload self, string, ccs.Bone -- @function [parent=#Armature] init -- @param self --- @param #string str --- @param #ccs.Bone bone +-- @param #string name +-- @param #ccs.Bone parentBone -- @return bool#bool ret (retunr value: bool) -------------------------------- +-- -- @function [parent=#Armature] setParentBone -- @param self --- @param #ccs.Bone bone +-- @param #ccs.Bone parentBone -------------------------------- +-- -- @function [parent=#Armature] drawContour -- @param self -------------------------------- +-- -- @function [parent=#Armature] setBatchNode -- @param self --- @param #ccs.BatchNode batchnode +-- @param #ccs.BatchNode batchNode -------------------------------- +-- -- @function [parent=#Armature] setArmatureData -- @param self --- @param #ccs.ArmatureData armaturedata +-- @param #ccs.ArmatureData armatureData -------------------------------- +-- Add a Bone to this Armature,
+-- param bone The Bone you want to add to Armature
+-- param parentName The parent Bone's name you want to add to . If it's nullptr, then set Armature to its parent -- @function [parent=#Armature] addBone -- @param self -- @param #ccs.Bone bone --- @param #string str +-- @param #string parentName -------------------------------- +-- -- @function [parent=#Armature] getArmatureData -- @param self -- @return ArmatureData#ArmatureData ret (return value: ccs.ArmatureData) -------------------------------- +-- -- @function [parent=#Armature] getVersion -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#Armature] getAnimation -- @param self -- @return ArmatureAnimation#ArmatureAnimation ret (return value: ccs.ArmatureAnimation) -------------------------------- +-- Get Armature's bone dictionary
+-- return Armature's bone dictionary -- @function [parent=#Armature] getBoneDic -- @param self -- @return map_table#map_table ret (return value: map_table) @@ -119,43 +146,50 @@ -- @overload self, string, ccs.Bone -- @function [parent=#Armature] create -- @param self --- @param #string str --- @param #ccs.Bone bone +-- @param #string name +-- @param #ccs.Bone parentBone -- @return Armature#Armature ret (retunr value: ccs.Armature) -------------------------------- +-- -- @function [parent=#Armature] setAnchorPoint -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table point -------------------------------- +-- -- @function [parent=#Armature] draw -- @param self -- @param #cc.Renderer renderer --- @param #mat4_table mat4 --- @param #unsigned int int +-- @param #mat4_table transform +-- @param #unsigned int flags -------------------------------- +-- -- @function [parent=#Armature] getAnchorPointInPoints -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- -- @function [parent=#Armature] update -- @param self --- @param #float float +-- @param #float dt -------------------------------- +-- -- @function [parent=#Armature] getNodeToParentTransform -- @param self -- @return mat4_table#mat4_table ret (return value: mat4_table) -------------------------------- +-- This boundingBox will calculate all bones' boundingBox every time -- @function [parent=#Armature] getBoundingBox -- @param self -- @return rect_table#rect_table ret (return value: rect_table) -------------------------------- +-- js ctor -- @function [parent=#Armature] Armature -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/ArmatureAnimation.lua b/cocos/scripting/lua-bindings/auto/api/ArmatureAnimation.lua index 66320119c5..6fdfc0e155 100644 --- a/cocos/scripting/lua-bindings/auto/api/ArmatureAnimation.lua +++ b/cocos/scripting/lua-bindings/auto/api/ArmatureAnimation.lua @@ -5,103 +5,140 @@ -- @parent_module ccs -------------------------------- +-- -- @function [parent=#ArmatureAnimation] getSpeedScale -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- Pause the Process -- @function [parent=#ArmatureAnimation] pause -- @param self -------------------------------- +-- Scale animation play speed.
+-- param animationScale Scale value -- @function [parent=#ArmatureAnimation] setSpeedScale -- @param self --- @param #float float +-- @param #float speedScale -------------------------------- +-- Init with a Armature
+-- param armature The Armature ArmatureAnimation will bind to -- @function [parent=#ArmatureAnimation] init -- @param self -- @param #ccs.Armature armature -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#ArmatureAnimation] playWithIndexes -- @param self --- @param #array_table array --- @param #int int --- @param #bool bool +-- @param #array_table movementIndexes +-- @param #int durationTo +-- @param #bool loop -------------------------------- +-- Play animation by animation name.
+-- param animationName The animation name you want to play
+-- param durationTo The frames between two animation changing-over.
+-- It's meaning is changing to this animation need how many frames
+-- -1 : use the value from MovementData get from flash design panel
+-- param loop Whether the animation is loop
+-- loop < 0 : use the value from MovementData get from flash design panel
+-- loop = 0 : this animation is not loop
+-- loop > 0 : this animation is loop -- @function [parent=#ArmatureAnimation] play -- @param self --- @param #string str --- @param #int int --- @param #int int +-- @param #string animationName +-- @param #int durationTo +-- @param #int loop -------------------------------- +-- Go to specified frame and pause current movement. -- @function [parent=#ArmatureAnimation] gotoAndPause -- @param self --- @param #int int +-- @param #int frameIndex -------------------------------- +-- Resume the Process -- @function [parent=#ArmatureAnimation] resume -- @param self -------------------------------- +-- Stop the Process -- @function [parent=#ArmatureAnimation] stop -- @param self -------------------------------- +-- -- @function [parent=#ArmatureAnimation] update -- @param self --- @param #float float +-- @param #float dt -------------------------------- +-- -- @function [parent=#ArmatureAnimation] getAnimationData -- @param self -- @return AnimationData#AnimationData ret (return value: ccs.AnimationData) -------------------------------- +-- -- @function [parent=#ArmatureAnimation] playWithIndex -- @param self --- @param #int int --- @param #int int --- @param #int int +-- @param #int animationIndex +-- @param #int durationTo +-- @param #int loop -------------------------------- +-- Get current movementID
+-- return The name of current movement -- @function [parent=#ArmatureAnimation] getCurrentMovementID -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- -- @function [parent=#ArmatureAnimation] setAnimationData -- @param self --- @param #ccs.AnimationData animationdata +-- @param #ccs.AnimationData data -------------------------------- +-- Go to specified frame and play current movement.
+-- You need first switch to the movement you want to play, then call this function.
+-- example : playByIndex(0);
+-- gotoAndPlay(0);
+-- playByIndex(1);
+-- gotoAndPlay(0);
+-- gotoAndPlay(15); -- @function [parent=#ArmatureAnimation] gotoAndPlay -- @param self --- @param #int int +-- @param #int frameIndex -------------------------------- +-- -- @function [parent=#ArmatureAnimation] playWithNames -- @param self --- @param #array_table array --- @param #int int --- @param #bool bool +-- @param #array_table movementNames +-- @param #int durationTo +-- @param #bool loop -------------------------------- +-- Get movement count -- @function [parent=#ArmatureAnimation] getMovementCount -- @param self -- @return long#long ret (return value: long) -------------------------------- +-- Create with a Armature
+-- param armature The Armature ArmatureAnimation will bind to -- @function [parent=#ArmatureAnimation] create -- @param self -- @param #ccs.Armature armature -- @return ArmatureAnimation#ArmatureAnimation ret (return value: ccs.ArmatureAnimation) -------------------------------- +-- js ctor -- @function [parent=#ArmatureAnimation] ArmatureAnimation -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/ArmatureData.lua b/cocos/scripting/lua-bindings/auto/api/ArmatureData.lua index d8558c9910..d22ae806e0 100644 --- a/cocos/scripting/lua-bindings/auto/api/ArmatureData.lua +++ b/cocos/scripting/lua-bindings/auto/api/ArmatureData.lua @@ -5,27 +5,32 @@ -- @parent_module ccs -------------------------------- +-- -- @function [parent=#ArmatureData] addBoneData -- @param self --- @param #ccs.BoneData bonedata +-- @param #ccs.BoneData boneData -------------------------------- +-- -- @function [parent=#ArmatureData] init -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#ArmatureData] getBoneData -- @param self --- @param #string str +-- @param #string boneName -- @return BoneData#BoneData ret (return value: ccs.BoneData) -------------------------------- +-- -- @function [parent=#ArmatureData] create -- @param self -- @return ArmatureData#ArmatureData ret (return value: ccs.ArmatureData) -------------------------------- +-- js ctor -- @function [parent=#ArmatureData] ArmatureData -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/ArmatureDataManager.lua b/cocos/scripting/lua-bindings/auto/api/ArmatureDataManager.lua index 8afaf2f804..690de6110a 100644 --- a/cocos/scripting/lua-bindings/auto/api/ArmatureDataManager.lua +++ b/cocos/scripting/lua-bindings/auto/api/ArmatureDataManager.lua @@ -5,110 +5,143 @@ -- @parent_module ccs -------------------------------- +-- -- @function [parent=#ArmatureDataManager] getAnimationDatas -- @param self -- @return map_table#map_table ret (return value: map_table) -------------------------------- +-- brief remove animation data
+-- param id the id of the animation data -- @function [parent=#ArmatureDataManager] removeAnimationData -- @param self --- @param #string str +-- @param #string id -------------------------------- +-- Add armature data
+-- param id The id of the armature data
+-- param armatureData ArmatureData * -- @function [parent=#ArmatureDataManager] addArmatureData -- @param self --- @param #string str --- @param #ccs.ArmatureData armaturedata --- @param #string str +-- @param #string id +-- @param #ccs.ArmatureData armatureData +-- @param #string configFilePath -------------------------------- -- @overload self, string, string, string -- @overload self, string -- @function [parent=#ArmatureDataManager] addArmatureFileInfo -- @param self --- @param #string str --- @param #string str --- @param #string str +-- @param #string imagePath +-- @param #string plistPath +-- @param #string configFilePath -------------------------------- +-- -- @function [parent=#ArmatureDataManager] removeArmatureFileInfo -- @param self --- @param #string str +-- @param #string configFilePath -------------------------------- +-- -- @function [parent=#ArmatureDataManager] getTextureDatas -- @param self -- @return map_table#map_table ret (return value: map_table) -------------------------------- +-- brief get texture data
+-- param id the id of the texture data you want to get
+-- return TextureData * -- @function [parent=#ArmatureDataManager] getTextureData -- @param self --- @param #string str +-- @param #string id -- @return TextureData#TextureData ret (return value: ccs.TextureData) -------------------------------- +-- brief get armature data
+-- param id the id of the armature data you want to get
+-- return ArmatureData * -- @function [parent=#ArmatureDataManager] getArmatureData -- @param self --- @param #string str +-- @param #string id -- @return ArmatureData#ArmatureData ret (return value: ccs.ArmatureData) -------------------------------- +-- brief get animation data from _animationDatas(Dictionary)
+-- param id the id of the animation data you want to get
+-- return AnimationData * -- @function [parent=#ArmatureDataManager] getAnimationData -- @param self --- @param #string str +-- @param #string id -- @return AnimationData#AnimationData ret (return value: ccs.AnimationData) -------------------------------- +-- brief add animation data
+-- param id the id of the animation data
+-- return AnimationData * -- @function [parent=#ArmatureDataManager] addAnimationData -- @param self --- @param #string str --- @param #ccs.AnimationData animationdata --- @param #string str +-- @param #string id +-- @param #ccs.AnimationData animationData +-- @param #string configFilePath -------------------------------- +-- Init ArmatureDataManager -- @function [parent=#ArmatureDataManager] init -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- brief remove armature data
+-- param id the id of the armature data you want to get -- @function [parent=#ArmatureDataManager] removeArmatureData -- @param self --- @param #string str +-- @param #string id -------------------------------- +-- -- @function [parent=#ArmatureDataManager] getArmatureDatas -- @param self -- @return map_table#map_table ret (return value: map_table) -------------------------------- +-- brief remove texture data
+-- param id the id of the texture data you want to get -- @function [parent=#ArmatureDataManager] removeTextureData -- @param self --- @param #string str +-- @param #string id -------------------------------- +-- brief add texture data
+-- param id the id of the texture data
+-- return TextureData * -- @function [parent=#ArmatureDataManager] addTextureData -- @param self --- @param #string str --- @param #ccs.TextureData texturedata --- @param #string str +-- @param #string id +-- @param #ccs.TextureData textureData +-- @param #string configFilePath -------------------------------- +-- brief Juge whether or not need auto load sprite file -- @function [parent=#ArmatureDataManager] isAutoLoadSpriteFile -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- brief Add sprite frame to CCSpriteFrameCache, it will save display name and it's relative image name -- @function [parent=#ArmatureDataManager] addSpriteFrameFromFile -- @param self --- @param #string str --- @param #string str --- @param #string str +-- @param #string plistPath +-- @param #string imagePath +-- @param #string configFilePath -------------------------------- +-- -- @function [parent=#ArmatureDataManager] destroyInstance -- @param self -------------------------------- +-- -- @function [parent=#ArmatureDataManager] getInstance -- @param self -- @return ArmatureDataManager#ArmatureDataManager ret (return value: ccs.ArmatureDataManager) diff --git a/cocos/scripting/lua-bindings/auto/api/ArmatureDisplayData.lua b/cocos/scripting/lua-bindings/auto/api/ArmatureDisplayData.lua index 450e398de0..5fcd62e60d 100644 --- a/cocos/scripting/lua-bindings/auto/api/ArmatureDisplayData.lua +++ b/cocos/scripting/lua-bindings/auto/api/ArmatureDisplayData.lua @@ -5,11 +5,13 @@ -- @parent_module ccs -------------------------------- +-- -- @function [parent=#ArmatureDisplayData] create -- @param self -- @return ArmatureDisplayData#ArmatureDisplayData ret (return value: ccs.ArmatureDisplayData) -------------------------------- +-- js ctor -- @function [parent=#ArmatureDisplayData] ArmatureDisplayData -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/AssetsManager.lua b/cocos/scripting/lua-bindings/auto/api/AssetsManager.lua index 364244e06f..c5ae73f466 100644 --- a/cocos/scripting/lua-bindings/auto/api/AssetsManager.lua +++ b/cocos/scripting/lua-bindings/auto/api/AssetsManager.lua @@ -5,75 +5,89 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#AssetsManager] setStoragePath -- @param self --- @param #char char +-- @param #char storagePath -------------------------------- +-- -- @function [parent=#AssetsManager] setPackageUrl -- @param self --- @param #char char +-- @param #char packageUrl -------------------------------- +-- -- @function [parent=#AssetsManager] checkUpdate -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#AssetsManager] getStoragePath -- @param self -- @return char#char ret (return value: char) -------------------------------- +-- -- @function [parent=#AssetsManager] update -- @param self -------------------------------- +-- @brief Sets connection time out in seconds -- @function [parent=#AssetsManager] setConnectionTimeout -- @param self --- @param #unsigned int int +-- @param #unsigned int timeout -------------------------------- +-- -- @function [parent=#AssetsManager] setVersionFileUrl -- @param self --- @param #char char +-- @param #char versionFileUrl -------------------------------- +-- -- @function [parent=#AssetsManager] getPackageUrl -- @param self -- @return char#char ret (return value: char) -------------------------------- +-- @brief Gets connection time out in secondes -- @function [parent=#AssetsManager] getConnectionTimeout -- @param self -- @return unsigned int#unsigned int ret (return value: unsigned int) -------------------------------- +-- -- @function [parent=#AssetsManager] getVersion -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- -- @function [parent=#AssetsManager] getVersionFileUrl -- @param self -- @return char#char ret (return value: char) -------------------------------- +-- -- @function [parent=#AssetsManager] deleteVersion -- @param self -------------------------------- +-- -- @function [parent=#AssetsManager] create -- @param self --- @param #char char --- @param #char char --- @param #char char --- @param #function func --- @param #function func --- @param #function func +-- @param #char packageUrl +-- @param #char versionFileUrl +-- @param #char storagePath +-- @param #function errorCallback +-- @param #function progressCallback +-- @param #function successCallback -- @return AssetsManager#AssetsManager ret (return value: cc.AssetsManager) -------------------------------- +-- -- @function [parent=#AssetsManager] AssetsManager -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/AtlasNode.lua b/cocos/scripting/lua-bindings/auto/api/AtlasNode.lua index d0a1fbd5b8..e035dc27a9 100644 --- a/cocos/scripting/lua-bindings/auto/api/AtlasNode.lua +++ b/cocos/scripting/lua-bindings/auto/api/AtlasNode.lua @@ -5,78 +5,93 @@ -- @parent_module cc -------------------------------- +-- updates the Atlas (indexed vertex array).
+-- Shall be overridden in subclasses -- @function [parent=#AtlasNode] updateAtlasValues -- @param self -------------------------------- +-- -- @function [parent=#AtlasNode] getTexture -- @param self -- @return Texture2D#Texture2D ret (return value: cc.Texture2D) -------------------------------- +-- -- @function [parent=#AtlasNode] setTextureAtlas -- @param self --- @param #cc.TextureAtlas textureatlas +-- @param #cc.TextureAtlas textureAtlas -------------------------------- +-- -- @function [parent=#AtlasNode] getTextureAtlas -- @param self -- @return TextureAtlas#TextureAtlas ret (return value: cc.TextureAtlas) -------------------------------- +-- -- @function [parent=#AtlasNode] getQuadsToDraw -- @param self -- @return long#long ret (return value: long) -------------------------------- +-- -- @function [parent=#AtlasNode] setTexture -- @param self --- @param #cc.Texture2D texture2d +-- @param #cc.Texture2D texture -------------------------------- +-- -- @function [parent=#AtlasNode] setQuadsToDraw -- @param self --- @param #long long +-- @param #long quadsToDraw -------------------------------- +-- creates a AtlasNode with an Atlas file the width and height of each item and the quantity of items to render -- @function [parent=#AtlasNode] create -- @param self --- @param #string str --- @param #int int --- @param #int int --- @param #int int +-- @param #string filename +-- @param #int tileWidth +-- @param #int tileHeight +-- @param #int itemsToRender -- @return AtlasNode#AtlasNode ret (return value: cc.AtlasNode) -------------------------------- +-- -- @function [parent=#AtlasNode] draw -- @param self -- @param #cc.Renderer renderer --- @param #mat4_table mat4 --- @param #unsigned int int +-- @param #mat4_table transform +-- @param #unsigned int flags -------------------------------- +-- -- @function [parent=#AtlasNode] isOpacityModifyRGB -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#AtlasNode] setColor -- @param self --- @param #color3b_table color3b +-- @param #color3b_table color -------------------------------- +-- -- @function [parent=#AtlasNode] getColor -- @param self -- @return color3b_table#color3b_table ret (return value: color3b_table) -------------------------------- +-- -- @function [parent=#AtlasNode] setOpacityModifyRGB -- @param self --- @param #bool bool +-- @param #bool isOpacityModifyRGB -------------------------------- +-- -- @function [parent=#AtlasNode] setOpacity -- @param self --- @param #unsigned char char +-- @param #unsigned char opacity return nil diff --git a/cocos/scripting/lua-bindings/auto/api/AttachNode.lua b/cocos/scripting/lua-bindings/auto/api/AttachNode.lua index dca12cf579..e61a0d0d48 100644 --- a/cocos/scripting/lua-bindings/auto/api/AttachNode.lua +++ b/cocos/scripting/lua-bindings/auto/api/AttachNode.lua @@ -5,21 +5,25 @@ -- @parent_module cc -------------------------------- +-- creates an AttachNode
+-- param attachBone The bone to which the AttachNode is going to attach, the attacheBone must be a bone of the AttachNode's parent -- @function [parent=#AttachNode] create -- @param self --- @param #cc.Bone3D bone3d +-- @param #cc.Bone3D attachBone -- @return AttachNode#AttachNode ret (return value: cc.AttachNode) -------------------------------- +-- -- @function [parent=#AttachNode] getWorldToNodeTransform -- @param self -- @return mat4_table#mat4_table ret (return value: mat4_table) -------------------------------- +-- -- @function [parent=#AttachNode] visit -- @param self -- @param #cc.Renderer renderer --- @param #mat4_table mat4 --- @param #unsigned int int +-- @param #mat4_table parentTransform +-- @param #unsigned int parentFlags return nil diff --git a/cocos/scripting/lua-bindings/auto/api/BaseData.lua b/cocos/scripting/lua-bindings/auto/api/BaseData.lua index 2d2d36b6a1..78f4aafeff 100644 --- a/cocos/scripting/lua-bindings/auto/api/BaseData.lua +++ b/cocos/scripting/lua-bindings/auto/api/BaseData.lua @@ -5,21 +5,25 @@ -- @parent_module ccs -------------------------------- +-- -- @function [parent=#BaseData] getColor -- @param self -- @return color4b_table#color4b_table ret (return value: color4b_table) -------------------------------- +-- -- @function [parent=#BaseData] setColor -- @param self --- @param #color4b_table color4b +-- @param #color4b_table color -------------------------------- +-- -- @function [parent=#BaseData] create -- @param self -- @return BaseData#BaseData ret (return value: ccs.BaseData) -------------------------------- +-- js ctor -- @function [parent=#BaseData] BaseData -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/BatchNode.lua b/cocos/scripting/lua-bindings/auto/api/BatchNode.lua index dfb42d2e5e..3e153863a9 100644 --- a/cocos/scripting/lua-bindings/auto/api/BatchNode.lua +++ b/cocos/scripting/lua-bindings/auto/api/BatchNode.lua @@ -5,11 +5,13 @@ -- @parent_module ccs -------------------------------- +-- js NA -- @function [parent=#BatchNode] init -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#BatchNode] create -- @param self -- @return BatchNode#BatchNode ret (return value: ccs.BatchNode) @@ -19,21 +21,23 @@ -- @overload self, cc.Node, int, int -- @function [parent=#BatchNode] addChild -- @param self --- @param #cc.Node node --- @param #int int --- @param #int int +-- @param #cc.Node pChild +-- @param #int zOrder +-- @param #int tag -------------------------------- +-- -- @function [parent=#BatchNode] draw -- @param self -- @param #cc.Renderer renderer --- @param #mat4_table mat4 --- @param #unsigned int int +-- @param #mat4_table transform +-- @param #unsigned int flags -------------------------------- +-- -- @function [parent=#BatchNode] removeChild -- @param self --- @param #cc.Node node --- @param #bool bool +-- @param #cc.Node child +-- @param #bool cleanup return nil diff --git a/cocos/scripting/lua-bindings/auto/api/BezierBy.lua b/cocos/scripting/lua-bindings/auto/api/BezierBy.lua index ed228fd60c..85dc00405e 100644 --- a/cocos/scripting/lua-bindings/auto/api/BezierBy.lua +++ b/cocos/scripting/lua-bindings/auto/api/BezierBy.lua @@ -5,23 +5,27 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#BezierBy] startWithTarget -- @param self --- @param #cc.Node node +-- @param #cc.Node target -------------------------------- +-- -- @function [parent=#BezierBy] clone -- @param self -- @return BezierBy#BezierBy ret (return value: cc.BezierBy) -------------------------------- +-- -- @function [parent=#BezierBy] reverse -- @param self -- @return BezierBy#BezierBy ret (return value: cc.BezierBy) -------------------------------- +-- -- @function [parent=#BezierBy] update -- @param self --- @param #float float +-- @param #float time return nil diff --git a/cocos/scripting/lua-bindings/auto/api/BezierTo.lua b/cocos/scripting/lua-bindings/auto/api/BezierTo.lua index 5bec1c1882..6499108d03 100644 --- a/cocos/scripting/lua-bindings/auto/api/BezierTo.lua +++ b/cocos/scripting/lua-bindings/auto/api/BezierTo.lua @@ -5,16 +5,19 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#BezierTo] startWithTarget -- @param self --- @param #cc.Node node +-- @param #cc.Node target -------------------------------- +-- -- @function [parent=#BezierTo] clone -- @param self -- @return BezierTo#BezierTo ret (return value: cc.BezierTo) -------------------------------- +-- -- @function [parent=#BezierTo] reverse -- @param self -- @return BezierTo#BezierTo ret (return value: cc.BezierTo) diff --git a/cocos/scripting/lua-bindings/auto/api/Blink.lua b/cocos/scripting/lua-bindings/auto/api/Blink.lua index 91bbeeee69..d63a7f8329 100644 --- a/cocos/scripting/lua-bindings/auto/api/Blink.lua +++ b/cocos/scripting/lua-bindings/auto/api/Blink.lua @@ -5,34 +5,40 @@ -- @parent_module cc -------------------------------- +-- creates the action -- @function [parent=#Blink] create -- @param self --- @param #float float --- @param #int int +-- @param #float duration +-- @param #int blinks -- @return Blink#Blink ret (return value: cc.Blink) -------------------------------- +-- -- @function [parent=#Blink] startWithTarget -- @param self --- @param #cc.Node node +-- @param #cc.Node target -------------------------------- +-- -- @function [parent=#Blink] clone -- @param self -- @return Blink#Blink ret (return value: cc.Blink) -------------------------------- +-- -- @function [parent=#Blink] stop -- @param self -------------------------------- +-- -- @function [parent=#Blink] reverse -- @param self -- @return Blink#Blink ret (return value: cc.Blink) -------------------------------- +-- -- @function [parent=#Blink] update -- @param self --- @param #float float +-- @param #float time return nil diff --git a/cocos/scripting/lua-bindings/auto/api/Bone.lua b/cocos/scripting/lua-bindings/auto/api/Bone.lua index 9b646e61db..99606c4270 100644 --- a/cocos/scripting/lua-bindings/auto/api/Bone.lua +++ b/cocos/scripting/lua-bindings/auto/api/Bone.lua @@ -5,163 +5,200 @@ -- @parent_module ccs -------------------------------- +-- -- @function [parent=#Bone] isTransformDirty -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#Bone] isIgnoreMovementBoneData -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- Update zorder -- @function [parent=#Bone] updateZOrder -- @param self -------------------------------- +-- -- @function [parent=#Bone] getDisplayRenderNode -- @param self -- @return Node#Node ret (return value: cc.Node) -------------------------------- +-- -- @function [parent=#Bone] isBlendDirty -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- Add a child to this bone, and it will let this child call setParent(Bone *parent) function to set self to it's parent
+-- param child the child you want to add -- @function [parent=#Bone] addChildBone -- @param self --- @param #ccs.Bone bone +-- @param #ccs.Bone child -------------------------------- +-- -- @function [parent=#Bone] getWorldInfo -- @param self -- @return BaseData#BaseData ret (return value: ccs.BaseData) -------------------------------- +-- -- @function [parent=#Bone] getTween -- @param self -- @return Tween#Tween ret (return value: ccs.Tween) -------------------------------- +-- Get parent bone
+-- return parent bone -- @function [parent=#Bone] getParentBone -- @param self -- @return Bone#Bone ret (return value: ccs.Bone) -------------------------------- +-- Update color to render display -- @function [parent=#Bone] updateColor -- @param self -------------------------------- +-- -- @function [parent=#Bone] setTransformDirty -- @param self --- @param #bool bool +-- @param #bool dirty -------------------------------- +-- -- @function [parent=#Bone] getDisplayRenderNodeType -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- -- @function [parent=#Bone] removeDisplay -- @param self --- @param #int int +-- @param #int index -------------------------------- +-- -- @function [parent=#Bone] setBoneData -- @param self --- @param #ccs.BoneData bonedata +-- @param #ccs.BoneData boneData -------------------------------- -- @overload self, string -- @overload self -- @function [parent=#Bone] init -- @param self --- @param #string str +-- @param #string name -- @return bool#bool ret (retunr value: bool) -------------------------------- +-- Set parent bone.
+-- If parent is NUll, then also remove this bone from armature.
+-- It will not set the Armature, if you want to add the bone to a Armature, you should use Armature::addBone(Bone *bone, const char* parentName).
+-- param parent the parent bone.
+-- nullptr : remove this bone from armature -- @function [parent=#Bone] setParentBone -- @param self --- @param #ccs.Bone bone +-- @param #ccs.Bone parent -------------------------------- -- @overload self, cc.Node, int -- @overload self, ccs.DisplayData, int -- @function [parent=#Bone] addDisplay -- @param self --- @param #ccs.DisplayData displaydata --- @param #int int +-- @param #ccs.DisplayData displayData +-- @param #int index -------------------------------- +-- Remove itself from its parent.
+-- param recursion whether or not to remove childBone's display -- @function [parent=#Bone] removeFromParent -- @param self --- @param #bool bool +-- @param #bool recursion -------------------------------- +-- -- @function [parent=#Bone] getColliderDetector -- @param self -- @return ColliderDetector#ColliderDetector ret (return value: ccs.ColliderDetector) -------------------------------- +-- -- @function [parent=#Bone] getChildArmature -- @param self -- @return Armature#Armature ret (return value: ccs.Armature) -------------------------------- +-- -- @function [parent=#Bone] getTweenData -- @param self -- @return FrameData#FrameData ret (return value: ccs.FrameData) -------------------------------- +-- -- @function [parent=#Bone] changeDisplayWithIndex -- @param self --- @param #int int --- @param #bool bool +-- @param #int index +-- @param #bool force -------------------------------- +-- -- @function [parent=#Bone] changeDisplayWithName -- @param self --- @param #string str --- @param #bool bool +-- @param #string name +-- @param #bool force -------------------------------- +-- -- @function [parent=#Bone] setArmature -- @param self -- @param #ccs.Armature armature -------------------------------- +-- -- @function [parent=#Bone] setBlendDirty -- @param self --- @param #bool bool +-- @param #bool dirty -------------------------------- +-- Removes a child Bone
+-- param bone the bone you want to remove -- @function [parent=#Bone] removeChildBone -- @param self -- @param #ccs.Bone bone --- @param #bool bool +-- @param #bool recursion -------------------------------- +-- -- @function [parent=#Bone] setChildArmature -- @param self --- @param #ccs.Armature armature +-- @param #ccs.Armature childArmature -------------------------------- +-- -- @function [parent=#Bone] getNodeToArmatureTransform -- @param self -- @return mat4_table#mat4_table ret (return value: mat4_table) -------------------------------- +-- -- @function [parent=#Bone] getDisplayManager -- @param self -- @return DisplayManager#DisplayManager ret (return value: ccs.DisplayManager) -------------------------------- +-- -- @function [parent=#Bone] getArmature -- @param self -- @return Armature#Armature ret (return value: ccs.Armature) -------------------------------- +-- -- @function [parent=#Bone] getBoneData -- @param self -- @return BoneData#BoneData ret (return value: ccs.BoneData) @@ -171,35 +208,41 @@ -- @overload self -- @function [parent=#Bone] create -- @param self --- @param #string str +-- @param #string name -- @return Bone#Bone ret (retunr value: ccs.Bone) -------------------------------- +-- -- @function [parent=#Bone] updateDisplayedColor -- @param self --- @param #color3b_table color3b +-- @param #color3b_table parentColor -------------------------------- +-- -- @function [parent=#Bone] setLocalZOrder -- @param self --- @param #int int +-- @param #int zOrder -------------------------------- +-- -- @function [parent=#Bone] getNodeToWorldTransform -- @param self -- @return mat4_table#mat4_table ret (return value: mat4_table) -------------------------------- +-- -- @function [parent=#Bone] update -- @param self --- @param #float float +-- @param #float delta -------------------------------- +-- -- @function [parent=#Bone] updateDisplayedOpacity -- @param self --- @param #unsigned char char +-- @param #unsigned char parentOpacity -------------------------------- +-- js ctor -- @function [parent=#Bone] Bone -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/BoneData.lua b/cocos/scripting/lua-bindings/auto/api/BoneData.lua index 2b4eea933a..7cc0750efb 100644 --- a/cocos/scripting/lua-bindings/auto/api/BoneData.lua +++ b/cocos/scripting/lua-bindings/auto/api/BoneData.lua @@ -5,27 +5,32 @@ -- @parent_module ccs -------------------------------- +-- -- @function [parent=#BoneData] getDisplayData -- @param self --- @param #int int +-- @param #int index -- @return DisplayData#DisplayData ret (return value: ccs.DisplayData) -------------------------------- +-- -- @function [parent=#BoneData] init -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#BoneData] addDisplayData -- @param self --- @param #ccs.DisplayData displaydata +-- @param #ccs.DisplayData displayData -------------------------------- +-- -- @function [parent=#BoneData] create -- @param self -- @return BoneData#BoneData ret (return value: ccs.BoneData) -------------------------------- +-- js ctor -- @function [parent=#BoneData] BoneData -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/Button.lua b/cocos/scripting/lua-bindings/auto/api/Button.lua index b0212c1988..544762f02c 100644 --- a/cocos/scripting/lua-bindings/auto/api/Button.lua +++ b/cocos/scripting/lua-bindings/auto/api/Button.lua @@ -5,168 +5,215 @@ -- @parent_module ccui -------------------------------- +-- -- @function [parent=#Button] getTitleText -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- -- @function [parent=#Button] setTitleFontSize -- @param self --- @param #float float +-- @param #float size -------------------------------- +-- Sets if button is using scale9 renderer.
+-- param true that using scale9 renderer, false otherwise. -- @function [parent=#Button] setScale9Enabled -- @param self --- @param #bool bool +-- @param #bool able -------------------------------- +-- brief Return a zoom scale -- @function [parent=#Button] getZoomScale -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#Button] getCapInsetsDisabledRenderer -- @param self -- @return rect_table#rect_table ret (return value: rect_table) -------------------------------- +-- -- @function [parent=#Button] setTitleColor -- @param self --- @param #color3b_table color3b +-- @param #color3b_table color -------------------------------- +-- Sets capinsets for button, if button is using scale9 renderer.
+-- param capInsets capinsets for button -- @function [parent=#Button] setCapInsetsDisabledRenderer -- @param self --- @param #rect_table rect +-- @param #rect_table capInsets -------------------------------- +-- Sets capinsets for button, if button is using scale9 renderer.
+-- param capInsets capinsets for button -- @function [parent=#Button] setCapInsets -- @param self --- @param #rect_table rect +-- @param #rect_table capInsets -------------------------------- +-- Load dark state texture for button.
+-- param disabled dark state texture.
+-- param texType @see TextureResType -- @function [parent=#Button] loadTextureDisabled -- @param self --- @param #string str --- @param #int texturerestype +-- @param #string disabled +-- @param #int texType -------------------------------- +-- -- @function [parent=#Button] setTitleText -- @param self --- @param #string str +-- @param #string text -------------------------------- +-- Sets capinsets for button, if button is using scale9 renderer.
+-- param capInsets capinsets for button -- @function [parent=#Button] setCapInsetsNormalRenderer -- @param self --- @param #rect_table rect +-- @param #rect_table capInsets -------------------------------- +-- Load selected state texture for button.
+-- param selected selected state texture.
+-- param texType @see TextureResType -- @function [parent=#Button] loadTexturePressed -- @param self --- @param #string str --- @param #int texturerestype +-- @param #string selected +-- @param #int texType -------------------------------- +-- -- @function [parent=#Button] setTitleFontName -- @param self --- @param #string str +-- @param #string fontName -------------------------------- +-- -- @function [parent=#Button] getCapInsetsNormalRenderer -- @param self -- @return rect_table#rect_table ret (return value: rect_table) -------------------------------- +-- -- @function [parent=#Button] getCapInsetsPressedRenderer -- @param self -- @return rect_table#rect_table ret (return value: rect_table) -------------------------------- +-- Load textures for button.
+-- param normal normal state texture name.
+-- param selected selected state texture name.
+-- param disabled disabled state texture name.
+-- param texType @see TextureResType -- @function [parent=#Button] loadTextures -- @param self --- @param #string str --- @param #string str --- @param #string str --- @param #int texturerestype +-- @param #string normal +-- @param #string selected +-- @param #string disabled +-- @param #int texType -------------------------------- +-- -- @function [parent=#Button] isScale9Enabled -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- Load normal state texture for button.
+-- param normal normal state texture.
+-- param texType @see TextureResType -- @function [parent=#Button] loadTextureNormal -- @param self --- @param #string str --- @param #int texturerestype +-- @param #string normal +-- @param #int texType -------------------------------- +-- Sets capinsets for button, if button is using scale9 renderer.
+-- param capInsets capinsets for button -- @function [parent=#Button] setCapInsetsPressedRenderer -- @param self --- @param #rect_table rect +-- @param #rect_table capInsets -------------------------------- +-- -- @function [parent=#Button] getTitleFontSize -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#Button] getTitleFontName -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- -- @function [parent=#Button] getTitleColor -- @param self -- @return color3b_table#color3b_table ret (return value: color3b_table) -------------------------------- +-- Changes if button can be clicked zoom effect.
+-- param true that can be clicked zoom effect, false otherwise. -- @function [parent=#Button] setPressedActionEnabled -- @param self --- @param #bool bool +-- @param #bool enabled -------------------------------- +-- When user pressed the button, the button will zoom to a scale.
+-- The final scale of the button equals (button original scale + _zoomScale) -- @function [parent=#Button] setZoomScale -- @param self --- @param #float float +-- @param #float scale -------------------------------- -- @overload self, string, string, string, int -- @overload self -- @function [parent=#Button] create -- @param self --- @param #string str --- @param #string str --- @param #string str --- @param #int texturerestype +-- @param #string normalImage +-- @param #string selectedImage +-- @param #string disableImage +-- @param #int texType -- @return Button#Button ret (retunr value: ccui.Button) -------------------------------- +-- -- @function [parent=#Button] createInstance -- @param self -- @return Ref#Ref ret (return value: cc.Ref) -------------------------------- +-- -- @function [parent=#Button] getVirtualRenderer -- @param self -- @return Node#Node ret (return value: cc.Node) -------------------------------- +-- Returns the "class name" of widget. -- @function [parent=#Button] getDescription -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- -- @function [parent=#Button] getVirtualRendererSize -- @param self -- @return size_table#size_table ret (return value: size_table) -------------------------------- +-- -- @function [parent=#Button] ignoreContentAdaptWithSize -- @param self --- @param #bool bool +-- @param #bool ignore -------------------------------- +-- Default constructor -- @function [parent=#Button] Button -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/CCBAnimationManager.lua b/cocos/scripting/lua-bindings/auto/api/CCBAnimationManager.lua index 1238d0c551..eddeeae1bd 100644 --- a/cocos/scripting/lua-bindings/auto/api/CCBAnimationManager.lua +++ b/cocos/scripting/lua-bindings/auto/api/CCBAnimationManager.lua @@ -5,197 +5,234 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#CCBAnimationManager] moveAnimationsFromNode -- @param self --- @param #cc.Node node --- @param #cc.Node node +-- @param #cc.Node fromNode +-- @param #cc.Node toNode -------------------------------- +-- -- @function [parent=#CCBAnimationManager] setAutoPlaySequenceId -- @param self --- @param #int int +-- @param #int autoPlaySequenceId -------------------------------- +-- -- @function [parent=#CCBAnimationManager] getDocumentCallbackNames -- @param self -- @return array_table#array_table ret (return value: array_table) -------------------------------- +-- -- @function [parent=#CCBAnimationManager] actionForSoundChannel -- @param self --- @param #cc.CCBSequenceProperty ccbsequenceproperty +-- @param #cc.CCBSequenceProperty channel -- @return Sequence#Sequence ret (return value: cc.Sequence) -------------------------------- +-- -- @function [parent=#CCBAnimationManager] setBaseValue -- @param self -- @param #cc.Value value --- @param #cc.Node node --- @param #string str +-- @param #cc.Node pNode +-- @param #string propName -------------------------------- +-- -- @function [parent=#CCBAnimationManager] getDocumentOutletNodes -- @param self -- @return array_table#array_table ret (return value: array_table) -------------------------------- +-- -- @function [parent=#CCBAnimationManager] getLastCompletedSequenceName -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- -- @function [parent=#CCBAnimationManager] setRootNode -- @param self --- @param #cc.Node node +-- @param #cc.Node pRootNode -------------------------------- +-- -- @function [parent=#CCBAnimationManager] runAnimationsForSequenceNamedTweenDuration -- @param self --- @param #char char --- @param #float float +-- @param #char pName +-- @param #float fTweenDuration -------------------------------- +-- -- @function [parent=#CCBAnimationManager] addDocumentOutletName -- @param self --- @param #string str +-- @param #string name -------------------------------- +-- -- @function [parent=#CCBAnimationManager] getSequences -- @param self -- @return array_table#array_table ret (return value: array_table) -------------------------------- +-- -- @function [parent=#CCBAnimationManager] getRootContainerSize -- @param self -- @return size_table#size_table ret (return value: size_table) -------------------------------- +-- -- @function [parent=#CCBAnimationManager] setDocumentControllerName -- @param self --- @param #string str +-- @param #string name -------------------------------- +-- -- @function [parent=#CCBAnimationManager] setObject -- @param self --- @param #cc.Ref ref --- @param #cc.Node node --- @param #string str +-- @param #cc.Ref obj +-- @param #cc.Node pNode +-- @param #string propName -------------------------------- +-- -- @function [parent=#CCBAnimationManager] getContainerSize -- @param self --- @param #cc.Node node +-- @param #cc.Node pNode -- @return size_table#size_table ret (return value: size_table) -------------------------------- +-- -- @function [parent=#CCBAnimationManager] actionForCallbackChannel -- @param self --- @param #cc.CCBSequenceProperty ccbsequenceproperty +-- @param #cc.CCBSequenceProperty channel -- @return Sequence#Sequence ret (return value: cc.Sequence) -------------------------------- +-- -- @function [parent=#CCBAnimationManager] getDocumentOutletNames -- @param self -- @return array_table#array_table ret (return value: array_table) -------------------------------- +-- -- @function [parent=#CCBAnimationManager] addDocumentCallbackControlEvents -- @param self --- @param #int eventtype +-- @param #int eventType -------------------------------- +-- -- @function [parent=#CCBAnimationManager] init -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#CCBAnimationManager] getKeyframeCallbacks -- @param self -- @return array_table#array_table ret (return value: array_table) -------------------------------- +-- -- @function [parent=#CCBAnimationManager] getDocumentCallbackControlEvents -- @param self -- @return array_table#array_table ret (return value: array_table) -------------------------------- +-- -- @function [parent=#CCBAnimationManager] setRootContainerSize -- @param self --- @param #size_table size +-- @param #size_table rootContainerSize -------------------------------- +-- -- @function [parent=#CCBAnimationManager] runAnimationsForSequenceIdTweenDuration -- @param self --- @param #int int --- @param #float float +-- @param #int nSeqId +-- @param #float fTweenDuraiton -------------------------------- +-- -- @function [parent=#CCBAnimationManager] getRunningSequenceName -- @param self -- @return char#char ret (return value: char) -------------------------------- +-- -- @function [parent=#CCBAnimationManager] getAutoPlaySequenceId -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- -- @function [parent=#CCBAnimationManager] addDocumentCallbackName -- @param self --- @param #string str +-- @param #string name -------------------------------- +-- -- @function [parent=#CCBAnimationManager] getRootNode -- @param self -- @return Node#Node ret (return value: cc.Node) -------------------------------- +-- -- @function [parent=#CCBAnimationManager] addDocumentOutletNode -- @param self -- @param #cc.Node node -------------------------------- +-- -- @function [parent=#CCBAnimationManager] getSequenceDuration -- @param self --- @param #char char +-- @param #char pSequenceName -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#CCBAnimationManager] addDocumentCallbackNode -- @param self -- @param #cc.Node node -------------------------------- +-- -- @function [parent=#CCBAnimationManager] runAnimationsForSequenceNamed -- @param self --- @param #char char +-- @param #char pName -------------------------------- +-- -- @function [parent=#CCBAnimationManager] getSequenceId -- @param self --- @param #char char +-- @param #char pSequenceName -- @return int#int ret (return value: int) -------------------------------- +-- -- @function [parent=#CCBAnimationManager] getDocumentCallbackNodes -- @param self -- @return array_table#array_table ret (return value: array_table) -------------------------------- +-- -- @function [parent=#CCBAnimationManager] setSequences -- @param self --- @param #array_table array +-- @param #array_table seq -------------------------------- +-- -- @function [parent=#CCBAnimationManager] debug -- @param self -------------------------------- +-- -- @function [parent=#CCBAnimationManager] getDocumentControllerName -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- js ctor -- @function [parent=#CCBAnimationManager] CCBAnimationManager -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/CCBReader.lua b/cocos/scripting/lua-bindings/auto/api/CCBReader.lua index b6fe92d042..78fba9b128 100644 --- a/cocos/scripting/lua-bindings/auto/api/CCBReader.lua +++ b/cocos/scripting/lua-bindings/auto/api/CCBReader.lua @@ -5,101 +5,122 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#CCBReader] addOwnerOutletName -- @param self --- @param #string str +-- @param #string name -------------------------------- +-- -- @function [parent=#CCBReader] getOwnerCallbackNames -- @param self -- @return array_table#array_table ret (return value: array_table) -------------------------------- +-- -- @function [parent=#CCBReader] addDocumentCallbackControlEvents -- @param self --- @param #int eventtype +-- @param #int eventType -------------------------------- +-- -- @function [parent=#CCBReader] setCCBRootPath -- @param self --- @param #char char +-- @param #char ccbRootPath -------------------------------- +-- -- @function [parent=#CCBReader] addOwnerOutletNode -- @param self -- @param #cc.Node node -------------------------------- +-- -- @function [parent=#CCBReader] getOwnerCallbackNodes -- @param self -- @return array_table#array_table ret (return value: array_table) -------------------------------- +-- -- @function [parent=#CCBReader] readSoundKeyframesForSeq -- @param self --- @param #cc.CCBSequence ccbsequence +-- @param #cc.CCBSequence seq -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#CCBReader] getCCBRootPath -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- -- @function [parent=#CCBReader] getOwnerCallbackControlEvents -- @param self -- @return array_table#array_table ret (return value: array_table) -------------------------------- +-- -- @function [parent=#CCBReader] getOwnerOutletNodes -- @param self -- @return array_table#array_table ret (return value: array_table) -------------------------------- +-- -- @function [parent=#CCBReader] readUTF8 -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- -- @function [parent=#CCBReader] addOwnerCallbackControlEvents -- @param self --- @param #int eventtype +-- @param #int type -------------------------------- +-- -- @function [parent=#CCBReader] getOwnerOutletNames -- @param self -- @return array_table#array_table ret (return value: array_table) -------------------------------- +-- js setActionManager
+-- lua setActionManager -- @function [parent=#CCBReader] setAnimationManager -- @param self --- @param #cc.CCBAnimationManager ccbanimationmanager +-- @param #cc.CCBAnimationManager pAnimationManager -------------------------------- +-- -- @function [parent=#CCBReader] readCallbackKeyframesForSeq -- @param self --- @param #cc.CCBSequence ccbsequence +-- @param #cc.CCBSequence seq -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#CCBReader] getAnimationManagersForNodes -- @param self -- @return array_table#array_table ret (return value: array_table) -------------------------------- +-- -- @function [parent=#CCBReader] getNodesWithAnimationManagers -- @param self -- @return array_table#array_table ret (return value: array_table) -------------------------------- +-- js getActionManager
+-- lua getActionManager -- @function [parent=#CCBReader] getAnimationManager -- @param self -- @return CCBAnimationManager#CCBAnimationManager ret (return value: cc.CCBAnimationManager) -------------------------------- +-- -- @function [parent=#CCBReader] setResolutionScale -- @param self --- @param #float float +-- @param #float scale -------------------------------- -- @overload self, cc.CCBReader @@ -107,9 +128,9 @@ -- @overload self -- @function [parent=#CCBReader] CCBReader -- @param self --- @param #cc.NodeLoaderLibrary nodeloaderlibrary --- @param #cc.CCBMemberVariableAssigner ccbmembervariableassigner --- @param #cc.CCBSelectorResolver ccbselectorresolver --- @param #cc.NodeLoaderListener nodeloaderlistener +-- @param #cc.NodeLoaderLibrary pNodeLoaderLibrary +-- @param #cc.CCBMemberVariableAssigner pCCBMemberVariableAssigner +-- @param #cc.CCBSelectorResolver pCCBSelectorResolver +-- @param #cc.NodeLoaderListener pNodeLoaderListener return nil diff --git a/cocos/scripting/lua-bindings/auto/api/CallFunc.lua b/cocos/scripting/lua-bindings/auto/api/CallFunc.lua index f45623fe4b..678814b81e 100644 --- a/cocos/scripting/lua-bindings/auto/api/CallFunc.lua +++ b/cocos/scripting/lua-bindings/auto/api/CallFunc.lua @@ -5,30 +5,36 @@ -- @parent_module cc -------------------------------- +-- executes the callback -- @function [parent=#CallFunc] execute -- @param self -------------------------------- +-- -- @function [parent=#CallFunc] getTargetCallback -- @param self -- @return Ref#Ref ret (return value: cc.Ref) -------------------------------- +-- -- @function [parent=#CallFunc] setTargetCallback -- @param self --- @param #cc.Ref ref +-- @param #cc.Ref sel -------------------------------- +-- -- @function [parent=#CallFunc] clone -- @param self -- @return CallFunc#CallFunc ret (return value: cc.CallFunc) -------------------------------- +-- -- @function [parent=#CallFunc] update -- @param self --- @param #float float +-- @param #float time -------------------------------- +-- -- @function [parent=#CallFunc] reverse -- @param self -- @return CallFunc#CallFunc ret (return value: cc.CallFunc) diff --git a/cocos/scripting/lua-bindings/auto/api/Camera.lua b/cocos/scripting/lua-bindings/auto/api/Camera.lua index af10889528..8f80b80254 100644 --- a/cocos/scripting/lua-bindings/auto/api/Camera.lua +++ b/cocos/scripting/lua-bindings/auto/api/Camera.lua @@ -5,79 +5,108 @@ -- @parent_module cc -------------------------------- +-- Gets the camera's projection matrix.
+-- return The camera projection matrix. -- @function [parent=#Camera] getProjectionMatrix -- @param self -- @return mat4_table#mat4_table ret (return value: mat4_table) -------------------------------- +-- get view projection matrix -- @function [parent=#Camera] getViewProjectionMatrix -- @param self -- @return mat4_table#mat4_table ret (return value: mat4_table) -------------------------------- +-- Gets the camera's view matrix.
+-- return The camera view matrix. -- @function [parent=#Camera] getViewMatrix -- @param self -- @return mat4_table#mat4_table ret (return value: mat4_table) -------------------------------- +-- get & set Camera flag -- @function [parent=#Camera] getCameraFlag -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- Gets the type of camera.
+-- return The camera type. -- @function [parent=#Camera] getType -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- Creates a view matrix based on the specified input parameters.
+-- param eyePosition The eye position.
+-- param targetPosition The target's center position.
+-- param up The up vector.
+-- param dst A matrix to store the result in. -- @function [parent=#Camera] lookAt -- @param self --- @param #vec3_table vec3 --- @param #vec3_table vec3 +-- @param #vec3_table target +-- @param #vec3_table up -------------------------------- +-- -- @function [parent=#Camera] setCameraFlag -- @param self --- @param #int cameraflag +-- @param #int flag -------------------------------- +-- Convert the specified point of viewport from screenspace coordinate into the worldspace coordinate. -- @function [parent=#Camera] unproject -- @param self --- @param #size_table size --- @param #vec3_table vec3 --- @param #vec3_table vec3 +-- @param #size_table viewport +-- @param #vec3_table src +-- @param #vec3_table dst -------------------------------- +-- create default camera, the camera type depends on Director::getProjection -- @function [parent=#Camera] create -- @param self -- @return Camera#Camera ret (return value: cc.Camera) -------------------------------- +-- Creates a perspective camera.
+-- param fieldOfView The field of view for the perspective camera (normally in the range of 40-60 degrees).
+-- param aspectRatio The aspect ratio of the camera (normally the width of the viewport divided by the height of the viewport).
+-- param nearPlane The near plane distance.
+-- param farPlane The far plane distance. -- @function [parent=#Camera] createPerspective -- @param self --- @param #float float --- @param #float float --- @param #float float --- @param #float float +-- @param #float fieldOfView +-- @param #float aspectRatio +-- @param #float nearPlane +-- @param #float farPlane -- @return Camera#Camera ret (return value: cc.Camera) -------------------------------- +-- Creates an orthographic camera.
+-- param zoomX The zoom factor along the X-axis of the orthographic projection (the width of the ortho projection).
+-- param zoomY The zoom factor along the Y-axis of the orthographic projection (the height of the ortho projection).
+-- param aspectRatio The aspect ratio of the orthographic projection.
+-- param nearPlane The near plane distance.
+-- param farPlane The far plane distance. -- @function [parent=#Camera] createOrthographic -- @param self --- @param #float float --- @param #float float --- @param #float float --- @param #float float +-- @param #float zoomX +-- @param #float zoomY +-- @param #float nearPlane +-- @param #float farPlane -- @return Camera#Camera ret (return value: cc.Camera) -------------------------------- +-- -- @function [parent=#Camera] getVisitingCamera -- @param self -- @return Camera#Camera ret (return value: cc.Camera) -------------------------------- +-- Sets the position (X, Y, and Z) in its parent's coordinate system -- @function [parent=#Camera] setPosition3D -- @param self --- @param #vec3_table vec3 +-- @param #vec3_table position return nil diff --git a/cocos/scripting/lua-bindings/auto/api/CardinalSplineBy.lua b/cocos/scripting/lua-bindings/auto/api/CardinalSplineBy.lua index 48c898c9ba..cc0fd9ca76 100644 --- a/cocos/scripting/lua-bindings/auto/api/CardinalSplineBy.lua +++ b/cocos/scripting/lua-bindings/auto/api/CardinalSplineBy.lua @@ -5,26 +5,31 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#CardinalSplineBy] startWithTarget -- @param self --- @param #cc.Node node +-- @param #cc.Node target -------------------------------- +-- -- @function [parent=#CardinalSplineBy] clone -- @param self -- @return CardinalSplineBy#CardinalSplineBy ret (return value: cc.CardinalSplineBy) -------------------------------- +-- -- @function [parent=#CardinalSplineBy] updatePosition -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table newPos -------------------------------- +-- -- @function [parent=#CardinalSplineBy] reverse -- @param self -- @return CardinalSplineBy#CardinalSplineBy ret (return value: cc.CardinalSplineBy) -------------------------------- +-- -- @function [parent=#CardinalSplineBy] CardinalSplineBy -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/CardinalSplineTo.lua b/cocos/scripting/lua-bindings/auto/api/CardinalSplineTo.lua index fd5bcb141b..324ca3035f 100644 --- a/cocos/scripting/lua-bindings/auto/api/CardinalSplineTo.lua +++ b/cocos/scripting/lua-bindings/auto/api/CardinalSplineTo.lua @@ -5,44 +5,53 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#CardinalSplineTo] getPoints -- @param self -- @return point_table#point_table ret (return value: point_table) -------------------------------- +-- -- @function [parent=#CardinalSplineTo] updatePosition -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table newPos -------------------------------- +-- initializes the action with a duration and an array of points -- @function [parent=#CardinalSplineTo] initWithDuration -- @param self --- @param #float float --- @param #point_table pointarray --- @param #float float +-- @param #float duration +-- @param #point_table points +-- @param #float tension -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#CardinalSplineTo] startWithTarget -- @param self --- @param #cc.Node node +-- @param #cc.Node target -------------------------------- +-- -- @function [parent=#CardinalSplineTo] clone -- @param self -- @return CardinalSplineTo#CardinalSplineTo ret (return value: cc.CardinalSplineTo) -------------------------------- +-- -- @function [parent=#CardinalSplineTo] reverse -- @param self -- @return CardinalSplineTo#CardinalSplineTo ret (return value: cc.CardinalSplineTo) -------------------------------- +-- -- @function [parent=#CardinalSplineTo] update -- @param self --- @param #float float +-- @param #float time -------------------------------- +-- js NA
+-- lua NA -- @function [parent=#CardinalSplineTo] CardinalSplineTo -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/CatmullRomBy.lua b/cocos/scripting/lua-bindings/auto/api/CatmullRomBy.lua index 3b82d8aae6..fda07cef71 100644 --- a/cocos/scripting/lua-bindings/auto/api/CatmullRomBy.lua +++ b/cocos/scripting/lua-bindings/auto/api/CatmullRomBy.lua @@ -5,18 +5,21 @@ -- @parent_module cc -------------------------------- +-- initializes the action with a duration and an array of points -- @function [parent=#CatmullRomBy] initWithDuration -- @param self --- @param #float float --- @param #point_table pointarray +-- @param #float dt +-- @param #point_table points -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#CatmullRomBy] clone -- @param self -- @return CatmullRomBy#CatmullRomBy ret (return value: cc.CatmullRomBy) -------------------------------- +-- -- @function [parent=#CatmullRomBy] reverse -- @param self -- @return CatmullRomBy#CatmullRomBy ret (return value: cc.CatmullRomBy) diff --git a/cocos/scripting/lua-bindings/auto/api/CatmullRomTo.lua b/cocos/scripting/lua-bindings/auto/api/CatmullRomTo.lua index 104e624774..c0fba61301 100644 --- a/cocos/scripting/lua-bindings/auto/api/CatmullRomTo.lua +++ b/cocos/scripting/lua-bindings/auto/api/CatmullRomTo.lua @@ -5,18 +5,21 @@ -- @parent_module cc -------------------------------- +-- initializes the action with a duration and an array of points -- @function [parent=#CatmullRomTo] initWithDuration -- @param self --- @param #float float --- @param #point_table pointarray +-- @param #float dt +-- @param #point_table points -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#CatmullRomTo] clone -- @param self -- @return CatmullRomTo#CatmullRomTo ret (return value: cc.CatmullRomTo) -------------------------------- +-- -- @function [parent=#CatmullRomTo] reverse -- @param self -- @return CatmullRomTo#CatmullRomTo ret (return value: cc.CatmullRomTo) diff --git a/cocos/scripting/lua-bindings/auto/api/CheckBox.lua b/cocos/scripting/lua-bindings/auto/api/CheckBox.lua index cdbab92888..3ef7cf5013 100644 --- a/cocos/scripting/lua-bindings/auto/api/CheckBox.lua +++ b/cocos/scripting/lua-bindings/auto/api/CheckBox.lua @@ -5,94 +5,123 @@ -- @parent_module ccui -------------------------------- +-- Load backGroundSelected texture for checkbox.
+-- param backGroundSelected backGround selected state texture.
+-- param texType @see TextureResType -- @function [parent=#CheckBox] loadTextureBackGroundSelected -- @param self --- @param #string str --- @param #int texturerestype +-- @param #string backGroundSelected +-- @param #int texType -------------------------------- +-- Load backGroundDisabled texture for checkbox.
+-- param backGroundDisabled backGroundDisabled texture.
+-- param texType @see TextureResType -- @function [parent=#CheckBox] loadTextureBackGroundDisabled -- @param self --- @param #string str --- @param #int texturerestype +-- @param #string backGroundDisabled +-- @param #int texType -------------------------------- +-- -- @function [parent=#CheckBox] setSelected -- @param self --- @param #bool bool +-- @param #bool selected -------------------------------- +-- -- @function [parent=#CheckBox] addEventListener -- @param self --- @param #function func +-- @param #function callback -------------------------------- +-- Load cross texture for checkbox.
+-- param cross cross texture.
+-- param texType @see TextureResType -- @function [parent=#CheckBox] loadTextureFrontCross -- @param self --- @param #string str --- @param #int texturerestype +-- @param #string +-- @param #int texType -------------------------------- +-- -- @function [parent=#CheckBox] isSelected -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- Load textures for checkbox.
+-- param backGround backGround texture.
+-- param backGroundSelected backGround selected state texture.
+-- param cross cross texture.
+-- param frontCrossDisabled cross dark state texture.
+-- param texType @see TextureResType -- @function [parent=#CheckBox] loadTextures -- @param self --- @param #string str --- @param #string str --- @param #string str --- @param #string str --- @param #string str --- @param #int texturerestype +-- @param #string backGround +-- @param #string backGroundSelected +-- @param #string cross +-- @param #string backGroundDisabled +-- @param #string frontCrossDisabled +-- @param #int texType -------------------------------- +-- Load backGround texture for checkbox.
+-- param backGround backGround texture.
+-- param texType @see TextureResType -- @function [parent=#CheckBox] loadTextureBackGround -- @param self --- @param #string str --- @param #int texturerestype +-- @param #string backGround +-- @param #int type -------------------------------- +-- Load frontCrossDisabled texture for checkbox.
+-- param frontCrossDisabled frontCrossDisabled texture.
+-- param texType @see TextureResType -- @function [parent=#CheckBox] loadTextureFrontCrossDisabled -- @param self --- @param #string str --- @param #int texturerestype +-- @param #string frontCrossDisabled +-- @param #int texType -------------------------------- -- @overload self, string, string, string, string, string, int -- @overload self -- @function [parent=#CheckBox] create -- @param self --- @param #string str --- @param #string str --- @param #string str --- @param #string str --- @param #string str --- @param #int texturerestype +-- @param #string backGround +-- @param #string backGroundSeleted +-- @param #string cross +-- @param #string backGroundDisabled +-- @param #string frontCrossDisabled +-- @param #int texType -- @return CheckBox#CheckBox ret (retunr value: ccui.CheckBox) -------------------------------- +-- -- @function [parent=#CheckBox] createInstance -- @param self -- @return Ref#Ref ret (return value: cc.Ref) -------------------------------- +-- -- @function [parent=#CheckBox] getVirtualRenderer -- @param self -- @return Node#Node ret (return value: cc.Node) -------------------------------- +-- Returns the "class name" of widget. -- @function [parent=#CheckBox] getDescription -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- -- @function [parent=#CheckBox] getVirtualRendererSize -- @param self -- @return size_table#size_table ret (return value: size_table) -------------------------------- +-- Default constructor -- @function [parent=#CheckBox] CheckBox -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/ClippingNode.lua b/cocos/scripting/lua-bindings/auto/api/ClippingNode.lua index f9ac0622a2..a8ac20c195 100644 --- a/cocos/scripting/lua-bindings/auto/api/ClippingNode.lua +++ b/cocos/scripting/lua-bindings/auto/api/ClippingNode.lua @@ -5,48 +5,62 @@ -- @parent_module cc -------------------------------- +-- Inverted. If this is set to true,
+-- the stencil is inverted, so the content is drawn where the stencil is NOT drawn.
+-- This default to false. -- @function [parent=#ClippingNode] isInverted -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#ClippingNode] setInverted -- @param self --- @param #bool bool +-- @param #bool inverted -------------------------------- +-- -- @function [parent=#ClippingNode] setStencil -- @param self --- @param #cc.Node node +-- @param #cc.Node stencil -------------------------------- +-- The alpha threshold.
+-- The content is drawn only where the stencil have pixel with alpha greater than the alphaThreshold.
+-- Should be a float between 0 and 1.
+-- This default to 1 (so alpha test is disabled). -- @function [parent=#ClippingNode] getAlphaThreshold -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- The Node to use as a stencil to do the clipping.
+-- The stencil node will be retained.
+-- This default to nil. -- @function [parent=#ClippingNode] getStencil -- @param self -- @return Node#Node ret (return value: cc.Node) -------------------------------- +-- -- @function [parent=#ClippingNode] setAlphaThreshold -- @param self --- @param #float float +-- @param #float alphaThreshold -------------------------------- -- @overload self, cc.Node -- @overload self -- @function [parent=#ClippingNode] create -- @param self --- @param #cc.Node node +-- @param #cc.Node stencil -- @return ClippingNode#ClippingNode ret (retunr value: cc.ClippingNode) -------------------------------- +-- -- @function [parent=#ClippingNode] visit -- @param self -- @param #cc.Renderer renderer --- @param #mat4_table mat4 --- @param #unsigned int int +-- @param #mat4_table parentTransform +-- @param #unsigned int parentFlags return nil diff --git a/cocos/scripting/lua-bindings/auto/api/ColorFrame.lua b/cocos/scripting/lua-bindings/auto/api/ColorFrame.lua index ba3389570c..8d70edb97b 100644 --- a/cocos/scripting/lua-bindings/auto/api/ColorFrame.lua +++ b/cocos/scripting/lua-bindings/auto/api/ColorFrame.lua @@ -5,41 +5,49 @@ -- @parent_module ccs -------------------------------- +-- -- @function [parent=#ColorFrame] getAlpha -- @param self -- @return unsigned char#unsigned char ret (return value: unsigned char) -------------------------------- +-- -- @function [parent=#ColorFrame] getColor -- @param self -- @return color3b_table#color3b_table ret (return value: color3b_table) -------------------------------- +-- -- @function [parent=#ColorFrame] setAlpha -- @param self --- @param #unsigned char char +-- @param #unsigned char alpha -------------------------------- +-- -- @function [parent=#ColorFrame] setColor -- @param self --- @param #color3b_table color3b +-- @param #color3b_table color -------------------------------- +-- -- @function [parent=#ColorFrame] create -- @param self -- @return ColorFrame#ColorFrame ret (return value: ccs.ColorFrame) -------------------------------- +-- -- @function [parent=#ColorFrame] apply -- @param self --- @param #float float +-- @param #float percent -------------------------------- +-- -- @function [parent=#ColorFrame] clone -- @param self -- @return Frame#Frame ret (return value: ccs.Frame) -------------------------------- +-- -- @function [parent=#ColorFrame] ColorFrame -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/ComAttribute.lua b/cocos/scripting/lua-bindings/auto/api/ComAttribute.lua index ea707b9cd1..4924c02278 100644 --- a/cocos/scripting/lua-bindings/auto/api/ComAttribute.lua +++ b/cocos/scripting/lua-bindings/auto/api/ComAttribute.lua @@ -5,82 +5,95 @@ -- @parent_module ccs -------------------------------- +-- -- @function [parent=#ComAttribute] getFloat -- @param self --- @param #string str --- @param #float float +-- @param #string key +-- @param #float def -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#ComAttribute] getString -- @param self --- @param #string str --- @param #string str +-- @param #string key +-- @param #string def -- @return string#string ret (return value: string) -------------------------------- +-- -- @function [parent=#ComAttribute] setFloat -- @param self --- @param #string str --- @param #float float +-- @param #string key +-- @param #float value -------------------------------- +-- -- @function [parent=#ComAttribute] setString -- @param self --- @param #string str --- @param #string str +-- @param #string key +-- @param #string value -------------------------------- +-- -- @function [parent=#ComAttribute] getBool -- @param self --- @param #string str --- @param #bool bool +-- @param #string key +-- @param #bool def -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#ComAttribute] setInt -- @param self --- @param #string str --- @param #int int +-- @param #string key +-- @param #int value -------------------------------- +-- -- @function [parent=#ComAttribute] parse -- @param self --- @param #string str +-- @param #string jsonFile -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#ComAttribute] getInt -- @param self --- @param #string str --- @param #int int +-- @param #string key +-- @param #int def -- @return int#int ret (return value: int) -------------------------------- +-- -- @function [parent=#ComAttribute] setBool -- @param self --- @param #string str --- @param #bool bool +-- @param #string key +-- @param #bool value -------------------------------- +-- -- @function [parent=#ComAttribute] create -- @param self -- @return ComAttribute#ComAttribute ret (return value: ccs.ComAttribute) -------------------------------- +-- -- @function [parent=#ComAttribute] createInstance -- @param self -- @return Ref#Ref ret (return value: cc.Ref) -------------------------------- +-- -- @function [parent=#ComAttribute] init -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#ComAttribute] serialize -- @param self --- @param #void void +-- @param #void r -- @return bool#bool ret (return value: bool) return nil diff --git a/cocos/scripting/lua-bindings/auto/api/ComAudio.lua b/cocos/scripting/lua-bindings/auto/api/ComAudio.lua index b7d19dbb4b..a79ab68966 100644 --- a/cocos/scripting/lua-bindings/auto/api/ComAudio.lua +++ b/cocos/scripting/lua-bindings/auto/api/ComAudio.lua @@ -5,35 +5,42 @@ -- @parent_module ccs -------------------------------- +-- -- @function [parent=#ComAudio] stopAllEffects -- @param self -------------------------------- +-- -- @function [parent=#ComAudio] getEffectsVolume -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#ComAudio] stopEffect -- @param self --- @param #unsigned int int +-- @param #unsigned int nSoundId -------------------------------- +-- -- @function [parent=#ComAudio] getBackgroundMusicVolume -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#ComAudio] willPlayBackgroundMusic -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#ComAudio] setBackgroundMusicVolume -- @param self --- @param #float float +-- @param #float volume -------------------------------- +-- -- @function [parent=#ComAudio] end -- @param self @@ -42,34 +49,40 @@ -- @overload self, bool -- @function [parent=#ComAudio] stopBackgroundMusic -- @param self --- @param #bool bool +-- @param #bool bReleaseData -------------------------------- +-- -- @function [parent=#ComAudio] pauseBackgroundMusic -- @param self -------------------------------- +-- -- @function [parent=#ComAudio] isBackgroundMusicPlaying -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#ComAudio] isLoop -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#ComAudio] resumeAllEffects -- @param self -------------------------------- +-- -- @function [parent=#ComAudio] pauseAllEffects -- @param self -------------------------------- +-- -- @function [parent=#ComAudio] preloadBackgroundMusic -- @param self --- @param #char char +-- @param #char pszFilePath -------------------------------- -- @overload self, char @@ -77,8 +90,8 @@ -- @overload self -- @function [parent=#ComAudio] playBackgroundMusic -- @param self --- @param #char char --- @param #bool bool +-- @param #char pszFilePath +-- @param #bool bLoop -------------------------------- -- @overload self, char @@ -86,85 +99,101 @@ -- @overload self -- @function [parent=#ComAudio] playEffect -- @param self --- @param #char char --- @param #bool bool +-- @param #char pszFilePath +-- @param #bool bLoop -- @return unsigned int#unsigned int ret (retunr value: unsigned int) -------------------------------- +-- -- @function [parent=#ComAudio] preloadEffect -- @param self --- @param #char char +-- @param #char pszFilePath -------------------------------- +-- -- @function [parent=#ComAudio] setLoop -- @param self --- @param #bool bool +-- @param #bool bLoop -------------------------------- +-- -- @function [parent=#ComAudio] unloadEffect -- @param self --- @param #char char +-- @param #char pszFilePath -------------------------------- +-- -- @function [parent=#ComAudio] rewindBackgroundMusic -- @param self -------------------------------- +-- -- @function [parent=#ComAudio] pauseEffect -- @param self --- @param #unsigned int int +-- @param #unsigned int nSoundId -------------------------------- +-- -- @function [parent=#ComAudio] resumeBackgroundMusic -- @param self -------------------------------- +-- -- @function [parent=#ComAudio] setFile -- @param self --- @param #char char +-- @param #char pszFilePath -------------------------------- +-- -- @function [parent=#ComAudio] setEffectsVolume -- @param self --- @param #float float +-- @param #float volume -------------------------------- +-- -- @function [parent=#ComAudio] getFile -- @param self -- @return char#char ret (return value: char) -------------------------------- +-- -- @function [parent=#ComAudio] resumeEffect -- @param self --- @param #unsigned int int +-- @param #unsigned int nSoundId -------------------------------- +-- -- @function [parent=#ComAudio] create -- @param self -- @return ComAudio#ComAudio ret (return value: ccs.ComAudio) -------------------------------- +-- -- @function [parent=#ComAudio] createInstance -- @param self -- @return Ref#Ref ret (return value: cc.Ref) -------------------------------- +-- -- @function [parent=#ComAudio] setEnabled -- @param self --- @param #bool bool +-- @param #bool b -------------------------------- +-- -- @function [parent=#ComAudio] isEnabled -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#ComAudio] serialize -- @param self --- @param #void void +-- @param #void r -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#ComAudio] init -- @param self -- @return bool#bool ret (return value: bool) diff --git a/cocos/scripting/lua-bindings/auto/api/ComController.lua b/cocos/scripting/lua-bindings/auto/api/ComController.lua index 381558d96e..9eed2a6c57 100644 --- a/cocos/scripting/lua-bindings/auto/api/ComController.lua +++ b/cocos/scripting/lua-bindings/auto/api/ComController.lua @@ -5,36 +5,43 @@ -- @parent_module ccs -------------------------------- +-- -- @function [parent=#ComController] create -- @param self -- @return ComController#ComController ret (return value: ccs.ComController) -------------------------------- +-- -- @function [parent=#ComController] createInstance -- @param self -- @return Ref#Ref ret (return value: cc.Ref) -------------------------------- +-- -- @function [parent=#ComController] setEnabled -- @param self --- @param #bool bool +-- @param #bool b -------------------------------- +-- -- @function [parent=#ComController] isEnabled -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#ComController] update -- @param self --- @param #float float +-- @param #float delta -------------------------------- +-- -- @function [parent=#ComController] init -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- js ctor -- @function [parent=#ComController] ComController -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/ComRender.lua b/cocos/scripting/lua-bindings/auto/api/ComRender.lua index 9c69bbac35..afc835a203 100644 --- a/cocos/scripting/lua-bindings/auto/api/ComRender.lua +++ b/cocos/scripting/lua-bindings/auto/api/ComRender.lua @@ -5,11 +5,13 @@ -- @parent_module ccs -------------------------------- +-- -- @function [parent=#ComRender] setNode -- @param self -- @param #cc.Node node -------------------------------- +-- -- @function [parent=#ComRender] getNode -- @param self -- @return Node#Node ret (return value: cc.Node) @@ -20,18 +22,20 @@ -- @function [parent=#ComRender] create -- @param self -- @param #cc.Node node --- @param #char char +-- @param #char comName -- @return ComRender#ComRender ret (retunr value: ccs.ComRender) -------------------------------- +-- -- @function [parent=#ComRender] createInstance -- @param self -- @return Ref#Ref ret (return value: cc.Ref) -------------------------------- +-- -- @function [parent=#ComRender] serialize -- @param self --- @param #void void +-- @param #void r -- @return bool#bool ret (return value: bool) return nil diff --git a/cocos/scripting/lua-bindings/auto/api/Component.lua b/cocos/scripting/lua-bindings/auto/api/Component.lua index 1c22bbb440..1f4132282b 100644 --- a/cocos/scripting/lua-bindings/auto/api/Component.lua +++ b/cocos/scripting/lua-bindings/auto/api/Component.lua @@ -5,46 +5,55 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#Component] setEnabled -- @param self --- @param #bool bool +-- @param #bool b -------------------------------- +-- -- @function [parent=#Component] setName -- @param self --- @param #string str +-- @param #string name -------------------------------- +-- -- @function [parent=#Component] isEnabled -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#Component] update -- @param self --- @param #float float +-- @param #float delta -------------------------------- +-- -- @function [parent=#Component] getOwner -- @param self -- @return Node#Node ret (return value: cc.Node) -------------------------------- +-- -- @function [parent=#Component] init -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#Component] setOwner -- @param self --- @param #cc.Node node +-- @param #cc.Node pOwner -------------------------------- +-- -- @function [parent=#Component] getName -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- -- @function [parent=#Component] create -- @param self -- @return Component#Component ret (return value: cc.Component) diff --git a/cocos/scripting/lua-bindings/auto/api/Console.lua b/cocos/scripting/lua-bindings/auto/api/Console.lua index cdca8f4060..25abbbf30c 100644 --- a/cocos/scripting/lua-bindings/auto/api/Console.lua +++ b/cocos/scripting/lua-bindings/auto/api/Console.lua @@ -5,24 +5,28 @@ -- @parent_module cc -------------------------------- +-- stops the Console. 'stop' will be called at destruction time as well -- @function [parent=#Console] stop -- @param self -------------------------------- +-- starts listening to specifed TCP port -- @function [parent=#Console] listenOnTCP -- @param self --- @param #int int +-- @param #int port -- @return bool#bool ret (return value: bool) -------------------------------- +-- starts listening to specifed file descriptor -- @function [parent=#Console] listenOnFileDescriptor -- @param self --- @param #int int +-- @param #int fd -- @return bool#bool ret (return value: bool) -------------------------------- +-- log something in the console -- @function [parent=#Console] log -- @param self --- @param #char char +-- @param #char buf return nil diff --git a/cocos/scripting/lua-bindings/auto/api/ContourData.lua b/cocos/scripting/lua-bindings/auto/api/ContourData.lua index f1a46b0aa1..078b7483de 100644 --- a/cocos/scripting/lua-bindings/auto/api/ContourData.lua +++ b/cocos/scripting/lua-bindings/auto/api/ContourData.lua @@ -5,21 +5,25 @@ -- @parent_module ccs -------------------------------- +-- -- @function [parent=#ContourData] init -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#ContourData] addVertex -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table vertex -------------------------------- +-- -- @function [parent=#ContourData] create -- @param self -- @return ContourData#ContourData ret (return value: ccs.ContourData) -------------------------------- +-- js ctor -- @function [parent=#ContourData] ContourData -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/Control.lua b/cocos/scripting/lua-bindings/auto/api/Control.lua index 8e832134da..df1f899b52 100644 --- a/cocos/scripting/lua-bindings/auto/api/Control.lua +++ b/cocos/scripting/lua-bindings/auto/api/Control.lua @@ -5,53 +5,65 @@ -- @parent_module cc -------------------------------- +-- Tells whether the control is enabled. -- @function [parent=#Control] setEnabled -- @param self --- @param #bool bool +-- @param #bool bEnabled -------------------------------- +-- -- @function [parent=#Control] onTouchMoved -- @param self -- @param #cc.Touch touch -- @param #cc.Event event -------------------------------- +-- -- @function [parent=#Control] getState -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- -- @function [parent=#Control] onTouchEnded -- @param self -- @param #cc.Touch touch -- @param #cc.Event event -------------------------------- +-- Sends action messages for the given control events.
+-- param controlEvents A bitmask whose set flags specify the control events for
+-- which action messages are sent. See "CCControlEvent" for bitmask constants. -- @function [parent=#Control] sendActionsForControlEvents -- @param self --- @param #int eventtype +-- @param #int controlEvents -------------------------------- +-- A Boolean value that determines the control selected state. -- @function [parent=#Control] setSelected -- @param self --- @param #bool bool +-- @param #bool bSelected -------------------------------- +-- -- @function [parent=#Control] isEnabled -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#Control] onTouchCancelled -- @param self -- @param #cc.Touch touch -- @param #cc.Event event -------------------------------- +-- Updates the control layout using its current internal state. -- @function [parent=#Control] needsLayout -- @param self -------------------------------- +-- -- @function [parent=#Control] onTouchBegan -- @param self -- @param #cc.Touch touch @@ -59,50 +71,64 @@ -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#Control] hasVisibleParents -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#Control] isSelected -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- Returns a boolean value that indicates whether a touch is inside the bounds
+-- of the receiver. The given touch must be relative to the world.
+-- param touch A Touch object that represents a touch.
+-- return Whether a touch is inside the receiver's rect. -- @function [parent=#Control] isTouchInside -- @param self -- @param #cc.Touch touch -- @return bool#bool ret (return value: bool) -------------------------------- +-- A Boolean value that determines whether the control is highlighted. -- @function [parent=#Control] setHighlighted -- @param self --- @param #bool bool +-- @param #bool bHighlighted -------------------------------- +-- Returns a point corresponding to the touh location converted into the
+-- control space coordinates.
+-- param touch A Touch object that represents a touch. -- @function [parent=#Control] getTouchLocation -- @param self -- @param #cc.Touch touch -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- -- @function [parent=#Control] isHighlighted -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- Creates a Control object -- @function [parent=#Control] create -- @param self -- @return Control#Control ret (return value: cc.Control) -------------------------------- +-- -- @function [parent=#Control] isOpacityModifyRGB -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#Control] setOpacityModifyRGB -- @param self --- @param #bool bool +-- @param #bool bOpacityModifyRGB return nil diff --git a/cocos/scripting/lua-bindings/auto/api/ControlButton.lua b/cocos/scripting/lua-bindings/auto/api/ControlButton.lua index 005e6b28da..5d757d9b16 100644 --- a/cocos/scripting/lua-bindings/auto/api/ControlButton.lua +++ b/cocos/scripting/lua-bindings/auto/api/ControlButton.lua @@ -5,102 +5,133 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#ControlButton] isPushed -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#ControlButton] setSelected -- @param self --- @param #bool bool +-- @param #bool enabled -------------------------------- +-- Sets the title label to use for the specified state.
+-- If a property is not specified for a state, the default is to use
+-- the ButtonStateNormal value.
+-- param label The title label to use for the specified state.
+-- param state The state that uses the specified title. The values are described
+-- in "CCControlState". -- @function [parent=#ControlButton] setTitleLabelForState -- @param self --- @param #cc.Node node +-- @param #cc.Node label -- @param #int state -------------------------------- +-- -- @function [parent=#ControlButton] setAdjustBackgroundImage -- @param self --- @param #bool bool +-- @param #bool adjustBackgroundImage -------------------------------- +-- -- @function [parent=#ControlButton] setHighlighted -- @param self --- @param #bool bool +-- @param #bool enabled -------------------------------- +-- -- @function [parent=#ControlButton] setZoomOnTouchDown -- @param self --- @param #bool bool +-- @param #bool var -------------------------------- +-- Sets the title string to use for the specified state.
+-- If a property is not specified for a state, the default is to use
+-- the ButtonStateNormal value.
+-- param title The title string to use for the specified state.
+-- param state The state that uses the specified title. The values are described
+-- in "CCControlState". -- @function [parent=#ControlButton] setTitleForState -- @param self --- @param #string str +-- @param #string title -- @param #int state -------------------------------- +-- -- @function [parent=#ControlButton] setLabelAnchorPoint -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table var -------------------------------- +-- -- @function [parent=#ControlButton] getLabelAnchorPoint -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- -- @function [parent=#ControlButton] getTitleTTFSizeForState -- @param self -- @param #int state -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#ControlButton] setTitleTTFForState -- @param self --- @param #string str +-- @param #string fntFile -- @param #int state -------------------------------- +-- -- @function [parent=#ControlButton] setTitleTTFSizeForState -- @param self --- @param #float float +-- @param #float size -- @param #int state -------------------------------- +-- -- @function [parent=#ControlButton] setTitleLabel -- @param self --- @param #cc.Node node +-- @param #cc.Node var -------------------------------- +-- -- @function [parent=#ControlButton] setPreferredSize -- @param self --- @param #size_table size +-- @param #size_table var -------------------------------- +-- -- @function [parent=#ControlButton] getCurrentTitleColor -- @param self -- @return color3b_table#color3b_table ret (return value: color3b_table) -------------------------------- +-- -- @function [parent=#ControlButton] setEnabled -- @param self --- @param #bool bool +-- @param #bool enabled -------------------------------- +-- Returns the background sprite used for a state.
+-- param state The state that uses the background sprite. Possible values are
+-- described in "CCControlState". -- @function [parent=#ControlButton] getBackgroundSpriteForState -- @param self -- @param #int state --- @return Scale9Sprite#Scale9Sprite ret (return value: cc.Scale9Sprite) +-- @return Scale9Sprite#Scale9Sprite ret (return value: ccui.Scale9Sprite) -------------------------------- +-- -- @function [parent=#ControlButton] getHorizontalOrigin -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- -- @function [parent=#ControlButton] needsLayout -- @param self @@ -112,161 +143,209 @@ -- @return string#string ret (retunr value: string) -------------------------------- +-- -- @function [parent=#ControlButton] getScaleRatio -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#ControlButton] getTitleTTFForState -- @param self -- @param #int state -- @return string#string ret (return value: string) -------------------------------- +-- -- @function [parent=#ControlButton] getBackgroundSprite -- @param self --- @return Scale9Sprite#Scale9Sprite ret (return value: cc.Scale9Sprite) +-- @return Scale9Sprite#Scale9Sprite ret (return value: ccui.Scale9Sprite) -------------------------------- +-- Returns the title color used for a state.
+-- param state The state that uses the specified color. The values are described
+-- in "CCControlState".
+-- return The color of the title for the specified state. -- @function [parent=#ControlButton] getTitleColorForState -- @param self -- @param #int state -- @return color3b_table#color3b_table ret (return value: color3b_table) -------------------------------- +-- Sets the color of the title to use for the specified state.
+-- param color The color of the title to use for the specified state.
+-- param state The state that uses the specified color. The values are described
+-- in "CCControlState". -- @function [parent=#ControlButton] setTitleColorForState -- @param self --- @param #color3b_table color3b +-- @param #color3b_table color -- @param #int state -------------------------------- +-- Adjust the background image. YES by default. If the property is set to NO, the
+-- background will use the prefered size of the background image. -- @function [parent=#ControlButton] doesAdjustBackgroundImage -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- Sets the background spriteFrame to use for the specified button state.
+-- param spriteFrame The background spriteFrame to use for the specified state.
+-- param state The state that uses the specified image. The values are described
+-- in "CCControlState". -- @function [parent=#ControlButton] setBackgroundSpriteFrameForState -- @param self --- @param #cc.SpriteFrame spriteframe +-- @param #cc.SpriteFrame spriteFrame -- @param #int state -------------------------------- +-- Sets the background sprite to use for the specified button state.
+-- param sprite The background sprite to use for the specified state.
+-- param state The state that uses the specified image. The values are described
+-- in "CCControlState". -- @function [parent=#ControlButton] setBackgroundSpriteForState -- @param self --- @param #cc.Scale9Sprite scale9sprite +-- @param #ccui.Scale9Sprite sprite -- @param #int state -------------------------------- +-- -- @function [parent=#ControlButton] setScaleRatio -- @param self --- @param #float float +-- @param #float var -------------------------------- +-- -- @function [parent=#ControlButton] setBackgroundSprite -- @param self --- @param #cc.Scale9Sprite scale9sprite +-- @param #ccui.Scale9Sprite var -------------------------------- +-- -- @function [parent=#ControlButton] getTitleLabel -- @param self -- @return Node#Node ret (return value: cc.Node) -------------------------------- +-- -- @function [parent=#ControlButton] getPreferredSize -- @param self -- @return size_table#size_table ret (return value: size_table) -------------------------------- +-- -- @function [parent=#ControlButton] getVerticalMargin -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- Returns the title label used for a state.
+-- param state The state that uses the title label. Possible values are described
+-- in "CCControlState". -- @function [parent=#ControlButton] getTitleLabelForState -- @param self -- @param #int state -- @return Node#Node ret (return value: cc.Node) -------------------------------- +-- -- @function [parent=#ControlButton] setMargins -- @param self --- @param #int int --- @param #int int +-- @param #int marginH +-- @param #int marginV -------------------------------- +-- Sets the font of the label, changes the label to a BMFont if neccessary.
+-- param fntFile The name of the font to change to
+-- param state The state that uses the specified fntFile. The values are described
+-- in "CCControlState". -- @function [parent=#ControlButton] setTitleBMFontForState -- @param self --- @param #string str +-- @param #string fntFile -- @param #int state -------------------------------- +-- -- @function [parent=#ControlButton] getTitleBMFontForState -- @param self -- @param #int state -- @return string#string ret (return value: string) -------------------------------- +-- -- @function [parent=#ControlButton] getZoomOnTouchDown -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- Returns the title used for a state.
+-- param state The state that uses the title. Possible values are described in
+-- "CCControlState".
+-- return The title for the specified state. -- @function [parent=#ControlButton] getTitleForState -- @param self -- @param #int state -- @return string#string ret (return value: string) -------------------------------- --- @overload self, cc.Scale9Sprite +-- @overload self, ccui.Scale9Sprite -- @overload self --- @overload self, cc.Node, cc.Scale9Sprite +-- @overload self, cc.Node, ccui.Scale9Sprite -- @overload self, string, string, float -- @function [parent=#ControlButton] create -- @param self --- @param #string str --- @param #string str --- @param #float float +-- @param #string title +-- @param #string fontName +-- @param #float fontSize -- @return ControlButton#ControlButton ret (retunr value: cc.ControlButton) -------------------------------- +-- -- @function [parent=#ControlButton] onTouchMoved -- @param self -- @param #cc.Touch touch -- @param #cc.Event event -------------------------------- +-- -- @function [parent=#ControlButton] onTouchEnded -- @param self -- @param #cc.Touch touch -- @param #cc.Event event -------------------------------- +-- -- @function [parent=#ControlButton] setColor -- @param self --- @param #color3b_table color3b +-- @param #color3b_table -------------------------------- +-- -- @function [parent=#ControlButton] onTouchCancelled -- @param self -- @param #cc.Touch touch -- @param #cc.Event event -------------------------------- +-- -- @function [parent=#ControlButton] setOpacity -- @param self --- @param #unsigned char char +-- @param #unsigned char var -------------------------------- +-- -- @function [parent=#ControlButton] updateDisplayedOpacity -- @param self --- @param #unsigned char char +-- @param #unsigned char parentOpacity -------------------------------- +-- -- @function [parent=#ControlButton] updateDisplayedColor -- @param self --- @param #color3b_table color3b +-- @param #color3b_table parentColor -------------------------------- +-- -- @function [parent=#ControlButton] onTouchBegan -- @param self -- @param #cc.Touch touch diff --git a/cocos/scripting/lua-bindings/auto/api/ControlColourPicker.lua b/cocos/scripting/lua-bindings/auto/api/ControlColourPicker.lua index f7e3e3cbe2..b46d5e855b 100644 --- a/cocos/scripting/lua-bindings/auto/api/ControlColourPicker.lua +++ b/cocos/scripting/lua-bindings/auto/api/ControlColourPicker.lua @@ -5,68 +5,81 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#ControlColourPicker] setEnabled -- @param self --- @param #bool bool +-- @param #bool bEnabled -------------------------------- +-- -- @function [parent=#ControlColourPicker] getHuePicker -- @param self -- @return ControlHuePicker#ControlHuePicker ret (return value: cc.ControlHuePicker) -------------------------------- +-- -- @function [parent=#ControlColourPicker] setColor -- @param self --- @param #color3b_table color3b +-- @param #color3b_table colorValue -------------------------------- +-- -- @function [parent=#ControlColourPicker] hueSliderValueChanged -- @param self --- @param #cc.Ref ref --- @param #int eventtype +-- @param #cc.Ref sender +-- @param #int controlEvent -------------------------------- +-- -- @function [parent=#ControlColourPicker] getcolourPicker -- @param self -- @return ControlSaturationBrightnessPicker#ControlSaturationBrightnessPicker ret (return value: cc.ControlSaturationBrightnessPicker) -------------------------------- +-- -- @function [parent=#ControlColourPicker] setBackground -- @param self --- @param #cc.Sprite sprite +-- @param #cc.Sprite var -------------------------------- +-- -- @function [parent=#ControlColourPicker] init -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#ControlColourPicker] setcolourPicker -- @param self --- @param #cc.ControlSaturationBrightnessPicker controlsaturationbrightnesspicker +-- @param #cc.ControlSaturationBrightnessPicker var -------------------------------- +-- -- @function [parent=#ControlColourPicker] colourSliderValueChanged -- @param self --- @param #cc.Ref ref --- @param #int eventtype +-- @param #cc.Ref sender +-- @param #int controlEvent -------------------------------- +-- -- @function [parent=#ControlColourPicker] setHuePicker -- @param self --- @param #cc.ControlHuePicker controlhuepicker +-- @param #cc.ControlHuePicker var -------------------------------- +-- -- @function [parent=#ControlColourPicker] getBackground -- @param self -- @return Sprite#Sprite ret (return value: cc.Sprite) -------------------------------- +-- -- @function [parent=#ControlColourPicker] create -- @param self -- @return ControlColourPicker#ControlColourPicker ret (return value: cc.ControlColourPicker) -------------------------------- +-- js ctor -- @function [parent=#ControlColourPicker] ControlColourPicker -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/ControlHuePicker.lua b/cocos/scripting/lua-bindings/auto/api/ControlHuePicker.lua index bedc24c43a..d907f2c9dd 100644 --- a/cocos/scripting/lua-bindings/auto/api/ControlHuePicker.lua +++ b/cocos/scripting/lua-bindings/auto/api/ControlHuePicker.lua @@ -5,83 +5,98 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#ControlHuePicker] setEnabled -- @param self --- @param #bool bool +-- @param #bool enabled -------------------------------- +-- -- @function [parent=#ControlHuePicker] initWithTargetAndPos -- @param self --- @param #cc.Node node --- @param #vec2_table vec2 +-- @param #cc.Node target +-- @param #vec2_table pos -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#ControlHuePicker] setHue -- @param self --- @param #float float +-- @param #float val -------------------------------- +-- -- @function [parent=#ControlHuePicker] getStartPos -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- -- @function [parent=#ControlHuePicker] getHue -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#ControlHuePicker] getSlider -- @param self -- @return Sprite#Sprite ret (return value: cc.Sprite) -------------------------------- +-- -- @function [parent=#ControlHuePicker] setBackground -- @param self --- @param #cc.Sprite sprite +-- @param #cc.Sprite var -------------------------------- +-- -- @function [parent=#ControlHuePicker] setHuePercentage -- @param self --- @param #float float +-- @param #float val -------------------------------- +-- -- @function [parent=#ControlHuePicker] getBackground -- @param self -- @return Sprite#Sprite ret (return value: cc.Sprite) -------------------------------- +-- -- @function [parent=#ControlHuePicker] getHuePercentage -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#ControlHuePicker] setSlider -- @param self --- @param #cc.Sprite sprite +-- @param #cc.Sprite var -------------------------------- +-- -- @function [parent=#ControlHuePicker] create -- @param self --- @param #cc.Node node --- @param #vec2_table vec2 +-- @param #cc.Node target +-- @param #vec2_table pos -- @return ControlHuePicker#ControlHuePicker ret (return value: cc.ControlHuePicker) -------------------------------- +-- -- @function [parent=#ControlHuePicker] onTouchMoved -- @param self --- @param #cc.Touch touch --- @param #cc.Event event +-- @param #cc.Touch pTouch +-- @param #cc.Event pEvent -------------------------------- +-- -- @function [parent=#ControlHuePicker] onTouchBegan -- @param self -- @param #cc.Touch touch --- @param #cc.Event event +-- @param #cc.Event pEvent -- @return bool#bool ret (return value: bool) -------------------------------- +-- js ctor -- @function [parent=#ControlHuePicker] ControlHuePicker -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/ControlPotentiometer.lua b/cocos/scripting/lua-bindings/auto/api/ControlPotentiometer.lua index 0df5064b16..a5581e6695 100644 --- a/cocos/scripting/lua-bindings/auto/api/ControlPotentiometer.lua +++ b/cocos/scripting/lua-bindings/auto/api/ControlPotentiometer.lua @@ -5,143 +5,170 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#ControlPotentiometer] setPreviousLocation -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table var -------------------------------- +-- -- @function [parent=#ControlPotentiometer] setValue -- @param self --- @param #float float +-- @param #float value -------------------------------- +-- -- @function [parent=#ControlPotentiometer] getProgressTimer -- @param self -- @return ProgressTimer#ProgressTimer ret (return value: cc.ProgressTimer) -------------------------------- +-- -- @function [parent=#ControlPotentiometer] getMaximumValue -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- Returns the angle in degree between line1 and line2. -- @function [parent=#ControlPotentiometer] angleInDegreesBetweenLineFromPoint_toPoint_toLineFromPoint_toPoint -- @param self --- @param #vec2_table vec2 --- @param #vec2_table vec2 --- @param #vec2_table vec2 --- @param #vec2_table vec2 +-- @param #vec2_table beginLineA +-- @param #vec2_table endLineA +-- @param #vec2_table beginLineB +-- @param #vec2_table endLineB -- @return float#float ret (return value: float) -------------------------------- +-- Factorize the event dispath into these methods. -- @function [parent=#ControlPotentiometer] potentiometerBegan -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table location -------------------------------- +-- -- @function [parent=#ControlPotentiometer] setMaximumValue -- @param self --- @param #float float +-- @param #float maximumValue -------------------------------- +-- -- @function [parent=#ControlPotentiometer] getMinimumValue -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#ControlPotentiometer] setThumbSprite -- @param self --- @param #cc.Sprite sprite +-- @param #cc.Sprite var -------------------------------- +-- -- @function [parent=#ControlPotentiometer] getValue -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#ControlPotentiometer] getPreviousLocation -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- Returns the distance between the point1 and point2. -- @function [parent=#ControlPotentiometer] distanceBetweenPointAndPoint -- @param self --- @param #vec2_table vec2 --- @param #vec2_table vec2 +-- @param #vec2_table point1 +-- @param #vec2_table point2 -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#ControlPotentiometer] potentiometerEnded -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table location -------------------------------- +-- -- @function [parent=#ControlPotentiometer] setProgressTimer -- @param self --- @param #cc.ProgressTimer progresstimer +-- @param #cc.ProgressTimer var -------------------------------- +-- -- @function [parent=#ControlPotentiometer] setMinimumValue -- @param self --- @param #float float +-- @param #float minimumValue -------------------------------- +-- -- @function [parent=#ControlPotentiometer] getThumbSprite -- @param self -- @return Sprite#Sprite ret (return value: cc.Sprite) -------------------------------- +-- Initializes a potentiometer with a track sprite and a progress bar.
+-- param trackSprite Sprite, that is used as a background.
+-- param progressTimer ProgressTimer, that is used as a progress bar. -- @function [parent=#ControlPotentiometer] initWithTrackSprite_ProgressTimer_ThumbSprite -- @param self --- @param #cc.Sprite sprite --- @param #cc.ProgressTimer progresstimer --- @param #cc.Sprite sprite +-- @param #cc.Sprite trackSprite +-- @param #cc.ProgressTimer progressTimer +-- @param #cc.Sprite thumbSprite -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#ControlPotentiometer] potentiometerMoved -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table location -------------------------------- +-- Creates potentiometer with a track filename and a progress filename. -- @function [parent=#ControlPotentiometer] create -- @param self --- @param #char char --- @param #char char --- @param #char char +-- @param #char backgroundFile +-- @param #char progressFile +-- @param #char thumbFile -- @return ControlPotentiometer#ControlPotentiometer ret (return value: cc.ControlPotentiometer) -------------------------------- +-- -- @function [parent=#ControlPotentiometer] isTouchInside -- @param self -- @param #cc.Touch touch -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#ControlPotentiometer] setEnabled -- @param self --- @param #bool bool +-- @param #bool enabled -------------------------------- +-- -- @function [parent=#ControlPotentiometer] onTouchMoved -- @param self --- @param #cc.Touch touch --- @param #cc.Event event +-- @param #cc.Touch pTouch +-- @param #cc.Event pEvent -------------------------------- +-- -- @function [parent=#ControlPotentiometer] onTouchEnded -- @param self --- @param #cc.Touch touch --- @param #cc.Event event +-- @param #cc.Touch pTouch +-- @param #cc.Event pEvent -------------------------------- +-- -- @function [parent=#ControlPotentiometer] onTouchBegan -- @param self --- @param #cc.Touch touch --- @param #cc.Event event +-- @param #cc.Touch pTouch +-- @param #cc.Event pEvent -- @return bool#bool ret (return value: bool) -------------------------------- +-- js ctor -- @function [parent=#ControlPotentiometer] ControlPotentiometer -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/ControlSaturationBrightnessPicker.lua b/cocos/scripting/lua-bindings/auto/api/ControlSaturationBrightnessPicker.lua index 83a6a99694..332012a086 100644 --- a/cocos/scripting/lua-bindings/auto/api/ControlSaturationBrightnessPicker.lua +++ b/cocos/scripting/lua-bindings/auto/api/ControlSaturationBrightnessPicker.lua @@ -5,60 +5,71 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#ControlSaturationBrightnessPicker] getShadow -- @param self -- @return Sprite#Sprite ret (return value: cc.Sprite) -------------------------------- +-- -- @function [parent=#ControlSaturationBrightnessPicker] initWithTargetAndPos -- @param self --- @param #cc.Node node --- @param #vec2_table vec2 +-- @param #cc.Node target +-- @param #vec2_table pos -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#ControlSaturationBrightnessPicker] getStartPos -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- -- @function [parent=#ControlSaturationBrightnessPicker] getOverlay -- @param self -- @return Sprite#Sprite ret (return value: cc.Sprite) -------------------------------- +-- -- @function [parent=#ControlSaturationBrightnessPicker] setEnabled -- @param self --- @param #bool bool +-- @param #bool enabled -------------------------------- +-- -- @function [parent=#ControlSaturationBrightnessPicker] getSlider -- @param self -- @return Sprite#Sprite ret (return value: cc.Sprite) -------------------------------- +-- -- @function [parent=#ControlSaturationBrightnessPicker] getBackground -- @param self -- @return Sprite#Sprite ret (return value: cc.Sprite) -------------------------------- +-- -- @function [parent=#ControlSaturationBrightnessPicker] getSaturation -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#ControlSaturationBrightnessPicker] getBrightness -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#ControlSaturationBrightnessPicker] create -- @param self --- @param #cc.Node node --- @param #vec2_table vec2 +-- @param #cc.Node target +-- @param #vec2_table pos -- @return ControlSaturationBrightnessPicker#ControlSaturationBrightnessPicker ret (return value: cc.ControlSaturationBrightnessPicker) -------------------------------- +-- js ctor -- @function [parent=#ControlSaturationBrightnessPicker] ControlSaturationBrightnessPicker -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/ControlSlider.lua b/cocos/scripting/lua-bindings/auto/api/ControlSlider.lua index d192cf7a93..33e66b6ccf 100644 --- a/cocos/scripting/lua-bindings/auto/api/ControlSlider.lua +++ b/cocos/scripting/lua-bindings/auto/api/ControlSlider.lua @@ -5,76 +5,91 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#ControlSlider] getSelectedThumbSprite -- @param self -- @return Sprite#Sprite ret (return value: cc.Sprite) -------------------------------- +-- -- @function [parent=#ControlSlider] locationFromTouch -- @param self -- @param #cc.Touch touch -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- -- @function [parent=#ControlSlider] setSelectedThumbSprite -- @param self --- @param #cc.Sprite sprite +-- @param #cc.Sprite var -------------------------------- +-- -- @function [parent=#ControlSlider] setProgressSprite -- @param self --- @param #cc.Sprite sprite +-- @param #cc.Sprite var -------------------------------- +-- -- @function [parent=#ControlSlider] getMaximumAllowedValue -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#ControlSlider] getMinimumAllowedValue -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#ControlSlider] getMinimumValue -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#ControlSlider] setThumbSprite -- @param self --- @param #cc.Sprite sprite +-- @param #cc.Sprite var -------------------------------- +-- -- @function [parent=#ControlSlider] setMinimumValue -- @param self --- @param #float float +-- @param #float val -------------------------------- +-- -- @function [parent=#ControlSlider] setMinimumAllowedValue -- @param self --- @param #float float +-- @param #float var -------------------------------- +-- -- @function [parent=#ControlSlider] setEnabled -- @param self --- @param #bool bool +-- @param #bool enabled -------------------------------- +-- -- @function [parent=#ControlSlider] setValue -- @param self --- @param #float float +-- @param #float val -------------------------------- +-- -- @function [parent=#ControlSlider] setMaximumValue -- @param self --- @param #float float +-- @param #float val -------------------------------- +-- -- @function [parent=#ControlSlider] needsLayout -- @param self -------------------------------- +-- -- @function [parent=#ControlSlider] getBackgroundSprite -- @param self -- @return Sprite#Sprite ret (return value: cc.Sprite) @@ -84,47 +99,54 @@ -- @overload self, cc.Sprite, cc.Sprite, cc.Sprite -- @function [parent=#ControlSlider] initWithSprites -- @param self --- @param #cc.Sprite sprite --- @param #cc.Sprite sprite --- @param #cc.Sprite sprite --- @param #cc.Sprite sprite +-- @param #cc.Sprite backgroundSprite +-- @param #cc.Sprite progressSprite +-- @param #cc.Sprite thumbSprite +-- @param #cc.Sprite selectedThumbSprite -- @return bool#bool ret (retunr value: bool) -------------------------------- +-- -- @function [parent=#ControlSlider] getMaximumValue -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#ControlSlider] isTouchInside -- @param self -- @param #cc.Touch touch -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#ControlSlider] getValue -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#ControlSlider] getThumbSprite -- @param self -- @return Sprite#Sprite ret (return value: cc.Sprite) -------------------------------- +-- -- @function [parent=#ControlSlider] getProgressSprite -- @param self -- @return Sprite#Sprite ret (return value: cc.Sprite) -------------------------------- +-- -- @function [parent=#ControlSlider] setBackgroundSprite -- @param self --- @param #cc.Sprite sprite +-- @param #cc.Sprite var -------------------------------- +-- -- @function [parent=#ControlSlider] setMaximumAllowedValue -- @param self --- @param #float float +-- @param #float var -------------------------------- -- @overload self, cc.Sprite, cc.Sprite, cc.Sprite @@ -133,13 +155,14 @@ -- @overload self, cc.Sprite, cc.Sprite, cc.Sprite, cc.Sprite -- @function [parent=#ControlSlider] create -- @param self --- @param #cc.Sprite sprite --- @param #cc.Sprite sprite --- @param #cc.Sprite sprite --- @param #cc.Sprite sprite +-- @param #cc.Sprite backgroundSprite +-- @param #cc.Sprite pogressSprite +-- @param #cc.Sprite thumbSprite +-- @param #cc.Sprite selectedThumbSprite -- @return ControlSlider#ControlSlider ret (retunr value: cc.ControlSlider) -------------------------------- +-- js ctor -- @function [parent=#ControlSlider] ControlSlider -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/ControlStepper.lua b/cocos/scripting/lua-bindings/auto/api/ControlStepper.lua index f7804e0d95..0e5009c367 100644 --- a/cocos/scripting/lua-bindings/auto/api/ControlStepper.lua +++ b/cocos/scripting/lua-bindings/auto/api/ControlStepper.lua @@ -5,138 +5,164 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#ControlStepper] setMinusSprite -- @param self --- @param #cc.Sprite sprite +-- @param #cc.Sprite var -------------------------------- +-- -- @function [parent=#ControlStepper] getMinusLabel -- @param self -- @return Label#Label ret (return value: cc.Label) -------------------------------- +-- -- @function [parent=#ControlStepper] setWraps -- @param self --- @param #bool bool +-- @param #bool wraps -------------------------------- +-- -- @function [parent=#ControlStepper] isContinuous -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#ControlStepper] getMinusSprite -- @param self -- @return Sprite#Sprite ret (return value: cc.Sprite) -------------------------------- +-- Update the layout of the stepper with the given touch location. -- @function [parent=#ControlStepper] updateLayoutUsingTouchLocation -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table location -------------------------------- +-- Set the numeric value of the stepper. If send is true, the Control::EventType::VALUE_CHANGED is sent. -- @function [parent=#ControlStepper] setValueWithSendingEvent -- @param self --- @param #double double --- @param #bool bool +-- @param #double value +-- @param #bool send -------------------------------- +-- -- @function [parent=#ControlStepper] getPlusLabel -- @param self -- @return Label#Label ret (return value: cc.Label) -------------------------------- +-- Stop the autorepeat. -- @function [parent=#ControlStepper] stopAutorepeat -- @param self -------------------------------- +-- -- @function [parent=#ControlStepper] setMinimumValue -- @param self --- @param #double double +-- @param #double minimumValue -------------------------------- +-- -- @function [parent=#ControlStepper] getPlusSprite -- @param self -- @return Sprite#Sprite ret (return value: cc.Sprite) -------------------------------- +-- -- @function [parent=#ControlStepper] setPlusSprite -- @param self --- @param #cc.Sprite sprite +-- @param #cc.Sprite var -------------------------------- +-- -- @function [parent=#ControlStepper] setMinusLabel -- @param self --- @param #cc.Label label +-- @param #cc.Label var -------------------------------- +-- -- @function [parent=#ControlStepper] setValue -- @param self --- @param #double double +-- @param #double value -------------------------------- +-- -- @function [parent=#ControlStepper] setStepValue -- @param self --- @param #double double +-- @param #double stepValue -------------------------------- +-- -- @function [parent=#ControlStepper] setMaximumValue -- @param self --- @param #double double +-- @param #double maximumValue -------------------------------- +-- -- @function [parent=#ControlStepper] update -- @param self --- @param #float float +-- @param #float dt -------------------------------- +-- Start the autorepeat increment/decrement. -- @function [parent=#ControlStepper] startAutorepeat -- @param self -------------------------------- +-- -- @function [parent=#ControlStepper] initWithMinusSpriteAndPlusSprite -- @param self --- @param #cc.Sprite sprite --- @param #cc.Sprite sprite +-- @param #cc.Sprite minusSprite +-- @param #cc.Sprite plusSprite -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#ControlStepper] getValue -- @param self -- @return double#double ret (return value: double) -------------------------------- +-- -- @function [parent=#ControlStepper] setPlusLabel -- @param self --- @param #cc.Label label +-- @param #cc.Label var -------------------------------- +-- -- @function [parent=#ControlStepper] create -- @param self --- @param #cc.Sprite sprite --- @param #cc.Sprite sprite +-- @param #cc.Sprite minusSprite +-- @param #cc.Sprite plusSprite -- @return ControlStepper#ControlStepper ret (return value: cc.ControlStepper) -------------------------------- +-- -- @function [parent=#ControlStepper] onTouchMoved -- @param self --- @param #cc.Touch touch --- @param #cc.Event event +-- @param #cc.Touch pTouch +-- @param #cc.Event pEvent -------------------------------- +-- -- @function [parent=#ControlStepper] onTouchEnded -- @param self --- @param #cc.Touch touch --- @param #cc.Event event +-- @param #cc.Touch pTouch +-- @param #cc.Event pEvent -------------------------------- +-- -- @function [parent=#ControlStepper] onTouchBegan -- @param self --- @param #cc.Touch touch --- @param #cc.Event event +-- @param #cc.Touch pTouch +-- @param #cc.Event pEvent -- @return bool#bool ret (return value: bool) -------------------------------- +-- js ctor -- @function [parent=#ControlStepper] ControlStepper -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/ControlSwitch.lua b/cocos/scripting/lua-bindings/auto/api/ControlSwitch.lua index fdff4eddfa..e7841e64f2 100644 --- a/cocos/scripting/lua-bindings/auto/api/ControlSwitch.lua +++ b/cocos/scripting/lua-bindings/auto/api/ControlSwitch.lua @@ -5,19 +5,21 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#ControlSwitch] setEnabled -- @param self --- @param #bool bool +-- @param #bool enabled -------------------------------- -- @overload self, bool -- @overload self, bool, bool -- @function [parent=#ControlSwitch] setOn -- @param self --- @param #bool bool --- @param #bool bool +-- @param #bool isOn +-- @param #bool animated -------------------------------- +-- -- @function [parent=#ControlSwitch] isOn -- @param self -- @return bool#bool ret (return value: bool) @@ -27,20 +29,22 @@ -- @overload self, cc.Sprite, cc.Sprite, cc.Sprite, cc.Sprite -- @function [parent=#ControlSwitch] initWithMaskSprite -- @param self --- @param #cc.Sprite sprite --- @param #cc.Sprite sprite --- @param #cc.Sprite sprite --- @param #cc.Sprite sprite --- @param #cc.Label label --- @param #cc.Label label +-- @param #cc.Sprite maskSprite +-- @param #cc.Sprite onSprite +-- @param #cc.Sprite offSprite +-- @param #cc.Sprite thumbSprite +-- @param #cc.Label onLabel +-- @param #cc.Label offLabel -- @return bool#bool ret (retunr value: bool) -------------------------------- +-- -- @function [parent=#ControlSwitch] hasMoved -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#ControlSwitch] locationFromTouch -- @param self -- @param #cc.Touch touch @@ -51,40 +55,45 @@ -- @overload self, cc.Sprite, cc.Sprite, cc.Sprite, cc.Sprite, cc.Label, cc.Label -- @function [parent=#ControlSwitch] create -- @param self --- @param #cc.Sprite sprite --- @param #cc.Sprite sprite --- @param #cc.Sprite sprite --- @param #cc.Sprite sprite --- @param #cc.Label label --- @param #cc.Label label +-- @param #cc.Sprite maskSprite +-- @param #cc.Sprite onSprite +-- @param #cc.Sprite offSprite +-- @param #cc.Sprite thumbSprite +-- @param #cc.Label onLabel +-- @param #cc.Label offLabel -- @return ControlSwitch#ControlSwitch ret (retunr value: cc.ControlSwitch) -------------------------------- +-- -- @function [parent=#ControlSwitch] onTouchMoved -- @param self --- @param #cc.Touch touch --- @param #cc.Event event +-- @param #cc.Touch pTouch +-- @param #cc.Event pEvent -------------------------------- +-- -- @function [parent=#ControlSwitch] onTouchEnded -- @param self --- @param #cc.Touch touch --- @param #cc.Event event +-- @param #cc.Touch pTouch +-- @param #cc.Event pEvent -------------------------------- +-- -- @function [parent=#ControlSwitch] onTouchCancelled -- @param self --- @param #cc.Touch touch --- @param #cc.Event event +-- @param #cc.Touch pTouch +-- @param #cc.Event pEvent -------------------------------- +-- -- @function [parent=#ControlSwitch] onTouchBegan -- @param self --- @param #cc.Touch touch --- @param #cc.Event event +-- @param #cc.Touch pTouch +-- @param #cc.Event pEvent -- @return bool#bool ret (return value: bool) -------------------------------- +-- js ctor -- @function [parent=#ControlSwitch] ControlSwitch -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/Controller.lua b/cocos/scripting/lua-bindings/auto/api/Controller.lua index 160b455817..25246a3bf9 100644 --- a/cocos/scripting/lua-bindings/auto/api/Controller.lua +++ b/cocos/scripting/lua-bindings/auto/api/Controller.lua @@ -4,48 +4,66 @@ -- @parent_module cc -------------------------------- +-- Activate receives key event from external key. e.g. back,menu.
+-- Controller receives only standard key which contained within enum Key by default.
+-- warning The API only work on the android platform for support diversified game controller.
+-- param externalKeyCode external key code
+-- param receive true if external key event on this controller should be receive, false otherwise. -- @function [parent=#Controller] receiveExternalKeyEvent -- @param self --- @param #int int --- @param #bool bool +-- @param #int externalKeyCode +-- @param #bool receive -------------------------------- +-- -- @function [parent=#Controller] getDeviceName -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- -- @function [parent=#Controller] isConnected -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#Controller] getDeviceId -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- Changes the tag that is used to identify the controller easily.
+-- param tag A integer that identifies the controller. -- @function [parent=#Controller] setTag -- @param self --- @param #int int +-- @param #int tag -------------------------------- +-- Returns a tag that is used to identify the controller easily.
+-- return An integer that identifies the controller. -- @function [parent=#Controller] getTag -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- To start discovering new controllers
+-- warning The API only work on the IOS platform.Empty implementation on Android -- @function [parent=#Controller] startDiscoveryController -- @param self -------------------------------- +-- End the discovery process
+-- warning The API only work on the IOS platform.Empty implementation on Android -- @function [parent=#Controller] stopDiscoveryController -- @param self -------------------------------- +-- Gets a controller with its tag
+-- param tag An identifier to find the controller. -- @function [parent=#Controller] getControllerByTag -- @param self --- @param #int int +-- @param #int tag -- @return Controller#Controller ret (return value: cc.Controller) return nil diff --git a/cocos/scripting/lua-bindings/auto/api/DelayTime.lua b/cocos/scripting/lua-bindings/auto/api/DelayTime.lua index 958ac24a6a..295db25818 100644 --- a/cocos/scripting/lua-bindings/auto/api/DelayTime.lua +++ b/cocos/scripting/lua-bindings/auto/api/DelayTime.lua @@ -5,22 +5,26 @@ -- @parent_module cc -------------------------------- +-- creates the action -- @function [parent=#DelayTime] create -- @param self --- @param #float float +-- @param #float d -- @return DelayTime#DelayTime ret (return value: cc.DelayTime) -------------------------------- +-- -- @function [parent=#DelayTime] clone -- @param self -- @return DelayTime#DelayTime ret (return value: cc.DelayTime) -------------------------------- +-- -- @function [parent=#DelayTime] update -- @param self --- @param #float float +-- @param #float time -------------------------------- +-- -- @function [parent=#DelayTime] reverse -- @param self -- @return DelayTime#DelayTime ret (return value: cc.DelayTime) diff --git a/cocos/scripting/lua-bindings/auto/api/Director.lua b/cocos/scripting/lua-bindings/auto/api/Director.lua index 6d684c5988..bdabea04f8 100644 --- a/cocos/scripting/lua-bindings/auto/api/Director.lua +++ b/cocos/scripting/lua-bindings/auto/api/Director.lua @@ -4,307 +4,418 @@ -- @parent_module cc -------------------------------- +-- Pauses the running scene.
+-- The running scene will be _drawed_ but all scheduled timers will be paused
+-- While paused, the draw rate will be 4 FPS to reduce CPU consumption -- @function [parent=#Director] pause -- @param self -------------------------------- +-- Sets the EventDispatcher associated with this director
+-- since v3.0 -- @function [parent=#Director] setEventDispatcher -- @param self --- @param #cc.EventDispatcher eventdispatcher +-- @param #cc.EventDispatcher dispatcher -------------------------------- +-- Suspends the execution of the running scene, pushing it on the stack of suspended scenes.
+-- The new scene will be executed.
+-- Try to avoid big stacks of pushed scenes to reduce memory allocation.
+-- ONLY call it if there is a running scene. -- @function [parent=#Director] pushScene -- @param self -- @param #cc.Scene scene -------------------------------- +-- -- @function [parent=#Director] getDeltaTime -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#Director] getContentScaleFactor -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- returns the size of the OpenGL view in pixels. -- @function [parent=#Director] getWinSizeInPixels -- @param self -- @return size_table#size_table ret (return value: size_table) -------------------------------- +-- -- @function [parent=#Director] getConsole -- @param self -- @return Console#Console ret (return value: cc.Console) -------------------------------- +-- -- @function [parent=#Director] pushMatrix -- @param self --- @param #int matrix_stack_type +-- @param #int type -------------------------------- +-- sets the OpenGL default values -- @function [parent=#Director] setGLDefaultValues -- @param self -------------------------------- +-- Sets the ActionManager associated with this director
+-- since v2.0 -- @function [parent=#Director] setActionManager -- @param self --- @param #cc.ActionManager actionmanager +-- @param #cc.ActionManager actionManager -------------------------------- +-- enables/disables OpenGL alpha blending -- @function [parent=#Director] setAlphaBlending -- @param self --- @param #bool bool +-- @param #bool on -------------------------------- +-- Pops out all scenes from the stack until the root scene in the queue.
+-- This scene will replace the running one.
+-- Internally it will call `popToSceneStackLevel(1)` -- @function [parent=#Director] popToRootScene -- @param self -------------------------------- +-- -- @function [parent=#Director] loadMatrix -- @param self --- @param #int matrix_stack_type --- @param #mat4_table mat4 +-- @param #int type +-- @param #mat4_table mat -------------------------------- +-- This object will be visited after the main scene is visited.
+-- This object MUST implement the "visit" selector.
+-- Useful to hook a notification object, like Notifications (http:github.com/manucorporat/CCNotifications)
+-- since v0.99.5 -- @function [parent=#Director] getNotificationNode -- @param self -- @return Node#Node ret (return value: cc.Node) -------------------------------- +-- returns the size of the OpenGL view in points. -- @function [parent=#Director] getWinSize -- @param self -- @return size_table#size_table ret (return value: size_table) -------------------------------- +-- -- @function [parent=#Director] getTextureCache -- @param self -- @return TextureCache#TextureCache ret (return value: cc.TextureCache) -------------------------------- +-- Whether or not the replaced scene will receive the cleanup message.
+-- If the new scene is pushed, then the old scene won't receive the "cleanup" message.
+-- If the new scene replaces the old one, the it will receive the "cleanup" message.
+-- since v0.99.0 -- @function [parent=#Director] isSendCleanupToScene -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- returns visible origin of the OpenGL view in points. -- @function [parent=#Director] getVisibleOrigin -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- -- @function [parent=#Director] mainLoop -- @param self -------------------------------- +-- enables/disables OpenGL depth test -- @function [parent=#Director] setDepthTest -- @param self --- @param #bool bool +-- @param #bool on -------------------------------- +-- get Frame Rate -- @function [parent=#Director] getFrameRate -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- seconds per frame -- @function [parent=#Director] getSecondsPerFrame -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- converts an OpenGL coordinate to a UIKit coordinate
+-- Useful to convert node points to window points for calls such as glScissor -- @function [parent=#Director] convertToUI -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table point -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- sets the default values based on the Configuration info -- @function [parent=#Director] setDefaultValues -- @param self -------------------------------- +-- -- @function [parent=#Director] init -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- Sets the Scheduler associated with this director
+-- since v2.0 -- @function [parent=#Director] setScheduler -- @param self -- @param #cc.Scheduler scheduler -------------------------------- +-- The main loop is triggered again.
+-- Call this function only if [stopAnimation] was called earlier
+-- warning Don't call this function to start the main loop. To run the main loop call runWithScene -- @function [parent=#Director] startAnimation -- @param self -------------------------------- +-- Get the GLView, where everything is rendered
+-- js NA
+-- lua NA -- @function [parent=#Director] getOpenGLView -- @param self -- @return GLView#GLView ret (return value: cc.GLView) -------------------------------- +-- Get current running Scene. Director can only run one Scene at a time -- @function [parent=#Director] getRunningScene -- @param self -- @return Scene#Scene ret (return value: cc.Scene) -------------------------------- +-- Sets the glViewport -- @function [parent=#Director] setViewport -- @param self -------------------------------- +-- Stops the animation. Nothing will be drawn. The main loop won't be triggered anymore.
+-- If you don't want to pause your animation call [pause] instead. -- @function [parent=#Director] stopAnimation -- @param self -------------------------------- +-- The size in pixels of the surface. It could be different than the screen size.
+-- High-res devices might have a higher surface size than the screen size.
+-- Only available when compiled using SDK >= 4.0.
+-- since v0.99.4 -- @function [parent=#Director] setContentScaleFactor -- @param self --- @param #float float +-- @param #float scaleFactor -------------------------------- +-- Pops out all scenes from the stack until it reaches `level`.
+-- If level is 0, it will end the director.
+-- If level is 1, it will pop all scenes until it reaches to root scene.
+-- If level is <= than the current stack level, it won't do anything. -- @function [parent=#Director] popToSceneStackLevel -- @param self --- @param #int int +-- @param #int level -------------------------------- +-- Resumes the paused scene
+-- The scheduled timers will be activated again.
+-- The "delta time" will be 0 (as if the game wasn't paused) -- @function [parent=#Director] resume -- @param self -------------------------------- +-- -- @function [parent=#Director] isNextDeltaTimeZero -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- Ends the execution, releases the running scene.
+-- It doesn't remove the OpenGL view from its parent. You have to do it manually.
+-- lua endToLua -- @function [parent=#Director] end -- @param self -------------------------------- +-- -- @function [parent=#Director] setOpenGLView -- @param self --- @param #cc.GLView glview +-- @param #cc.GLView openGLView -------------------------------- +-- converts a UIKit coordinate to an OpenGL coordinate
+-- Useful to convert (multi) touch coordinates to the current layout (portrait or landscape) -- @function [parent=#Director] convertToGL -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table point -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- Removes all cocos2d cached data.
+-- It will purge the TextureCache, SpriteFrameCache, LabelBMFont cache
+-- since v0.99.3 -- @function [parent=#Director] purgeCachedData -- @param self -------------------------------- +-- How many frames were called since the director started -- @function [parent=#Director] getTotalFrames -- @param self -- @return unsigned int#unsigned int ret (return value: unsigned int) -------------------------------- +-- Enters the Director's main loop with the given Scene.
+-- Call it to run only your FIRST scene.
+-- Don't call it if there is already a running scene.
+-- It will call pushScene: and then it will call startAnimation -- @function [parent=#Director] runWithScene -- @param self -- @param #cc.Scene scene -------------------------------- +-- -- @function [parent=#Director] setNotificationNode -- @param self -- @param #cc.Node node -------------------------------- +-- Draw the scene.
+-- This method is called every frame. Don't call it manually. -- @function [parent=#Director] drawScene -- @param self -------------------------------- +-- / FIXME: missing description -- @function [parent=#Director] getZEye -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#Director] getMatrix -- @param self --- @param #int matrix_stack_type +-- @param #int type -- @return mat4_table#mat4_table ret (return value: mat4_table) -------------------------------- +-- Pops out a scene from the stack.
+-- This scene will replace the running one.
+-- The running scene will be deleted. If there are no more scenes in the stack the execution is terminated.
+-- ONLY call it if there is a running scene. -- @function [parent=#Director] popScene -- @param self -------------------------------- +-- Whether or not to display the FPS on the bottom-left corner -- @function [parent=#Director] isDisplayStats -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#Director] setProjection -- @param self -- @param #int projection -------------------------------- +-- -- @function [parent=#Director] loadIdentityMatrix -- @param self --- @param #int matrix_stack_type +-- @param #int type -------------------------------- +-- -- @function [parent=#Director] setNextDeltaTimeZero -- @param self --- @param #bool bool +-- @param #bool nextDeltaTimeZero -------------------------------- +-- -- @function [parent=#Director] resetMatrixStack -- @param self -------------------------------- +-- -- @function [parent=#Director] popMatrix -- @param self --- @param #int matrix_stack_type +-- @param #int type -------------------------------- +-- returns visible size of the OpenGL view in points.
+-- the value is equal to getWinSize if don't invoke
+-- GLView::setDesignResolutionSize() -- @function [parent=#Director] getVisibleSize -- @param self -- @return size_table#size_table ret (return value: size_table) -------------------------------- +-- Gets the Scheduler associated with this director
+-- since v2.0 -- @function [parent=#Director] getScheduler -- @param self -- @return Scheduler#Scheduler ret (return value: cc.Scheduler) -------------------------------- +-- Set the FPS value. -- @function [parent=#Director] setAnimationInterval -- @param self --- @param #double double +-- @param #double interval -------------------------------- +-- Get the FPS value -- @function [parent=#Director] getAnimationInterval -- @param self -- @return double#double ret (return value: double) -------------------------------- +-- Whether or not the Director is paused -- @function [parent=#Director] isPaused -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- Display the FPS on the bottom-left corner -- @function [parent=#Director] setDisplayStats -- @param self --- @param #bool bool +-- @param #bool displayStats -------------------------------- +-- Gets the EventDispatcher associated with this director
+-- since v3.0 -- @function [parent=#Director] getEventDispatcher -- @param self -- @return EventDispatcher#EventDispatcher ret (return value: cc.EventDispatcher) -------------------------------- +-- Replaces the running scene with a new one. The running scene is terminated.
+-- ONLY call it if there is a running scene. -- @function [parent=#Director] replaceScene -- @param self -- @param #cc.Scene scene -------------------------------- +-- -- @function [parent=#Director] multiplyMatrix -- @param self --- @param #int matrix_stack_type --- @param #mat4_table mat4 +-- @param #int type +-- @param #mat4_table mat -------------------------------- +-- Gets the ActionManager associated with this director
+-- since v2.0 -- @function [parent=#Director] getActionManager -- @param self -- @return ActionManager#ActionManager ret (return value: cc.ActionManager) -------------------------------- +-- returns a shared instance of the director -- @function [parent=#Director] getInstance -- @param self -- @return Director#Director ret (return value: cc.Director) diff --git a/cocos/scripting/lua-bindings/auto/api/DisplayData.lua b/cocos/scripting/lua-bindings/auto/api/DisplayData.lua index fc4a6c1930..772d00d704 100644 --- a/cocos/scripting/lua-bindings/auto/api/DisplayData.lua +++ b/cocos/scripting/lua-bindings/auto/api/DisplayData.lua @@ -5,22 +5,26 @@ -- @parent_module ccs -------------------------------- +-- -- @function [parent=#DisplayData] copy -- @param self --- @param #ccs.DisplayData displaydata +-- @param #ccs.DisplayData displayData -------------------------------- +-- -- @function [parent=#DisplayData] changeDisplayToTexture -- @param self --- @param #string str +-- @param #string displayName -- @return string#string ret (return value: string) -------------------------------- +-- -- @function [parent=#DisplayData] create -- @param self -- @return DisplayData#DisplayData ret (return value: ccs.DisplayData) -------------------------------- +-- js ctor -- @function [parent=#DisplayData] DisplayData -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/DisplayManager.lua b/cocos/scripting/lua-bindings/auto/api/DisplayManager.lua index 0739f44691..efbcde86af 100644 --- a/cocos/scripting/lua-bindings/auto/api/DisplayManager.lua +++ b/cocos/scripting/lua-bindings/auto/api/DisplayManager.lua @@ -5,42 +5,50 @@ -- @parent_module ccs -------------------------------- +-- -- @function [parent=#DisplayManager] getDisplayRenderNode -- @param self -- @return Node#Node ret (return value: cc.Node) -------------------------------- +-- -- @function [parent=#DisplayManager] getAnchorPointInPoints -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- -- @function [parent=#DisplayManager] getDisplayRenderNodeType -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- -- @function [parent=#DisplayManager] removeDisplay -- @param self --- @param #int int +-- @param #int index -------------------------------- +-- -- @function [parent=#DisplayManager] setForceChangeDisplay -- @param self --- @param #bool bool +-- @param #bool force -------------------------------- +-- -- @function [parent=#DisplayManager] init -- @param self -- @param #ccs.Bone bone -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#DisplayManager] getContentSize -- @param self -- @return size_table#size_table ret (return value: size_table) -------------------------------- +-- -- @function [parent=#DisplayManager] getBoundingBox -- @param self -- @return rect_table#rect_table ret (return value: rect_table) @@ -50,67 +58,85 @@ -- @overload self, ccs.DisplayData, int -- @function [parent=#DisplayManager] addDisplay -- @param self --- @param #ccs.DisplayData displaydata --- @param #int int +-- @param #ccs.DisplayData displayData +-- @param #int index -------------------------------- -- @overload self, float, float -- @overload self, vec2_table -- @function [parent=#DisplayManager] containPoint -- @param self --- @param #float float --- @param #float float +-- @param #float x +-- @param #float y -- @return bool#bool ret (retunr value: bool) -------------------------------- +-- Change display by index. You can just use this method to change display in the display list.
+-- The display list is just used for this bone, and it is the displays you may use in every frame.
+-- Note : if index is the same with prev index, the method will not effect
+-- param index The index of the display you want to change
+-- param force If true, then force change display to specified display, or current display will set to display index edit in the flash every key frame. -- @function [parent=#DisplayManager] changeDisplayWithIndex -- @param self --- @param #int int --- @param #bool bool +-- @param #int index +-- @param #bool force -------------------------------- +-- -- @function [parent=#DisplayManager] changeDisplayWithName -- @param self --- @param #string str --- @param #bool bool +-- @param #string name +-- @param #bool force -------------------------------- +-- -- @function [parent=#DisplayManager] isForceChangeDisplay -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#DisplayManager] getCurrentDisplayIndex -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- -- @function [parent=#DisplayManager] getAnchorPoint -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- -- @function [parent=#DisplayManager] getDecorativeDisplayList -- @param self -- @return array_table#array_table ret (return value: array_table) -------------------------------- +-- Determines if the display is visible
+-- see setVisible(bool)
+-- return true if the node is visible, false if the node is hidden. -- @function [parent=#DisplayManager] isVisible -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- Sets whether the display is visible
+-- The default value is true, a node is default to visible
+-- param visible true if the node is visible, false if the node is hidden. -- @function [parent=#DisplayManager] setVisible -- @param self --- @param #bool bool +-- @param #bool visible -------------------------------- +-- -- @function [parent=#DisplayManager] create -- @param self -- @param #ccs.Bone bone -- @return DisplayManager#DisplayManager ret (return value: ccs.DisplayManager) -------------------------------- +-- -- @function [parent=#DisplayManager] DisplayManager -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/DrawNode.lua b/cocos/scripting/lua-bindings/auto/api/DrawNode.lua index 381306a3a4..0e9687481b 100644 --- a/cocos/scripting/lua-bindings/auto/api/DrawNode.lua +++ b/cocos/scripting/lua-bindings/auto/api/DrawNode.lua @@ -5,67 +5,76 @@ -- @parent_module cc -------------------------------- +-- draw a quadratic bezier curve with color and number of segments -- @function [parent=#DrawNode] drawQuadraticBezier -- @param self --- @param #vec2_table vec2 --- @param #vec2_table vec2 --- @param #vec2_table vec2 --- @param #unsigned int int --- @param #color4f_table color4f +-- @param #vec2_table from +-- @param #vec2_table control +-- @param #vec2_table to +-- @param #unsigned int segments +-- @param #color4f_table color -------------------------------- +-- -- @function [parent=#DrawNode] onDraw -- @param self --- @param #mat4_table mat4 --- @param #unsigned int int +-- @param #mat4_table transform +-- @param #unsigned int flags -------------------------------- +-- Clear the geometry in the node's buffer. -- @function [parent=#DrawNode] clear -- @param self -------------------------------- +-- draw a triangle with color -- @function [parent=#DrawNode] drawTriangle -- @param self --- @param #vec2_table vec2 --- @param #vec2_table vec2 --- @param #vec2_table vec2 --- @param #color4f_table color4f +-- @param #vec2_table p1 +-- @param #vec2_table p2 +-- @param #vec2_table p3 +-- @param #color4f_table color -------------------------------- +-- draw a dot at a position, with a given radius and color -- @function [parent=#DrawNode] drawDot -- @param self --- @param #vec2_table vec2 --- @param #float float --- @param #color4f_table color4f +-- @param #vec2_table pos +-- @param #float radius +-- @param #color4f_table color -------------------------------- +-- draw a cubic bezier curve with color and number of segments -- @function [parent=#DrawNode] drawCubicBezier -- @param self --- @param #vec2_table vec2 --- @param #vec2_table vec2 --- @param #vec2_table vec2 --- @param #vec2_table vec2 --- @param #unsigned int int --- @param #color4f_table color4f +-- @param #vec2_table from +-- @param #vec2_table control1 +-- @param #vec2_table control2 +-- @param #vec2_table to +-- @param #unsigned int segments +-- @param #color4f_table color -------------------------------- +-- draw a segment with a radius and color -- @function [parent=#DrawNode] drawSegment -- @param self --- @param #vec2_table vec2 --- @param #vec2_table vec2 --- @param #float float --- @param #color4f_table color4f +-- @param #vec2_table from +-- @param #vec2_table to +-- @param #float radius +-- @param #color4f_table color -------------------------------- +-- creates and initialize a DrawNode node -- @function [parent=#DrawNode] create -- @param self -- @return DrawNode#DrawNode ret (return value: cc.DrawNode) -------------------------------- +-- -- @function [parent=#DrawNode] draw -- @param self -- @param #cc.Renderer renderer --- @param #mat4_table mat4 --- @param #unsigned int int +-- @param #mat4_table transform +-- @param #unsigned int flags return nil diff --git a/cocos/scripting/lua-bindings/auto/api/EaseBackIn.lua b/cocos/scripting/lua-bindings/auto/api/EaseBackIn.lua index 850030d9c3..2186611bf2 100644 --- a/cocos/scripting/lua-bindings/auto/api/EaseBackIn.lua +++ b/cocos/scripting/lua-bindings/auto/api/EaseBackIn.lua @@ -5,22 +5,26 @@ -- @parent_module cc -------------------------------- +-- creates the action -- @function [parent=#EaseBackIn] create -- @param self --- @param #cc.ActionInterval actioninterval +-- @param #cc.ActionInterval action -- @return EaseBackIn#EaseBackIn ret (return value: cc.EaseBackIn) -------------------------------- +-- -- @function [parent=#EaseBackIn] clone -- @param self -- @return EaseBackIn#EaseBackIn ret (return value: cc.EaseBackIn) -------------------------------- +-- -- @function [parent=#EaseBackIn] update -- @param self --- @param #float float +-- @param #float time -------------------------------- +-- -- @function [parent=#EaseBackIn] reverse -- @param self -- @return ActionEase#ActionEase ret (return value: cc.ActionEase) diff --git a/cocos/scripting/lua-bindings/auto/api/EaseBackInOut.lua b/cocos/scripting/lua-bindings/auto/api/EaseBackInOut.lua index 035aeedbfb..bf34e1c7a7 100644 --- a/cocos/scripting/lua-bindings/auto/api/EaseBackInOut.lua +++ b/cocos/scripting/lua-bindings/auto/api/EaseBackInOut.lua @@ -5,22 +5,26 @@ -- @parent_module cc -------------------------------- +-- creates the action -- @function [parent=#EaseBackInOut] create -- @param self --- @param #cc.ActionInterval actioninterval +-- @param #cc.ActionInterval action -- @return EaseBackInOut#EaseBackInOut ret (return value: cc.EaseBackInOut) -------------------------------- +-- -- @function [parent=#EaseBackInOut] clone -- @param self -- @return EaseBackInOut#EaseBackInOut ret (return value: cc.EaseBackInOut) -------------------------------- +-- -- @function [parent=#EaseBackInOut] update -- @param self --- @param #float float +-- @param #float time -------------------------------- +-- -- @function [parent=#EaseBackInOut] reverse -- @param self -- @return EaseBackInOut#EaseBackInOut ret (return value: cc.EaseBackInOut) diff --git a/cocos/scripting/lua-bindings/auto/api/EaseBackOut.lua b/cocos/scripting/lua-bindings/auto/api/EaseBackOut.lua index c1bdda9357..4c277e7572 100644 --- a/cocos/scripting/lua-bindings/auto/api/EaseBackOut.lua +++ b/cocos/scripting/lua-bindings/auto/api/EaseBackOut.lua @@ -5,22 +5,26 @@ -- @parent_module cc -------------------------------- +-- creates the action -- @function [parent=#EaseBackOut] create -- @param self --- @param #cc.ActionInterval actioninterval +-- @param #cc.ActionInterval action -- @return EaseBackOut#EaseBackOut ret (return value: cc.EaseBackOut) -------------------------------- +-- -- @function [parent=#EaseBackOut] clone -- @param self -- @return EaseBackOut#EaseBackOut ret (return value: cc.EaseBackOut) -------------------------------- +-- -- @function [parent=#EaseBackOut] update -- @param self --- @param #float float +-- @param #float time -------------------------------- +-- -- @function [parent=#EaseBackOut] reverse -- @param self -- @return ActionEase#ActionEase ret (return value: cc.ActionEase) diff --git a/cocos/scripting/lua-bindings/auto/api/EaseBezierAction.lua b/cocos/scripting/lua-bindings/auto/api/EaseBezierAction.lua index 5b800810aa..c04acabcb5 100644 --- a/cocos/scripting/lua-bindings/auto/api/EaseBezierAction.lua +++ b/cocos/scripting/lua-bindings/auto/api/EaseBezierAction.lua @@ -5,30 +5,35 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#EaseBezierAction] setBezierParamer -- @param self --- @param #float float --- @param #float float --- @param #float float --- @param #float float +-- @param #float p0 +-- @param #float p1 +-- @param #float p2 +-- @param #float p3 -------------------------------- +-- creates the action -- @function [parent=#EaseBezierAction] create -- @param self --- @param #cc.ActionInterval actioninterval +-- @param #cc.ActionInterval action -- @return EaseBezierAction#EaseBezierAction ret (return value: cc.EaseBezierAction) -------------------------------- +-- -- @function [parent=#EaseBezierAction] clone -- @param self -- @return EaseBezierAction#EaseBezierAction ret (return value: cc.EaseBezierAction) -------------------------------- +-- -- @function [parent=#EaseBezierAction] update -- @param self --- @param #float float +-- @param #float time -------------------------------- +-- -- @function [parent=#EaseBezierAction] reverse -- @param self -- @return EaseBezierAction#EaseBezierAction ret (return value: cc.EaseBezierAction) diff --git a/cocos/scripting/lua-bindings/auto/api/EaseBounce.lua b/cocos/scripting/lua-bindings/auto/api/EaseBounce.lua index 037dce873b..bd2089568e 100644 --- a/cocos/scripting/lua-bindings/auto/api/EaseBounce.lua +++ b/cocos/scripting/lua-bindings/auto/api/EaseBounce.lua @@ -5,11 +5,13 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#EaseBounce] clone -- @param self -- @return EaseBounce#EaseBounce ret (return value: cc.EaseBounce) -------------------------------- +-- -- @function [parent=#EaseBounce] reverse -- @param self -- @return EaseBounce#EaseBounce ret (return value: cc.EaseBounce) diff --git a/cocos/scripting/lua-bindings/auto/api/EaseBounceIn.lua b/cocos/scripting/lua-bindings/auto/api/EaseBounceIn.lua index 0f7b0e7ea6..eb1e5bbd9d 100644 --- a/cocos/scripting/lua-bindings/auto/api/EaseBounceIn.lua +++ b/cocos/scripting/lua-bindings/auto/api/EaseBounceIn.lua @@ -5,22 +5,26 @@ -- @parent_module cc -------------------------------- +-- creates the action -- @function [parent=#EaseBounceIn] create -- @param self --- @param #cc.ActionInterval actioninterval +-- @param #cc.ActionInterval action -- @return EaseBounceIn#EaseBounceIn ret (return value: cc.EaseBounceIn) -------------------------------- +-- -- @function [parent=#EaseBounceIn] clone -- @param self -- @return EaseBounceIn#EaseBounceIn ret (return value: cc.EaseBounceIn) -------------------------------- +-- -- @function [parent=#EaseBounceIn] update -- @param self --- @param #float float +-- @param #float time -------------------------------- +-- -- @function [parent=#EaseBounceIn] reverse -- @param self -- @return EaseBounce#EaseBounce ret (return value: cc.EaseBounce) diff --git a/cocos/scripting/lua-bindings/auto/api/EaseBounceInOut.lua b/cocos/scripting/lua-bindings/auto/api/EaseBounceInOut.lua index e81ea374e4..740d3c8704 100644 --- a/cocos/scripting/lua-bindings/auto/api/EaseBounceInOut.lua +++ b/cocos/scripting/lua-bindings/auto/api/EaseBounceInOut.lua @@ -5,22 +5,26 @@ -- @parent_module cc -------------------------------- +-- creates the action -- @function [parent=#EaseBounceInOut] create -- @param self --- @param #cc.ActionInterval actioninterval +-- @param #cc.ActionInterval action -- @return EaseBounceInOut#EaseBounceInOut ret (return value: cc.EaseBounceInOut) -------------------------------- +-- -- @function [parent=#EaseBounceInOut] clone -- @param self -- @return EaseBounceInOut#EaseBounceInOut ret (return value: cc.EaseBounceInOut) -------------------------------- +-- -- @function [parent=#EaseBounceInOut] update -- @param self --- @param #float float +-- @param #float time -------------------------------- +-- -- @function [parent=#EaseBounceInOut] reverse -- @param self -- @return EaseBounceInOut#EaseBounceInOut ret (return value: cc.EaseBounceInOut) diff --git a/cocos/scripting/lua-bindings/auto/api/EaseBounceOut.lua b/cocos/scripting/lua-bindings/auto/api/EaseBounceOut.lua index 1dc028dfdd..64a284eede 100644 --- a/cocos/scripting/lua-bindings/auto/api/EaseBounceOut.lua +++ b/cocos/scripting/lua-bindings/auto/api/EaseBounceOut.lua @@ -5,22 +5,26 @@ -- @parent_module cc -------------------------------- +-- creates the action -- @function [parent=#EaseBounceOut] create -- @param self --- @param #cc.ActionInterval actioninterval +-- @param #cc.ActionInterval action -- @return EaseBounceOut#EaseBounceOut ret (return value: cc.EaseBounceOut) -------------------------------- +-- -- @function [parent=#EaseBounceOut] clone -- @param self -- @return EaseBounceOut#EaseBounceOut ret (return value: cc.EaseBounceOut) -------------------------------- +-- -- @function [parent=#EaseBounceOut] update -- @param self --- @param #float float +-- @param #float time -------------------------------- +-- -- @function [parent=#EaseBounceOut] reverse -- @param self -- @return EaseBounce#EaseBounce ret (return value: cc.EaseBounce) diff --git a/cocos/scripting/lua-bindings/auto/api/EaseCircleActionIn.lua b/cocos/scripting/lua-bindings/auto/api/EaseCircleActionIn.lua index 647f88bdd1..51b0b6490e 100644 --- a/cocos/scripting/lua-bindings/auto/api/EaseCircleActionIn.lua +++ b/cocos/scripting/lua-bindings/auto/api/EaseCircleActionIn.lua @@ -5,22 +5,26 @@ -- @parent_module cc -------------------------------- +-- creates the action -- @function [parent=#EaseCircleActionIn] create -- @param self --- @param #cc.ActionInterval actioninterval +-- @param #cc.ActionInterval action -- @return EaseCircleActionIn#EaseCircleActionIn ret (return value: cc.EaseCircleActionIn) -------------------------------- +-- -- @function [parent=#EaseCircleActionIn] clone -- @param self -- @return EaseCircleActionIn#EaseCircleActionIn ret (return value: cc.EaseCircleActionIn) -------------------------------- +-- -- @function [parent=#EaseCircleActionIn] update -- @param self --- @param #float float +-- @param #float time -------------------------------- +-- -- @function [parent=#EaseCircleActionIn] reverse -- @param self -- @return EaseCircleActionIn#EaseCircleActionIn ret (return value: cc.EaseCircleActionIn) diff --git a/cocos/scripting/lua-bindings/auto/api/EaseCircleActionInOut.lua b/cocos/scripting/lua-bindings/auto/api/EaseCircleActionInOut.lua index bbe15b71c5..f879df09e5 100644 --- a/cocos/scripting/lua-bindings/auto/api/EaseCircleActionInOut.lua +++ b/cocos/scripting/lua-bindings/auto/api/EaseCircleActionInOut.lua @@ -5,22 +5,26 @@ -- @parent_module cc -------------------------------- +-- creates the action -- @function [parent=#EaseCircleActionInOut] create -- @param self --- @param #cc.ActionInterval actioninterval +-- @param #cc.ActionInterval action -- @return EaseCircleActionInOut#EaseCircleActionInOut ret (return value: cc.EaseCircleActionInOut) -------------------------------- +-- -- @function [parent=#EaseCircleActionInOut] clone -- @param self -- @return EaseCircleActionInOut#EaseCircleActionInOut ret (return value: cc.EaseCircleActionInOut) -------------------------------- +-- -- @function [parent=#EaseCircleActionInOut] update -- @param self --- @param #float float +-- @param #float time -------------------------------- +-- -- @function [parent=#EaseCircleActionInOut] reverse -- @param self -- @return EaseCircleActionInOut#EaseCircleActionInOut ret (return value: cc.EaseCircleActionInOut) diff --git a/cocos/scripting/lua-bindings/auto/api/EaseCircleActionOut.lua b/cocos/scripting/lua-bindings/auto/api/EaseCircleActionOut.lua index bc8c231259..1a9f175414 100644 --- a/cocos/scripting/lua-bindings/auto/api/EaseCircleActionOut.lua +++ b/cocos/scripting/lua-bindings/auto/api/EaseCircleActionOut.lua @@ -5,22 +5,26 @@ -- @parent_module cc -------------------------------- +-- creates the action -- @function [parent=#EaseCircleActionOut] create -- @param self --- @param #cc.ActionInterval actioninterval +-- @param #cc.ActionInterval action -- @return EaseCircleActionOut#EaseCircleActionOut ret (return value: cc.EaseCircleActionOut) -------------------------------- +-- -- @function [parent=#EaseCircleActionOut] clone -- @param self -- @return EaseCircleActionOut#EaseCircleActionOut ret (return value: cc.EaseCircleActionOut) -------------------------------- +-- -- @function [parent=#EaseCircleActionOut] update -- @param self --- @param #float float +-- @param #float time -------------------------------- +-- -- @function [parent=#EaseCircleActionOut] reverse -- @param self -- @return EaseCircleActionOut#EaseCircleActionOut ret (return value: cc.EaseCircleActionOut) diff --git a/cocos/scripting/lua-bindings/auto/api/EaseCubicActionIn.lua b/cocos/scripting/lua-bindings/auto/api/EaseCubicActionIn.lua index 4320a97977..0e53d65c72 100644 --- a/cocos/scripting/lua-bindings/auto/api/EaseCubicActionIn.lua +++ b/cocos/scripting/lua-bindings/auto/api/EaseCubicActionIn.lua @@ -5,22 +5,26 @@ -- @parent_module cc -------------------------------- +-- creates the action -- @function [parent=#EaseCubicActionIn] create -- @param self --- @param #cc.ActionInterval actioninterval +-- @param #cc.ActionInterval action -- @return EaseCubicActionIn#EaseCubicActionIn ret (return value: cc.EaseCubicActionIn) -------------------------------- +-- -- @function [parent=#EaseCubicActionIn] clone -- @param self -- @return EaseCubicActionIn#EaseCubicActionIn ret (return value: cc.EaseCubicActionIn) -------------------------------- +-- -- @function [parent=#EaseCubicActionIn] update -- @param self --- @param #float float +-- @param #float time -------------------------------- +-- -- @function [parent=#EaseCubicActionIn] reverse -- @param self -- @return EaseCubicActionIn#EaseCubicActionIn ret (return value: cc.EaseCubicActionIn) diff --git a/cocos/scripting/lua-bindings/auto/api/EaseCubicActionInOut.lua b/cocos/scripting/lua-bindings/auto/api/EaseCubicActionInOut.lua index adcc8e1bd2..fbbb49a273 100644 --- a/cocos/scripting/lua-bindings/auto/api/EaseCubicActionInOut.lua +++ b/cocos/scripting/lua-bindings/auto/api/EaseCubicActionInOut.lua @@ -5,22 +5,26 @@ -- @parent_module cc -------------------------------- +-- creates the action -- @function [parent=#EaseCubicActionInOut] create -- @param self --- @param #cc.ActionInterval actioninterval +-- @param #cc.ActionInterval action -- @return EaseCubicActionInOut#EaseCubicActionInOut ret (return value: cc.EaseCubicActionInOut) -------------------------------- +-- -- @function [parent=#EaseCubicActionInOut] clone -- @param self -- @return EaseCubicActionInOut#EaseCubicActionInOut ret (return value: cc.EaseCubicActionInOut) -------------------------------- +-- -- @function [parent=#EaseCubicActionInOut] update -- @param self --- @param #float float +-- @param #float time -------------------------------- +-- -- @function [parent=#EaseCubicActionInOut] reverse -- @param self -- @return EaseCubicActionInOut#EaseCubicActionInOut ret (return value: cc.EaseCubicActionInOut) diff --git a/cocos/scripting/lua-bindings/auto/api/EaseCubicActionOut.lua b/cocos/scripting/lua-bindings/auto/api/EaseCubicActionOut.lua index e09318698c..2250af3226 100644 --- a/cocos/scripting/lua-bindings/auto/api/EaseCubicActionOut.lua +++ b/cocos/scripting/lua-bindings/auto/api/EaseCubicActionOut.lua @@ -5,22 +5,26 @@ -- @parent_module cc -------------------------------- +-- creates the action -- @function [parent=#EaseCubicActionOut] create -- @param self --- @param #cc.ActionInterval actioninterval +-- @param #cc.ActionInterval action -- @return EaseCubicActionOut#EaseCubicActionOut ret (return value: cc.EaseCubicActionOut) -------------------------------- +-- -- @function [parent=#EaseCubicActionOut] clone -- @param self -- @return EaseCubicActionOut#EaseCubicActionOut ret (return value: cc.EaseCubicActionOut) -------------------------------- +-- -- @function [parent=#EaseCubicActionOut] update -- @param self --- @param #float float +-- @param #float time -------------------------------- +-- -- @function [parent=#EaseCubicActionOut] reverse -- @param self -- @return EaseCubicActionOut#EaseCubicActionOut ret (return value: cc.EaseCubicActionOut) diff --git a/cocos/scripting/lua-bindings/auto/api/EaseElastic.lua b/cocos/scripting/lua-bindings/auto/api/EaseElastic.lua index 6d9f1190ab..aa8c965c02 100644 --- a/cocos/scripting/lua-bindings/auto/api/EaseElastic.lua +++ b/cocos/scripting/lua-bindings/auto/api/EaseElastic.lua @@ -5,21 +5,25 @@ -- @parent_module cc -------------------------------- +-- set period of the wave in radians. -- @function [parent=#EaseElastic] setPeriod -- @param self --- @param #float float +-- @param #float fPeriod -------------------------------- +-- get period of the wave in radians. default is 0.3 -- @function [parent=#EaseElastic] getPeriod -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#EaseElastic] clone -- @param self -- @return EaseElastic#EaseElastic ret (return value: cc.EaseElastic) -------------------------------- +-- -- @function [parent=#EaseElastic] reverse -- @param self -- @return EaseElastic#EaseElastic ret (return value: cc.EaseElastic) diff --git a/cocos/scripting/lua-bindings/auto/api/EaseElasticIn.lua b/cocos/scripting/lua-bindings/auto/api/EaseElasticIn.lua index b38769fd4d..be975202b7 100644 --- a/cocos/scripting/lua-bindings/auto/api/EaseElasticIn.lua +++ b/cocos/scripting/lua-bindings/auto/api/EaseElasticIn.lua @@ -9,21 +9,24 @@ -- @overload self, cc.ActionInterval, float -- @function [parent=#EaseElasticIn] create -- @param self --- @param #cc.ActionInterval actioninterval --- @param #float float +-- @param #cc.ActionInterval action +-- @param #float period -- @return EaseElasticIn#EaseElasticIn ret (retunr value: cc.EaseElasticIn) -------------------------------- +-- -- @function [parent=#EaseElasticIn] clone -- @param self -- @return EaseElasticIn#EaseElasticIn ret (return value: cc.EaseElasticIn) -------------------------------- +-- -- @function [parent=#EaseElasticIn] update -- @param self --- @param #float float +-- @param #float time -------------------------------- +-- -- @function [parent=#EaseElasticIn] reverse -- @param self -- @return EaseElastic#EaseElastic ret (return value: cc.EaseElastic) diff --git a/cocos/scripting/lua-bindings/auto/api/EaseElasticInOut.lua b/cocos/scripting/lua-bindings/auto/api/EaseElasticInOut.lua index 5d836c34ae..cae6e19b10 100644 --- a/cocos/scripting/lua-bindings/auto/api/EaseElasticInOut.lua +++ b/cocos/scripting/lua-bindings/auto/api/EaseElasticInOut.lua @@ -9,21 +9,24 @@ -- @overload self, cc.ActionInterval, float -- @function [parent=#EaseElasticInOut] create -- @param self --- @param #cc.ActionInterval actioninterval --- @param #float float +-- @param #cc.ActionInterval action +-- @param #float period -- @return EaseElasticInOut#EaseElasticInOut ret (retunr value: cc.EaseElasticInOut) -------------------------------- +-- -- @function [parent=#EaseElasticInOut] clone -- @param self -- @return EaseElasticInOut#EaseElasticInOut ret (return value: cc.EaseElasticInOut) -------------------------------- +-- -- @function [parent=#EaseElasticInOut] update -- @param self --- @param #float float +-- @param #float time -------------------------------- +-- -- @function [parent=#EaseElasticInOut] reverse -- @param self -- @return EaseElasticInOut#EaseElasticInOut ret (return value: cc.EaseElasticInOut) diff --git a/cocos/scripting/lua-bindings/auto/api/EaseElasticOut.lua b/cocos/scripting/lua-bindings/auto/api/EaseElasticOut.lua index a3a2498473..2b825cc636 100644 --- a/cocos/scripting/lua-bindings/auto/api/EaseElasticOut.lua +++ b/cocos/scripting/lua-bindings/auto/api/EaseElasticOut.lua @@ -9,21 +9,24 @@ -- @overload self, cc.ActionInterval, float -- @function [parent=#EaseElasticOut] create -- @param self --- @param #cc.ActionInterval actioninterval --- @param #float float +-- @param #cc.ActionInterval action +-- @param #float period -- @return EaseElasticOut#EaseElasticOut ret (retunr value: cc.EaseElasticOut) -------------------------------- +-- -- @function [parent=#EaseElasticOut] clone -- @param self -- @return EaseElasticOut#EaseElasticOut ret (return value: cc.EaseElasticOut) -------------------------------- +-- -- @function [parent=#EaseElasticOut] update -- @param self --- @param #float float +-- @param #float time -------------------------------- +-- -- @function [parent=#EaseElasticOut] reverse -- @param self -- @return EaseElastic#EaseElastic ret (return value: cc.EaseElastic) diff --git a/cocos/scripting/lua-bindings/auto/api/EaseExponentialIn.lua b/cocos/scripting/lua-bindings/auto/api/EaseExponentialIn.lua index 75601c4396..21007fb6ee 100644 --- a/cocos/scripting/lua-bindings/auto/api/EaseExponentialIn.lua +++ b/cocos/scripting/lua-bindings/auto/api/EaseExponentialIn.lua @@ -5,22 +5,26 @@ -- @parent_module cc -------------------------------- +-- creates the action -- @function [parent=#EaseExponentialIn] create -- @param self --- @param #cc.ActionInterval actioninterval +-- @param #cc.ActionInterval action -- @return EaseExponentialIn#EaseExponentialIn ret (return value: cc.EaseExponentialIn) -------------------------------- +-- -- @function [parent=#EaseExponentialIn] clone -- @param self -- @return EaseExponentialIn#EaseExponentialIn ret (return value: cc.EaseExponentialIn) -------------------------------- +-- -- @function [parent=#EaseExponentialIn] update -- @param self --- @param #float float +-- @param #float time -------------------------------- +-- -- @function [parent=#EaseExponentialIn] reverse -- @param self -- @return ActionEase#ActionEase ret (return value: cc.ActionEase) diff --git a/cocos/scripting/lua-bindings/auto/api/EaseExponentialInOut.lua b/cocos/scripting/lua-bindings/auto/api/EaseExponentialInOut.lua index c3985a8546..a61ad52653 100644 --- a/cocos/scripting/lua-bindings/auto/api/EaseExponentialInOut.lua +++ b/cocos/scripting/lua-bindings/auto/api/EaseExponentialInOut.lua @@ -5,22 +5,26 @@ -- @parent_module cc -------------------------------- +-- creates the action -- @function [parent=#EaseExponentialInOut] create -- @param self --- @param #cc.ActionInterval actioninterval +-- @param #cc.ActionInterval action -- @return EaseExponentialInOut#EaseExponentialInOut ret (return value: cc.EaseExponentialInOut) -------------------------------- +-- -- @function [parent=#EaseExponentialInOut] clone -- @param self -- @return EaseExponentialInOut#EaseExponentialInOut ret (return value: cc.EaseExponentialInOut) -------------------------------- +-- -- @function [parent=#EaseExponentialInOut] update -- @param self --- @param #float float +-- @param #float time -------------------------------- +-- -- @function [parent=#EaseExponentialInOut] reverse -- @param self -- @return EaseExponentialInOut#EaseExponentialInOut ret (return value: cc.EaseExponentialInOut) diff --git a/cocos/scripting/lua-bindings/auto/api/EaseExponentialOut.lua b/cocos/scripting/lua-bindings/auto/api/EaseExponentialOut.lua index e9a42c2a67..c434d595fd 100644 --- a/cocos/scripting/lua-bindings/auto/api/EaseExponentialOut.lua +++ b/cocos/scripting/lua-bindings/auto/api/EaseExponentialOut.lua @@ -5,22 +5,26 @@ -- @parent_module cc -------------------------------- +-- creates the action -- @function [parent=#EaseExponentialOut] create -- @param self --- @param #cc.ActionInterval actioninterval +-- @param #cc.ActionInterval action -- @return EaseExponentialOut#EaseExponentialOut ret (return value: cc.EaseExponentialOut) -------------------------------- +-- -- @function [parent=#EaseExponentialOut] clone -- @param self -- @return EaseExponentialOut#EaseExponentialOut ret (return value: cc.EaseExponentialOut) -------------------------------- +-- -- @function [parent=#EaseExponentialOut] update -- @param self --- @param #float float +-- @param #float time -------------------------------- +-- -- @function [parent=#EaseExponentialOut] reverse -- @param self -- @return ActionEase#ActionEase ret (return value: cc.ActionEase) diff --git a/cocos/scripting/lua-bindings/auto/api/EaseIn.lua b/cocos/scripting/lua-bindings/auto/api/EaseIn.lua index 139d6a7a70..bda5e33379 100644 --- a/cocos/scripting/lua-bindings/auto/api/EaseIn.lua +++ b/cocos/scripting/lua-bindings/auto/api/EaseIn.lua @@ -5,23 +5,27 @@ -- @parent_module cc -------------------------------- +-- Creates the action with the inner action and the rate parameter -- @function [parent=#EaseIn] create -- @param self --- @param #cc.ActionInterval actioninterval --- @param #float float +-- @param #cc.ActionInterval action +-- @param #float rate -- @return EaseIn#EaseIn ret (return value: cc.EaseIn) -------------------------------- +-- -- @function [parent=#EaseIn] clone -- @param self -- @return EaseIn#EaseIn ret (return value: cc.EaseIn) -------------------------------- +-- -- @function [parent=#EaseIn] update -- @param self --- @param #float float +-- @param #float time -------------------------------- +-- -- @function [parent=#EaseIn] reverse -- @param self -- @return EaseIn#EaseIn ret (return value: cc.EaseIn) diff --git a/cocos/scripting/lua-bindings/auto/api/EaseInOut.lua b/cocos/scripting/lua-bindings/auto/api/EaseInOut.lua index 965523b368..76491459b1 100644 --- a/cocos/scripting/lua-bindings/auto/api/EaseInOut.lua +++ b/cocos/scripting/lua-bindings/auto/api/EaseInOut.lua @@ -5,23 +5,27 @@ -- @parent_module cc -------------------------------- +-- Creates the action with the inner action and the rate parameter -- @function [parent=#EaseInOut] create -- @param self --- @param #cc.ActionInterval actioninterval --- @param #float float +-- @param #cc.ActionInterval action +-- @param #float rate -- @return EaseInOut#EaseInOut ret (return value: cc.EaseInOut) -------------------------------- +-- -- @function [parent=#EaseInOut] clone -- @param self -- @return EaseInOut#EaseInOut ret (return value: cc.EaseInOut) -------------------------------- +-- -- @function [parent=#EaseInOut] update -- @param self --- @param #float float +-- @param #float time -------------------------------- +-- -- @function [parent=#EaseInOut] reverse -- @param self -- @return EaseInOut#EaseInOut ret (return value: cc.EaseInOut) diff --git a/cocos/scripting/lua-bindings/auto/api/EaseOut.lua b/cocos/scripting/lua-bindings/auto/api/EaseOut.lua index ec630b401d..3312ee56d7 100644 --- a/cocos/scripting/lua-bindings/auto/api/EaseOut.lua +++ b/cocos/scripting/lua-bindings/auto/api/EaseOut.lua @@ -5,23 +5,27 @@ -- @parent_module cc -------------------------------- +-- Creates the action with the inner action and the rate parameter -- @function [parent=#EaseOut] create -- @param self --- @param #cc.ActionInterval actioninterval --- @param #float float +-- @param #cc.ActionInterval action +-- @param #float rate -- @return EaseOut#EaseOut ret (return value: cc.EaseOut) -------------------------------- +-- -- @function [parent=#EaseOut] clone -- @param self -- @return EaseOut#EaseOut ret (return value: cc.EaseOut) -------------------------------- +-- -- @function [parent=#EaseOut] update -- @param self --- @param #float float +-- @param #float time -------------------------------- +-- -- @function [parent=#EaseOut] reverse -- @param self -- @return EaseOut#EaseOut ret (return value: cc.EaseOut) diff --git a/cocos/scripting/lua-bindings/auto/api/EaseQuadraticActionIn.lua b/cocos/scripting/lua-bindings/auto/api/EaseQuadraticActionIn.lua index 0eab085d84..56ef34210f 100644 --- a/cocos/scripting/lua-bindings/auto/api/EaseQuadraticActionIn.lua +++ b/cocos/scripting/lua-bindings/auto/api/EaseQuadraticActionIn.lua @@ -5,22 +5,26 @@ -- @parent_module cc -------------------------------- +-- creates the action -- @function [parent=#EaseQuadraticActionIn] create -- @param self --- @param #cc.ActionInterval actioninterval +-- @param #cc.ActionInterval action -- @return EaseQuadraticActionIn#EaseQuadraticActionIn ret (return value: cc.EaseQuadraticActionIn) -------------------------------- +-- -- @function [parent=#EaseQuadraticActionIn] clone -- @param self -- @return EaseQuadraticActionIn#EaseQuadraticActionIn ret (return value: cc.EaseQuadraticActionIn) -------------------------------- +-- -- @function [parent=#EaseQuadraticActionIn] update -- @param self --- @param #float float +-- @param #float time -------------------------------- +-- -- @function [parent=#EaseQuadraticActionIn] reverse -- @param self -- @return EaseQuadraticActionIn#EaseQuadraticActionIn ret (return value: cc.EaseQuadraticActionIn) diff --git a/cocos/scripting/lua-bindings/auto/api/EaseQuadraticActionInOut.lua b/cocos/scripting/lua-bindings/auto/api/EaseQuadraticActionInOut.lua index 531d387b79..2e31d2c428 100644 --- a/cocos/scripting/lua-bindings/auto/api/EaseQuadraticActionInOut.lua +++ b/cocos/scripting/lua-bindings/auto/api/EaseQuadraticActionInOut.lua @@ -5,22 +5,26 @@ -- @parent_module cc -------------------------------- +-- creates the action -- @function [parent=#EaseQuadraticActionInOut] create -- @param self --- @param #cc.ActionInterval actioninterval +-- @param #cc.ActionInterval action -- @return EaseQuadraticActionInOut#EaseQuadraticActionInOut ret (return value: cc.EaseQuadraticActionInOut) -------------------------------- +-- -- @function [parent=#EaseQuadraticActionInOut] clone -- @param self -- @return EaseQuadraticActionInOut#EaseQuadraticActionInOut ret (return value: cc.EaseQuadraticActionInOut) -------------------------------- +-- -- @function [parent=#EaseQuadraticActionInOut] update -- @param self --- @param #float float +-- @param #float time -------------------------------- +-- -- @function [parent=#EaseQuadraticActionInOut] reverse -- @param self -- @return EaseQuadraticActionInOut#EaseQuadraticActionInOut ret (return value: cc.EaseQuadraticActionInOut) diff --git a/cocos/scripting/lua-bindings/auto/api/EaseQuadraticActionOut.lua b/cocos/scripting/lua-bindings/auto/api/EaseQuadraticActionOut.lua index e5b5f69955..a457f90723 100644 --- a/cocos/scripting/lua-bindings/auto/api/EaseQuadraticActionOut.lua +++ b/cocos/scripting/lua-bindings/auto/api/EaseQuadraticActionOut.lua @@ -5,22 +5,26 @@ -- @parent_module cc -------------------------------- +-- creates the action -- @function [parent=#EaseQuadraticActionOut] create -- @param self --- @param #cc.ActionInterval actioninterval +-- @param #cc.ActionInterval action -- @return EaseQuadraticActionOut#EaseQuadraticActionOut ret (return value: cc.EaseQuadraticActionOut) -------------------------------- +-- -- @function [parent=#EaseQuadraticActionOut] clone -- @param self -- @return EaseQuadraticActionOut#EaseQuadraticActionOut ret (return value: cc.EaseQuadraticActionOut) -------------------------------- +-- -- @function [parent=#EaseQuadraticActionOut] update -- @param self --- @param #float float +-- @param #float time -------------------------------- +-- -- @function [parent=#EaseQuadraticActionOut] reverse -- @param self -- @return EaseQuadraticActionOut#EaseQuadraticActionOut ret (return value: cc.EaseQuadraticActionOut) diff --git a/cocos/scripting/lua-bindings/auto/api/EaseQuarticActionIn.lua b/cocos/scripting/lua-bindings/auto/api/EaseQuarticActionIn.lua index 9763da5cce..71d6b84792 100644 --- a/cocos/scripting/lua-bindings/auto/api/EaseQuarticActionIn.lua +++ b/cocos/scripting/lua-bindings/auto/api/EaseQuarticActionIn.lua @@ -5,22 +5,26 @@ -- @parent_module cc -------------------------------- +-- creates the action -- @function [parent=#EaseQuarticActionIn] create -- @param self --- @param #cc.ActionInterval actioninterval +-- @param #cc.ActionInterval action -- @return EaseQuarticActionIn#EaseQuarticActionIn ret (return value: cc.EaseQuarticActionIn) -------------------------------- +-- -- @function [parent=#EaseQuarticActionIn] clone -- @param self -- @return EaseQuarticActionIn#EaseQuarticActionIn ret (return value: cc.EaseQuarticActionIn) -------------------------------- +-- -- @function [parent=#EaseQuarticActionIn] update -- @param self --- @param #float float +-- @param #float time -------------------------------- +-- -- @function [parent=#EaseQuarticActionIn] reverse -- @param self -- @return EaseQuarticActionIn#EaseQuarticActionIn ret (return value: cc.EaseQuarticActionIn) diff --git a/cocos/scripting/lua-bindings/auto/api/EaseQuarticActionInOut.lua b/cocos/scripting/lua-bindings/auto/api/EaseQuarticActionInOut.lua index 49d5f23685..9edd4fe4bd 100644 --- a/cocos/scripting/lua-bindings/auto/api/EaseQuarticActionInOut.lua +++ b/cocos/scripting/lua-bindings/auto/api/EaseQuarticActionInOut.lua @@ -5,22 +5,26 @@ -- @parent_module cc -------------------------------- +-- creates the action -- @function [parent=#EaseQuarticActionInOut] create -- @param self --- @param #cc.ActionInterval actioninterval +-- @param #cc.ActionInterval action -- @return EaseQuarticActionInOut#EaseQuarticActionInOut ret (return value: cc.EaseQuarticActionInOut) -------------------------------- +-- -- @function [parent=#EaseQuarticActionInOut] clone -- @param self -- @return EaseQuarticActionInOut#EaseQuarticActionInOut ret (return value: cc.EaseQuarticActionInOut) -------------------------------- +-- -- @function [parent=#EaseQuarticActionInOut] update -- @param self --- @param #float float +-- @param #float time -------------------------------- +-- -- @function [parent=#EaseQuarticActionInOut] reverse -- @param self -- @return EaseQuarticActionInOut#EaseQuarticActionInOut ret (return value: cc.EaseQuarticActionInOut) diff --git a/cocos/scripting/lua-bindings/auto/api/EaseQuarticActionOut.lua b/cocos/scripting/lua-bindings/auto/api/EaseQuarticActionOut.lua index c63c378424..c19781f8e7 100644 --- a/cocos/scripting/lua-bindings/auto/api/EaseQuarticActionOut.lua +++ b/cocos/scripting/lua-bindings/auto/api/EaseQuarticActionOut.lua @@ -5,22 +5,26 @@ -- @parent_module cc -------------------------------- +-- creates the action -- @function [parent=#EaseQuarticActionOut] create -- @param self --- @param #cc.ActionInterval actioninterval +-- @param #cc.ActionInterval action -- @return EaseQuarticActionOut#EaseQuarticActionOut ret (return value: cc.EaseQuarticActionOut) -------------------------------- +-- -- @function [parent=#EaseQuarticActionOut] clone -- @param self -- @return EaseQuarticActionOut#EaseQuarticActionOut ret (return value: cc.EaseQuarticActionOut) -------------------------------- +-- -- @function [parent=#EaseQuarticActionOut] update -- @param self --- @param #float float +-- @param #float time -------------------------------- +-- -- @function [parent=#EaseQuarticActionOut] reverse -- @param self -- @return EaseQuarticActionOut#EaseQuarticActionOut ret (return value: cc.EaseQuarticActionOut) diff --git a/cocos/scripting/lua-bindings/auto/api/EaseQuinticActionIn.lua b/cocos/scripting/lua-bindings/auto/api/EaseQuinticActionIn.lua index a0ed09cfc3..49f216a67e 100644 --- a/cocos/scripting/lua-bindings/auto/api/EaseQuinticActionIn.lua +++ b/cocos/scripting/lua-bindings/auto/api/EaseQuinticActionIn.lua @@ -5,22 +5,26 @@ -- @parent_module cc -------------------------------- +-- creates the action -- @function [parent=#EaseQuinticActionIn] create -- @param self --- @param #cc.ActionInterval actioninterval +-- @param #cc.ActionInterval action -- @return EaseQuinticActionIn#EaseQuinticActionIn ret (return value: cc.EaseQuinticActionIn) -------------------------------- +-- -- @function [parent=#EaseQuinticActionIn] clone -- @param self -- @return EaseQuinticActionIn#EaseQuinticActionIn ret (return value: cc.EaseQuinticActionIn) -------------------------------- +-- -- @function [parent=#EaseQuinticActionIn] update -- @param self --- @param #float float +-- @param #float time -------------------------------- +-- -- @function [parent=#EaseQuinticActionIn] reverse -- @param self -- @return EaseQuinticActionIn#EaseQuinticActionIn ret (return value: cc.EaseQuinticActionIn) diff --git a/cocos/scripting/lua-bindings/auto/api/EaseQuinticActionInOut.lua b/cocos/scripting/lua-bindings/auto/api/EaseQuinticActionInOut.lua index 24231cae27..ecb66dde84 100644 --- a/cocos/scripting/lua-bindings/auto/api/EaseQuinticActionInOut.lua +++ b/cocos/scripting/lua-bindings/auto/api/EaseQuinticActionInOut.lua @@ -5,22 +5,26 @@ -- @parent_module cc -------------------------------- +-- creates the action -- @function [parent=#EaseQuinticActionInOut] create -- @param self --- @param #cc.ActionInterval actioninterval +-- @param #cc.ActionInterval action -- @return EaseQuinticActionInOut#EaseQuinticActionInOut ret (return value: cc.EaseQuinticActionInOut) -------------------------------- +-- -- @function [parent=#EaseQuinticActionInOut] clone -- @param self -- @return EaseQuinticActionInOut#EaseQuinticActionInOut ret (return value: cc.EaseQuinticActionInOut) -------------------------------- +-- -- @function [parent=#EaseQuinticActionInOut] update -- @param self --- @param #float float +-- @param #float time -------------------------------- +-- -- @function [parent=#EaseQuinticActionInOut] reverse -- @param self -- @return EaseQuinticActionInOut#EaseQuinticActionInOut ret (return value: cc.EaseQuinticActionInOut) diff --git a/cocos/scripting/lua-bindings/auto/api/EaseQuinticActionOut.lua b/cocos/scripting/lua-bindings/auto/api/EaseQuinticActionOut.lua index b87c6d5fc2..3b44212159 100644 --- a/cocos/scripting/lua-bindings/auto/api/EaseQuinticActionOut.lua +++ b/cocos/scripting/lua-bindings/auto/api/EaseQuinticActionOut.lua @@ -5,22 +5,26 @@ -- @parent_module cc -------------------------------- +-- creates the action -- @function [parent=#EaseQuinticActionOut] create -- @param self --- @param #cc.ActionInterval actioninterval +-- @param #cc.ActionInterval action -- @return EaseQuinticActionOut#EaseQuinticActionOut ret (return value: cc.EaseQuinticActionOut) -------------------------------- +-- -- @function [parent=#EaseQuinticActionOut] clone -- @param self -- @return EaseQuinticActionOut#EaseQuinticActionOut ret (return value: cc.EaseQuinticActionOut) -------------------------------- +-- -- @function [parent=#EaseQuinticActionOut] update -- @param self --- @param #float float +-- @param #float time -------------------------------- +-- -- @function [parent=#EaseQuinticActionOut] reverse -- @param self -- @return EaseQuinticActionOut#EaseQuinticActionOut ret (return value: cc.EaseQuinticActionOut) diff --git a/cocos/scripting/lua-bindings/auto/api/EaseRateAction.lua b/cocos/scripting/lua-bindings/auto/api/EaseRateAction.lua index 2712d20ef1..4508d53990 100644 --- a/cocos/scripting/lua-bindings/auto/api/EaseRateAction.lua +++ b/cocos/scripting/lua-bindings/auto/api/EaseRateAction.lua @@ -5,21 +5,25 @@ -- @parent_module cc -------------------------------- +-- set rate value for the actions -- @function [parent=#EaseRateAction] setRate -- @param self --- @param #float float +-- @param #float rate -------------------------------- +-- get rate value for the actions -- @function [parent=#EaseRateAction] getRate -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#EaseRateAction] clone -- @param self -- @return EaseRateAction#EaseRateAction ret (return value: cc.EaseRateAction) -------------------------------- +-- -- @function [parent=#EaseRateAction] reverse -- @param self -- @return EaseRateAction#EaseRateAction ret (return value: cc.EaseRateAction) diff --git a/cocos/scripting/lua-bindings/auto/api/EaseSineIn.lua b/cocos/scripting/lua-bindings/auto/api/EaseSineIn.lua index fb85e63833..8f77dfde52 100644 --- a/cocos/scripting/lua-bindings/auto/api/EaseSineIn.lua +++ b/cocos/scripting/lua-bindings/auto/api/EaseSineIn.lua @@ -5,22 +5,26 @@ -- @parent_module cc -------------------------------- +-- creates the action -- @function [parent=#EaseSineIn] create -- @param self --- @param #cc.ActionInterval actioninterval +-- @param #cc.ActionInterval action -- @return EaseSineIn#EaseSineIn ret (return value: cc.EaseSineIn) -------------------------------- +-- -- @function [parent=#EaseSineIn] clone -- @param self -- @return EaseSineIn#EaseSineIn ret (return value: cc.EaseSineIn) -------------------------------- +-- -- @function [parent=#EaseSineIn] update -- @param self --- @param #float float +-- @param #float time -------------------------------- +-- -- @function [parent=#EaseSineIn] reverse -- @param self -- @return ActionEase#ActionEase ret (return value: cc.ActionEase) diff --git a/cocos/scripting/lua-bindings/auto/api/EaseSineInOut.lua b/cocos/scripting/lua-bindings/auto/api/EaseSineInOut.lua index d1f4828dca..0425c998db 100644 --- a/cocos/scripting/lua-bindings/auto/api/EaseSineInOut.lua +++ b/cocos/scripting/lua-bindings/auto/api/EaseSineInOut.lua @@ -5,22 +5,26 @@ -- @parent_module cc -------------------------------- +-- creates the action -- @function [parent=#EaseSineInOut] create -- @param self --- @param #cc.ActionInterval actioninterval +-- @param #cc.ActionInterval action -- @return EaseSineInOut#EaseSineInOut ret (return value: cc.EaseSineInOut) -------------------------------- +-- -- @function [parent=#EaseSineInOut] clone -- @param self -- @return EaseSineInOut#EaseSineInOut ret (return value: cc.EaseSineInOut) -------------------------------- +-- -- @function [parent=#EaseSineInOut] update -- @param self --- @param #float float +-- @param #float time -------------------------------- +-- -- @function [parent=#EaseSineInOut] reverse -- @param self -- @return EaseSineInOut#EaseSineInOut ret (return value: cc.EaseSineInOut) diff --git a/cocos/scripting/lua-bindings/auto/api/EaseSineOut.lua b/cocos/scripting/lua-bindings/auto/api/EaseSineOut.lua index aae018e91f..b751bed6af 100644 --- a/cocos/scripting/lua-bindings/auto/api/EaseSineOut.lua +++ b/cocos/scripting/lua-bindings/auto/api/EaseSineOut.lua @@ -5,22 +5,26 @@ -- @parent_module cc -------------------------------- +-- creates the action -- @function [parent=#EaseSineOut] create -- @param self --- @param #cc.ActionInterval actioninterval +-- @param #cc.ActionInterval action -- @return EaseSineOut#EaseSineOut ret (return value: cc.EaseSineOut) -------------------------------- +-- -- @function [parent=#EaseSineOut] clone -- @param self -- @return EaseSineOut#EaseSineOut ret (return value: cc.EaseSineOut) -------------------------------- +-- -- @function [parent=#EaseSineOut] update -- @param self --- @param #float float +-- @param #float time -------------------------------- +-- -- @function [parent=#EaseSineOut] reverse -- @param self -- @return ActionEase#ActionEase ret (return value: cc.ActionEase) diff --git a/cocos/scripting/lua-bindings/auto/api/EditBox.lua b/cocos/scripting/lua-bindings/auto/api/EditBox.lua deleted file mode 100644 index 35579ac4c8..0000000000 --- a/cocos/scripting/lua-bindings/auto/api/EditBox.lua +++ /dev/null @@ -1,134 +0,0 @@ - --------------------------------- --- @module EditBox --- @extend ControlButton,IMEDelegate --- @parent_module cc - --------------------------------- --- @function [parent=#EditBox] getText --- @param self --- @return char#char ret (return value: char) - --------------------------------- --- @function [parent=#EditBox] setPlaceholderFontName --- @param self --- @param #char char - --------------------------------- --- @function [parent=#EditBox] getPlaceHolder --- @param self --- @return char#char ret (return value: char) - --------------------------------- --- @function [parent=#EditBox] setFontName --- @param self --- @param #char char - --------------------------------- --- @function [parent=#EditBox] setPlaceholderFontSize --- @param self --- @param #int int - --------------------------------- --- @function [parent=#EditBox] setInputMode --- @param self --- @param #int inputmode - --------------------------------- --- @function [parent=#EditBox] setPlaceholderFontColor --- @param self --- @param #color3b_table color3b - --------------------------------- --- @function [parent=#EditBox] setFontColor --- @param self --- @param #color3b_table color3b - --------------------------------- --- @function [parent=#EditBox] setPlaceholderFont --- @param self --- @param #char char --- @param #int int - --------------------------------- --- @function [parent=#EditBox] setFontSize --- @param self --- @param #int int - --------------------------------- --- @function [parent=#EditBox] initWithSizeAndBackgroundSprite --- @param self --- @param #size_table size --- @param #cc.Scale9Sprite scale9sprite --- @return bool#bool ret (return value: bool) - --------------------------------- --- @function [parent=#EditBox] setPlaceHolder --- @param self --- @param #char char - --------------------------------- --- @function [parent=#EditBox] setReturnType --- @param self --- @param #int keyboardreturntype - --------------------------------- --- @function [parent=#EditBox] setInputFlag --- @param self --- @param #int inputflag - --------------------------------- --- @function [parent=#EditBox] getMaxLength --- @param self --- @return int#int ret (return value: int) - --------------------------------- --- @function [parent=#EditBox] setText --- @param self --- @param #char char - --------------------------------- --- @function [parent=#EditBox] setMaxLength --- @param self --- @param #int int - --------------------------------- --- @function [parent=#EditBox] setFont --- @param self --- @param #char char --- @param #int int - --------------------------------- --- @function [parent=#EditBox] create --- @param self --- @param #size_table size --- @param #cc.Scale9Sprite scale9sprite --- @param #cc.Scale9Sprite scale9sprite --- @param #cc.Scale9Sprite scale9sprite --- @return EditBox#EditBox ret (return value: cc.EditBox) - --------------------------------- --- @function [parent=#EditBox] setAnchorPoint --- @param self --- @param #vec2_table vec2 - --------------------------------- --- @function [parent=#EditBox] setPosition --- @param self --- @param #vec2_table vec2 - --------------------------------- --- @function [parent=#EditBox] setVisible --- @param self --- @param #bool bool - --------------------------------- --- @function [parent=#EditBox] setContentSize --- @param self --- @param #size_table size - --------------------------------- --- @function [parent=#EditBox] EditBox --- @param self - -return nil diff --git a/cocos/scripting/lua-bindings/auto/api/Event.lua b/cocos/scripting/lua-bindings/auto/api/Event.lua index aebf35b831..62e8c8347e 100644 --- a/cocos/scripting/lua-bindings/auto/api/Event.lua +++ b/cocos/scripting/lua-bindings/auto/api/Event.lua @@ -5,21 +5,28 @@ -- @parent_module cc -------------------------------- +-- Checks whether the event has been stopped -- @function [parent=#Event] isStopped -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- Gets the event type -- @function [parent=#Event] getType -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- @brief Gets current target of the event
+-- return The target with which the event associates.
+-- note It onlys be available when the event listener is associated with node.
+-- It returns 0 when the listener is associated with fixed priority. -- @function [parent=#Event] getCurrentTarget -- @param self -- @return Node#Node ret (return value: cc.Node) -------------------------------- +-- Stops propagation for current event -- @function [parent=#Event] stopPropagation -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/EventController.lua b/cocos/scripting/lua-bindings/auto/api/EventController.lua index e727158d6f..108baafc32 100644 --- a/cocos/scripting/lua-bindings/auto/api/EventController.lua +++ b/cocos/scripting/lua-bindings/auto/api/EventController.lua @@ -5,31 +5,37 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#EventController] getControllerEventType -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- -- @function [parent=#EventController] setConnectStatus -- @param self --- @param #bool bool +-- @param #bool isConnected -------------------------------- +-- -- @function [parent=#EventController] isConnected -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#EventController] setKeyCode -- @param self --- @param #int int +-- @param #int keyCode -------------------------------- +-- -- @function [parent=#EventController] getController -- @param self -- @return Controller#Controller ret (return value: cc.Controller) -------------------------------- +-- -- @function [parent=#EventController] getKeyCode -- @param self -- @return int#int ret (return value: int) @@ -39,8 +45,8 @@ -- @overload self, int, cc.Controller, int -- @function [parent=#EventController] EventController -- @param self --- @param #int controllereventtype +-- @param #int type -- @param #cc.Controller controller --- @param #int int +-- @param #int keyCode return nil diff --git a/cocos/scripting/lua-bindings/auto/api/EventCustom.lua b/cocos/scripting/lua-bindings/auto/api/EventCustom.lua index 2f8ebe818d..645d85e0a7 100644 --- a/cocos/scripting/lua-bindings/auto/api/EventCustom.lua +++ b/cocos/scripting/lua-bindings/auto/api/EventCustom.lua @@ -5,13 +5,15 @@ -- @parent_module cc -------------------------------- +-- Gets event name -- @function [parent=#EventCustom] getEventName -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- Constructor -- @function [parent=#EventCustom] EventCustom -- @param self --- @param #string str +-- @param #string eventName return nil diff --git a/cocos/scripting/lua-bindings/auto/api/EventDispatcher.lua b/cocos/scripting/lua-bindings/auto/api/EventDispatcher.lua index 84c8901a93..2db1cfbe9a 100644 --- a/cocos/scripting/lua-bindings/auto/api/EventDispatcher.lua +++ b/cocos/scripting/lua-bindings/auto/api/EventDispatcher.lua @@ -5,83 +5,111 @@ -- @parent_module cc -------------------------------- +-- Pauses all listeners which are associated the specified target. -- @function [parent=#EventDispatcher] pauseEventListenersForTarget -- @param self --- @param #cc.Node node --- @param #bool bool +-- @param #cc.Node target +-- @param #bool recursive -------------------------------- +-- Adds a event listener for a specified event with the priority of scene graph.
+-- param listener The listener of a specified event.
+-- param node The priority of the listener is based on the draw order of this node.
+-- note The priority of scene graph will be fixed value 0. So the order of listener item
+-- in the vector will be ' <0, scene graph (0 priority), >0'. -- @function [parent=#EventDispatcher] addEventListenerWithSceneGraphPriority -- @param self --- @param #cc.EventListener eventlistener +-- @param #cc.EventListener listener -- @param #cc.Node node -------------------------------- +-- Whether to enable dispatching events -- @function [parent=#EventDispatcher] setEnabled -- @param self --- @param #bool bool +-- @param #bool isEnabled -------------------------------- +-- Adds a event listener for a specified event with the fixed priority.
+-- param listener The listener of a specified event.
+-- param fixedPriority The fixed priority of the listener.
+-- note A lower priority will be called before the ones that have a higher value.
+-- 0 priority is forbidden for fixed priority since it's used for scene graph based priority. -- @function [parent=#EventDispatcher] addEventListenerWithFixedPriority -- @param self --- @param #cc.EventListener eventlistener --- @param #int int +-- @param #cc.EventListener listener +-- @param #int fixedPriority -------------------------------- +-- Remove a listener
+-- param listener The specified event listener which needs to be removed. -- @function [parent=#EventDispatcher] removeEventListener -- @param self --- @param #cc.EventListener eventlistener +-- @param #cc.EventListener listener -------------------------------- +-- Resumes all listeners which are associated the specified target. -- @function [parent=#EventDispatcher] resumeEventListenersForTarget -- @param self --- @param #cc.Node node --- @param #bool bool +-- @param #cc.Node target +-- @param #bool recursive -------------------------------- +-- Removes all listeners which are associated with the specified target. -- @function [parent=#EventDispatcher] removeEventListenersForTarget -- @param self --- @param #cc.Node node --- @param #bool bool +-- @param #cc.Node target +-- @param #bool recursive -------------------------------- +-- Sets listener's priority with fixed value. -- @function [parent=#EventDispatcher] setPriority -- @param self --- @param #cc.EventListener eventlistener --- @param #int int +-- @param #cc.EventListener listener +-- @param #int fixedPriority -------------------------------- +-- Adds a Custom event listener.
+-- It will use a fixed priority of 1.
+-- return the generated event. Needed in order to remove the event from the dispather -- @function [parent=#EventDispatcher] addCustomEventListener -- @param self --- @param #string str --- @param #function func +-- @param #string eventName +-- @param #function callback -- @return EventListenerCustom#EventListenerCustom ret (return value: cc.EventListenerCustom) -------------------------------- +-- Dispatches the event
+-- Also removes all EventListeners marked for deletion from the
+-- event dispatcher list. -- @function [parent=#EventDispatcher] dispatchEvent -- @param self -- @param #cc.Event event -------------------------------- +-- Removes all listeners -- @function [parent=#EventDispatcher] removeAllEventListeners -- @param self -------------------------------- +-- Removes all custom listeners with the same event name -- @function [parent=#EventDispatcher] removeCustomEventListeners -- @param self --- @param #string str +-- @param #string customEventName -------------------------------- +-- Checks whether dispatching events is enabled -- @function [parent=#EventDispatcher] isEnabled -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- Removes all listeners with the same event listener type -- @function [parent=#EventDispatcher] removeEventListenersForType -- @param self --- @param #int type +-- @param #int listenerType -------------------------------- +-- Constructor of EventDispatcher -- @function [parent=#EventDispatcher] EventDispatcher -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/EventFocus.lua b/cocos/scripting/lua-bindings/auto/api/EventFocus.lua index 3aa39d96ff..29c49daf43 100644 --- a/cocos/scripting/lua-bindings/auto/api/EventFocus.lua +++ b/cocos/scripting/lua-bindings/auto/api/EventFocus.lua @@ -5,9 +5,10 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#EventFocus] EventFocus -- @param self --- @param #ccui.Widget widget --- @param #ccui.Widget widget +-- @param #ccui.Widget widgetLoseFocus +-- @param #ccui.Widget widgetGetFocus return nil diff --git a/cocos/scripting/lua-bindings/auto/api/EventFrame.lua b/cocos/scripting/lua-bindings/auto/api/EventFrame.lua index 2638ad42bc..67930d7f4c 100644 --- a/cocos/scripting/lua-bindings/auto/api/EventFrame.lua +++ b/cocos/scripting/lua-bindings/auto/api/EventFrame.lua @@ -5,26 +5,31 @@ -- @parent_module ccs -------------------------------- +-- -- @function [parent=#EventFrame] setEvent -- @param self --- @param #string str +-- @param #string event -------------------------------- +-- -- @function [parent=#EventFrame] getEvent -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- -- @function [parent=#EventFrame] create -- @param self -- @return EventFrame#EventFrame ret (return value: ccs.EventFrame) -------------------------------- +-- -- @function [parent=#EventFrame] clone -- @param self -- @return Frame#Frame ret (return value: ccs.Frame) -------------------------------- +-- -- @function [parent=#EventFrame] EventFrame -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/EventKeyboard.lua b/cocos/scripting/lua-bindings/auto/api/EventKeyboard.lua index 86f722ae6b..23861ac190 100644 --- a/cocos/scripting/lua-bindings/auto/api/EventKeyboard.lua +++ b/cocos/scripting/lua-bindings/auto/api/EventKeyboard.lua @@ -5,9 +5,10 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#EventKeyboard] EventKeyboard -- @param self --- @param #int keycode --- @param #bool bool +-- @param #int keyCode +-- @param #bool isPressed return nil diff --git a/cocos/scripting/lua-bindings/auto/api/EventListener.lua b/cocos/scripting/lua-bindings/auto/api/EventListener.lua index 2bd1addba5..220f4b3901 100644 --- a/cocos/scripting/lua-bindings/auto/api/EventListener.lua +++ b/cocos/scripting/lua-bindings/auto/api/EventListener.lua @@ -5,21 +5,29 @@ -- @parent_module cc -------------------------------- +-- Enables or disables the listener
+-- note Only listeners with `enabled` state will be able to receive events.
+-- When an listener was initialized, it's enabled by default.
+-- An event listener can receive events when it is enabled and is not paused.
+-- paused state is always false when it is a fixed priority listener. -- @function [parent=#EventListener] setEnabled -- @param self --- @param #bool bool +-- @param #bool enabled -------------------------------- +-- Clones the listener, its subclasses have to override this method. -- @function [parent=#EventListener] clone -- @param self -- @return EventListener#EventListener ret (return value: cc.EventListener) -------------------------------- +-- Checks whether the listener is enabled -- @function [parent=#EventListener] isEnabled -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- Checks whether the listener is available. -- @function [parent=#EventListener] checkAvailable -- @param self -- @return bool#bool ret (return value: bool) diff --git a/cocos/scripting/lua-bindings/auto/api/EventListenerAcceleration.lua b/cocos/scripting/lua-bindings/auto/api/EventListenerAcceleration.lua index 0ac7abb066..33760d7da4 100644 --- a/cocos/scripting/lua-bindings/auto/api/EventListenerAcceleration.lua +++ b/cocos/scripting/lua-bindings/auto/api/EventListenerAcceleration.lua @@ -5,11 +5,13 @@ -- @parent_module cc -------------------------------- +-- / Overrides -- @function [parent=#EventListenerAcceleration] clone -- @param self -- @return EventListenerAcceleration#EventListenerAcceleration ret (return value: cc.EventListenerAcceleration) -------------------------------- +-- -- @function [parent=#EventListenerAcceleration] checkAvailable -- @param self -- @return bool#bool ret (return value: bool) diff --git a/cocos/scripting/lua-bindings/auto/api/EventListenerController.lua b/cocos/scripting/lua-bindings/auto/api/EventListenerController.lua index 338b93fcd1..362d380c5b 100644 --- a/cocos/scripting/lua-bindings/auto/api/EventListenerController.lua +++ b/cocos/scripting/lua-bindings/auto/api/EventListenerController.lua @@ -5,16 +5,19 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#EventListenerController] create -- @param self -- @return EventListenerController#EventListenerController ret (return value: cc.EventListenerController) -------------------------------- +-- -- @function [parent=#EventListenerController] clone -- @param self -- @return EventListenerController#EventListenerController ret (return value: cc.EventListenerController) -------------------------------- +-- / Overrides -- @function [parent=#EventListenerController] checkAvailable -- @param self -- @return bool#bool ret (return value: bool) diff --git a/cocos/scripting/lua-bindings/auto/api/EventListenerCustom.lua b/cocos/scripting/lua-bindings/auto/api/EventListenerCustom.lua index c8d4281472..c634a11605 100644 --- a/cocos/scripting/lua-bindings/auto/api/EventListenerCustom.lua +++ b/cocos/scripting/lua-bindings/auto/api/EventListenerCustom.lua @@ -5,11 +5,13 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#EventListenerCustom] clone -- @param self -- @return EventListenerCustom#EventListenerCustom ret (return value: cc.EventListenerCustom) -------------------------------- +-- / Overrides -- @function [parent=#EventListenerCustom] checkAvailable -- @param self -- @return bool#bool ret (return value: bool) diff --git a/cocos/scripting/lua-bindings/auto/api/EventListenerFocus.lua b/cocos/scripting/lua-bindings/auto/api/EventListenerFocus.lua index 038a145fa7..7e6c399722 100644 --- a/cocos/scripting/lua-bindings/auto/api/EventListenerFocus.lua +++ b/cocos/scripting/lua-bindings/auto/api/EventListenerFocus.lua @@ -5,11 +5,13 @@ -- @parent_module cc -------------------------------- +-- / Overrides -- @function [parent=#EventListenerFocus] clone -- @param self -- @return EventListenerFocus#EventListenerFocus ret (return value: cc.EventListenerFocus) -------------------------------- +-- -- @function [parent=#EventListenerFocus] checkAvailable -- @param self -- @return bool#bool ret (return value: bool) diff --git a/cocos/scripting/lua-bindings/auto/api/EventListenerKeyboard.lua b/cocos/scripting/lua-bindings/auto/api/EventListenerKeyboard.lua index ff9594630a..9c8fcc5110 100644 --- a/cocos/scripting/lua-bindings/auto/api/EventListenerKeyboard.lua +++ b/cocos/scripting/lua-bindings/auto/api/EventListenerKeyboard.lua @@ -5,11 +5,13 @@ -- @parent_module cc -------------------------------- +-- / Overrides -- @function [parent=#EventListenerKeyboard] clone -- @param self -- @return EventListenerKeyboard#EventListenerKeyboard ret (return value: cc.EventListenerKeyboard) -------------------------------- +-- -- @function [parent=#EventListenerKeyboard] checkAvailable -- @param self -- @return bool#bool ret (return value: bool) diff --git a/cocos/scripting/lua-bindings/auto/api/EventListenerMouse.lua b/cocos/scripting/lua-bindings/auto/api/EventListenerMouse.lua index fc04e71698..4015a24615 100644 --- a/cocos/scripting/lua-bindings/auto/api/EventListenerMouse.lua +++ b/cocos/scripting/lua-bindings/auto/api/EventListenerMouse.lua @@ -5,11 +5,13 @@ -- @parent_module cc -------------------------------- +-- / Overrides -- @function [parent=#EventListenerMouse] clone -- @param self -- @return EventListenerMouse#EventListenerMouse ret (return value: cc.EventListenerMouse) -------------------------------- +-- -- @function [parent=#EventListenerMouse] checkAvailable -- @param self -- @return bool#bool ret (return value: bool) diff --git a/cocos/scripting/lua-bindings/auto/api/EventListenerPhysicsContact.lua b/cocos/scripting/lua-bindings/auto/api/EventListenerPhysicsContact.lua index 5c9d1e6fc5..02039547f8 100644 --- a/cocos/scripting/lua-bindings/auto/api/EventListenerPhysicsContact.lua +++ b/cocos/scripting/lua-bindings/auto/api/EventListenerPhysicsContact.lua @@ -5,16 +5,19 @@ -- @parent_module cc -------------------------------- +-- create the listener -- @function [parent=#EventListenerPhysicsContact] create -- @param self -- @return EventListenerPhysicsContact#EventListenerPhysicsContact ret (return value: cc.EventListenerPhysicsContact) -------------------------------- +-- -- @function [parent=#EventListenerPhysicsContact] clone -- @param self -- @return EventListenerPhysicsContact#EventListenerPhysicsContact ret (return value: cc.EventListenerPhysicsContact) -------------------------------- +-- -- @function [parent=#EventListenerPhysicsContact] checkAvailable -- @param self -- @return bool#bool ret (return value: bool) diff --git a/cocos/scripting/lua-bindings/auto/api/EventListenerPhysicsContactWithBodies.lua b/cocos/scripting/lua-bindings/auto/api/EventListenerPhysicsContactWithBodies.lua index 88e8610634..02b608e263 100644 --- a/cocos/scripting/lua-bindings/auto/api/EventListenerPhysicsContactWithBodies.lua +++ b/cocos/scripting/lua-bindings/auto/api/EventListenerPhysicsContactWithBodies.lua @@ -5,20 +5,23 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#EventListenerPhysicsContactWithBodies] hitTest -- @param self --- @param #cc.PhysicsShape physicsshape --- @param #cc.PhysicsShape physicsshape +-- @param #cc.PhysicsShape shapeA +-- @param #cc.PhysicsShape shapeB -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#EventListenerPhysicsContactWithBodies] create -- @param self --- @param #cc.PhysicsBody physicsbody --- @param #cc.PhysicsBody physicsbody +-- @param #cc.PhysicsBody bodyA +-- @param #cc.PhysicsBody bodyB -- @return EventListenerPhysicsContactWithBodies#EventListenerPhysicsContactWithBodies ret (return value: cc.EventListenerPhysicsContactWithBodies) -------------------------------- +-- -- @function [parent=#EventListenerPhysicsContactWithBodies] clone -- @param self -- @return EventListenerPhysicsContactWithBodies#EventListenerPhysicsContactWithBodies ret (return value: cc.EventListenerPhysicsContactWithBodies) diff --git a/cocos/scripting/lua-bindings/auto/api/EventListenerPhysicsContactWithGroup.lua b/cocos/scripting/lua-bindings/auto/api/EventListenerPhysicsContactWithGroup.lua index 73c3f799f2..0222b32314 100644 --- a/cocos/scripting/lua-bindings/auto/api/EventListenerPhysicsContactWithGroup.lua +++ b/cocos/scripting/lua-bindings/auto/api/EventListenerPhysicsContactWithGroup.lua @@ -5,19 +5,22 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#EventListenerPhysicsContactWithGroup] hitTest -- @param self --- @param #cc.PhysicsShape physicsshape --- @param #cc.PhysicsShape physicsshape +-- @param #cc.PhysicsShape shapeA +-- @param #cc.PhysicsShape shapeB -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#EventListenerPhysicsContactWithGroup] create -- @param self --- @param #int int +-- @param #int group -- @return EventListenerPhysicsContactWithGroup#EventListenerPhysicsContactWithGroup ret (return value: cc.EventListenerPhysicsContactWithGroup) -------------------------------- +-- -- @function [parent=#EventListenerPhysicsContactWithGroup] clone -- @param self -- @return EventListenerPhysicsContactWithGroup#EventListenerPhysicsContactWithGroup ret (return value: cc.EventListenerPhysicsContactWithGroup) diff --git a/cocos/scripting/lua-bindings/auto/api/EventListenerPhysicsContactWithShapes.lua b/cocos/scripting/lua-bindings/auto/api/EventListenerPhysicsContactWithShapes.lua index 902a390148..96f49e33c7 100644 --- a/cocos/scripting/lua-bindings/auto/api/EventListenerPhysicsContactWithShapes.lua +++ b/cocos/scripting/lua-bindings/auto/api/EventListenerPhysicsContactWithShapes.lua @@ -5,20 +5,23 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#EventListenerPhysicsContactWithShapes] hitTest -- @param self --- @param #cc.PhysicsShape physicsshape --- @param #cc.PhysicsShape physicsshape +-- @param #cc.PhysicsShape shapeA +-- @param #cc.PhysicsShape shapeB -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#EventListenerPhysicsContactWithShapes] create -- @param self --- @param #cc.PhysicsShape physicsshape --- @param #cc.PhysicsShape physicsshape +-- @param #cc.PhysicsShape shapeA +-- @param #cc.PhysicsShape shapeB -- @return EventListenerPhysicsContactWithShapes#EventListenerPhysicsContactWithShapes ret (return value: cc.EventListenerPhysicsContactWithShapes) -------------------------------- +-- -- @function [parent=#EventListenerPhysicsContactWithShapes] clone -- @param self -- @return EventListenerPhysicsContactWithShapes#EventListenerPhysicsContactWithShapes ret (return value: cc.EventListenerPhysicsContactWithShapes) diff --git a/cocos/scripting/lua-bindings/auto/api/EventListenerTouchAllAtOnce.lua b/cocos/scripting/lua-bindings/auto/api/EventListenerTouchAllAtOnce.lua index fd7e487488..3c6425d423 100644 --- a/cocos/scripting/lua-bindings/auto/api/EventListenerTouchAllAtOnce.lua +++ b/cocos/scripting/lua-bindings/auto/api/EventListenerTouchAllAtOnce.lua @@ -5,11 +5,13 @@ -- @parent_module cc -------------------------------- +-- / Overrides -- @function [parent=#EventListenerTouchAllAtOnce] clone -- @param self -- @return EventListenerTouchAllAtOnce#EventListenerTouchAllAtOnce ret (return value: cc.EventListenerTouchAllAtOnce) -------------------------------- +-- -- @function [parent=#EventListenerTouchAllAtOnce] checkAvailable -- @param self -- @return bool#bool ret (return value: bool) diff --git a/cocos/scripting/lua-bindings/auto/api/EventListenerTouchOneByOne.lua b/cocos/scripting/lua-bindings/auto/api/EventListenerTouchOneByOne.lua index 1da5fcb02e..adfc237d07 100644 --- a/cocos/scripting/lua-bindings/auto/api/EventListenerTouchOneByOne.lua +++ b/cocos/scripting/lua-bindings/auto/api/EventListenerTouchOneByOne.lua @@ -5,21 +5,25 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#EventListenerTouchOneByOne] isSwallowTouches -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#EventListenerTouchOneByOne] setSwallowTouches -- @param self --- @param #bool bool +-- @param #bool needSwallow -------------------------------- +-- / Overrides -- @function [parent=#EventListenerTouchOneByOne] clone -- @param self -- @return EventListenerTouchOneByOne#EventListenerTouchOneByOne ret (return value: cc.EventListenerTouchOneByOne) -------------------------------- +-- -- @function [parent=#EventListenerTouchOneByOne] checkAvailable -- @param self -- @return bool#bool ret (return value: bool) diff --git a/cocos/scripting/lua-bindings/auto/api/EventMouse.lua b/cocos/scripting/lua-bindings/auto/api/EventMouse.lua index 4d991e49e3..4021c695a2 100644 --- a/cocos/scripting/lua-bindings/auto/api/EventMouse.lua +++ b/cocos/scripting/lua-bindings/auto/api/EventMouse.lua @@ -5,85 +5,101 @@ -- @parent_module cc -------------------------------- +-- returns the previous touch location in screen coordinates -- @function [parent=#EventMouse] getPreviousLocationInView -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- returns the current touch location in OpenGL coordinates -- @function [parent=#EventMouse] getLocation -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- -- @function [parent=#EventMouse] getMouseButton -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- returns the previous touch location in OpenGL coordinates -- @function [parent=#EventMouse] getPreviousLocation -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- returns the delta of 2 current touches locations in screen coordinates -- @function [parent=#EventMouse] getDelta -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- Set mouse scroll data -- @function [parent=#EventMouse] setScrollData -- @param self --- @param #float float --- @param #float float +-- @param #float scrollX +-- @param #float scrollY -------------------------------- +-- returns the start touch location in screen coordinates -- @function [parent=#EventMouse] getStartLocationInView -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- returns the start touch location in OpenGL coordinates -- @function [parent=#EventMouse] getStartLocation -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- -- @function [parent=#EventMouse] setMouseButton -- @param self --- @param #int int +-- @param #int button -------------------------------- +-- returns the current touch location in screen coordinates -- @function [parent=#EventMouse] getLocationInView -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- -- @function [parent=#EventMouse] getScrollY -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#EventMouse] getScrollX -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#EventMouse] getCursorX -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#EventMouse] getCursorY -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#EventMouse] setCursorPosition -- @param self --- @param #float float --- @param #float float +-- @param #float x +-- @param #float y -------------------------------- +-- -- @function [parent=#EventMouse] EventMouse -- @param self --- @param #int mouseeventtype +-- @param #int mouseEventCode return nil diff --git a/cocos/scripting/lua-bindings/auto/api/EventTouch.lua b/cocos/scripting/lua-bindings/auto/api/EventTouch.lua index d32256fd93..16567c6908 100644 --- a/cocos/scripting/lua-bindings/auto/api/EventTouch.lua +++ b/cocos/scripting/lua-bindings/auto/api/EventTouch.lua @@ -5,16 +5,19 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#EventTouch] getEventCode -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- -- @function [parent=#EventTouch] setEventCode -- @param self --- @param #int eventcode +-- @param #int eventCode -------------------------------- +-- -- @function [parent=#EventTouch] EventTouch -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/FadeIn.lua b/cocos/scripting/lua-bindings/auto/api/FadeIn.lua index f9875e7109..9b21453127 100644 --- a/cocos/scripting/lua-bindings/auto/api/FadeIn.lua +++ b/cocos/scripting/lua-bindings/auto/api/FadeIn.lua @@ -5,27 +5,32 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#FadeIn] setReverseAction -- @param self --- @param #cc.FadeTo fadeto +-- @param #cc.FadeTo ac -------------------------------- +-- creates the action -- @function [parent=#FadeIn] create -- @param self --- @param #float float +-- @param #float d -- @return FadeIn#FadeIn ret (return value: cc.FadeIn) -------------------------------- +-- -- @function [parent=#FadeIn] startWithTarget -- @param self --- @param #cc.Node node +-- @param #cc.Node target -------------------------------- +-- -- @function [parent=#FadeIn] clone -- @param self -- @return FadeIn#FadeIn ret (return value: cc.FadeIn) -------------------------------- +-- -- @function [parent=#FadeIn] reverse -- @param self -- @return FadeTo#FadeTo ret (return value: cc.FadeTo) diff --git a/cocos/scripting/lua-bindings/auto/api/FadeOut.lua b/cocos/scripting/lua-bindings/auto/api/FadeOut.lua index e49935eb6e..8d4ec375af 100644 --- a/cocos/scripting/lua-bindings/auto/api/FadeOut.lua +++ b/cocos/scripting/lua-bindings/auto/api/FadeOut.lua @@ -5,27 +5,32 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#FadeOut] setReverseAction -- @param self --- @param #cc.FadeTo fadeto +-- @param #cc.FadeTo ac -------------------------------- +-- creates the action -- @function [parent=#FadeOut] create -- @param self --- @param #float float +-- @param #float d -- @return FadeOut#FadeOut ret (return value: cc.FadeOut) -------------------------------- +-- -- @function [parent=#FadeOut] startWithTarget -- @param self --- @param #cc.Node node +-- @param #cc.Node target -------------------------------- +-- -- @function [parent=#FadeOut] clone -- @param self -- @return FadeOut#FadeOut ret (return value: cc.FadeOut) -------------------------------- +-- -- @function [parent=#FadeOut] reverse -- @param self -- @return FadeTo#FadeTo ret (return value: cc.FadeTo) diff --git a/cocos/scripting/lua-bindings/auto/api/FadeOutBLTiles.lua b/cocos/scripting/lua-bindings/auto/api/FadeOutBLTiles.lua index 6936709eaf..52afec3aa4 100644 --- a/cocos/scripting/lua-bindings/auto/api/FadeOutBLTiles.lua +++ b/cocos/scripting/lua-bindings/auto/api/FadeOutBLTiles.lua @@ -5,22 +5,25 @@ -- @parent_module cc -------------------------------- +-- creates the action with the grid size and the duration -- @function [parent=#FadeOutBLTiles] create -- @param self --- @param #float float --- @param #size_table size +-- @param #float duration +-- @param #size_table gridSize -- @return FadeOutBLTiles#FadeOutBLTiles ret (return value: cc.FadeOutBLTiles) -------------------------------- +-- -- @function [parent=#FadeOutBLTiles] clone -- @param self -- @return FadeOutBLTiles#FadeOutBLTiles ret (return value: cc.FadeOutBLTiles) -------------------------------- +-- -- @function [parent=#FadeOutBLTiles] testFunc -- @param self --- @param #size_table size --- @param #float float +-- @param #size_table pos +-- @param #float time -- @return float#float ret (return value: float) return nil diff --git a/cocos/scripting/lua-bindings/auto/api/FadeOutDownTiles.lua b/cocos/scripting/lua-bindings/auto/api/FadeOutDownTiles.lua index 0fdf8f3c1b..111e762731 100644 --- a/cocos/scripting/lua-bindings/auto/api/FadeOutDownTiles.lua +++ b/cocos/scripting/lua-bindings/auto/api/FadeOutDownTiles.lua @@ -5,22 +5,25 @@ -- @parent_module cc -------------------------------- +-- creates the action with the grid size and the duration -- @function [parent=#FadeOutDownTiles] create -- @param self --- @param #float float --- @param #size_table size +-- @param #float duration +-- @param #size_table gridSize -- @return FadeOutDownTiles#FadeOutDownTiles ret (return value: cc.FadeOutDownTiles) -------------------------------- +-- -- @function [parent=#FadeOutDownTiles] clone -- @param self -- @return FadeOutDownTiles#FadeOutDownTiles ret (return value: cc.FadeOutDownTiles) -------------------------------- +-- -- @function [parent=#FadeOutDownTiles] testFunc -- @param self --- @param #size_table size --- @param #float float +-- @param #size_table pos +-- @param #float time -- @return float#float ret (return value: float) return nil diff --git a/cocos/scripting/lua-bindings/auto/api/FadeOutTRTiles.lua b/cocos/scripting/lua-bindings/auto/api/FadeOutTRTiles.lua index 127a804281..6315647ab9 100644 --- a/cocos/scripting/lua-bindings/auto/api/FadeOutTRTiles.lua +++ b/cocos/scripting/lua-bindings/auto/api/FadeOutTRTiles.lua @@ -5,43 +5,50 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#FadeOutTRTiles] turnOnTile -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table pos -------------------------------- +-- -- @function [parent=#FadeOutTRTiles] turnOffTile -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table pos -------------------------------- +-- -- @function [parent=#FadeOutTRTiles] transformTile -- @param self --- @param #vec2_table vec2 --- @param #float float +-- @param #vec2_table pos +-- @param #float distance -------------------------------- +-- -- @function [parent=#FadeOutTRTiles] testFunc -- @param self --- @param #size_table size --- @param #float float +-- @param #size_table pos +-- @param #float time -- @return float#float ret (return value: float) -------------------------------- +-- creates the action with the grid size and the duration -- @function [parent=#FadeOutTRTiles] create -- @param self --- @param #float float --- @param #size_table size +-- @param #float duration +-- @param #size_table gridSize -- @return FadeOutTRTiles#FadeOutTRTiles ret (return value: cc.FadeOutTRTiles) -------------------------------- +-- -- @function [parent=#FadeOutTRTiles] clone -- @param self -- @return FadeOutTRTiles#FadeOutTRTiles ret (return value: cc.FadeOutTRTiles) -------------------------------- +-- -- @function [parent=#FadeOutTRTiles] update -- @param self --- @param #float float +-- @param #float time return nil diff --git a/cocos/scripting/lua-bindings/auto/api/FadeOutUpTiles.lua b/cocos/scripting/lua-bindings/auto/api/FadeOutUpTiles.lua index 22a5bae741..9d871f5f51 100644 --- a/cocos/scripting/lua-bindings/auto/api/FadeOutUpTiles.lua +++ b/cocos/scripting/lua-bindings/auto/api/FadeOutUpTiles.lua @@ -5,28 +5,32 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#FadeOutUpTiles] transformTile -- @param self --- @param #vec2_table vec2 --- @param #float float +-- @param #vec2_table pos +-- @param #float distance -------------------------------- +-- creates the action with the grid size and the duration -- @function [parent=#FadeOutUpTiles] create -- @param self --- @param #float float --- @param #size_table size +-- @param #float duration +-- @param #size_table gridSize -- @return FadeOutUpTiles#FadeOutUpTiles ret (return value: cc.FadeOutUpTiles) -------------------------------- +-- -- @function [parent=#FadeOutUpTiles] clone -- @param self -- @return FadeOutUpTiles#FadeOutUpTiles ret (return value: cc.FadeOutUpTiles) -------------------------------- +-- -- @function [parent=#FadeOutUpTiles] testFunc -- @param self --- @param #size_table size --- @param #float float +-- @param #size_table pos +-- @param #float time -- @return float#float ret (return value: float) return nil diff --git a/cocos/scripting/lua-bindings/auto/api/FadeTo.lua b/cocos/scripting/lua-bindings/auto/api/FadeTo.lua index 854e4047ba..81cf2e8fec 100644 --- a/cocos/scripting/lua-bindings/auto/api/FadeTo.lua +++ b/cocos/scripting/lua-bindings/auto/api/FadeTo.lua @@ -5,30 +5,35 @@ -- @parent_module cc -------------------------------- +-- creates an action with duration and opacity -- @function [parent=#FadeTo] create -- @param self --- @param #float float --- @param #unsigned char char +-- @param #float duration +-- @param #unsigned char opacity -- @return FadeTo#FadeTo ret (return value: cc.FadeTo) -------------------------------- +-- -- @function [parent=#FadeTo] startWithTarget -- @param self --- @param #cc.Node node +-- @param #cc.Node target -------------------------------- +-- -- @function [parent=#FadeTo] clone -- @param self -- @return FadeTo#FadeTo ret (return value: cc.FadeTo) -------------------------------- +-- -- @function [parent=#FadeTo] reverse -- @param self -- @return FadeTo#FadeTo ret (return value: cc.FadeTo) -------------------------------- +-- -- @function [parent=#FadeTo] update -- @param self --- @param #float float +-- @param #float time return nil diff --git a/cocos/scripting/lua-bindings/auto/api/FileUtils.lua b/cocos/scripting/lua-bindings/auto/api/FileUtils.lua index 465eafc67b..8f3aa1f787 100644 --- a/cocos/scripting/lua-bindings/auto/api/FileUtils.lua +++ b/cocos/scripting/lua-bindings/auto/api/FileUtils.lua @@ -4,166 +4,320 @@ -- @parent_module cc -------------------------------- +-- Returns the fullpath for a given filename.
+-- First it will try to get a new filename from the "filenameLookup" dictionary.
+-- If a new filename can't be found on the dictionary, it will use the original filename.
+-- Then it will try to obtain the full path of the filename using the FileUtils search rules: resolutions, and search paths.
+-- The file search is based on the array element order of search paths and resolution directories.
+-- For instance:
+-- We set two elements("/mnt/sdcard/", "internal_dir/") to search paths vector by setSearchPaths,
+-- and set three elements("resources-ipadhd/", "resources-ipad/", "resources-iphonehd")
+-- to resolutions vector by setSearchResolutionsOrder. The "internal_dir" is relative to "Resources/".
+-- If we have a file named 'sprite.png', the mapping in fileLookup dictionary contains `key: sprite.png -> value: sprite.pvr.gz`.
+-- Firstly, it will replace 'sprite.png' with 'sprite.pvr.gz', then searching the file sprite.pvr.gz as follows:
+-- /mnt/sdcard/resources-ipadhd/sprite.pvr.gz (if not found, search next)
+-- /mnt/sdcard/resources-ipad/sprite.pvr.gz (if not found, search next)
+-- /mnt/sdcard/resources-iphonehd/sprite.pvr.gz (if not found, search next)
+-- /mnt/sdcard/sprite.pvr.gz (if not found, search next)
+-- internal_dir/resources-ipadhd/sprite.pvr.gz (if not found, search next)
+-- internal_dir/resources-ipad/sprite.pvr.gz (if not found, search next)
+-- internal_dir/resources-iphonehd/sprite.pvr.gz (if not found, search next)
+-- internal_dir/sprite.pvr.gz (if not found, return "sprite.png")
+-- If the filename contains relative path like "gamescene/uilayer/sprite.png",
+-- and the mapping in fileLookup dictionary contains `key: gamescene/uilayer/sprite.png -> value: gamescene/uilayer/sprite.pvr.gz`.
+-- The file search order will be:
+-- /mnt/sdcard/gamescene/uilayer/resources-ipadhd/sprite.pvr.gz (if not found, search next)
+-- /mnt/sdcard/gamescene/uilayer/resources-ipad/sprite.pvr.gz (if not found, search next)
+-- /mnt/sdcard/gamescene/uilayer/resources-iphonehd/sprite.pvr.gz (if not found, search next)
+-- /mnt/sdcard/gamescene/uilayer/sprite.pvr.gz (if not found, search next)
+-- internal_dir/gamescene/uilayer/resources-ipadhd/sprite.pvr.gz (if not found, search next)
+-- internal_dir/gamescene/uilayer/resources-ipad/sprite.pvr.gz (if not found, search next)
+-- internal_dir/gamescene/uilayer/resources-iphonehd/sprite.pvr.gz (if not found, search next)
+-- internal_dir/gamescene/uilayer/sprite.pvr.gz (if not found, return "gamescene/uilayer/sprite.png")
+-- If the new file can't be found on the file system, it will return the parameter filename directly.
+-- This method was added to simplify multiplatform support. Whether you are using cocos2d-js or any cross-compilation toolchain like StellaSDK or Apportable,
+-- you might need to load different resources for a given file in the different platforms.
+-- since v2.1 -- @function [parent=#FileUtils] fullPathForFilename -- @param self --- @param #string str +-- @param #string filename -- @return string#string ret (return value: string) -------------------------------- +-- Gets string from a file. -- @function [parent=#FileUtils] getStringFromFile -- @param self --- @param #string str +-- @param #string filename -- @return string#string ret (return value: string) -------------------------------- +-- Sets the filenameLookup dictionary.
+-- param pFilenameLookupDict The dictionary for replacing filename.
+-- since v2.1 -- @function [parent=#FileUtils] setFilenameLookupDictionary -- @param self --- @param #map_table map +-- @param #map_table filenameLookupDict -------------------------------- +-- Remove a file
+-- param filepath The full path of the file, it must be an absolute path.
+-- return true if the file have been removed successfully, otherwise it will return false. -- @function [parent=#FileUtils] removeFile -- @param self --- @param #string str +-- @param #string filepath -- @return bool#bool ret (return value: bool) -------------------------------- +-- Checks whether the path is an absolute path.
+-- note On Android, if the parameter passed in is relative to "assets/", this method will treat it as an absolute path.
+-- Also on Blackberry, path starts with "app/native/Resources/" is treated as an absolute path.
+-- param strPath The path that needs to be checked.
+-- return true if it's an absolute path, otherwise it will return false. -- @function [parent=#FileUtils] isAbsolutePath -- @param self --- @param #string str +-- @param #string path -- @return bool#bool ret (return value: bool) -------------------------------- +-- Rename a file under the given directory
+-- param path The parent directory path of the file, it must be an absolute path.
+-- param oldname The current name of the file.
+-- param name The new name of the file.
+-- return true if the file have been renamed successfully, otherwise it will return false. -- @function [parent=#FileUtils] renameFile -- @param self --- @param #string str --- @param #string str --- @param #string str +-- @param #string path +-- @param #string oldname +-- @param #string name -- @return bool#bool ret (return value: bool) -------------------------------- +-- Loads the filenameLookup dictionary from the contents of a filename.
+-- note The plist file name should follow the format below:
+-- code
+--
+--
+--
+--
+-- filenames
+--
+-- sounds/click.wav
+-- sounds/click.caf
+-- sounds/endgame.wav
+-- sounds/endgame.caf
+-- sounds/gem-0.wav
+-- sounds/gem-0.caf
+--

+-- metadata
+--
+-- version
+-- 1
+--

+--

+--

+-- endcode
+-- param filename The plist file name.
+-- since v2.1
+-- js loadFilenameLookup
+-- lua loadFilenameLookup -- @function [parent=#FileUtils] loadFilenameLookupDictionaryFromFile -- @param self --- @param #string str +-- @param #string filename -------------------------------- +-- -- @function [parent=#FileUtils] isPopupNotify -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- Converts the contents of a file to a ValueVector.
+-- note This method is used internally. -- @function [parent=#FileUtils] getValueVectorFromFile -- @param self --- @param #string str +-- @param #string filename -- @return array_table#array_table ret (return value: array_table) -------------------------------- +-- Gets the array of search paths.
+-- return The array of search paths.
+-- see fullPathForFilename(const char*).
+-- lua NA -- @function [parent=#FileUtils] getSearchPaths -- @param self -- @return array_table#array_table ret (return value: array_table) -------------------------------- +-- Write a ValueMap to a plist file.
+-- note This method is used internally. -- @function [parent=#FileUtils] writeToFile -- @param self --- @param #map_table map --- @param #string str +-- @param #map_table dict +-- @param #string fullPath -- @return bool#bool ret (return value: bool) -------------------------------- +-- Converts the contents of a file to a ValueMap.
+-- note This method is used internally. -- @function [parent=#FileUtils] getValueMapFromFile -- @param self --- @param #string str +-- @param #string filename -- @return map_table#map_table ret (return value: map_table) -------------------------------- +-- Converts the contents of a file to a ValueMap.
+-- note This method is used internally. -- @function [parent=#FileUtils] getValueMapFromData -- @param self --- @param #char char --- @param #int int +-- @param #char filedata +-- @param #int filesize -- @return map_table#map_table ret (return value: map_table) -------------------------------- +-- Remove a directory
+-- param dirPath The full path of the directory, it must be an absolute path.
+-- return true if the directory have been removed successfully, otherwise it will return false. -- @function [parent=#FileUtils] removeDirectory -- @param self --- @param #string str +-- @param #string dirPath -- @return bool#bool ret (return value: bool) -------------------------------- +-- Sets the array of search paths.
+-- You can use this array to modify the search path of the resources.
+-- If you want to use "themes" or search resources in the "cache", you can do it easily by adding new entries in this array.
+-- note This method could access relative path and absolute path.
+-- If the relative path was passed to the vector, FileUtils will add the default resource directory before the relative path.
+-- For instance:
+-- On Android, the default resource root path is "assets/".
+-- If "/mnt/sdcard/" and "resources-large" were set to the search paths vector,
+-- "resources-large" will be converted to "assets/resources-large" since it was a relative path.
+-- param searchPaths The array contains search paths.
+-- see fullPathForFilename(const char*)
+-- since v2.1
+-- In js:var setSearchPaths(var jsval);
+-- lua NA -- @function [parent=#FileUtils] setSearchPaths -- @param self --- @param #array_table array +-- @param #array_table searchPaths -------------------------------- +-- Retrieve the file size
+-- note If a relative path was passed in, it will be inserted a default root path at the beginning.
+-- param filepath The path of the file, it could be a relative or absolute path.
+-- return The file size. -- @function [parent=#FileUtils] getFileSize -- @param self --- @param #string str +-- @param #string filepath -- @return long#long ret (return value: long) -------------------------------- +-- Sets the array that contains the search order of the resources.
+-- param searchResolutionsOrder The source array that contains the search order of the resources.
+-- see getSearchResolutionsOrder(void), fullPathForFilename(const char*).
+-- since v2.1
+-- In js:var setSearchResolutionsOrder(var jsval)
+-- lua NA -- @function [parent=#FileUtils] setSearchResolutionsOrder -- @param self --- @param #array_table array +-- @param #array_table searchResolutionsOrder -------------------------------- +-- Append search order of the resources.
+-- see setSearchResolutionsOrder(), fullPathForFilename().
+-- since v2.1 -- @function [parent=#FileUtils] addSearchResolutionsOrder -- @param self --- @param #string str --- @param #bool bool +-- @param #string order +-- @param #bool front -------------------------------- +-- Add search path.
+-- since v2.1 -- @function [parent=#FileUtils] addSearchPath -- @param self --- @param #string str --- @param #bool bool +-- @param #string path +-- @param #bool front -------------------------------- +-- Checks whether a file exists.
+-- note If a relative path was passed in, it will be inserted a default root path at the beginning.
+-- param strFilePath The path of the file, it could be a relative or absolute path.
+-- return true if the file exists, otherwise it will return false. -- @function [parent=#FileUtils] isFileExist -- @param self --- @param #string str +-- @param #string filename -- @return bool#bool ret (return value: bool) -------------------------------- +-- Purges the file searching cache.
+-- note It should be invoked after the resources were updated.
+-- For instance, in the CocosPlayer sample, every time you run application from CocosBuilder,
+-- All the resources will be downloaded to the writable folder, before new js app launchs,
+-- this method should be invoked to clean the file search cache. -- @function [parent=#FileUtils] purgeCachedEntries -- @param self -------------------------------- +-- Gets full path from a file name and the path of the reletive file.
+-- param filename The file name.
+-- param pszRelativeFile The path of the relative file.
+-- return The full path.
+-- e.g. filename: hello.png, pszRelativeFile: /User/path1/path2/hello.plist
+-- Return: /User/path1/path2/hello.pvr (If there a a key(hello.png)-value(hello.pvr) in FilenameLookup dictionary. ) -- @function [parent=#FileUtils] fullPathFromRelativeFile -- @param self --- @param #string str --- @param #string str +-- @param #string filename +-- @param #string relativeFile -- @return string#string ret (return value: string) -------------------------------- +-- Sets/Gets whether to pop-up a message box when failed to load an image. -- @function [parent=#FileUtils] setPopupNotify -- @param self --- @param #bool bool +-- @param #bool notify -------------------------------- +-- Checks whether the path is a directory
+-- param dirPath The path of the directory, it could be a relative or an absolute path.
+-- return true if the directory exists, otherwise it will return false. -- @function [parent=#FileUtils] isDirectoryExist -- @param self --- @param #string str +-- @param #string dirPath -- @return bool#bool ret (return value: bool) -------------------------------- +-- Gets the array that contains the search order of the resources.
+-- see setSearchResolutionsOrder(const std::vector&), fullPathForFilename(const char*).
+-- since v2.1
+-- lua NA -- @function [parent=#FileUtils] getSearchResolutionsOrder -- @param self -- @return array_table#array_table ret (return value: array_table) -------------------------------- +-- Creates a directory
+-- param dirPath The path of the directory, it must be an absolute path.
+-- return true if the directory have been created successfully, otherwise it will return false. -- @function [parent=#FileUtils] createDirectory -- @param self --- @param #string str +-- @param #string dirPath -- @return bool#bool ret (return value: bool) -------------------------------- +-- Gets the writable path.
+-- return The path that can be write/read a file in -- @function [parent=#FileUtils] getWritablePath -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- Destroys the instance of FileUtils. -- @function [parent=#FileUtils] destroyInstance -- @param self -------------------------------- +-- Gets the instance of FileUtils. -- @function [parent=#FileUtils] getInstance -- @param self -- @return FileUtils#FileUtils ret (return value: cc.FileUtils) diff --git a/cocos/scripting/lua-bindings/auto/api/FiniteTimeAction.lua b/cocos/scripting/lua-bindings/auto/api/FiniteTimeAction.lua index a89deabc3f..c14f9aba2e 100644 --- a/cocos/scripting/lua-bindings/auto/api/FiniteTimeAction.lua +++ b/cocos/scripting/lua-bindings/auto/api/FiniteTimeAction.lua @@ -5,21 +5,25 @@ -- @parent_module cc -------------------------------- +-- set duration in seconds of the action -- @function [parent=#FiniteTimeAction] setDuration -- @param self --- @param #float float +-- @param #float duration -------------------------------- +-- get duration in seconds of the action -- @function [parent=#FiniteTimeAction] getDuration -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#FiniteTimeAction] clone -- @param self -- @return FiniteTimeAction#FiniteTimeAction ret (return value: cc.FiniteTimeAction) -------------------------------- +-- -- @function [parent=#FiniteTimeAction] reverse -- @param self -- @return FiniteTimeAction#FiniteTimeAction ret (return value: cc.FiniteTimeAction) diff --git a/cocos/scripting/lua-bindings/auto/api/FlipX.lua b/cocos/scripting/lua-bindings/auto/api/FlipX.lua index ab9ca2096d..530a3978cb 100644 --- a/cocos/scripting/lua-bindings/auto/api/FlipX.lua +++ b/cocos/scripting/lua-bindings/auto/api/FlipX.lua @@ -5,22 +5,26 @@ -- @parent_module cc -------------------------------- +-- create the action -- @function [parent=#FlipX] create -- @param self --- @param #bool bool +-- @param #bool x -- @return FlipX#FlipX ret (return value: cc.FlipX) -------------------------------- +-- -- @function [parent=#FlipX] clone -- @param self -- @return FlipX#FlipX ret (return value: cc.FlipX) -------------------------------- +-- -- @function [parent=#FlipX] update -- @param self --- @param #float float +-- @param #float time -------------------------------- +-- -- @function [parent=#FlipX] reverse -- @param self -- @return FlipX#FlipX ret (return value: cc.FlipX) diff --git a/cocos/scripting/lua-bindings/auto/api/FlipX3D.lua b/cocos/scripting/lua-bindings/auto/api/FlipX3D.lua index 4823e905f5..b948ef4880 100644 --- a/cocos/scripting/lua-bindings/auto/api/FlipX3D.lua +++ b/cocos/scripting/lua-bindings/auto/api/FlipX3D.lua @@ -5,19 +5,22 @@ -- @parent_module cc -------------------------------- +-- creates the action with duration -- @function [parent=#FlipX3D] create -- @param self --- @param #float float +-- @param #float duration -- @return FlipX3D#FlipX3D ret (return value: cc.FlipX3D) -------------------------------- +-- -- @function [parent=#FlipX3D] clone -- @param self -- @return FlipX3D#FlipX3D ret (return value: cc.FlipX3D) -------------------------------- +-- -- @function [parent=#FlipX3D] update -- @param self --- @param #float float +-- @param #float time return nil diff --git a/cocos/scripting/lua-bindings/auto/api/FlipY.lua b/cocos/scripting/lua-bindings/auto/api/FlipY.lua index bb8be4aa66..f0d76b4a1e 100644 --- a/cocos/scripting/lua-bindings/auto/api/FlipY.lua +++ b/cocos/scripting/lua-bindings/auto/api/FlipY.lua @@ -5,22 +5,26 @@ -- @parent_module cc -------------------------------- +-- create the action -- @function [parent=#FlipY] create -- @param self --- @param #bool bool +-- @param #bool y -- @return FlipY#FlipY ret (return value: cc.FlipY) -------------------------------- +-- -- @function [parent=#FlipY] clone -- @param self -- @return FlipY#FlipY ret (return value: cc.FlipY) -------------------------------- +-- -- @function [parent=#FlipY] update -- @param self --- @param #float float +-- @param #float time -------------------------------- +-- -- @function [parent=#FlipY] reverse -- @param self -- @return FlipY#FlipY ret (return value: cc.FlipY) diff --git a/cocos/scripting/lua-bindings/auto/api/FlipY3D.lua b/cocos/scripting/lua-bindings/auto/api/FlipY3D.lua index dda47890cb..47b8104226 100644 --- a/cocos/scripting/lua-bindings/auto/api/FlipY3D.lua +++ b/cocos/scripting/lua-bindings/auto/api/FlipY3D.lua @@ -5,19 +5,22 @@ -- @parent_module cc -------------------------------- +-- creates the action with duration -- @function [parent=#FlipY3D] create -- @param self --- @param #float float +-- @param #float duration -- @return FlipY3D#FlipY3D ret (return value: cc.FlipY3D) -------------------------------- +-- -- @function [parent=#FlipY3D] clone -- @param self -- @return FlipY3D#FlipY3D ret (return value: cc.FlipY3D) -------------------------------- +-- -- @function [parent=#FlipY3D] update -- @param self --- @param #float float +-- @param #float time return nil diff --git a/cocos/scripting/lua-bindings/auto/api/Follow.lua b/cocos/scripting/lua-bindings/auto/api/Follow.lua index ebc67f26dc..c4cc29986b 100644 --- a/cocos/scripting/lua-bindings/auto/api/Follow.lua +++ b/cocos/scripting/lua-bindings/auto/api/Follow.lua @@ -5,42 +5,53 @@ -- @parent_module cc -------------------------------- +-- alter behavior - turn on/off boundary -- @function [parent=#Follow] setBoudarySet -- @param self --- @param #bool bool +-- @param #bool value -------------------------------- +-- -- @function [parent=#Follow] isBoundarySet -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- Creates the action with a set boundary or with no boundary.
+-- param followedNode The node to be followed.
+-- param rect The boundary. If \p rect is equal to Rect::ZERO, it'll work
+-- with no boundary. -- @function [parent=#Follow] create -- @param self --- @param #cc.Node node +-- @param #cc.Node followedNode -- @param #rect_table rect -- @return Follow#Follow ret (return value: cc.Follow) -------------------------------- +-- -- @function [parent=#Follow] step -- @param self --- @param #float float +-- @param #float dt -------------------------------- +-- -- @function [parent=#Follow] clone -- @param self -- @return Follow#Follow ret (return value: cc.Follow) -------------------------------- +-- -- @function [parent=#Follow] stop -- @param self -------------------------------- +-- -- @function [parent=#Follow] reverse -- @param self -- @return Follow#Follow ret (return value: cc.Follow) -------------------------------- +-- -- @function [parent=#Follow] isDone -- @param self -- @return bool#bool ret (return value: bool) diff --git a/cocos/scripting/lua-bindings/auto/api/Frame.lua b/cocos/scripting/lua-bindings/auto/api/Frame.lua index e339312138..a2f7cb095d 100644 --- a/cocos/scripting/lua-bindings/auto/api/Frame.lua +++ b/cocos/scripting/lua-bindings/auto/api/Frame.lua @@ -5,51 +5,61 @@ -- @parent_module ccs -------------------------------- +-- -- @function [parent=#Frame] clone -- @param self -- @return Frame#Frame ret (return value: ccs.Frame) -------------------------------- +-- -- @function [parent=#Frame] setNode -- @param self -- @param #cc.Node node -------------------------------- +-- -- @function [parent=#Frame] setTimeline -- @param self -- @param #ccs.Timeline timeline -------------------------------- +-- -- @function [parent=#Frame] getFrameIndex -- @param self -- @return unsigned int#unsigned int ret (return value: unsigned int) -------------------------------- +-- -- @function [parent=#Frame] apply -- @param self --- @param #float float +-- @param #float percent -------------------------------- +-- -- @function [parent=#Frame] isTween -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#Frame] setFrameIndex -- @param self --- @param #unsigned int int +-- @param #unsigned int frameIndex -------------------------------- +-- -- @function [parent=#Frame] setTween -- @param self --- @param #bool bool +-- @param #bool tween -------------------------------- +-- -- @function [parent=#Frame] getTimeline -- @param self -- @return Timeline#Timeline ret (return value: ccs.Timeline) -------------------------------- +-- -- @function [parent=#Frame] getNode -- @param self -- @return Node#Node ret (return value: cc.Node) diff --git a/cocos/scripting/lua-bindings/auto/api/FrameData.lua b/cocos/scripting/lua-bindings/auto/api/FrameData.lua index 038aa1923b..3bc8f4334f 100644 --- a/cocos/scripting/lua-bindings/auto/api/FrameData.lua +++ b/cocos/scripting/lua-bindings/auto/api/FrameData.lua @@ -5,16 +5,19 @@ -- @parent_module ccs -------------------------------- +-- -- @function [parent=#FrameData] copy -- @param self --- @param #ccs.BaseData basedata +-- @param #ccs.BaseData baseData -------------------------------- +-- -- @function [parent=#FrameData] create -- @param self -- @return FrameData#FrameData ret (return value: ccs.FrameData) -------------------------------- +-- js ctor -- @function [parent=#FrameData] FrameData -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/GLProgram.lua b/cocos/scripting/lua-bindings/auto/api/GLProgram.lua index 21a267ccf7..125f68811d 100644 --- a/cocos/scripting/lua-bindings/auto/api/GLProgram.lua +++ b/cocos/scripting/lua-bindings/auto/api/GLProgram.lua @@ -5,29 +5,34 @@ -- @parent_module cc -------------------------------- +-- returns the fragmentShader error log -- @function [parent=#GLProgram] getFragmentShaderLog -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- -- @function [parent=#GLProgram] initWithByteArrays -- @param self --- @param #char char --- @param #char char +-- @param #char vShaderByteArray +-- @param #char fShaderByteArray -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#GLProgram] initWithFilenames -- @param self --- @param #string str --- @param #string str +-- @param #string vShaderFilename +-- @param #string fShaderFilename -- @return bool#bool ret (return value: bool) -------------------------------- +-- it will call glUseProgram() -- @function [parent=#GLProgram] use -- @param self -------------------------------- +-- returns the vertexShader error log -- @function [parent=#GLProgram] getVertexShaderLog -- @param self -- @return string#string ret (return value: string) @@ -37,54 +42,74 @@ -- @overload self -- @function [parent=#GLProgram] setUniformsForBuiltins -- @param self --- @param #mat4_table mat4 +-- @param #mat4_table modelView -------------------------------- +-- It will create 4 uniforms:
+-- - kUniformPMatrix
+-- - kUniformMVMatrix
+-- - kUniformMVPMatrix
+-- - GLProgram::UNIFORM_SAMPLER
+-- And it will bind "GLProgram::UNIFORM_SAMPLER" to 0 -- @function [parent=#GLProgram] updateUniforms -- @param self -------------------------------- +-- calls glUniform1i only if the values are different than the previous call for this same shader program.
+-- js setUniformLocationI32
+-- lua setUniformLocationI32 -- @function [parent=#GLProgram] setUniformLocationWith1i -- @param self --- @param #int int --- @param #int int +-- @param #int location +-- @param #int i1 -------------------------------- +-- -- @function [parent=#GLProgram] reset -- @param self -------------------------------- +-- It will add a new attribute to the shader by calling glBindAttribLocation -- @function [parent=#GLProgram] bindAttribLocation -- @param self --- @param #string str --- @param #unsigned int int +-- @param #string attributeName +-- @param #unsigned int index -------------------------------- +-- calls glGetAttribLocation -- @function [parent=#GLProgram] getAttribLocation -- @param self --- @param #string str +-- @param #string attributeName -- @return int#int ret (return value: int) -------------------------------- +-- links the glProgram -- @function [parent=#GLProgram] link -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- Initializes the GLProgram with a vertex and fragment with bytes array
+-- js initWithString
+-- lua initWithString -- @function [parent=#GLProgram] createWithByteArrays -- @param self --- @param #char char --- @param #char char +-- @param #char vShaderByteArray +-- @param #char fShaderByteArray -- @return GLProgram#GLProgram ret (return value: cc.GLProgram) -------------------------------- +-- Initializes the GLProgram with a vertex and fragment with contents of filenames
+-- js init
+-- lua init -- @function [parent=#GLProgram] createWithFilenames -- @param self --- @param #string str --- @param #string str +-- @param #string vShaderFilename +-- @param #string fShaderFilename -- @return GLProgram#GLProgram ret (return value: cc.GLProgram) -------------------------------- +-- -- @function [parent=#GLProgram] GLProgram -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/GLProgramCache.lua b/cocos/scripting/lua-bindings/auto/api/GLProgramCache.lua index a7ddd24ba7..405063fd94 100644 --- a/cocos/scripting/lua-bindings/auto/api/GLProgramCache.lua +++ b/cocos/scripting/lua-bindings/auto/api/GLProgramCache.lua @@ -5,35 +5,42 @@ -- @parent_module cc -------------------------------- +-- adds a GLProgram to the cache for a given name -- @function [parent=#GLProgramCache] addGLProgram -- @param self --- @param #cc.GLProgram glprogram --- @param #string str +-- @param #cc.GLProgram program +-- @param #string key -------------------------------- +-- returns a GL program for a given key -- @function [parent=#GLProgramCache] getGLProgram -- @param self --- @param #string str +-- @param #string key -- @return GLProgram#GLProgram ret (return value: cc.GLProgram) -------------------------------- +-- reload the default shaders -- @function [parent=#GLProgramCache] reloadDefaultGLPrograms -- @param self -------------------------------- +-- loads the default shaders -- @function [parent=#GLProgramCache] loadDefaultGLPrograms -- @param self -------------------------------- +-- purges the cache. It releases the retained instance. -- @function [parent=#GLProgramCache] destroyInstance -- @param self -------------------------------- +-- returns the shared instance -- @function [parent=#GLProgramCache] getInstance -- @param self -- @return GLProgramCache#GLProgramCache ret (return value: cc.GLProgramCache) -------------------------------- +-- js ctor -- @function [parent=#GLProgramCache] GLProgramCache -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/GLProgramState.lua b/cocos/scripting/lua-bindings/auto/api/GLProgramState.lua index 45e1e90168..0cd5f93193 100644 --- a/cocos/scripting/lua-bindings/auto/api/GLProgramState.lua +++ b/cocos/scripting/lua-bindings/auto/api/GLProgramState.lua @@ -11,32 +11,37 @@ -- @overload self, int, unsigned int -- @function [parent=#GLProgramState] setUniformTexture -- @param self --- @param #int int --- @param #unsigned int int +-- @param #int uniformLocation +-- @param #unsigned int textureId -------------------------------- -- @overload self, int, mat4_table -- @overload self, string, mat4_table -- @function [parent=#GLProgramState] setUniformMat4 -- @param self --- @param #string str --- @param #mat4_table mat4 +-- @param #string uniformName +-- @param #mat4_table value -------------------------------- +-- -- @function [parent=#GLProgramState] applyUniforms -- @param self -------------------------------- +-- -- @function [parent=#GLProgramState] applyGLProgram -- @param self --- @param #mat4_table mat4 +-- @param #mat4_table modelView -------------------------------- +-- -- @function [parent=#GLProgramState] getUniformCount -- @param self -- @return long#long ret (return value: long) -------------------------------- +-- apply vertex attributes
+-- param applyAttribFlags Call GL::enableVertexAttribs(_vertexAttribsFlags) or not -- @function [parent=#GLProgramState] applyAttributes -- @param self @@ -45,26 +50,27 @@ -- @overload self, string, float -- @function [parent=#GLProgramState] setUniformFloat -- @param self --- @param #string str --- @param #float float +-- @param #string uniformName +-- @param #float value -------------------------------- -- @overload self, int, vec3_table -- @overload self, string, vec3_table -- @function [parent=#GLProgramState] setUniformVec3 -- @param self --- @param #string str --- @param #vec3_table vec3 +-- @param #string uniformName +-- @param #vec3_table value -------------------------------- -- @overload self, int, int -- @overload self, string, int -- @function [parent=#GLProgramState] setUniformInt -- @param self --- @param #string str --- @param #int int +-- @param #string uniformName +-- @param #int value -------------------------------- +-- -- @function [parent=#GLProgramState] getVertexAttribCount -- @param self -- @return long#long ret (return value: long) @@ -74,10 +80,11 @@ -- @overload self, string, vec4_table -- @function [parent=#GLProgramState] setUniformVec4 -- @param self --- @param #string str --- @param #vec4_table vec4 +-- @param #string uniformName +-- @param #vec4_table value -------------------------------- +-- -- @function [parent=#GLProgramState] setGLProgram -- @param self -- @param #cc.GLProgram glprogram @@ -87,37 +94,43 @@ -- @overload self, string, vec2_table -- @function [parent=#GLProgramState] setUniformVec2 -- @param self --- @param #string str --- @param #vec2_table vec2 +-- @param #string uniformName +-- @param #vec2_table value -------------------------------- +-- -- @function [parent=#GLProgramState] getVertexAttribsFlags -- @param self -- @return unsigned int#unsigned int ret (return value: unsigned int) -------------------------------- +-- -- @function [parent=#GLProgramState] apply -- @param self --- @param #mat4_table mat4 +-- @param #mat4_table modelView -------------------------------- +-- -- @function [parent=#GLProgramState] getGLProgram -- @param self -- @return GLProgram#GLProgram ret (return value: cc.GLProgram) -------------------------------- +-- returns a new instance of GLProgramState for a given GLProgram -- @function [parent=#GLProgramState] create -- @param self -- @param #cc.GLProgram glprogram -- @return GLProgramState#GLProgramState ret (return value: cc.GLProgramState) -------------------------------- +-- gets-or-creates an instance of GLProgramState for a given GLProgramName -- @function [parent=#GLProgramState] getOrCreateWithGLProgramName -- @param self --- @param #string str +-- @param #string glProgramName -- @return GLProgramState#GLProgramState ret (return value: cc.GLProgramState) -------------------------------- +-- gets-or-creates an instance of GLProgramState for a given GLProgram -- @function [parent=#GLProgramState] getOrCreateWithGLProgram -- @param self -- @param #cc.GLProgram glprogram diff --git a/cocos/scripting/lua-bindings/auto/api/GLView.lua b/cocos/scripting/lua-bindings/auto/api/GLView.lua index fd42bfe851..85456927f0 100644 --- a/cocos/scripting/lua-bindings/auto/api/GLView.lua +++ b/cocos/scripting/lua-bindings/auto/api/GLView.lua @@ -5,163 +5,203 @@ -- @parent_module cc -------------------------------- +-- Set the frame size of EGL view. -- @function [parent=#GLView] setFrameSize -- @param self --- @param #float float --- @param #float float +-- @param #float width +-- @param #float height -------------------------------- +-- Get the opengl view port rectangle. -- @function [parent=#GLView] getViewPortRect -- @param self -- @return rect_table#rect_table ret (return value: rect_table) -------------------------------- +-- only works on ios platform -- @function [parent=#GLView] setContentScaleFactor -- @param self --- @param #float float +-- @param #float scaleFactor -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#GLView] getContentScaleFactor -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- Open or close IME keyboard , subclass must implement this method. -- @function [parent=#GLView] setIMEKeyboardState -- @param self --- @param #bool bool +-- @param #bool open -------------------------------- +-- Set Scissor rectangle with points. -- @function [parent=#GLView] setScissorInPoints -- @param self --- @param #float float --- @param #float float --- @param #float float --- @param #float float +-- @param #float x +-- @param #float y +-- @param #float w +-- @param #float h -------------------------------- +-- -- @function [parent=#GLView] getViewName -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- Get whether opengl render system is ready, subclass must implement this method. -- @function [parent=#GLView] isOpenGLReady -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- Force destroying EGL view, subclass must implement this method. -- @function [parent=#GLView] end -- @param self -------------------------------- +-- Get scale factor of the vertical direction. -- @function [parent=#GLView] getScaleY -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- Get scale factor of the horizontal direction. -- @function [parent=#GLView] getScaleX -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- Get the visible origin point of opengl viewport. -- @function [parent=#GLView] getVisibleOrigin -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- Get the frame size of EGL view.
+-- In general, it returns the screen size since the EGL view is a fullscreen view. -- @function [parent=#GLView] getFrameSize -- @param self -- @return size_table#size_table ret (return value: size_table) -------------------------------- +-- Set and get zoom factor for frame. This two methods are for
+-- debugging big resolution (e.g.new ipad) app on desktop. -- @function [parent=#GLView] setFrameZoomFactor -- @param self --- @param #float float +-- @param #float zoomFactor -------------------------------- +-- -- @function [parent=#GLView] getFrameZoomFactor -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- Get design resolution size.
+-- Default resolution size is the same as 'getFrameSize'. -- @function [parent=#GLView] getDesignResolutionSize -- @param self -- @return size_table#size_table ret (return value: size_table) -------------------------------- +-- -- @function [parent=#GLView] windowShouldClose -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- Exchanges the front and back buffers, subclass must implement this method. -- @function [parent=#GLView] swapBuffers -- @param self -------------------------------- +-- Set the design resolution size.
+-- param width Design resolution width.
+-- param height Design resolution height.
+-- param resolutionPolicy The resolution policy desired, you may choose:
+-- [1] EXACT_FIT Fill screen by stretch-to-fit: if the design resolution ratio of width to height is different from the screen resolution ratio, your game view will be stretched.
+-- [2] NO_BORDER Full screen without black border: if the design resolution ratio of width to height is different from the screen resolution ratio, two areas of your game view will be cut.
+-- [3] SHOW_ALL Full screen with black border: if the design resolution ratio of width to height is different from the screen resolution ratio, two black borders will be shown. -- @function [parent=#GLView] setDesignResolutionSize -- @param self --- @param #float float --- @param #float float --- @param #int resolutionpolicy +-- @param #float width +-- @param #float height +-- @param #int resolutionPolicy -------------------------------- +-- returns the current Resolution policy -- @function [parent=#GLView] getResolutionPolicy -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- returns whether or not the view is in Retina Display mode -- @function [parent=#GLView] isRetinaDisplay -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- Set opengl view port rectangle with points. -- @function [parent=#GLView] setViewPortInPoints -- @param self --- @param #float float --- @param #float float --- @param #float float --- @param #float float +-- @param #float x +-- @param #float y +-- @param #float w +-- @param #float h -------------------------------- +-- Get the current scissor rectangle -- @function [parent=#GLView] getScissorRect -- @param self -- @return rect_table#rect_table ret (return value: rect_table) -------------------------------- +-- Get retina factor -- @function [parent=#GLView] getRetinaFactor -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- -- @function [parent=#GLView] setViewName -- @param self --- @param #string str +-- @param #string viewname -------------------------------- +-- Get the visible rectangle of opengl viewport. -- @function [parent=#GLView] getVisibleRect -- @param self -- @return rect_table#rect_table ret (return value: rect_table) -------------------------------- +-- Get the visible area size of opengl viewport. -- @function [parent=#GLView] getVisibleSize -- @param self -- @return size_table#size_table ret (return value: size_table) -------------------------------- +-- Get whether GL_SCISSOR_TEST is enable -- @function [parent=#GLView] isScissorEnabled -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#GLView] pollEvents -- @param self -------------------------------- +-- -- @function [parent=#GLView] setGLContextAttrs -- @param self --- @param #GLContextAttrs glcontextattrs +-- @param #GLContextAttrs glContextAttrs -------------------------------- +-- -- @function [parent=#GLView] getGLContextAttrs -- @param self -- @return GLContextAttrs#GLContextAttrs ret (return value: GLContextAttrs) diff --git a/cocos/scripting/lua-bindings/auto/api/GLViewImpl.lua b/cocos/scripting/lua-bindings/auto/api/GLViewImpl.lua index 37b80b7f7e..433292ff64 100644 --- a/cocos/scripting/lua-bindings/auto/api/GLViewImpl.lua +++ b/cocos/scripting/lua-bindings/auto/api/GLViewImpl.lua @@ -5,31 +5,36 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#GLViewImpl] createWithRect -- @param self --- @param #string str +-- @param #string viewName -- @param #rect_table rect --- @param #float float +-- @param #float frameZoomFactor -- @return GLViewImpl#GLViewImpl ret (return value: cc.GLViewImpl) -------------------------------- +-- -- @function [parent=#GLViewImpl] create -- @param self --- @param #string str +-- @param #string viewname -- @return GLViewImpl#GLViewImpl ret (return value: cc.GLViewImpl) -------------------------------- +-- -- @function [parent=#GLViewImpl] createWithFullScreen -- @param self --- @param #string str +-- @param #string viewName -- @return GLViewImpl#GLViewImpl ret (return value: cc.GLViewImpl) -------------------------------- +-- -- @function [parent=#GLViewImpl] setIMEKeyboardState -- @param self --- @param #bool bool +-- @param #bool bOpen -------------------------------- +-- -- @function [parent=#GLViewImpl] isOpenGLReady -- @param self -- @return bool#bool ret (return value: bool) diff --git a/cocos/scripting/lua-bindings/auto/api/GUIReader.lua b/cocos/scripting/lua-bindings/auto/api/GUIReader.lua index b32f8d0270..cd73bb0fce 100644 --- a/cocos/scripting/lua-bindings/auto/api/GUIReader.lua +++ b/cocos/scripting/lua-bindings/auto/api/GUIReader.lua @@ -5,38 +5,45 @@ -- @parent_module ccs -------------------------------- +-- -- @function [parent=#GUIReader] setFilePath -- @param self --- @param #string str +-- @param #string strFilePath -------------------------------- +-- -- @function [parent=#GUIReader] widgetFromJsonFile -- @param self --- @param #char char +-- @param #char fileName -- @return Widget#Widget ret (return value: ccui.Widget) -------------------------------- +-- -- @function [parent=#GUIReader] getFilePath -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- -- @function [parent=#GUIReader] widgetFromBinaryFile -- @param self --- @param #char char +-- @param #char fileName -- @return Widget#Widget ret (return value: ccui.Widget) -------------------------------- +-- -- @function [parent=#GUIReader] getVersionInteger -- @param self --- @param #char char +-- @param #char str -- @return int#int ret (return value: int) -------------------------------- +-- -- @function [parent=#GUIReader] destroyInstance -- @param self -------------------------------- +-- -- @function [parent=#GUIReader] getInstance -- @param self -- @return GUIReader#GUIReader ret (return value: ccs.GUIReader) diff --git a/cocos/scripting/lua-bindings/auto/api/Grid3D.lua b/cocos/scripting/lua-bindings/auto/api/Grid3D.lua index 8adbad9174..b20675bf6f 100644 --- a/cocos/scripting/lua-bindings/auto/api/Grid3D.lua +++ b/cocos/scripting/lua-bindings/auto/api/Grid3D.lua @@ -9,24 +9,28 @@ -- @overload self, size_table, cc.Texture2D, bool -- @function [parent=#Grid3D] create -- @param self --- @param #size_table size --- @param #cc.Texture2D texture2d --- @param #bool bool +-- @param #size_table gridSize +-- @param #cc.Texture2D texture +-- @param #bool flipped -- @return Grid3D#Grid3D ret (retunr value: cc.Grid3D) -------------------------------- +-- -- @function [parent=#Grid3D] calculateVertexPoints -- @param self -------------------------------- +-- -- @function [parent=#Grid3D] blit -- @param self -------------------------------- +-- -- @function [parent=#Grid3D] reuse -- @param self -------------------------------- +-- js ctor -- @function [parent=#Grid3D] Grid3D -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/Grid3DAction.lua b/cocos/scripting/lua-bindings/auto/api/Grid3DAction.lua index 5863941c70..d4dec67c66 100644 --- a/cocos/scripting/lua-bindings/auto/api/Grid3DAction.lua +++ b/cocos/scripting/lua-bindings/auto/api/Grid3DAction.lua @@ -5,11 +5,13 @@ -- @parent_module cc -------------------------------- +-- returns the grid -- @function [parent=#Grid3DAction] getGrid -- @param self -- @return GridBase#GridBase ret (return value: cc.GridBase) -------------------------------- +-- -- @function [parent=#Grid3DAction] clone -- @param self -- @return Grid3DAction#Grid3DAction ret (return value: cc.Grid3DAction) diff --git a/cocos/scripting/lua-bindings/auto/api/GridAction.lua b/cocos/scripting/lua-bindings/auto/api/GridAction.lua index 4f6abb4c43..b9d8e572bc 100644 --- a/cocos/scripting/lua-bindings/auto/api/GridAction.lua +++ b/cocos/scripting/lua-bindings/auto/api/GridAction.lua @@ -5,21 +5,25 @@ -- @parent_module cc -------------------------------- +-- returns the grid -- @function [parent=#GridAction] getGrid -- @param self -- @return GridBase#GridBase ret (return value: cc.GridBase) -------------------------------- +-- -- @function [parent=#GridAction] startWithTarget -- @param self --- @param #cc.Node node +-- @param #cc.Node target -------------------------------- +-- -- @function [parent=#GridAction] clone -- @param self -- @return GridAction#GridAction ret (return value: cc.GridAction) -------------------------------- +-- -- @function [parent=#GridAction] reverse -- @param self -- @return GridAction#GridAction ret (return value: cc.GridAction) diff --git a/cocos/scripting/lua-bindings/auto/api/GridBase.lua b/cocos/scripting/lua-bindings/auto/api/GridBase.lua index e42656495f..bfea6b3f12 100644 --- a/cocos/scripting/lua-bindings/auto/api/GridBase.lua +++ b/cocos/scripting/lua-bindings/auto/api/GridBase.lua @@ -5,62 +5,75 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#GridBase] setGridSize -- @param self --- @param #size_table size +-- @param #size_table gridSize -------------------------------- +-- -- @function [parent=#GridBase] calculateVertexPoints -- @param self -------------------------------- +-- -- @function [parent=#GridBase] afterDraw -- @param self --- @param #cc.Node node +-- @param #cc.Node target -------------------------------- +-- -- @function [parent=#GridBase] beforeDraw -- @param self -------------------------------- +-- is texture flipped -- @function [parent=#GridBase] isTextureFlipped -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- size of the grid -- @function [parent=#GridBase] getGridSize -- @param self -- @return size_table#size_table ret (return value: size_table) -------------------------------- +-- pixels between the grids -- @function [parent=#GridBase] getStep -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- -- @function [parent=#GridBase] set2DProjection -- @param self -------------------------------- +-- -- @function [parent=#GridBase] setStep -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table step -------------------------------- +-- -- @function [parent=#GridBase] setTextureFlipped -- @param self --- @param #bool bool +-- @param #bool flipped -------------------------------- +-- -- @function [parent=#GridBase] blit -- @param self -------------------------------- +-- -- @function [parent=#GridBase] setActive -- @param self --- @param #bool bool +-- @param #bool active -------------------------------- +-- number of times that the grid will be reused -- @function [parent=#GridBase] getReuseGrid -- @param self -- @return int#int ret (return value: int) @@ -70,22 +83,25 @@ -- @overload self, size_table, cc.Texture2D, bool -- @function [parent=#GridBase] initWithSize -- @param self --- @param #size_table size --- @param #cc.Texture2D texture2d --- @param #bool bool +-- @param #size_table gridSize +-- @param #cc.Texture2D texture +-- @param #bool flipped -- @return bool#bool ret (retunr value: bool) -------------------------------- +-- -- @function [parent=#GridBase] setReuseGrid -- @param self --- @param #int int +-- @param #int reuseGrid -------------------------------- +-- whether or not the grid is active -- @function [parent=#GridBase] isActive -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#GridBase] reuse -- @param self @@ -94,9 +110,9 @@ -- @overload self, size_table, cc.Texture2D, bool -- @function [parent=#GridBase] create -- @param self --- @param #size_table size --- @param #cc.Texture2D texture2d --- @param #bool bool +-- @param #size_table gridSize +-- @param #cc.Texture2D texture +-- @param #bool flipped -- @return GridBase#GridBase ret (retunr value: cc.GridBase) return nil diff --git a/cocos/scripting/lua-bindings/auto/api/HBox.lua b/cocos/scripting/lua-bindings/auto/api/HBox.lua index 54ce53f9e3..cec73b279a 100644 --- a/cocos/scripting/lua-bindings/auto/api/HBox.lua +++ b/cocos/scripting/lua-bindings/auto/api/HBox.lua @@ -13,6 +13,7 @@ -- @return HBox#HBox ret (retunr value: ccui.HBox) -------------------------------- +-- Default constructor -- @function [parent=#HBox] HBox -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/Helper.lua b/cocos/scripting/lua-bindings/auto/api/Helper.lua index f7d6579957..539ae88abb 100644 --- a/cocos/scripting/lua-bindings/auto/api/Helper.lua +++ b/cocos/scripting/lua-bindings/auto/api/Helper.lua @@ -4,32 +4,46 @@ -- @parent_module ccui -------------------------------- +-- brief Get a UTF8 substring from a std::string with a given start position and length
+-- Sample: std::string str = "中国中国中国”; substr = getSubStringOfUTF8String(str,0,2) will = "中国"
+-- param start The start position of the substring.
+-- param length The length of the substring in UTF8 count
+-- return a UTF8 substring -- @function [parent=#Helper] getSubStringOfUTF8String -- @param self -- @param #string str --- @param #unsigned long long --- @param #unsigned long long +-- @param #unsigned long start +-- @param #unsigned long length -- @return string#string ret (return value: string) -------------------------------- +-- Finds a widget whose tag equals to param tag from root widget.
+-- param root widget which will be seeked.
+-- tag tag value.
+-- return finded result. -- @function [parent=#Helper] seekWidgetByTag -- @param self --- @param #ccui.Widget widget --- @param #int int +-- @param #ccui.Widget root +-- @param #int tag -- @return Widget#Widget ret (return value: ccui.Widget) -------------------------------- +-- -- @function [parent=#Helper] seekActionWidgetByActionTag -- @param self --- @param #ccui.Widget widget --- @param #int int +-- @param #ccui.Widget root +-- @param #int tag -- @return Widget#Widget ret (return value: ccui.Widget) -------------------------------- +-- Finds a widget whose name equals to param name from root widget.
+-- param root widget which will be seeked.
+-- name name value.
+-- return finded result. -- @function [parent=#Helper] seekWidgetByName -- @param self --- @param #ccui.Widget widget --- @param #string str +-- @param #ccui.Widget root +-- @param #string name -- @return Widget#Widget ret (return value: ccui.Widget) return nil diff --git a/cocos/scripting/lua-bindings/auto/api/Hide.lua b/cocos/scripting/lua-bindings/auto/api/Hide.lua index b40dbd8ea7..4aa81b057e 100644 --- a/cocos/scripting/lua-bindings/auto/api/Hide.lua +++ b/cocos/scripting/lua-bindings/auto/api/Hide.lua @@ -5,21 +5,25 @@ -- @parent_module cc -------------------------------- +-- Allocates and initializes the action -- @function [parent=#Hide] create -- @param self -- @return Hide#Hide ret (return value: cc.Hide) -------------------------------- +-- -- @function [parent=#Hide] clone -- @param self -- @return Hide#Hide ret (return value: cc.Hide) -------------------------------- +-- -- @function [parent=#Hide] update -- @param self --- @param #float float +-- @param #float time -------------------------------- +-- -- @function [parent=#Hide] reverse -- @param self -- @return ActionInstant#ActionInstant ret (return value: cc.ActionInstant) diff --git a/cocos/scripting/lua-bindings/auto/api/Image.lua b/cocos/scripting/lua-bindings/auto/api/Image.lua index 4ce6cd8d50..bc93b29571 100644 --- a/cocos/scripting/lua-bindings/auto/api/Image.lua +++ b/cocos/scripting/lua-bindings/auto/api/Image.lua @@ -5,69 +5,89 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#Image] hasPremultipliedAlpha -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- brief Save Image data to the specified file, with specified format.
+-- param filePath the file's absolute path, including file suffix.
+-- param isToRGB whether the image is saved as RGB format. -- @function [parent=#Image] saveToFile -- @param self --- @param #string str --- @param #bool bool +-- @param #string filename +-- @param #bool isToRGB -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#Image] hasAlpha -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#Image] isCompressed -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#Image] getHeight -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- brief Load the image from the specified path.
+-- param path the absolute file path.
+-- return true if loaded correctly. -- @function [parent=#Image] initWithImageFile -- @param self --- @param #string str +-- @param #string path -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#Image] getWidth -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- -- @function [parent=#Image] getBitPerPixel -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- -- @function [parent=#Image] getFileType -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- -- @function [parent=#Image] getNumberOfMipmaps -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- -- @function [parent=#Image] getRenderFormat -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- treats (or not) PVR files as if they have alpha premultiplied.
+-- Since it is impossible to know at runtime if the PVR images have the alpha channel premultiplied, it is
+-- possible load them as if they have (or not) the alpha channel premultiplied.
+-- By default it is disabled. -- @function [parent=#Image] setPVRImagesHavePremultipliedAlpha -- @param self --- @param #bool bool +-- @param #bool haveAlphaPremultiplied -------------------------------- +-- js ctor -- @function [parent=#Image] Image -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/ImageView.lua b/cocos/scripting/lua-bindings/auto/api/ImageView.lua index 395449e067..6bfec98e56 100644 --- a/cocos/scripting/lua-bindings/auto/api/ImageView.lua +++ b/cocos/scripting/lua-bindings/auto/api/ImageView.lua @@ -5,32 +5,43 @@ -- @parent_module ccui -------------------------------- +-- Load texture for imageview.
+-- param fileName file name of texture.
+-- param texType @see TextureResType -- @function [parent=#ImageView] loadTexture -- @param self --- @param #string str --- @param #int texturerestype +-- @param #string fileName +-- @param #int texType -------------------------------- +-- Sets if imageview is using scale9 renderer.
+-- param able true that using scale9 renderer, false otherwise. -- @function [parent=#ImageView] setScale9Enabled -- @param self --- @param #bool bool +-- @param #bool able -------------------------------- +-- Updates the texture rect of the ImageView in points.
+-- It will call setTextureRect:rotated:untrimmedSize with rotated = NO, and utrimmedSize = rect.size. -- @function [parent=#ImageView] setTextureRect -- @param self -- @param #rect_table rect -------------------------------- +-- Sets capinsets for imageview, if imageview is using scale9 renderer.
+-- param capInsets capinsets for imageview -- @function [parent=#ImageView] setCapInsets -- @param self --- @param #rect_table rect +-- @param #rect_table capInsets -------------------------------- +-- -- @function [parent=#ImageView] getCapInsets -- @param self -- @return rect_table#rect_table ret (return value: rect_table) -------------------------------- +-- -- @function [parent=#ImageView] isScale9Enabled -- @param self -- @return bool#bool ret (return value: bool) @@ -40,36 +51,42 @@ -- @overload self -- @function [parent=#ImageView] create -- @param self --- @param #string str --- @param #int texturerestype +-- @param #string imageFileName +-- @param #int texType -- @return ImageView#ImageView ret (retunr value: ccui.ImageView) -------------------------------- +-- -- @function [parent=#ImageView] createInstance -- @param self -- @return Ref#Ref ret (return value: cc.Ref) -------------------------------- +-- -- @function [parent=#ImageView] getVirtualRenderer -- @param self -- @return Node#Node ret (return value: cc.Node) -------------------------------- +-- Returns the "class name" of widget. -- @function [parent=#ImageView] getDescription -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- -- @function [parent=#ImageView] getVirtualRendererSize -- @param self -- @return size_table#size_table ret (return value: size_table) -------------------------------- +-- -- @function [parent=#ImageView] ignoreContentAdaptWithSize -- @param self --- @param #bool bool +-- @param #bool ignore -------------------------------- +-- Default constructor -- @function [parent=#ImageView] ImageView -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/InnerActionFrame.lua b/cocos/scripting/lua-bindings/auto/api/InnerActionFrame.lua index 5de5259f53..1ca735b5ef 100644 --- a/cocos/scripting/lua-bindings/auto/api/InnerActionFrame.lua +++ b/cocos/scripting/lua-bindings/auto/api/InnerActionFrame.lua @@ -5,36 +5,43 @@ -- @parent_module ccs -------------------------------- +-- -- @function [parent=#InnerActionFrame] getInnerActionType -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- -- @function [parent=#InnerActionFrame] setStartFrameIndex -- @param self --- @param #int int +-- @param #int frameIndex -------------------------------- +-- -- @function [parent=#InnerActionFrame] setInnerActionType -- @param self --- @param #int inneractiontype +-- @param #int type -------------------------------- +-- -- @function [parent=#InnerActionFrame] getStartFrameIndex -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- -- @function [parent=#InnerActionFrame] create -- @param self -- @return InnerActionFrame#InnerActionFrame ret (return value: ccs.InnerActionFrame) -------------------------------- +-- -- @function [parent=#InnerActionFrame] clone -- @param self -- @return Frame#Frame ret (return value: ccs.Frame) -------------------------------- +-- -- @function [parent=#InnerActionFrame] InnerActionFrame -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/JumpBy.lua b/cocos/scripting/lua-bindings/auto/api/JumpBy.lua index d507b67485..14eb4a8885 100644 --- a/cocos/scripting/lua-bindings/auto/api/JumpBy.lua +++ b/cocos/scripting/lua-bindings/auto/api/JumpBy.lua @@ -5,32 +5,37 @@ -- @parent_module cc -------------------------------- +-- creates the action -- @function [parent=#JumpBy] create -- @param self --- @param #float float --- @param #vec2_table vec2 --- @param #float float --- @param #int int +-- @param #float duration +-- @param #vec2_table position +-- @param #float height +-- @param #int jumps -- @return JumpBy#JumpBy ret (return value: cc.JumpBy) -------------------------------- +-- -- @function [parent=#JumpBy] startWithTarget -- @param self --- @param #cc.Node node +-- @param #cc.Node target -------------------------------- +-- -- @function [parent=#JumpBy] clone -- @param self -- @return JumpBy#JumpBy ret (return value: cc.JumpBy) -------------------------------- +-- -- @function [parent=#JumpBy] reverse -- @param self -- @return JumpBy#JumpBy ret (return value: cc.JumpBy) -------------------------------- +-- -- @function [parent=#JumpBy] update -- @param self --- @param #float float +-- @param #float time return nil diff --git a/cocos/scripting/lua-bindings/auto/api/JumpTiles3D.lua b/cocos/scripting/lua-bindings/auto/api/JumpTiles3D.lua index 53c834be5b..dd54c6becf 100644 --- a/cocos/scripting/lua-bindings/auto/api/JumpTiles3D.lua +++ b/cocos/scripting/lua-bindings/auto/api/JumpTiles3D.lua @@ -5,42 +5,49 @@ -- @parent_module cc -------------------------------- +-- amplitude rate -- @function [parent=#JumpTiles3D] getAmplitudeRate -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#JumpTiles3D] setAmplitude -- @param self --- @param #float float +-- @param #float amplitude -------------------------------- +-- -- @function [parent=#JumpTiles3D] setAmplitudeRate -- @param self --- @param #float float +-- @param #float amplitudeRate -------------------------------- +-- amplitude of the sin -- @function [parent=#JumpTiles3D] getAmplitude -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- creates the action with the number of jumps, the sin amplitude, the grid size and the duration -- @function [parent=#JumpTiles3D] create -- @param self --- @param #float float --- @param #size_table size --- @param #unsigned int int --- @param #float float +-- @param #float duration +-- @param #size_table gridSize +-- @param #unsigned int numberOfJumps +-- @param #float amplitude -- @return JumpTiles3D#JumpTiles3D ret (return value: cc.JumpTiles3D) -------------------------------- +-- -- @function [parent=#JumpTiles3D] clone -- @param self -- @return JumpTiles3D#JumpTiles3D ret (return value: cc.JumpTiles3D) -------------------------------- +-- -- @function [parent=#JumpTiles3D] update -- @param self --- @param #float float +-- @param #float time return nil diff --git a/cocos/scripting/lua-bindings/auto/api/JumpTo.lua b/cocos/scripting/lua-bindings/auto/api/JumpTo.lua index d2e4081e8d..daeb353815 100644 --- a/cocos/scripting/lua-bindings/auto/api/JumpTo.lua +++ b/cocos/scripting/lua-bindings/auto/api/JumpTo.lua @@ -5,25 +5,29 @@ -- @parent_module cc -------------------------------- +-- creates the action -- @function [parent=#JumpTo] create -- @param self --- @param #float float --- @param #vec2_table vec2 --- @param #float float --- @param #int int +-- @param #float duration +-- @param #vec2_table position +-- @param #float height +-- @param #int jumps -- @return JumpTo#JumpTo ret (return value: cc.JumpTo) -------------------------------- +-- -- @function [parent=#JumpTo] startWithTarget -- @param self --- @param #cc.Node node +-- @param #cc.Node target -------------------------------- +-- -- @function [parent=#JumpTo] clone -- @param self -- @return JumpTo#JumpTo ret (return value: cc.JumpTo) -------------------------------- +-- -- @function [parent=#JumpTo] reverse -- @param self -- @return JumpTo#JumpTo ret (return value: cc.JumpTo) diff --git a/cocos/scripting/lua-bindings/auto/api/Label.lua b/cocos/scripting/lua-bindings/auto/api/Label.lua index 52319e86ec..ccd1e9e660 100644 --- a/cocos/scripting/lua-bindings/auto/api/Label.lua +++ b/cocos/scripting/lua-bindings/auto/api/Label.lua @@ -5,123 +5,157 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#Label] isClipMarginEnabled -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- Enable shadow for the label
+-- todo support blur for shadow effect -- @function [parent=#Label] enableShadow -- @param self -------------------------------- +-- Sets the untransformed size of the label in a more efficient way. -- @function [parent=#Label] setDimensions -- @param self --- @param #unsigned int int --- @param #unsigned int int +-- @param #unsigned int width +-- @param #unsigned int height -------------------------------- +-- -- @function [parent=#Label] getString -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- -- @function [parent=#Label] getHeight -- @param self -- @return unsigned int#unsigned int ret (return value: unsigned int) -------------------------------- +-- disable shadow/outline/glow rendering -- @function [parent=#Label] disableEffect -- @param self -------------------------------- +-- set TTF configuration for Label -- @function [parent=#Label] setTTFConfig -- @param self --- @param #cc._ttfConfig _ttfconfig +-- @param #cc._ttfConfig ttfConfig -- @return bool#bool ret (return value: bool) -------------------------------- +-- Returns the text color of this label
+-- Only support for TTF and system font
+-- warning Different from the color of Node. -- @function [parent=#Label] getTextColor -- @param self -- @return color4b_table#color4b_table ret (return value: color4b_table) -------------------------------- +-- Sets the untransformed size of the label.
+-- The label's width be used for text align if the set value not equal zero.
+-- The label's max line width will be equal to the same value. -- @function [parent=#Label] setWidth -- @param self --- @param #unsigned int int +-- @param #unsigned int width -------------------------------- +-- -- @function [parent=#Label] getMaxLineWidth -- @param self -- @return unsigned int#unsigned int ret (return value: unsigned int) -------------------------------- +-- -- @function [parent=#Label] getHorizontalAlignment -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- clip upper and lower margin for reduce height of label. -- @function [parent=#Label] setClipMarginEnabled -- @param self --- @param #bool bool +-- @param #bool clipEnabled -------------------------------- +-- changes the string to render
+-- warning It is as expensive as changing the string if you haven't set up TTF/BMFont/CharMap for the label. -- @function [parent=#Label] setString -- @param self --- @param #string str +-- @param #string text -------------------------------- +-- -- @function [parent=#Label] setSystemFontName -- @param self --- @param #string str +-- @param #string systemFont -------------------------------- +-- -- @function [parent=#Label] setBMFontFilePath -- @param self --- @param #string str --- @param #vec2_table vec2 +-- @param #string bmfontFilePath +-- @param #vec2_table imageOffset -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#Label] getFontAtlas -- @param self -- @return FontAtlas#FontAtlas ret (return value: cc.FontAtlas) -------------------------------- +-- Sets the line height of the label
+-- warning Not support system font
+-- since v3.2.0 -- @function [parent=#Label] setLineHeight -- @param self --- @param #float float +-- @param #float height -------------------------------- +-- -- @function [parent=#Label] setSystemFontSize -- @param self --- @param #float float +-- @param #float fontSize -------------------------------- +-- update content immediately. -- @function [parent=#Label] updateContent -- @param self -------------------------------- +-- -- @function [parent=#Label] getStringLength -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- -- @function [parent=#Label] setLineBreakWithoutSpace -- @param self --- @param #bool bool +-- @param #bool breakWithoutSpace -------------------------------- +-- -- @function [parent=#Label] getStringNumLines -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- only support for TTF -- @function [parent=#Label] enableOutline -- @param self --- @param #color4b_table color4b --- @param #int int +-- @param #color4b_table outlineColor +-- @param #int outlineSize -------------------------------- +-- Returns the additional kerning of this label
+-- warning Not support system font
+-- since v3.2.0 -- @function [parent=#Label] getAdditionalKerning -- @param self -- @return float#float ret (return value: float) @@ -132,117 +166,145 @@ -- @overload self, string -- @function [parent=#Label] setCharMap -- @param self --- @param #string str --- @param #int int --- @param #int int --- @param #int int +-- @param #string charMapFile +-- @param #int itemWidth +-- @param #int itemHeight +-- @param #int startCharMap -- @return bool#bool ret (retunr value: bool) -------------------------------- +-- -- @function [parent=#Label] getDimensions -- @param self -- @return size_table#size_table ret (return value: size_table) -------------------------------- +-- Sets the max line width of the label.
+-- The label's max line width be used for force line breaks if the set value not equal zero.
+-- The label's width and max line width has not always to be equal. -- @function [parent=#Label] setMaxLineWidth -- @param self --- @param #unsigned int int +-- @param #unsigned int maxLineWidth -------------------------------- +-- -- @function [parent=#Label] getSystemFontName -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- -- @function [parent=#Label] setVerticalAlignment -- @param self --- @param #int textvalignment +-- @param #int vAlignment -------------------------------- +-- Returns the line height of this label
+-- warning Not support system font -- @function [parent=#Label] getLineHeight -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#Label] getTTFConfig -- @param self -- @return _ttfConfig#_ttfConfig ret (return value: cc._ttfConfig) -------------------------------- +-- -- @function [parent=#Label] getVerticalAlignment -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- Sets the text color of the label
+-- Only support for TTF and system font
+-- warning Different from the color of Node. -- @function [parent=#Label] setTextColor -- @param self --- @param #color4b_table color4b +-- @param #color4b_table color -------------------------------- +-- Sets the untransformed size of the label.
+-- The label's height be used for text align if the set value not equal zero.
+-- The text will display of incomplete when the size of label not enough to support display all text. -- @function [parent=#Label] setHeight -- @param self --- @param #unsigned int int +-- @param #unsigned int height -------------------------------- +-- -- @function [parent=#Label] getWidth -- @param self -- @return unsigned int#unsigned int ret (return value: unsigned int) -------------------------------- +-- only support for TTF -- @function [parent=#Label] enableGlow -- @param self --- @param #color4b_table color4b +-- @param #color4b_table glowColor -------------------------------- +-- -- @function [parent=#Label] getLetter -- @param self --- @param #int int +-- @param #int lettetIndex -- @return Sprite#Sprite ret (return value: cc.Sprite) -------------------------------- +-- Sets the additional kerning of the label
+-- warning Not support system font
+-- since v3.2.0 -- @function [parent=#Label] setAdditionalKerning -- @param self --- @param #float float +-- @param #float space -------------------------------- +-- -- @function [parent=#Label] getSystemFontSize -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#Label] getTextAlignment -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- -- @function [parent=#Label] getBMFontFilePath -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- -- @function [parent=#Label] setHorizontalAlignment -- @param self --- @param #int texthalignment +-- @param #int hAlignment -------------------------------- -- @overload self, int, int -- @overload self, int -- @function [parent=#Label] setAlignment -- @param self --- @param #int texthalignment --- @param #int textvalignment +-- @param #int hAlignment +-- @param #int vAlignment -------------------------------- +-- -- @function [parent=#Label] createWithBMFont -- @param self --- @param #string str --- @param #string str --- @param #int texthalignment --- @param #int int --- @param #vec2_table vec2 +-- @param #string bmfontFilePath +-- @param #string text +-- @param #int alignment +-- @param #int maxLineWidth +-- @param #vec2_table imageOffset -- @return Label#Label ret (return value: cc.Label) -------------------------------- +-- -- @function [parent=#Label] create -- @param self -- @return Label#Label ret (return value: cc.Label) @@ -253,111 +315,130 @@ -- @overload self, string -- @function [parent=#Label] createWithCharMap -- @param self --- @param #string str --- @param #int int --- @param #int int --- @param #int int +-- @param #string charMapFile +-- @param #int itemWidth +-- @param #int itemHeight +-- @param #int startCharMap -- @return Label#Label ret (retunr value: cc.Label) -------------------------------- +-- Creates a label with an initial string,font[font name or font file],font size, dimension in points, horizontal alignment and vertical alignment.
+-- warning It will generate texture by the platform-dependent code -- @function [parent=#Label] createWithSystemFont -- @param self --- @param #string str --- @param #string str --- @param #float float --- @param #size_table size --- @param #int texthalignment --- @param #int textvalignment +-- @param #string text +-- @param #string font +-- @param #float fontSize +-- @param #size_table dimensions +-- @param #int hAlignment +-- @param #int vAlignment -- @return Label#Label ret (return value: cc.Label) -------------------------------- +-- -- @function [parent=#Label] draw -- @param self -- @param #cc.Renderer renderer --- @param #mat4_table mat4 --- @param #unsigned int int +-- @param #mat4_table transform +-- @param #unsigned int flags -------------------------------- +-- -- @function [parent=#Label] addChild -- @param self --- @param #cc.Node node --- @param #int int --- @param #int int +-- @param #cc.Node child +-- @param #int zOrder +-- @param #int tag -------------------------------- +-- -- @function [parent=#Label] setScaleY -- @param self --- @param #float float +-- @param #float scaleY -------------------------------- +-- -- @function [parent=#Label] setScaleX -- @param self --- @param #float float +-- @param #float scaleX -------------------------------- +-- -- @function [parent=#Label] isOpacityModifyRGB -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#Label] getScaleY -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#Label] setBlendFunc -- @param self --- @param #cc.BlendFunc blendfunc +-- @param #cc.BlendFunc blendFunc -------------------------------- +-- -- @function [parent=#Label] visit -- @param self -- @param #cc.Renderer renderer --- @param #mat4_table mat4 --- @param #unsigned int int +-- @param #mat4_table parentTransform +-- @param #unsigned int parentFlags -------------------------------- +-- -- @function [parent=#Label] getScaleX -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#Label] getDescription -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- -- @function [parent=#Label] setOpacityModifyRGB -- @param self --- @param #bool bool +-- @param #bool isOpacityModifyRGB -------------------------------- +-- -- @function [parent=#Label] setScale -- @param self --- @param #float float +-- @param #float scale -------------------------------- +-- -- @function [parent=#Label] sortAllChildren -- @param self -------------------------------- +-- -- @function [parent=#Label] updateDisplayedOpacity -- @param self --- @param #unsigned char char +-- @param #unsigned char parentOpacity -------------------------------- +-- -- @function [parent=#Label] getContentSize -- @param self -- @return size_table#size_table ret (return value: size_table) -------------------------------- +-- -- @function [parent=#Label] getBoundingBox -- @param self -- @return rect_table#rect_table ret (return value: rect_table) -------------------------------- +-- -- @function [parent=#Label] updateDisplayedColor -- @param self --- @param #color3b_table color3b +-- @param #color3b_table parentColor return nil diff --git a/cocos/scripting/lua-bindings/auto/api/LabelAtlas.lua b/cocos/scripting/lua-bindings/auto/api/LabelAtlas.lua index 50753ea4c0..53d042dc5f 100644 --- a/cocos/scripting/lua-bindings/auto/api/LabelAtlas.lua +++ b/cocos/scripting/lua-bindings/auto/api/LabelAtlas.lua @@ -5,9 +5,10 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#LabelAtlas] setString -- @param self --- @param #string str +-- @param #string label -------------------------------- -- @overload self, string, string @@ -15,18 +16,20 @@ -- @overload self, string, cc.Texture2D, int, int, int -- @function [parent=#LabelAtlas] initWithString -- @param self --- @param #string str --- @param #cc.Texture2D texture2d --- @param #int int --- @param #int int --- @param #int int +-- @param #string string +-- @param #cc.Texture2D texture +-- @param #int itemWidth +-- @param #int itemHeight +-- @param #int startCharMap -- @return bool#bool ret (retunr value: bool) -------------------------------- +-- -- @function [parent=#LabelAtlas] updateAtlasValues -- @param self -------------------------------- +-- -- @function [parent=#LabelAtlas] getString -- @param self -- @return string#string ret (return value: string) @@ -37,14 +40,15 @@ -- @overload self, string, string -- @function [parent=#LabelAtlas] create -- @param self --- @param #string str --- @param #string str --- @param #int int --- @param #int int --- @param #int int +-- @param #string string +-- @param #string charMapFile +-- @param #int itemWidth +-- @param #int itemHeight +-- @param #int startCharMap -- @return LabelAtlas#LabelAtlas ret (retunr value: cc.LabelAtlas) -------------------------------- +-- -- @function [parent=#LabelAtlas] getDescription -- @param self -- @return string#string ret (return value: string) diff --git a/cocos/scripting/lua-bindings/auto/api/Layer.lua b/cocos/scripting/lua-bindings/auto/api/Layer.lua index 8918c08dbe..cca3874464 100644 --- a/cocos/scripting/lua-bindings/auto/api/Layer.lua +++ b/cocos/scripting/lua-bindings/auto/api/Layer.lua @@ -5,11 +5,13 @@ -- @parent_module cc -------------------------------- +-- creates a fullscreen black layer -- @function [parent=#Layer] create -- @param self -- @return Layer#Layer ret (return value: cc.Layer) -------------------------------- +-- -- @function [parent=#Layer] getDescription -- @param self -- @return string#string ret (return value: string) diff --git a/cocos/scripting/lua-bindings/auto/api/LayerColor.lua b/cocos/scripting/lua-bindings/auto/api/LayerColor.lua index 6a190c9eb1..c4cdc21e89 100644 --- a/cocos/scripting/lua-bindings/auto/api/LayerColor.lua +++ b/cocos/scripting/lua-bindings/auto/api/LayerColor.lua @@ -5,20 +5,24 @@ -- @parent_module cc -------------------------------- +-- change width and height in Points
+-- since v0.8 -- @function [parent=#LayerColor] changeWidthAndHeight -- @param self --- @param #float float --- @param #float float +-- @param #float w +-- @param #float h -------------------------------- +-- change height in Points -- @function [parent=#LayerColor] changeHeight -- @param self --- @param #float float +-- @param #float h -------------------------------- +-- change width in Points -- @function [parent=#LayerColor] changeWidth -- @param self --- @param #float float +-- @param #float w -------------------------------- -- @overload self, color4b_table, float, float @@ -26,26 +30,29 @@ -- @overload self, color4b_table -- @function [parent=#LayerColor] create -- @param self --- @param #color4b_table color4b --- @param #float float --- @param #float float +-- @param #color4b_table color +-- @param #float width +-- @param #float height -- @return LayerColor#LayerColor ret (retunr value: cc.LayerColor) -------------------------------- +-- -- @function [parent=#LayerColor] draw -- @param self -- @param #cc.Renderer renderer --- @param #mat4_table mat4 --- @param #unsigned int int +-- @param #mat4_table transform +-- @param #unsigned int flags -------------------------------- +-- -- @function [parent=#LayerColor] getDescription -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- -- @function [parent=#LayerColor] setContentSize -- @param self --- @param #size_table size +-- @param #size_table var return nil diff --git a/cocos/scripting/lua-bindings/auto/api/LayerGradient.lua b/cocos/scripting/lua-bindings/auto/api/LayerGradient.lua index 8f18269408..fda8a00876 100644 --- a/cocos/scripting/lua-bindings/auto/api/LayerGradient.lua +++ b/cocos/scripting/lua-bindings/auto/api/LayerGradient.lua @@ -5,64 +5,78 @@ -- @parent_module cc -------------------------------- +-- Returns the start color of the gradient -- @function [parent=#LayerGradient] getStartColor -- @param self -- @return color3b_table#color3b_table ret (return value: color3b_table) -------------------------------- +-- -- @function [parent=#LayerGradient] isCompressedInterpolation -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- Returns the start opacity of the gradient -- @function [parent=#LayerGradient] getStartOpacity -- @param self -- @return unsigned char#unsigned char ret (return value: unsigned char) -------------------------------- +-- Sets the directional vector that will be used for the gradient.
+-- The default value is vertical direction (0,-1). -- @function [parent=#LayerGradient] setVector -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table alongVector -------------------------------- +-- Returns the start opacity of the gradient -- @function [parent=#LayerGradient] setStartOpacity -- @param self --- @param #unsigned char char +-- @param #unsigned char startOpacity -------------------------------- +-- Whether or not the interpolation will be compressed in order to display all the colors of the gradient both in canonical and non canonical vectors
+-- Default: true -- @function [parent=#LayerGradient] setCompressedInterpolation -- @param self --- @param #bool bool +-- @param #bool compressedInterpolation -------------------------------- +-- Returns the end opacity of the gradient -- @function [parent=#LayerGradient] setEndOpacity -- @param self --- @param #unsigned char char +-- @param #unsigned char endOpacity -------------------------------- +-- Returns the directional vector used for the gradient -- @function [parent=#LayerGradient] getVector -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- Sets the end color of the gradient -- @function [parent=#LayerGradient] setEndColor -- @param self --- @param #color3b_table color3b +-- @param #color3b_table endColor -------------------------------- +-- Returns the end color of the gradient -- @function [parent=#LayerGradient] getEndColor -- @param self -- @return color3b_table#color3b_table ret (return value: color3b_table) -------------------------------- +-- Returns the end opacity of the gradient -- @function [parent=#LayerGradient] getEndOpacity -- @param self -- @return unsigned char#unsigned char ret (return value: unsigned char) -------------------------------- +-- Sets the start color of the gradient -- @function [parent=#LayerGradient] setStartColor -- @param self --- @param #color3b_table color3b +-- @param #color3b_table startColor -------------------------------- -- @overload self, color4b_table, color4b_table @@ -70,12 +84,13 @@ -- @overload self, color4b_table, color4b_table, vec2_table -- @function [parent=#LayerGradient] create -- @param self --- @param #color4b_table color4b --- @param #color4b_table color4b --- @param #vec2_table vec2 +-- @param #color4b_table start +-- @param #color4b_table end +-- @param #vec2_table v -- @return LayerGradient#LayerGradient ret (retunr value: cc.LayerGradient) -------------------------------- +-- -- @function [parent=#LayerGradient] getDescription -- @param self -- @return string#string ret (return value: string) diff --git a/cocos/scripting/lua-bindings/auto/api/LayerMultiplex.lua b/cocos/scripting/lua-bindings/auto/api/LayerMultiplex.lua index 3f577da04d..b413d3dd25 100644 --- a/cocos/scripting/lua-bindings/auto/api/LayerMultiplex.lua +++ b/cocos/scripting/lua-bindings/auto/api/LayerMultiplex.lua @@ -5,21 +5,27 @@ -- @parent_module cc -------------------------------- +-- release the current layer and switches to another layer indexed by n.
+-- The current (old) layer will be removed from it's parent with 'cleanup=true'. -- @function [parent=#LayerMultiplex] switchToAndReleaseMe -- @param self --- @param #int int +-- @param #int n -------------------------------- +-- -- @function [parent=#LayerMultiplex] addLayer -- @param self -- @param #cc.Layer layer -------------------------------- +-- switches to a certain layer indexed by n.
+-- The current (old) layer will be removed from it's parent with 'cleanup=true'. -- @function [parent=#LayerMultiplex] switchTo -- @param self --- @param #int int +-- @param #int n -------------------------------- +-- -- @function [parent=#LayerMultiplex] getDescription -- @param self -- @return string#string ret (return value: string) diff --git a/cocos/scripting/lua-bindings/auto/api/Layout.lua b/cocos/scripting/lua-bindings/auto/api/Layout.lua index fc0c574ce7..4612380c7a 100644 --- a/cocos/scripting/lua-bindings/auto/api/Layout.lua +++ b/cocos/scripting/lua-bindings/auto/api/Layout.lua @@ -5,177 +5,223 @@ -- @parent_module ccui -------------------------------- +-- Sets background color vector for layout, if color type is BackGroundColorType::GRADIENT
+-- param vector -- @function [parent=#Layout] setBackGroundColorVector -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table vector -------------------------------- +-- -- @function [parent=#Layout] setClippingType -- @param self --- @param #int clippingtype +-- @param #int type -------------------------------- +-- Sets Color Type for layout.
+-- param type @see LayoutBackGroundColorType. -- @function [parent=#Layout] setBackGroundColorType -- @param self --- @param #int backgroundcolortype +-- @param #int type -------------------------------- +-- If a layout is loop focused which means that the focus movement will be inside the layout
+-- param loop pass true to let the focus movement loop inside the layout -- @function [parent=#Layout] setLoopFocus -- @param self --- @param #bool bool +-- @param #bool loop -------------------------------- +-- -- @function [parent=#Layout] setBackGroundImageColor -- @param self --- @param #color3b_table color3b +-- @param #color3b_table color -------------------------------- +-- -- @function [parent=#Layout] getBackGroundColorVector -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- -- @function [parent=#Layout] getClippingType -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- return If focus loop is enabled, then it will return true, otherwise it returns false. The default value is false. -- @function [parent=#Layout] isLoopFocus -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- Remove the background image of layout. -- @function [parent=#Layout] removeBackGroundImage -- @param self -------------------------------- +-- -- @function [parent=#Layout] getBackGroundColorOpacity -- @param self -- @return unsigned char#unsigned char ret (return value: unsigned char) -------------------------------- +-- Gets if layout is clipping enabled.
+-- return if layout is clipping enabled. -- @function [parent=#Layout] isClippingEnabled -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#Layout] setBackGroundImageOpacity -- @param self --- @param #unsigned char char +-- @param #unsigned char opacity -------------------------------- +-- Sets a background image for layout
+-- param fileName image file path.
+-- param texType @see TextureResType. TextureResType::LOCAL means local file, TextureResType::PLIST means sprite frame. -- @function [parent=#Layout] setBackGroundImage -- @param self --- @param #string str --- @param #int texturerestype +-- @param #string fileName +-- @param #int texType -------------------------------- -- @overload self, color3b_table, color3b_table -- @overload self, color3b_table -- @function [parent=#Layout] setBackGroundColor -- @param self --- @param #color3b_table color3b --- @param #color3b_table color3b +-- @param #color3b_table startColor +-- @param #color3b_table endColor -------------------------------- +-- request to refresh widget layout -- @function [parent=#Layout] requestDoLayout -- @param self -------------------------------- +-- -- @function [parent=#Layout] getBackGroundImageCapInsets -- @param self -- @return rect_table#rect_table ret (return value: rect_table) -------------------------------- +-- -- @function [parent=#Layout] getBackGroundColor -- @param self -- @return color3b_table#color3b_table ret (return value: color3b_table) -------------------------------- +-- Changes if layout can clip it's content and child.
+-- If you really need this, please enable it. But it would reduce the rendering efficiency.
+-- param clipping enabled. -- @function [parent=#Layout] setClippingEnabled -- @param self --- @param #bool bool +-- @param #bool enabled -------------------------------- +-- -- @function [parent=#Layout] getBackGroundImageColor -- @param self -- @return color3b_table#color3b_table ret (return value: color3b_table) -------------------------------- +-- -- @function [parent=#Layout] isBackGroundImageScale9Enabled -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#Layout] getBackGroundColorType -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- -- @function [parent=#Layout] getBackGroundEndColor -- @param self -- @return color3b_table#color3b_table ret (return value: color3b_table) -------------------------------- +-- Sets background opacity layout.
+-- param opacity -- @function [parent=#Layout] setBackGroundColorOpacity -- @param self --- @param #unsigned char char +-- @param #unsigned char opacity -------------------------------- +-- -- @function [parent=#Layout] getBackGroundImageOpacity -- @param self -- @return unsigned char#unsigned char ret (return value: unsigned char) -------------------------------- +-- return To query whether the layout will pass the focus to its children or not. The default value is true -- @function [parent=#Layout] isPassFocusToChild -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- Sets a background image capinsets for layout, if the background image is a scale9 render.
+-- param capinsets of background image. -- @function [parent=#Layout] setBackGroundImageCapInsets -- @param self --- @param #rect_table rect +-- @param #rect_table capInsets -------------------------------- +-- Gets background image texture size.
+-- return background image texture size. -- @function [parent=#Layout] getBackGroundImageTextureSize -- @param self -- @return size_table#size_table ret (return value: size_table) -------------------------------- +-- force refresh widget layout -- @function [parent=#Layout] forceDoLayout -- @param self -------------------------------- +-- -- @function [parent=#Layout] getLayoutType -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- param pass To specify whether the layout pass its focus to its child -- @function [parent=#Layout] setPassFocusToChild -- @param self --- @param #bool bool +-- @param #bool pass -------------------------------- +-- -- @function [parent=#Layout] getBackGroundStartColor -- @param self -- @return color3b_table#color3b_table ret (return value: color3b_table) -------------------------------- +-- Sets background iamge use scale9 renderer.
+-- param enabled true that use scale9 renderer, false otherwise. -- @function [parent=#Layout] setBackGroundImageScale9Enabled -- @param self --- @param #bool bool +-- @param #bool enabled -------------------------------- +-- -- @function [parent=#Layout] setLayoutType -- @param self -- @param #int type -------------------------------- +-- Allocates and initializes a layout. -- @function [parent=#Layout] create -- @param self -- @return Layout#Layout ret (return value: ccui.Layout) -------------------------------- +-- -- @function [parent=#Layout] createInstance -- @param self -- @return Ref#Ref ret (return value: cc.Ref) @@ -187,38 +233,52 @@ -- @overload self, cc.Node, int, string -- @function [parent=#Layout] addChild -- @param self --- @param #cc.Node node --- @param #int int --- @param #string str +-- @param #cc.Node child +-- @param #int zOrder +-- @param #string name -------------------------------- +-- Returns the "class name" of widget. -- @function [parent=#Layout] getDescription -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- Removes all children from the container, and do a cleanup to all running actions depending on the cleanup parameter.
+-- param cleanup true if all running actions on all children nodes should be cleanup, false oterwise.
+-- js removeAllChildren
+-- lua removeAllChildren -- @function [parent=#Layout] removeAllChildrenWithCleanup -- @param self --- @param #bool bool +-- @param #bool cleanup -------------------------------- +-- Removes all children from the container with a cleanup.
+-- see `removeAllChildrenWithCleanup(bool)` -- @function [parent=#Layout] removeAllChildren -- @param self -------------------------------- +-- When a widget is in a layout, you could call this method to get the next focused widget within a specified direction.
+-- If the widget is not in a layout, it will return itself
+-- param dir the direction to look for the next focused widget in a layout
+-- param current the current focused widget
+-- return the next focused widget in a layout -- @function [parent=#Layout] findNextFocusedWidget -- @param self --- @param #int focusdirection --- @param #ccui.Widget widget +-- @param #int direction +-- @param #ccui.Widget current -- @return Widget#Widget ret (return value: ccui.Widget) -------------------------------- +-- -- @function [parent=#Layout] removeChild -- @param self --- @param #cc.Node node --- @param #bool bool +-- @param #cc.Node child +-- @param #bool cleanup -------------------------------- +-- Default constructor -- @function [parent=#Layout] Layout -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/LayoutParameter.lua b/cocos/scripting/lua-bindings/auto/api/LayoutParameter.lua index 590f5ea26d..93f935f428 100644 --- a/cocos/scripting/lua-bindings/auto/api/LayoutParameter.lua +++ b/cocos/scripting/lua-bindings/auto/api/LayoutParameter.lua @@ -5,31 +5,40 @@ -- @parent_module ccui -------------------------------- +-- -- @function [parent=#LayoutParameter] clone -- @param self -- @return LayoutParameter#LayoutParameter ret (return value: ccui.LayoutParameter) -------------------------------- +-- Gets LayoutParameterType of LayoutParameter.
+-- see LayoutParameterType
+-- return LayoutParameterType -- @function [parent=#LayoutParameter] getLayoutType -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- -- @function [parent=#LayoutParameter] createCloneInstance -- @param self -- @return LayoutParameter#LayoutParameter ret (return value: ccui.LayoutParameter) -------------------------------- +-- -- @function [parent=#LayoutParameter] copyProperties -- @param self --- @param #ccui.LayoutParameter layoutparameter +-- @param #ccui.LayoutParameter model -------------------------------- +-- Allocates and initializes.
+-- return A initialized LayoutParameter which is marked as "autorelease". -- @function [parent=#LayoutParameter] create -- @param self -- @return LayoutParameter#LayoutParameter ret (return value: ccui.LayoutParameter) -------------------------------- +-- Default constructor -- @function [parent=#LayoutParameter] LayoutParameter -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/Lens3D.lua b/cocos/scripting/lua-bindings/auto/api/Lens3D.lua index 2bfdba6006..780fef9f24 100644 --- a/cocos/scripting/lua-bindings/auto/api/Lens3D.lua +++ b/cocos/scripting/lua-bindings/auto/api/Lens3D.lua @@ -5,47 +5,55 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#Lens3D] setPosition -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table position -------------------------------- +-- Set whether lens is concave -- @function [parent=#Lens3D] setConcave -- @param self --- @param #bool bool +-- @param #bool concave -------------------------------- +-- Set lens center position -- @function [parent=#Lens3D] setLensEffect -- @param self --- @param #float float +-- @param #float lensEffect -------------------------------- +-- -- @function [parent=#Lens3D] getPosition -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- Get lens center position -- @function [parent=#Lens3D] getLensEffect -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- creates the action with center position, radius, a grid size and duration -- @function [parent=#Lens3D] create -- @param self --- @param #float float --- @param #size_table size --- @param #vec2_table vec2 --- @param #float float +-- @param #float duration +-- @param #size_table gridSize +-- @param #vec2_table position +-- @param #float radius -- @return Lens3D#Lens3D ret (return value: cc.Lens3D) -------------------------------- +-- -- @function [parent=#Lens3D] clone -- @param self -- @return Lens3D#Lens3D ret (return value: cc.Lens3D) -------------------------------- +-- -- @function [parent=#Lens3D] update -- @param self --- @param #float float +-- @param #float time return nil diff --git a/cocos/scripting/lua-bindings/auto/api/LinearLayoutParameter.lua b/cocos/scripting/lua-bindings/auto/api/LinearLayoutParameter.lua index 81db029efb..0b73c6dce6 100644 --- a/cocos/scripting/lua-bindings/auto/api/LinearLayoutParameter.lua +++ b/cocos/scripting/lua-bindings/auto/api/LinearLayoutParameter.lua @@ -5,31 +5,42 @@ -- @parent_module ccui -------------------------------- +-- Sets LinearGravity parameter for LayoutParameter.
+-- see LinearGravity
+-- param LinearGravity -- @function [parent=#LinearLayoutParameter] setGravity -- @param self --- @param #int lineargravity +-- @param #int gravity -------------------------------- +-- Gets LinearGravity parameter for LayoutParameter.
+-- see LinearGravity
+-- return LinearGravity -- @function [parent=#LinearLayoutParameter] getGravity -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- Allocates and initializes.
+-- return A initialized LayoutParameter which is marked as "autorelease". -- @function [parent=#LinearLayoutParameter] create -- @param self -- @return LinearLayoutParameter#LinearLayoutParameter ret (return value: ccui.LinearLayoutParameter) -------------------------------- +-- -- @function [parent=#LinearLayoutParameter] createCloneInstance -- @param self -- @return LayoutParameter#LayoutParameter ret (return value: ccui.LayoutParameter) -------------------------------- +-- -- @function [parent=#LinearLayoutParameter] copyProperties -- @param self --- @param #ccui.LayoutParameter layoutparameter +-- @param #ccui.LayoutParameter model -------------------------------- +-- Default constructor -- @function [parent=#LinearLayoutParameter] LinearLayoutParameter -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/Liquid.lua b/cocos/scripting/lua-bindings/auto/api/Liquid.lua index 1d70bc7690..d572cb528b 100644 --- a/cocos/scripting/lua-bindings/auto/api/Liquid.lua +++ b/cocos/scripting/lua-bindings/auto/api/Liquid.lua @@ -5,42 +5,49 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#Liquid] getAmplitudeRate -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#Liquid] setAmplitude -- @param self --- @param #float float +-- @param #float amplitude -------------------------------- +-- -- @function [parent=#Liquid] setAmplitudeRate -- @param self --- @param #float float +-- @param #float amplitudeRate -------------------------------- +-- -- @function [parent=#Liquid] getAmplitude -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- creates the action with amplitude, a grid and duration -- @function [parent=#Liquid] create -- @param self --- @param #float float --- @param #size_table size --- @param #unsigned int int --- @param #float float +-- @param #float duration +-- @param #size_table gridSize +-- @param #unsigned int waves +-- @param #float amplitude -- @return Liquid#Liquid ret (return value: cc.Liquid) -------------------------------- +-- -- @function [parent=#Liquid] clone -- @param self -- @return Liquid#Liquid ret (return value: cc.Liquid) -------------------------------- +-- -- @function [parent=#Liquid] update -- @param self --- @param #float float +-- @param #float time return nil diff --git a/cocos/scripting/lua-bindings/auto/api/ListView.lua b/cocos/scripting/lua-bindings/auto/api/ListView.lua index eb0b32815d..550f7ede5d 100644 --- a/cocos/scripting/lua-bindings/auto/api/ListView.lua +++ b/cocos/scripting/lua-bindings/auto/api/ListView.lua @@ -5,103 +5,133 @@ -- @parent_module ccui -------------------------------- +-- Returns the index of item.
+-- param item the item which need to be checked.
+-- return the index of item. -- @function [parent=#ListView] getIndex -- @param self --- @param #ccui.Widget widget +-- @param #ccui.Widget item -- @return long#long ret (return value: long) -------------------------------- +-- -- @function [parent=#ListView] removeAllItems -- @param self -------------------------------- +-- Changes the gravity of listview.
+-- see ListViewGravity -- @function [parent=#ListView] setGravity -- @param self -- @param #int gravity -------------------------------- +-- Push back custom item into listview. -- @function [parent=#ListView] pushBackCustomItem -- @param self --- @param #ccui.Widget widget +-- @param #ccui.Widget item -------------------------------- +-- Returns the item container. -- @function [parent=#ListView] getItems -- @param self -- @return array_table#array_table ret (return value: array_table) -------------------------------- +-- Removes a item whose index is same as the parameter.
+-- param index of item. -- @function [parent=#ListView] removeItem -- @param self --- @param #long long +-- @param #long index -------------------------------- +-- -- @function [parent=#ListView] getCurSelectedIndex -- @param self -- @return long#long ret (return value: long) -------------------------------- +-- Insert a default item(create by a cloned model) into listview. -- @function [parent=#ListView] insertDefaultItem -- @param self --- @param #long long +-- @param #long index -------------------------------- +-- -- @function [parent=#ListView] requestRefreshView -- @param self -------------------------------- +-- Changes the margin between each item.
+-- param margin -- @function [parent=#ListView] setItemsMargin -- @param self --- @param #float float +-- @param #float margin -------------------------------- +-- -- @function [parent=#ListView] refreshView -- @param self -------------------------------- +-- Removes the last item of listview. -- @function [parent=#ListView] removeLastItem -- @param self -------------------------------- +-- -- @function [parent=#ListView] getItemsMargin -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#ListView] addEventListener -- @param self --- @param #function func +-- @param #function callback -------------------------------- +-- Returns a item whose index is same as the parameter.
+-- param index of item.
+-- return the item widget. -- @function [parent=#ListView] getItem -- @param self --- @param #long long +-- @param #long index -- @return Widget#Widget ret (return value: ccui.Widget) -------------------------------- +-- Sets a item model for listview
+-- A model will be cloned for adding default item.
+-- param model item model for listview -- @function [parent=#ListView] setItemModel -- @param self --- @param #ccui.Widget widget +-- @param #ccui.Widget model -------------------------------- +-- -- @function [parent=#ListView] doLayout -- @param self -------------------------------- +-- Push back a default item(create by a cloned model) into listview. -- @function [parent=#ListView] pushBackDefaultItem -- @param self -------------------------------- +-- Insert custom item into listview. -- @function [parent=#ListView] insertCustomItem -- @param self --- @param #ccui.Widget widget --- @param #long long +-- @param #ccui.Widget item +-- @param #long index -------------------------------- +-- Allocates and initializes. -- @function [parent=#ListView] create -- @param self -- @return ListView#ListView ret (return value: ccui.ListView) -------------------------------- +-- -- @function [parent=#ListView] createInstance -- @param self -- @return Ref#Ref ret (return value: cc.Ref) @@ -113,36 +143,44 @@ -- @overload self, cc.Node, int, string -- @function [parent=#ListView] addChild -- @param self --- @param #cc.Node node --- @param #int int --- @param #string str +-- @param #cc.Node child +-- @param #int zOrder +-- @param #string name -------------------------------- +-- Changes scroll direction of scrollview.
+-- see Direction Direction::VERTICAL means vertical scroll, Direction::HORIZONTAL means horizontal scroll
+-- param dir, set the list view's scroll direction -- @function [parent=#ListView] setDirection -- @param self --- @param #int direction +-- @param #int dir -------------------------------- +-- -- @function [parent=#ListView] getDescription -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- -- @function [parent=#ListView] removeAllChildrenWithCleanup -- @param self --- @param #bool bool +-- @param #bool cleanup -------------------------------- +-- -- @function [parent=#ListView] removeAllChildren -- @param self -------------------------------- +-- -- @function [parent=#ListView] removeChild -- @param self --- @param #cc.Node node --- @param #bool bool +-- @param #cc.Node child +-- @param #bool cleaup -------------------------------- +-- Default constructor -- @function [parent=#ListView] ListView -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/LoadingBar.lua b/cocos/scripting/lua-bindings/auto/api/LoadingBar.lua index 132912332c..bb0fa5deff 100644 --- a/cocos/scripting/lua-bindings/auto/api/LoadingBar.lua +++ b/cocos/scripting/lua-bindings/auto/api/LoadingBar.lua @@ -5,47 +5,66 @@ -- @parent_module ccui -------------------------------- +-- Changes the progress direction of loadingbar.
+-- param percent percent value from 1 to 100. -- @function [parent=#LoadingBar] setPercent -- @param self --- @param #float float +-- @param #float percent -------------------------------- +-- Load texture for loadingbar.
+-- param texture file name of texture.
+-- param texType @see TextureResType -- @function [parent=#LoadingBar] loadTexture -- @param self --- @param #string str --- @param #int texturerestype +-- @param #string texture +-- @param #int texType -------------------------------- +-- Changes the progress direction of loadingbar.
+-- see Direction LEFT means progress left to right, RIGHT otherwise.
+-- param direction Direction -- @function [parent=#LoadingBar] setDirection -- @param self -- @param #int direction -------------------------------- +-- Sets if loadingbar is using scale9 renderer.
+-- param enabled true that using scale9 renderer, false otherwise. -- @function [parent=#LoadingBar] setScale9Enabled -- @param self --- @param #bool bool +-- @param #bool enabled -------------------------------- +-- Sets capinsets for loadingbar, if loadingbar is using scale9 renderer.
+-- param capInsets capinsets for loadingbar -- @function [parent=#LoadingBar] setCapInsets -- @param self --- @param #rect_table rect +-- @param #rect_table capInsets -------------------------------- +-- Gets the progress direction of loadingbar.
+-- see Direction LEFT means progress left to right, RIGHT otherwise.
+-- return Direction -- @function [parent=#LoadingBar] getDirection -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- -- @function [parent=#LoadingBar] getCapInsets -- @param self -- @return rect_table#rect_table ret (return value: rect_table) -------------------------------- +-- -- @function [parent=#LoadingBar] isScale9Enabled -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- Gets the progress direction of loadingbar.
+-- return percent value from 1 to 100. -- @function [parent=#LoadingBar] getPercent -- @param self -- @return float#float ret (return value: float) @@ -55,36 +74,42 @@ -- @overload self -- @function [parent=#LoadingBar] create -- @param self --- @param #string str --- @param #float float +-- @param #string textureName +-- @param #float percentage -- @return LoadingBar#LoadingBar ret (retunr value: ccui.LoadingBar) -------------------------------- +-- -- @function [parent=#LoadingBar] createInstance -- @param self -- @return Ref#Ref ret (return value: cc.Ref) -------------------------------- +-- -- @function [parent=#LoadingBar] getVirtualRenderer -- @param self -- @return Node#Node ret (return value: cc.Node) -------------------------------- +-- Returns the "class name" of widget. -- @function [parent=#LoadingBar] getDescription -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- -- @function [parent=#LoadingBar] getVirtualRendererSize -- @param self -- @return size_table#size_table ret (return value: size_table) -------------------------------- +-- -- @function [parent=#LoadingBar] ignoreContentAdaptWithSize -- @param self --- @param #bool bool +-- @param #bool ignore -------------------------------- +-- Default constructor -- @function [parent=#LoadingBar] LoadingBar -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/Menu.lua b/cocos/scripting/lua-bindings/auto/api/Menu.lua index 3a228e3443..9c5f8e0bc4 100644 --- a/cocos/scripting/lua-bindings/auto/api/Menu.lua +++ b/cocos/scripting/lua-bindings/auto/api/Menu.lua @@ -5,30 +5,38 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#Menu] setEnabled -- @param self --- @param #bool bool +-- @param #bool value -------------------------------- +-- align items vertically -- @function [parent=#Menu] alignItemsVertically -- @param self -------------------------------- +-- -- @function [parent=#Menu] isEnabled -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- align items horizontally with padding
+-- since v0.7.2 -- @function [parent=#Menu] alignItemsHorizontallyWithPadding -- @param self --- @param #float float +-- @param #float padding -------------------------------- +-- align items vertically with padding
+-- since v0.7.2 -- @function [parent=#Menu] alignItemsVerticallyWithPadding -- @param self --- @param #float float +-- @param #float padding -------------------------------- +-- align items horizontally -- @function [parent=#Menu] alignItemsHorizontally -- @param self @@ -39,29 +47,33 @@ -- @overload self, cc.Node, int, string -- @function [parent=#Menu] addChild -- @param self --- @param #cc.Node node --- @param #int int --- @param #string str +-- @param #cc.Node child +-- @param #int zOrder +-- @param #string name -------------------------------- +-- -- @function [parent=#Menu] isOpacityModifyRGB -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#Menu] getDescription -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- -- @function [parent=#Menu] setOpacityModifyRGB -- @param self --- @param #bool bool +-- @param #bool bValue -------------------------------- +-- -- @function [parent=#Menu] removeChild -- @param self --- @param #cc.Node node --- @param #bool bool +-- @param #cc.Node child +-- @param #bool cleanup return nil diff --git a/cocos/scripting/lua-bindings/auto/api/MenuItem.lua b/cocos/scripting/lua-bindings/auto/api/MenuItem.lua index 12a0238e4c..b525b9112c 100644 --- a/cocos/scripting/lua-bindings/auto/api/MenuItem.lua +++ b/cocos/scripting/lua-bindings/auto/api/MenuItem.lua @@ -5,38 +5,46 @@ -- @parent_module cc -------------------------------- +-- enables or disables the item -- @function [parent=#MenuItem] setEnabled -- @param self --- @param #bool bool +-- @param #bool value -------------------------------- +-- Activate the item -- @function [parent=#MenuItem] activate -- @param self -------------------------------- +-- returns whether or not the item is enabled -- @function [parent=#MenuItem] isEnabled -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- The item was selected (not activated), similar to "mouse-over" -- @function [parent=#MenuItem] selected -- @param self -------------------------------- +-- returns whether or not the item is selected -- @function [parent=#MenuItem] isSelected -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- The item was unselected -- @function [parent=#MenuItem] unselected -- @param self -------------------------------- +-- Returns the outside box -- @function [parent=#MenuItem] rect -- @param self -- @return rect_table#rect_table ret (return value: rect_table) -------------------------------- +-- -- @function [parent=#MenuItem] getDescription -- @param self -- @return string#string ret (return value: string) diff --git a/cocos/scripting/lua-bindings/auto/api/MenuItemFont.lua b/cocos/scripting/lua-bindings/auto/api/MenuItemFont.lua index 7f0c2f5767..fd9baf15a8 100644 --- a/cocos/scripting/lua-bindings/auto/api/MenuItemFont.lua +++ b/cocos/scripting/lua-bindings/auto/api/MenuItemFont.lua @@ -5,43 +5,59 @@ -- @parent_module cc -------------------------------- +-- get font size
+-- js getFontSize -- @function [parent=#MenuItemFont] getFontSizeObj -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- returns the name of the Font
+-- js getFontNameObj -- @function [parent=#MenuItemFont] getFontNameObj -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- set font size
+-- c++ can not overload static and non-static member functions with the same parameter types
+-- so change the name to setFontSizeObj
+-- js setFontSize -- @function [parent=#MenuItemFont] setFontSizeObj -- @param self --- @param #int int +-- @param #int size -------------------------------- +-- set the font name
+-- c++ can not overload static and non-static member functions with the same parameter types
+-- so change the name to setFontNameObj
+-- js setFontName -- @function [parent=#MenuItemFont] setFontNameObj -- @param self --- @param #string str +-- @param #string name -------------------------------- +-- set the default font name -- @function [parent=#MenuItemFont] setFontName -- @param self --- @param #string str +-- @param #string name -------------------------------- +-- get default font size -- @function [parent=#MenuItemFont] getFontSize -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- get the default font name -- @function [parent=#MenuItemFont] getFontName -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- set default font size -- @function [parent=#MenuItemFont] setFontSize -- @param self --- @param #int int +-- @param #int size return nil diff --git a/cocos/scripting/lua-bindings/auto/api/MenuItemImage.lua b/cocos/scripting/lua-bindings/auto/api/MenuItemImage.lua index 81b37760cd..bdad1c852f 100644 --- a/cocos/scripting/lua-bindings/auto/api/MenuItemImage.lua +++ b/cocos/scripting/lua-bindings/auto/api/MenuItemImage.lua @@ -5,18 +5,21 @@ -- @parent_module cc -------------------------------- +-- sets the sprite frame for the disabled image -- @function [parent=#MenuItemImage] setDisabledSpriteFrame -- @param self --- @param #cc.SpriteFrame spriteframe +-- @param #cc.SpriteFrame frame -------------------------------- +-- sets the sprite frame for the selected image -- @function [parent=#MenuItemImage] setSelectedSpriteFrame -- @param self --- @param #cc.SpriteFrame spriteframe +-- @param #cc.SpriteFrame frame -------------------------------- +-- sets the sprite frame for the normal image -- @function [parent=#MenuItemImage] setNormalSpriteFrame -- @param self --- @param #cc.SpriteFrame spriteframe +-- @param #cc.SpriteFrame frame return nil diff --git a/cocos/scripting/lua-bindings/auto/api/MenuItemLabel.lua b/cocos/scripting/lua-bindings/auto/api/MenuItemLabel.lua index 177d9f914b..9048226099 100644 --- a/cocos/scripting/lua-bindings/auto/api/MenuItemLabel.lua +++ b/cocos/scripting/lua-bindings/auto/api/MenuItemLabel.lua @@ -5,44 +5,53 @@ -- @parent_module cc -------------------------------- +-- Gets the color that will be used to disable the item -- @function [parent=#MenuItemLabel] getDisabledColor -- @param self -- @return color3b_table#color3b_table ret (return value: color3b_table) -------------------------------- +-- sets a new string to the inner label -- @function [parent=#MenuItemLabel] setString -- @param self --- @param #string str +-- @param #string label -------------------------------- +-- Sets the label that is rendered. -- @function [parent=#MenuItemLabel] setLabel -- @param self -- @param #cc.Node node -------------------------------- +-- Sets the color that will be used to disable the item -- @function [parent=#MenuItemLabel] setDisabledColor -- @param self --- @param #color3b_table color3b +-- @param #color3b_table color -------------------------------- +-- Gets the label that is rendered. -- @function [parent=#MenuItemLabel] getLabel -- @param self -- @return Node#Node ret (return value: cc.Node) -------------------------------- +-- -- @function [parent=#MenuItemLabel] setEnabled -- @param self --- @param #bool bool +-- @param #bool enabled -------------------------------- +-- -- @function [parent=#MenuItemLabel] activate -- @param self -------------------------------- +-- -- @function [parent=#MenuItemLabel] unselected -- @param self -------------------------------- +-- -- @function [parent=#MenuItemLabel] selected -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/MenuItemSprite.lua b/cocos/scripting/lua-bindings/auto/api/MenuItemSprite.lua index 881f690df1..5af7c2fd8e 100644 --- a/cocos/scripting/lua-bindings/auto/api/MenuItemSprite.lua +++ b/cocos/scripting/lua-bindings/auto/api/MenuItemSprite.lua @@ -5,45 +5,54 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#MenuItemSprite] setEnabled -- @param self --- @param #bool bool +-- @param #bool bEnabled -------------------------------- +-- since v0.99.5 -- @function [parent=#MenuItemSprite] selected -- @param self -------------------------------- +-- Sets the image used when the item is not selected -- @function [parent=#MenuItemSprite] setNormalImage -- @param self --- @param #cc.Node node +-- @param #cc.Node image -------------------------------- +-- Sets the image used when the item is disabled -- @function [parent=#MenuItemSprite] setDisabledImage -- @param self --- @param #cc.Node node +-- @param #cc.Node image -------------------------------- +-- Sets the image used when the item is selected -- @function [parent=#MenuItemSprite] setSelectedImage -- @param self --- @param #cc.Node node +-- @param #cc.Node image -------------------------------- +-- Gets the image used when the item is disabled -- @function [parent=#MenuItemSprite] getDisabledImage -- @param self -- @return Node#Node ret (return value: cc.Node) -------------------------------- +-- Gets the image used when the item is selected -- @function [parent=#MenuItemSprite] getSelectedImage -- @param self -- @return Node#Node ret (return value: cc.Node) -------------------------------- +-- Gets the image used when the item is not selected -- @function [parent=#MenuItemSprite] getNormalImage -- @param self -- @return Node#Node ret (return value: cc.Node) -------------------------------- +-- -- @function [parent=#MenuItemSprite] unselected -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/MenuItemToggle.lua b/cocos/scripting/lua-bindings/auto/api/MenuItemToggle.lua index 7442feb1b5..a2e32d4499 100644 --- a/cocos/scripting/lua-bindings/auto/api/MenuItemToggle.lua +++ b/cocos/scripting/lua-bindings/auto/api/MenuItemToggle.lua @@ -5,44 +5,53 @@ -- @parent_module cc -------------------------------- +-- Sets the array that contains the subitems. -- @function [parent=#MenuItemToggle] setSubItems -- @param self --- @param #array_table array +-- @param #array_table items -------------------------------- +-- Gets the index of the selected item -- @function [parent=#MenuItemToggle] getSelectedIndex -- @param self -- @return unsigned int#unsigned int ret (return value: unsigned int) -------------------------------- +-- add more menu item -- @function [parent=#MenuItemToggle] addSubItem -- @param self --- @param #cc.MenuItem menuitem +-- @param #cc.MenuItem item -------------------------------- +-- return the selected item -- @function [parent=#MenuItemToggle] getSelectedItem -- @param self -- @return MenuItem#MenuItem ret (return value: cc.MenuItem) -------------------------------- +-- Sets the index of the selected item -- @function [parent=#MenuItemToggle] setSelectedIndex -- @param self --- @param #unsigned int int +-- @param #unsigned int index -------------------------------- +-- -- @function [parent=#MenuItemToggle] setEnabled -- @param self --- @param #bool bool +-- @param #bool var -------------------------------- +-- -- @function [parent=#MenuItemToggle] activate -- @param self -------------------------------- +-- -- @function [parent=#MenuItemToggle] unselected -- @param self -------------------------------- +-- -- @function [parent=#MenuItemToggle] selected -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/Mesh.lua b/cocos/scripting/lua-bindings/auto/api/Mesh.lua index b9b817d4f2..2b58a7a1dc 100644 --- a/cocos/scripting/lua-bindings/auto/api/Mesh.lua +++ b/cocos/scripting/lua-bindings/auto/api/Mesh.lua @@ -5,6 +5,7 @@ -- @parent_module cc -------------------------------- +-- get mesh vertex attribute count -- @function [parent=#Mesh] getMeshVertexAttribCount -- @param self -- @return long#long ret (return value: long) @@ -14,93 +15,110 @@ -- @overload self, string -- @function [parent=#Mesh] setTexture -- @param self --- @param #string str +-- @param #string texPath -------------------------------- +-- mesh index data getter -- @function [parent=#Mesh] getMeshIndexData -- @param self -- @return MeshIndexData#MeshIndexData ret (return value: cc.MeshIndexData) -------------------------------- +-- -- @function [parent=#Mesh] getTexture -- @param self -- @return Texture2D#Texture2D ret (return value: cc.Texture2D) -------------------------------- +-- skin getter -- @function [parent=#Mesh] getSkin -- @param self -- @return MeshSkin#MeshSkin ret (return value: cc.MeshSkin) -------------------------------- +-- name getter -- @function [parent=#Mesh] getName -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- -- @function [parent=#Mesh] setBlendFunc -- @param self --- @param #cc.BlendFunc blendfunc +-- @param #cc.BlendFunc blendFunc -------------------------------- +-- get index format -- @function [parent=#Mesh] getIndexFormat -- @param self -- @return unsigned int#unsigned int ret (return value: unsigned int) -------------------------------- +-- get per vertex size in bytes -- @function [parent=#Mesh] getVertexSizeInBytes -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- -- @function [parent=#Mesh] getBlendFunc -- @param self -- @return BlendFunc#BlendFunc ret (return value: cc.BlendFunc) -------------------------------- +-- get GLProgramState -- @function [parent=#Mesh] getGLProgramState -- @param self -- @return GLProgramState#GLProgramState ret (return value: cc.GLProgramState) -------------------------------- +-- get index count -- @function [parent=#Mesh] getIndexCount -- @param self -- @return long#long ret (return value: long) -------------------------------- +-- get vertex buffer -- @function [parent=#Mesh] getVertexBuffer -- @param self -- @return unsigned int#unsigned int ret (return value: unsigned int) -------------------------------- +-- get MeshVertexAttribute by index -- @function [parent=#Mesh] getMeshVertexAttribute -- @param self --- @param #int int +-- @param #int idx -- @return MeshVertexAttrib#MeshVertexAttrib ret (return value: cc.MeshVertexAttrib) -------------------------------- +-- -- @function [parent=#Mesh] isVisible -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- get index buffer -- @function [parent=#Mesh] getIndexBuffer -- @param self -- @return unsigned int#unsigned int ret (return value: unsigned int) -------------------------------- +-- has vertex attribute? -- @function [parent=#Mesh] hasVertexAttrib -- @param self --- @param #int int +-- @param #int attrib -- @return bool#bool ret (return value: bool) -------------------------------- +-- get primitive type -- @function [parent=#Mesh] getPrimitiveType -- @param self -- @return unsigned int#unsigned int ret (return value: unsigned int) -------------------------------- +-- visible getter and setter -- @function [parent=#Mesh] setVisible -- @param self --- @param #bool bool +-- @param #bool visible return nil diff --git a/cocos/scripting/lua-bindings/auto/api/MotionStreak.lua b/cocos/scripting/lua-bindings/auto/api/MotionStreak.lua index 47f6c9dbeb..63d586f109 100644 --- a/cocos/scripting/lua-bindings/auto/api/MotionStreak.lua +++ b/cocos/scripting/lua-bindings/auto/api/MotionStreak.lua @@ -5,92 +5,108 @@ -- @parent_module cc -------------------------------- +-- Remove all living segments of the ribbon -- @function [parent=#MotionStreak] reset -- @param self -------------------------------- +-- -- @function [parent=#MotionStreak] setTexture -- @param self --- @param #cc.Texture2D texture2d +-- @param #cc.Texture2D texture -------------------------------- +-- -- @function [parent=#MotionStreak] getTexture -- @param self -- @return Texture2D#Texture2D ret (return value: cc.Texture2D) -------------------------------- +-- color used for the tint -- @function [parent=#MotionStreak] tintWithColor -- @param self --- @param #color3b_table color3b +-- @param #color3b_table colors -------------------------------- +-- -- @function [parent=#MotionStreak] setStartingPositionInitialized -- @param self --- @param #bool bool +-- @param #bool bStartingPositionInitialized -------------------------------- +-- -- @function [parent=#MotionStreak] isStartingPositionInitialized -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- When fast mode is enabled, new points are added faster but with lower precision -- @function [parent=#MotionStreak] isFastMode -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#MotionStreak] setFastMode -- @param self --- @param #bool bool +-- @param #bool bFastMode -------------------------------- -- @overload self, float, float, float, color3b_table, cc.Texture2D -- @overload self, float, float, float, color3b_table, string -- @function [parent=#MotionStreak] create -- @param self --- @param #float float --- @param #float float --- @param #float float --- @param #color3b_table color3b --- @param #string str +-- @param #float fade +-- @param #float minSeg +-- @param #float stroke +-- @param #color3b_table color +-- @param #string path -- @return MotionStreak#MotionStreak ret (retunr value: cc.MotionStreak) -------------------------------- +-- -- @function [parent=#MotionStreak] isOpacityModifyRGB -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#MotionStreak] setPositionY -- @param self --- @param #float float +-- @param #float y -------------------------------- +-- -- @function [parent=#MotionStreak] setPositionX -- @param self --- @param #float float +-- @param #float x -------------------------------- +-- -- @function [parent=#MotionStreak] getPositionY -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#MotionStreak] getPositionX -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#MotionStreak] setOpacity -- @param self --- @param #unsigned char char +-- @param #unsigned char opacity -------------------------------- +-- -- @function [parent=#MotionStreak] setOpacityModifyRGB -- @param self --- @param #bool bool +-- @param #bool value -------------------------------- +-- -- @function [parent=#MotionStreak] getOpacity -- @param self -- @return unsigned char#unsigned char ret (return value: unsigned char) @@ -100,15 +116,15 @@ -- @overload self, vec2_table -- @function [parent=#MotionStreak] setPosition -- @param self --- @param #float float --- @param #float float +-- @param #float x +-- @param #float y -------------------------------- -- @overload self, float, float -- @overload self -- @function [parent=#MotionStreak] getPosition -- @param self --- @param #float float --- @param #float float +-- @param #float x +-- @param #float y return nil diff --git a/cocos/scripting/lua-bindings/auto/api/MoveBy.lua b/cocos/scripting/lua-bindings/auto/api/MoveBy.lua index c478aff92a..ee6d677fce 100644 --- a/cocos/scripting/lua-bindings/auto/api/MoveBy.lua +++ b/cocos/scripting/lua-bindings/auto/api/MoveBy.lua @@ -5,30 +5,35 @@ -- @parent_module cc -------------------------------- +-- creates the action -- @function [parent=#MoveBy] create -- @param self --- @param #float float --- @param #vec2_table vec2 +-- @param #float duration +-- @param #vec2_table deltaPosition -- @return MoveBy#MoveBy ret (return value: cc.MoveBy) -------------------------------- +-- -- @function [parent=#MoveBy] startWithTarget -- @param self --- @param #cc.Node node +-- @param #cc.Node target -------------------------------- +-- -- @function [parent=#MoveBy] clone -- @param self -- @return MoveBy#MoveBy ret (return value: cc.MoveBy) -------------------------------- +-- -- @function [parent=#MoveBy] reverse -- @param self -- @return MoveBy#MoveBy ret (return value: cc.MoveBy) -------------------------------- +-- -- @function [parent=#MoveBy] update -- @param self --- @param #float float +-- @param #float time return nil diff --git a/cocos/scripting/lua-bindings/auto/api/MoveTo.lua b/cocos/scripting/lua-bindings/auto/api/MoveTo.lua index 432c2baff3..0212565eda 100644 --- a/cocos/scripting/lua-bindings/auto/api/MoveTo.lua +++ b/cocos/scripting/lua-bindings/auto/api/MoveTo.lua @@ -5,18 +5,21 @@ -- @parent_module cc -------------------------------- +-- creates the action -- @function [parent=#MoveTo] create -- @param self --- @param #float float --- @param #vec2_table vec2 +-- @param #float duration +-- @param #vec2_table position -- @return MoveTo#MoveTo ret (return value: cc.MoveTo) -------------------------------- +-- -- @function [parent=#MoveTo] startWithTarget -- @param self --- @param #cc.Node node +-- @param #cc.Node target -------------------------------- +-- -- @function [parent=#MoveTo] clone -- @param self -- @return MoveTo#MoveTo ret (return value: cc.MoveTo) diff --git a/cocos/scripting/lua-bindings/auto/api/MovementBoneData.lua b/cocos/scripting/lua-bindings/auto/api/MovementBoneData.lua index 89f032a8ad..c6c456be00 100644 --- a/cocos/scripting/lua-bindings/auto/api/MovementBoneData.lua +++ b/cocos/scripting/lua-bindings/auto/api/MovementBoneData.lua @@ -5,27 +5,32 @@ -- @parent_module ccs -------------------------------- +-- -- @function [parent=#MovementBoneData] init -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#MovementBoneData] getFrameData -- @param self --- @param #int int +-- @param #int index -- @return FrameData#FrameData ret (return value: ccs.FrameData) -------------------------------- +-- -- @function [parent=#MovementBoneData] addFrameData -- @param self --- @param #ccs.FrameData framedata +-- @param #ccs.FrameData frameData -------------------------------- +-- -- @function [parent=#MovementBoneData] create -- @param self -- @return MovementBoneData#MovementBoneData ret (return value: ccs.MovementBoneData) -------------------------------- +-- js ctor -- @function [parent=#MovementBoneData] MovementBoneData -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/MovementData.lua b/cocos/scripting/lua-bindings/auto/api/MovementData.lua index 0e79adf323..3bc6b1b16a 100644 --- a/cocos/scripting/lua-bindings/auto/api/MovementData.lua +++ b/cocos/scripting/lua-bindings/auto/api/MovementData.lua @@ -5,22 +5,26 @@ -- @parent_module ccs -------------------------------- +-- -- @function [parent=#MovementData] getMovementBoneData -- @param self --- @param #string str +-- @param #string boneName -- @return MovementBoneData#MovementBoneData ret (return value: ccs.MovementBoneData) -------------------------------- +-- -- @function [parent=#MovementData] addMovementBoneData -- @param self --- @param #ccs.MovementBoneData movementbonedata +-- @param #ccs.MovementBoneData movBoneData -------------------------------- +-- -- @function [parent=#MovementData] create -- @param self -- @return MovementData#MovementData ret (return value: ccs.MovementData) -------------------------------- +-- js ctor -- @function [parent=#MovementData] MovementData -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/Node.lua b/cocos/scripting/lua-bindings/auto/api/Node.lua index e97163ead5..3fc9d7d51d 100644 --- a/cocos/scripting/lua-bindings/auto/api/Node.lua +++ b/cocos/scripting/lua-bindings/auto/api/Node.lua @@ -11,42 +11,57 @@ -- @overload self, cc.Node, int, string -- @function [parent=#Node] addChild -- @param self --- @param #cc.Node node --- @param #int int --- @param #string str +-- @param #cc.Node child +-- @param #int localZOrder +-- @param #string name -------------------------------- -- @overload self, cc.Component -- @overload self, string -- @function [parent=#Node] removeComponent -- @param self --- @param #string str +-- @param #string name -- @return bool#bool ret (retunr value: bool) -------------------------------- +-- set the PhysicsBody that let the sprite effect with physics
+-- note This method will set anchor point to Vec2::ANCHOR_MIDDLE if body not null, and you cann't change anchor point if node has a physics body. -- @function [parent=#Node] setPhysicsBody -- @param self --- @param #cc.PhysicsBody physicsbody +-- @param #cc.PhysicsBody body -------------------------------- +-- Gets the description string. It makes debugging easier.
+-- return A string
+-- js NA
+-- lua NA -- @function [parent=#Node] getDescription -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- Sets the Y rotation (angle) of the node in degrees which performs a vertical rotational skew.
+-- The difference between `setRotationalSkew()` and `setSkew()` is that the first one simulate Flash's skew functionality
+-- while the second one uses the real skew function.
+-- 0 is the default rotation angle.
+-- Positive values rotate node clockwise, and negative values for anti-clockwise.
+-- param rotationY The Y rotation in degrees.
+-- warning The physics body doesn't support this. -- @function [parent=#Node] setRotationSkewY -- @param self --- @param #float float +-- @param #float rotationY -------------------------------- +-- -- @function [parent=#Node] setOpacityModifyRGB -- @param self --- @param #bool bool +-- @param #bool value -------------------------------- +-- -- @function [parent=#Node] setCascadeOpacityEnabled -- @param self --- @param #bool bool +-- @param #bool cascadeOpacityEnabled -------------------------------- -- @overload self @@ -56,159 +71,237 @@ -- @return array_table#array_table ret (retunr value: array_table) -------------------------------- +-- -- @function [parent=#Node] setOnExitCallback -- @param self --- @param #function func +-- @param #function callback -------------------------------- +-- Pauses all scheduled selectors, actions and event listeners..
+-- This method is called internally by onExit -- @function [parent=#Node] pause -- @param self -------------------------------- +-- Converts a local Vec2 to world space coordinates.The result is in Points.
+-- treating the returned/received node point as anchor relative. -- @function [parent=#Node] convertToWorldSpaceAR -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table nodePoint -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- Gets whether the anchor point will be (0,0) when you position this node.
+-- see `ignoreAnchorPointForPosition(bool)`
+-- return true if the anchor point will be (0,0) when you position this node. -- @function [parent=#Node] isIgnoreAnchorPointForPosition -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- Gets a child from the container with its name
+-- param name An identifier to find the child node.
+-- return a Node object whose name equals to the input parameter
+-- since v3.2 -- @function [parent=#Node] getChildByName -- @param self --- @param #string str +-- @param #string name -- @return Node#Node ret (return value: cc.Node) -------------------------------- +-- -- @function [parent=#Node] updateDisplayedOpacity -- @param self --- @param #unsigned char char +-- @param #unsigned char parentOpacity -------------------------------- +-- get & set camera mask, the node is visible by the camera whose camera flag & node's camera mask is true -- @function [parent=#Node] getCameraMask -- @param self -- @return unsigned short#unsigned short ret (return value: unsigned short) -------------------------------- +-- Sets the rotation (angle) of the node in degrees.
+-- 0 is the default rotation angle.
+-- Positive values rotate node clockwise, and negative values for anti-clockwise.
+-- param rotation The rotation of the node in degrees. -- @function [parent=#Node] setRotation -- @param self --- @param #float float +-- @param #float rotation -------------------------------- +-- Changes the scale factor on Z axis of this node
+-- The Default value is 1.0 if you haven't changed it before.
+-- param scaleY The scale factor on Y axis.
+-- warning The physics body doesn't support this. -- @function [parent=#Node] setScaleZ -- @param self --- @param #float float +-- @param #float scaleZ -------------------------------- +-- Sets the scale (y) of the node.
+-- It is a scaling factor that multiplies the height of the node and its children.
+-- param scaleY The scale factor on Y axis.
+-- warning The physics body doesn't support this. -- @function [parent=#Node] setScaleY -- @param self --- @param #float float +-- @param #float scaleY -------------------------------- +-- Sets the scale (x) of the node.
+-- It is a scaling factor that multiplies the width of the node and its children.
+-- param scaleX The scale factor on X axis.
+-- warning The physics body doesn't support this. -- @function [parent=#Node] setScaleX -- @param self --- @param #float float +-- @param #float scaleX -------------------------------- +-- Sets the X rotation (angle) of the node in degrees which performs a horizontal rotational skew.
+-- The difference between `setRotationalSkew()` and `setSkew()` is that the first one simulate Flash's skew functionality
+-- while the second one uses the real skew function.
+-- 0 is the default rotation angle.
+-- Positive values rotate node clockwise, and negative values for anti-clockwise.
+-- param rotationX The X rotation in degrees which performs a horizontal rotational skew.
+-- warning The physics body doesn't support this. -- @function [parent=#Node] setRotationSkewX -- @param self --- @param #float float +-- @param #float rotationX -------------------------------- +-- -- @function [parent=#Node] setonEnterTransitionDidFinishCallback -- @param self --- @param #function func +-- @param #function callback -------------------------------- +-- removes all components -- @function [parent=#Node] removeAllComponents -- @param self -------------------------------- +-- -- @function [parent=#Node] _setLocalZOrder -- @param self --- @param #int int +-- @param #int z -------------------------------- +-- -- @function [parent=#Node] setCameraMask -- @param self --- @param #unsigned short short --- @param #bool bool +-- @param #unsigned short mask +-- @param #bool applyChildren -------------------------------- +-- Returns a tag that is used to identify the node easily.
+-- return An integer that identifies the node.
+-- Please use `getTag()` instead. -- @function [parent=#Node] getTag -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- / @{/ @name GLProgram
+-- Return the GLProgram (shader) currently used for this node
+-- return The GLProgram (shader) currently used for this node -- @function [parent=#Node] getGLProgram -- @param self -- @return GLProgram#GLProgram ret (return value: cc.GLProgram) -------------------------------- +-- Returns the world affine transform matrix. The matrix is in Pixels. -- @function [parent=#Node] getNodeToWorldTransform -- @param self -- @return mat4_table#mat4_table ret (return value: mat4_table) -------------------------------- +-- returns the position (X,Y,Z) in its parent's coordinate system -- @function [parent=#Node] getPosition3D -- @param self -- @return vec3_table#vec3_table ret (return value: vec3_table) -------------------------------- +-- Removes a child from the container. It will also cleanup all running actions depending on the cleanup parameter.
+-- param child The child node which will be removed.
+-- param cleanup true if all running actions and callbacks on the child node will be cleanup, false otherwise. -- @function [parent=#Node] removeChild -- @param self --- @param #cc.Node node --- @param #bool bool +-- @param #cc.Node child +-- @param #bool cleanup -------------------------------- +-- Converts a Vec2 to world space coordinates. The result is in Points. -- @function [parent=#Node] convertToWorldSpace -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table nodePoint -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- Returns the Scene that contains the Node.
+-- It returns `nullptr` if the node doesn't belong to any Scene.
+-- This function recursively calls parent->getScene() until parent is a Scene object. The results are not cached. It is that the user caches the results in case this functions is being used inside a loop. -- @function [parent=#Node] getScene -- @param self -- @return Scene#Scene ret (return value: cc.Scene) -------------------------------- +-- -- @function [parent=#Node] getEventDispatcher -- @param self -- @return EventDispatcher#EventDispatcher ret (return value: cc.EventDispatcher) -------------------------------- +-- Changes the X skew angle of the node in degrees.
+-- The difference between `setRotationalSkew()` and `setSkew()` is that the first one simulate Flash's skew functionality
+-- while the second one uses the real skew function.
+-- This angle describes the shear distortion in the X direction.
+-- Thus, it is the angle between the Y coordinate and the left edge of the shape
+-- The default skewX angle is 0. Positive values distort the node in a CW direction.
+-- param skewX The X skew angle of the node in degrees.
+-- warning The physics body doesn't support this. -- @function [parent=#Node] setSkewX -- @param self --- @param #float float +-- @param #float skewX -------------------------------- +-- -- @function [parent=#Node] setGLProgramState -- @param self --- @param #cc.GLProgramState glprogramstate +-- @param #cc.GLProgramState glProgramState -------------------------------- +-- -- @function [parent=#Node] setOnEnterCallback -- @param self --- @param #function func +-- @param #function callback -------------------------------- +-- -- @function [parent=#Node] getOpacity -- @param self -- @return unsigned char#unsigned char ret (return value: unsigned char) -------------------------------- +-- Sets the position (x,y) using values between 0 and 1.
+-- The positions in pixels is calculated like the following:
+-- code pseudo code
+-- void setNormalizedPosition(Vec2 pos) {
+-- Size s = getParent()->getContentSize();
+-- _position = pos * s;
+-- }
+-- endcode -- @function [parent=#Node] setNormalizedPosition -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table position -------------------------------- +-- -- @function [parent=#Node] setonExitTransitionDidStartCallback -- @param self --- @param #function func +-- @param #function callback -------------------------------- +-- convenience methods which take a Touch instead of Vec2 -- @function [parent=#Node] convertTouchToNodeSpace -- @param self -- @param #cc.Touch touch @@ -219,55 +312,70 @@ -- @overload self -- @function [parent=#Node] removeAllChildrenWithCleanup -- @param self --- @param #bool bool +-- @param #bool cleanup -------------------------------- +-- -- @function [parent=#Node] getNodeToParentAffineTransform -- @param self -- @return AffineTransform#AffineTransform ret (return value: cc.AffineTransform) -------------------------------- +-- -- @function [parent=#Node] isCascadeOpacityEnabled -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- Sets the parent node
+-- param parent A pointer to the parent node -- @function [parent=#Node] setParent -- @param self --- @param #cc.Node node +-- @param #cc.Node parent -------------------------------- +-- Returns a string that is used to identify the node.
+-- return A string that identifies the node.
+-- since v3.2 -- @function [parent=#Node] getName -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- returns the rotation (X,Y,Z) in degrees. -- @function [parent=#Node] getRotation3D -- @param self -- @return vec3_table#vec3_table ret (return value: vec3_table) -------------------------------- +-- Returns the matrix that transform the node's (local) space coordinates into the parent's space coordinates.
+-- The matrix is in Pixels. -- @function [parent=#Node] getNodeToParentTransform -- @param self -- @return mat4_table#mat4_table ret (return value: mat4_table) -------------------------------- +-- converts a Touch (world coordinates) into a local coordinate. This method is AR (Anchor Relative). -- @function [parent=#Node] convertTouchToNodeSpaceAR -- @param self -- @param #cc.Touch touch -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- Converts a Vec2 to node (local) space coordinates. The result is in Points. -- @function [parent=#Node] convertToNodeSpace -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table worldPoint -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- Resumes all scheduled selectors, actions and event listeners.
+-- This method is called internally by onEnter -- @function [parent=#Node] resume -- @param self -------------------------------- +-- get the PhysicsBody the sprite have -- @function [parent=#Node] getPhysicsBody -- @param self -- @return PhysicsBody#PhysicsBody ret (return value: cc.PhysicsBody) @@ -277,108 +385,178 @@ -- @overload self, vec2_table -- @function [parent=#Node] setPosition -- @param self --- @param #float float --- @param #float float +-- @param #float x +-- @param #float y -------------------------------- +-- Removes an action from the running action list by its tag.
+-- param tag A tag that indicates the action to be removed. -- @function [parent=#Node] stopActionByTag -- @param self --- @param #int int +-- @param #int tag -------------------------------- +-- Reorders a child according to a new z value.
+-- param child An already added child node. It MUST be already added.
+-- param localZOrder Z order for drawing priority. Please refer to setLocalZOrder(int) -- @function [parent=#Node] reorderChild -- @param self --- @param #cc.Node node --- @param #int int +-- @param #cc.Node child +-- @param #int localZOrder -------------------------------- +-- Sets whether the anchor point will be (0,0) when you position this node.
+-- This is an internal method, only used by Layer and Scene. Don't call it outside framework.
+-- The default value is false, while in Layer and Scene are true
+-- param ignore true if anchor point will be (0,0) when you position this node
+-- todo This method should be renamed as setIgnoreAnchorPointForPosition(bool) or something with "set" -- @function [parent=#Node] ignoreAnchorPointForPosition -- @param self --- @param #bool bool +-- @param #bool ignore -------------------------------- +-- Changes the Y skew angle of the node in degrees.
+-- The difference between `setRotationalSkew()` and `setSkew()` is that the first one simulate Flash's skew functionality
+-- while the second one uses the real skew function.
+-- This angle describes the shear distortion in the Y direction.
+-- Thus, it is the angle between the X coordinate and the bottom edge of the shape
+-- The default skewY angle is 0. Positive values distort the node in a CCW direction.
+-- param skewY The Y skew angle of the node in degrees.
+-- warning The physics body doesn't support this. -- @function [parent=#Node] setSkewY -- @param self --- @param #float float +-- @param #float skewY -------------------------------- +-- Sets the 'z' coordinate in the position. It is the OpenGL Z vertex value.
+-- The OpenGL depth buffer and depth testing are disabled by default. You need to turn them on
+-- in order to use this property correctly.
+-- `setPositionZ()` also sets the `setGlobalZValue()` with the positionZ as value.
+-- see `setGlobalZValue()`
+-- param vertexZ OpenGL Z vertex of this node. -- @function [parent=#Node] setPositionZ -- @param self --- @param #float float +-- @param #float positionZ -------------------------------- +-- Sets the rotation (X,Y,Z) in degrees.
+-- Useful for 3d rotations
+-- warning The physics body doesn't support this. -- @function [parent=#Node] setRotation3D -- @param self --- @param #vec3_table vec3 +-- @param #vec3_table rotation -------------------------------- +-- Gets/Sets x or y coordinate individually for position.
+-- These methods are used in Lua and Javascript Bindings -- @function [parent=#Node] setPositionX -- @param self --- @param #float float +-- @param #float x -------------------------------- +-- Sets the Transformation matrix manually. -- @function [parent=#Node] setNodeToParentTransform -- @param self --- @param #mat4_table mat4 +-- @param #mat4_table transform -------------------------------- +-- Returns the anchor point in percent.
+-- see `setAnchorPoint(const Vec2&)`
+-- return The anchor point of node. -- @function [parent=#Node] getAnchorPoint -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- Returns the numbers of actions that are running plus the ones that are schedule to run (actions in actionsToAdd and actions arrays).
+-- Composable actions are counted as 1 action. Example:
+-- If you are running 1 Sequence of 7 actions, it will return 1.
+-- If you are running 7 Sequences of 2 actions, it will return 7.
+-- todo Rename to getNumberOfRunningActions()
+-- return The number of actions that are running plus the ones that are schedule to run -- @function [parent=#Node] getNumberOfRunningActions -- @param self -- @return long#long ret (return value: long) -------------------------------- +-- Calls children's updateTransform() method recursively.
+-- This method is moved from Sprite, so it's no longer specific to Sprite.
+-- As the result, you apply SpriteBatchNode's optimization on your customed Node.
+-- e.g., `batchNode->addChild(myCustomNode)`, while you can only addChild(sprite) before. -- @function [parent=#Node] updateTransform -- @param self -------------------------------- +-- Sets the shader program for this node
+-- Since v2.0, each rendering node must set its shader program.
+-- It should be set in initialize phase.
+-- code
+-- node->setGLrProgram(GLProgramCache::getInstance()->getProgram(GLProgram::SHADER_NAME_POSITION_TEXTURE_COLOR));
+-- endcode
+-- param shaderProgram The shader program -- @function [parent=#Node] setGLProgram -- @param self -- @param #cc.GLProgram glprogram -------------------------------- +-- Determines if the node is visible
+-- see `setVisible(bool)`
+-- return true if the node is visible, false if the node is hidden. -- @function [parent=#Node] isVisible -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- Returns the amount of children
+-- return The amount of children. -- @function [parent=#Node] getChildrenCount -- @param self -- @return long#long ret (return value: long) -------------------------------- +-- Converts a Vec2 to node (local) space coordinates. The result is in Points.
+-- treating the returned/received node point as anchor relative. -- @function [parent=#Node] convertToNodeSpaceAR -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table worldPoint -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- adds a component -- @function [parent=#Node] addComponent -- @param self -- @param #cc.Component component -- @return bool#bool ret (return value: bool) -------------------------------- +-- Executes an action, and returns the action that is executed.
+-- This node becomes the action's target. Refer to Action::getTarget()
+-- warning Actions don't retain their target.
+-- return An Action pointer -- @function [parent=#Node] runAction -- @param self -- @param #cc.Action action -- @return Action#Action ret (return value: cc.Action) -------------------------------- +-- -- @function [parent=#Node] isOpacityModifyRGB -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- Returns the rotation of the node in degrees.
+-- see `setRotation(float)`
+-- return The rotation of the node in degrees. -- @function [parent=#Node] getRotation -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- Returns the anchorPoint in absolute pixels.
+-- warning You can only read it. If you wish to modify it, use anchorPoint instead.
+-- see `getAnchorPoint()`
+-- return The anchor point in absolute pixels. -- @function [parent=#Node] getAnchorPointInPoints -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) @@ -389,68 +567,93 @@ -- @function [parent=#Node] visit -- @param self -- @param #cc.Renderer renderer --- @param #mat4_table mat4 --- @param #unsigned int int +-- @param #mat4_table parentTransform +-- @param #unsigned int parentFlags -------------------------------- +-- Removes a child from the container by tag value. It will also cleanup all running actions depending on the cleanup parameter
+-- param name A string that identifies a child node
+-- param cleanup true if all running actions and callbacks on the child node will be cleanup, false otherwise. -- @function [parent=#Node] removeChildByName -- @param self --- @param #string str --- @param #bool bool +-- @param #string name +-- @param #bool cleanup -------------------------------- +-- -- @function [parent=#Node] getGLProgramState -- @param self -- @return GLProgramState#GLProgramState ret (return value: cc.GLProgramState) -------------------------------- +-- Sets a Scheduler object that is used to schedule all "updates" and timers.
+-- warning If you set a new Scheduler, then previously created timers/update are going to be removed.
+-- param scheduler A Shdeduler object that is used to schedule all "update" and timers. -- @function [parent=#Node] setScheduler -- @param self -- @param #cc.Scheduler scheduler -------------------------------- +-- Stops and removes all actions from the running action list . -- @function [parent=#Node] stopAllActions -- @param self -------------------------------- +-- Returns the X skew angle of the node in degrees.
+-- see `setSkewX(float)`
+-- return The X skew angle of the node in degrees. -- @function [parent=#Node] getSkewX -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- Returns the Y skew angle of the node in degrees.
+-- see `setSkewY(float)`
+-- return The Y skew angle of the node in degrees. -- @function [parent=#Node] getSkewY -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#Node] getDisplayedColor -- @param self -- @return color3b_table#color3b_table ret (return value: color3b_table) -------------------------------- +-- Gets an action from the running action list by its tag.
+-- see `setTag(int)`, `getTag()`.
+-- return The action object with the given tag. -- @function [parent=#Node] getActionByTag -- @param self --- @param #int int +-- @param #int tag -- @return Action#Action ret (return value: cc.Action) -------------------------------- +-- Changes the name that is used to identify the node easily.
+-- param name A string that identifies the node.
+-- since v3.2 -- @function [parent=#Node] setName -- @param self --- @param #string str +-- @param #string name -------------------------------- -- @overload self, cc.AffineTransform -- @overload self, mat4_table -- @function [parent=#Node] setAdditionalTransform -- @param self --- @param #mat4_table mat4 +-- @param #mat4_table additionalTransform -------------------------------- +-- -- @function [parent=#Node] getDisplayedOpacity -- @param self -- @return unsigned char#unsigned char ret (return value: unsigned char) -------------------------------- +-- Gets the local Z order of this node.
+-- see `setLocalZOrder(int)`
+-- return The local (relative to its siblings) Z order. -- @function [parent=#Node] getLocalZOrder -- @param self -- @return int#int ret (return value: int) @@ -463,26 +666,37 @@ -- @return Scheduler#Scheduler ret (retunr value: cc.Scheduler) -------------------------------- +-- -- @function [parent=#Node] getParentToNodeAffineTransform -- @param self -- @return AffineTransform#AffineTransform ret (return value: cc.AffineTransform) -------------------------------- +-- Returns the arrival order, indicates which children is added previously.
+-- see `setOrderOfArrival(unsigned int)`
+-- return The arrival order. -- @function [parent=#Node] getOrderOfArrival -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- Sets the ActionManager object that is used by all actions.
+-- warning If you set a new ActionManager, then previously created actions will be removed.
+-- param actionManager A ActionManager object that is used by all actions. -- @function [parent=#Node] setActionManager -- @param self --- @param #cc.ActionManager actionmanager +-- @param #cc.ActionManager actionManager -------------------------------- +-- -- @function [parent=#Node] setColor -- @param self --- @param #color3b_table color3b +-- @param #color3b_table color -------------------------------- +-- Returns whether or not the node is "running".
+-- If the node is running it will accept event callbacks like onEnter(), onExit(), update()
+-- return Whether or not the node is running. -- @function [parent=#Node] isRunning -- @param self -- @return bool#bool ret (return value: bool) @@ -495,146 +709,218 @@ -- @return Node#Node ret (retunr value: cc.Node) -------------------------------- +-- Gets position Z coordinate of this node.
+-- see setPositionZ(float)
+-- return the position Z coordinate of this node. -- @function [parent=#Node] getPositionZ -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#Node] getPositionY -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#Node] getPositionX -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- Removes a child from the container by tag value. It will also cleanup all running actions depending on the cleanup parameter
+-- param tag An interger number that identifies a child node
+-- param cleanup true if all running actions and callbacks on the child node will be cleanup, false otherwise.
+-- Please use `removeChildByName` instead. -- @function [parent=#Node] removeChildByTag -- @param self --- @param #int int --- @param #bool bool +-- @param #int tag +-- @param #bool cleanup -------------------------------- +-- -- @function [parent=#Node] setPositionY -- @param self --- @param #float float +-- @param #float y -------------------------------- +-- -- @function [parent=#Node] getNodeToWorldAffineTransform -- @param self -- @return AffineTransform#AffineTransform ret (return value: cc.AffineTransform) -------------------------------- +-- -- @function [parent=#Node] updateDisplayedColor -- @param self --- @param #color3b_table color3b +-- @param #color3b_table parentColor -------------------------------- +-- Sets whether the node is visible
+-- The default value is true, a node is default to visible
+-- param visible true if the node is visible, false if the node is hidden. -- @function [parent=#Node] setVisible -- @param self --- @param #bool bool +-- @param #bool visible -------------------------------- +-- Returns the matrix that transform parent's space coordinates to the node's (local) space coordinates.
+-- The matrix is in Pixels. -- @function [parent=#Node] getParentToNodeTransform -- @param self -- @return mat4_table#mat4_table ret (return value: mat4_table) -------------------------------- +-- Defines the oder in which the nodes are renderer.
+-- Nodes that have a Global Z Order lower, are renderer first.
+-- In case two or more nodes have the same Global Z Order, the oder is not guaranteed.
+-- The only exception if the Nodes have a Global Z Order == 0. In that case, the Scene Graph order is used.
+-- By default, all nodes have a Global Z Order = 0. That means that by default, the Scene Graph order is used to render the nodes.
+-- Global Z Order is useful when you need to render nodes in an order different than the Scene Graph order.
+-- Limitations: Global Z Order can't be used used by Nodes that have SpriteBatchNode as one of their acenstors.
+-- And if ClippingNode is one of the ancestors, then "global Z order" will be relative to the ClippingNode.
+-- see `setLocalZOrder()`
+-- see `setVertexZ()`
+-- since v3.0 -- @function [parent=#Node] setGlobalZOrder -- @param self --- @param #float float +-- @param #float globalZOrder -------------------------------- -- @overload self, float, float -- @overload self, float -- @function [parent=#Node] setScale -- @param self --- @param #float float --- @param #float float +-- @param #float scaleX +-- @param #float scaleY -------------------------------- +-- Gets a child from the container with its tag
+-- param tag An identifier to find the child node.
+-- return a Node object whose tag equals to the input parameter
+-- Please use `getChildByName()` instead -- @function [parent=#Node] getChildByTag -- @param self --- @param #int int +-- @param #int tag -- @return Node#Node ret (return value: cc.Node) -------------------------------- +-- Sets the arrival order when this node has a same ZOrder with other children.
+-- A node which called addChild subsequently will take a larger arrival order,
+-- If two children have the same Z order, the child with larger arrival order will be drawn later.
+-- warning This method is used internally for localZOrder sorting, don't change this manually
+-- param orderOfArrival The arrival order. -- @function [parent=#Node] setOrderOfArrival -- @param self --- @param #int int +-- @param #int orderOfArrival -------------------------------- +-- Returns the scale factor on Z axis of this node
+-- see `setScaleZ(float)`
+-- return The scale factor on Z axis. -- @function [parent=#Node] getScaleZ -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- Returns the scale factor on Y axis of this node
+-- see `setScaleY(float)`
+-- return The scale factor on Y axis. -- @function [parent=#Node] getScaleY -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- Returns the scale factor on X axis of this node
+-- see setScaleX(float)
+-- return The scale factor on X axis. -- @function [parent=#Node] getScaleX -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- LocalZOrder is the 'key' used to sort the node relative to its siblings.
+-- The Node's parent will sort all its children based ont the LocalZOrder value.
+-- If two nodes have the same LocalZOrder, then the node that was added first to the children's array will be in front of the other node in the array.
+-- Also, the Scene Graph is traversed using the "In-Order" tree traversal algorithm ( http:en.wikipedia.org/wiki/Tree_traversal#In-order )
+-- And Nodes that have LocalZOder values < 0 are the "left" subtree
+-- While Nodes with LocalZOder >=0 are the "right" subtree.
+-- see `setGlobalZOrder`
+-- see `setVertexZ` -- @function [parent=#Node] setLocalZOrder -- @param self --- @param #int int +-- @param #int localZOrder -------------------------------- +-- -- @function [parent=#Node] getWorldToNodeAffineTransform -- @param self -- @return AffineTransform#AffineTransform ret (return value: cc.AffineTransform) -------------------------------- +-- -- @function [parent=#Node] setCascadeColorEnabled -- @param self --- @param #bool bool +-- @param #bool cascadeColorEnabled -------------------------------- +-- -- @function [parent=#Node] setOpacity -- @param self --- @param #unsigned char char +-- @param #unsigned char opacity -------------------------------- +-- Stops all running actions and schedulers -- @function [parent=#Node] cleanup -- @param self -------------------------------- +-- / @{/ @name component functions
+-- gets a component by its name -- @function [parent=#Node] getComponent -- @param self --- @param #string str +-- @param #string name -- @return Component#Component ret (return value: cc.Component) -------------------------------- +-- Returns the untransformed size of the node.
+-- see `setContentSize(const Size&)`
+-- return The untransformed size of the node. -- @function [parent=#Node] getContentSize -- @param self -- @return size_table#size_table ret (return value: size_table) -------------------------------- +-- Removes all actions from the running action list by its tag.
+-- param tag A tag that indicates the action to be removed. -- @function [parent=#Node] stopAllActionsByTag -- @param self --- @param #int int +-- @param #int tag -------------------------------- +-- -- @function [parent=#Node] getColor -- @param self -- @return color3b_table#color3b_table ret (return value: color3b_table) -------------------------------- +-- Returns an AABB (axis-aligned bounding-box) in its parent's coordinate system.
+-- return An AABB (axis-aligned bounding-box) in its parent's coordinate system -- @function [parent=#Node] getBoundingBox -- @param self -- @return rect_table#rect_table ret (return value: rect_table) -------------------------------- +-- -- @function [parent=#Node] setEventDispatcher -- @param self --- @param #cc.EventDispatcher eventdispatcher +-- @param #cc.EventDispatcher dispatcher -------------------------------- +-- Returns the Node's Global Z Order.
+-- see `setGlobalZOrder(int)`
+-- return The node's global Z order -- @function [parent=#Node] getGlobalZOrder -- @param self -- @return float#float ret (return value: float) @@ -645,71 +931,101 @@ -- @function [parent=#Node] draw -- @param self -- @param #cc.Renderer renderer --- @param #mat4_table mat4 --- @param #unsigned int int +-- @param #mat4_table transform +-- @param #unsigned int flags -------------------------------- +-- Returns a user assigned Object
+-- Similar to UserData, but instead of holding a void* it holds an object.
+-- The UserObject will be retained once in this method,
+-- and the previous UserObject (if existed) will be released.
+-- The UserObject will be released in Node's destructor.
+-- param userObject A user assigned Object -- @function [parent=#Node] setUserObject -- @param self --- @param #cc.Ref ref +-- @param #cc.Ref userObject -------------------------------- -- @overload self, bool -- @overload self -- @function [parent=#Node] removeFromParentAndCleanup -- @param self --- @param #bool bool +-- @param #bool cleanup -------------------------------- +-- Sets the position (X, Y, and Z) in its parent's coordinate system -- @function [parent=#Node] setPosition3D -- @param self --- @param #vec3_table vec3 +-- @param #vec3_table position -------------------------------- +-- -- @function [parent=#Node] update -- @param self --- @param #float float +-- @param #float delta -------------------------------- +-- Sorts the children array once before drawing, instead of every time when a child is added or reordered.
+-- This appraoch can improves the performance massively.
+-- note Don't call this manually unless a child added needs to be removed in the same frame -- @function [parent=#Node] sortAllChildren -- @param self -------------------------------- +-- Returns the inverse world affine transform matrix. The matrix is in Pixels. -- @function [parent=#Node] getWorldToNodeTransform -- @param self -- @return mat4_table#mat4_table ret (return value: mat4_table) -------------------------------- +-- Gets the scale factor of the node, when X and Y have the same scale factor.
+-- warning Assert when `_scaleX != _scaleY`
+-- see setScale(float)
+-- return The scale factor of the node. -- @function [parent=#Node] getScale -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- returns the normalized position -- @function [parent=#Node] getNormalizedPosition -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- Gets the X rotation (angle) of the node in degrees which performs a horizontal rotation skew.
+-- see `setRotationSkewX(float)`
+-- return The X rotation in degrees. -- @function [parent=#Node] getRotationSkewX -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- Gets the Y rotation (angle) of the node in degrees which performs a vertical rotational skew.
+-- see `setRotationSkewY(float)`
+-- return The Y rotation in degrees. -- @function [parent=#Node] getRotationSkewY -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- Changes the tag that is used to identify the node easily.
+-- Please refer to getTag for the sample code.
+-- param tag A integer that identifies the node.
+-- Please use `setName()` instead. -- @function [parent=#Node] setTag -- @param self --- @param #int int +-- @param #int tag -------------------------------- +-- -- @function [parent=#Node] isCascadeColorEnabled -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- Stops and removes an action from the running action list.
+-- param action The action object to be removed. -- @function [parent=#Node] stopAction -- @param self -- @param #cc.Action action @@ -722,6 +1038,8 @@ -- @return ActionManager#ActionManager ret (retunr value: cc.ActionManager) -------------------------------- +-- Allocates and initializes a node.
+-- return A initialized node which is marked as "autorelease". -- @function [parent=#Node] create -- @param self -- @return Node#Node ret (return value: cc.Node) diff --git a/cocos/scripting/lua-bindings/auto/api/NodeGrid.lua b/cocos/scripting/lua-bindings/auto/api/NodeGrid.lua index 2d99049a3c..7ccb4f01c2 100644 --- a/cocos/scripting/lua-bindings/auto/api/NodeGrid.lua +++ b/cocos/scripting/lua-bindings/auto/api/NodeGrid.lua @@ -5,9 +5,10 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#NodeGrid] setTarget -- @param self --- @param #cc.Node node +-- @param #cc.Node target -------------------------------- -- @overload self @@ -17,20 +18,24 @@ -- @return GridBase#GridBase ret (retunr value: cc.GridBase) -------------------------------- +-- Changes a grid object that is used when applying effects
+-- param grid A Grid object that is used when applying effects -- @function [parent=#NodeGrid] setGrid -- @param self --- @param #cc.GridBase gridbase +-- @param #cc.GridBase grid -------------------------------- +-- -- @function [parent=#NodeGrid] create -- @param self -- @return NodeGrid#NodeGrid ret (return value: cc.NodeGrid) -------------------------------- +-- -- @function [parent=#NodeGrid] visit -- @param self -- @param #cc.Renderer renderer --- @param #mat4_table mat4 --- @param #unsigned int int +-- @param #mat4_table parentTransform +-- @param #unsigned int parentFlags return nil diff --git a/cocos/scripting/lua-bindings/auto/api/NodeReader.lua b/cocos/scripting/lua-bindings/auto/api/NodeReader.lua index 51e345250a..989c2ae99b 100644 --- a/cocos/scripting/lua-bindings/auto/api/NodeReader.lua +++ b/cocos/scripting/lua-bindings/auto/api/NodeReader.lua @@ -4,56 +4,67 @@ -- @parent_module ccs -------------------------------- +-- -- @function [parent=#NodeReader] setJsonPath -- @param self --- @param #string str +-- @param #string jsonPath -------------------------------- +-- -- @function [parent=#NodeReader] createNode -- @param self --- @param #string str +-- @param #string filename -- @return Node#Node ret (return value: cc.Node) -------------------------------- +-- -- @function [parent=#NodeReader] loadNodeWithFile -- @param self --- @param #string str +-- @param #string fileName -- @return Node#Node ret (return value: cc.Node) -------------------------------- +-- -- @function [parent=#NodeReader] purge -- @param self -------------------------------- +-- -- @function [parent=#NodeReader] init -- @param self -------------------------------- +-- -- @function [parent=#NodeReader] loadNodeWithContent -- @param self --- @param #string str +-- @param #string content -- @return Node#Node ret (return value: cc.Node) -------------------------------- +-- -- @function [parent=#NodeReader] isRecordJsonPath -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#NodeReader] getJsonPath -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- -- @function [parent=#NodeReader] setRecordJsonPath -- @param self --- @param #bool bool +-- @param #bool record -------------------------------- +-- -- @function [parent=#NodeReader] destroyInstance -- @param self -------------------------------- +-- -- @function [parent=#NodeReader] NodeReader -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/OrbitCamera.lua b/cocos/scripting/lua-bindings/auto/api/OrbitCamera.lua index c4130a75c8..9919cf681e 100644 --- a/cocos/scripting/lua-bindings/auto/api/OrbitCamera.lua +++ b/cocos/scripting/lua-bindings/auto/api/OrbitCamera.lua @@ -5,30 +5,34 @@ -- @parent_module cc -------------------------------- +-- creates a OrbitCamera action with radius, delta-radius, z, deltaZ, x, deltaX -- @function [parent=#OrbitCamera] create -- @param self --- @param #float float --- @param #float float --- @param #float float --- @param #float float --- @param #float float --- @param #float float --- @param #float float +-- @param #float t +-- @param #float radius +-- @param #float deltaRadius +-- @param #float angleZ +-- @param #float deltaAngleZ +-- @param #float angleX +-- @param #float deltaAngleX -- @return OrbitCamera#OrbitCamera ret (return value: cc.OrbitCamera) -------------------------------- +-- -- @function [parent=#OrbitCamera] startWithTarget -- @param self --- @param #cc.Node node +-- @param #cc.Node target -------------------------------- +-- -- @function [parent=#OrbitCamera] clone -- @param self -- @return OrbitCamera#OrbitCamera ret (return value: cc.OrbitCamera) -------------------------------- +-- -- @function [parent=#OrbitCamera] update -- @param self --- @param #float float +-- @param #float time return nil diff --git a/cocos/scripting/lua-bindings/auto/api/PageTurn3D.lua b/cocos/scripting/lua-bindings/auto/api/PageTurn3D.lua index aa9eff0b3d..2d17a6451a 100644 --- a/cocos/scripting/lua-bindings/auto/api/PageTurn3D.lua +++ b/cocos/scripting/lua-bindings/auto/api/PageTurn3D.lua @@ -5,20 +5,23 @@ -- @parent_module cc -------------------------------- +-- create the action -- @function [parent=#PageTurn3D] create -- @param self --- @param #float float --- @param #size_table size +-- @param #float duration +-- @param #size_table gridSize -- @return PageTurn3D#PageTurn3D ret (return value: cc.PageTurn3D) -------------------------------- +-- -- @function [parent=#PageTurn3D] clone -- @param self -- @return PageTurn3D#PageTurn3D ret (return value: cc.PageTurn3D) -------------------------------- +-- -- @function [parent=#PageTurn3D] update -- @param self --- @param #float float +-- @param #float time return nil diff --git a/cocos/scripting/lua-bindings/auto/api/PageView.lua b/cocos/scripting/lua-bindings/auto/api/PageView.lua index f68253b507..f32fed2e39 100644 --- a/cocos/scripting/lua-bindings/auto/api/PageView.lua +++ b/cocos/scripting/lua-bindings/auto/api/PageView.lua @@ -5,114 +5,150 @@ -- @parent_module ccui -------------------------------- +-- brief Return user defined scroll page threshold -- @function [parent=#PageView] getCustomScrollThreshold -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- Gets current page index.
+-- return current page index. -- @function [parent=#PageView] getCurPageIndex -- @param self -- @return long#long ret (return value: long) -------------------------------- +-- Add a widget to a page of pageview.
+-- param widget widget to be added to pageview.
+-- param pageIdx index of page.
+-- param forceCreate if force create and there is no page exsit, pageview would create a default page for adding widget. -- @function [parent=#PageView] addWidgetToPage -- @param self -- @param #ccui.Widget widget --- @param #long long --- @param #bool bool +-- @param #long pageIdx +-- @param #bool forceCreate -------------------------------- +-- brief Query whether we are using user defined scroll page threshold or not -- @function [parent=#PageView] isUsingCustomScrollThreshold -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#PageView] getPage -- @param self --- @param #long long +-- @param #long index -- @return Layout#Layout ret (return value: ccui.Layout) -------------------------------- +-- Remove a page of pageview.
+-- param page page which will be removed. -- @function [parent=#PageView] removePage -- @param self --- @param #ccui.Layout layout +-- @param #ccui.Layout page -------------------------------- +-- -- @function [parent=#PageView] addEventListener -- @param self --- @param #function func +-- @param #function callback -------------------------------- +-- brief Set using user defined scroll page threshold or not
+-- If you set it to false, then the default scroll threshold is pageView.width / 2 -- @function [parent=#PageView] setUsingCustomScrollThreshold -- @param self --- @param #bool bool +-- @param #bool flag -------------------------------- +-- brief If you don't specify the value, the pageView will scroll when half pageview width reached -- @function [parent=#PageView] setCustomScrollThreshold -- @param self --- @param #float float +-- @param #float threshold -------------------------------- +-- Insert a page to pageview.
+-- param page page to be added to pageview. -- @function [parent=#PageView] insertPage -- @param self --- @param #ccui.Layout layout --- @param #int int +-- @param #ccui.Layout page +-- @param #int idx -------------------------------- +-- scroll pageview to index.
+-- param idx index of page. -- @function [parent=#PageView] scrollToPage -- @param self --- @param #long long +-- @param #long idx -------------------------------- +-- Remove a page at index of pageview.
+-- param index index of page. -- @function [parent=#PageView] removePageAtIndex -- @param self --- @param #long long +-- @param #long index -------------------------------- +-- -- @function [parent=#PageView] getPages -- @param self -- @return array_table#array_table ret (return value: array_table) -------------------------------- +-- -- @function [parent=#PageView] removeAllPages -- @param self -------------------------------- +-- Push back a page to pageview.
+-- param page page to be added to pageview. -- @function [parent=#PageView] addPage -- @param self --- @param #ccui.Layout layout +-- @param #ccui.Layout page -------------------------------- +-- Allocates and initializes. -- @function [parent=#PageView] create -- @param self -- @return PageView#PageView ret (return value: ccui.PageView) -------------------------------- +-- -- @function [parent=#PageView] createInstance -- @param self -- @return Ref#Ref ret (return value: cc.Ref) -------------------------------- +-- Gets LayoutType.
+-- see LayoutType
+-- return LayoutType -- @function [parent=#PageView] getLayoutType -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- Returns the "class name" of widget. -- @function [parent=#PageView] getDescription -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- -- @function [parent=#PageView] update -- @param self --- @param #float float +-- @param #float dt -------------------------------- +-- Sets LayoutType.
+-- see LayoutType
+-- param type LayoutType -- @function [parent=#PageView] setLayoutType -- @param self -- @param #int type -------------------------------- +-- Default constructor -- @function [parent=#PageView] PageView -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/ParallaxNode.lua b/cocos/scripting/lua-bindings/auto/api/ParallaxNode.lua index 3a55ee2e5a..08e5385b90 100644 --- a/cocos/scripting/lua-bindings/auto/api/ParallaxNode.lua +++ b/cocos/scripting/lua-bindings/auto/api/ParallaxNode.lua @@ -5,19 +5,22 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#ParallaxNode] addChild -- @param self --- @param #cc.Node node --- @param #int int --- @param #vec2_table vec2 --- @param #vec2_table vec2 +-- @param #cc.Node child +-- @param #int z +-- @param #vec2_table parallaxRatio +-- @param #vec2_table positionOffset -------------------------------- +-- -- @function [parent=#ParallaxNode] removeAllChildrenWithCleanup -- @param self --- @param #bool bool +-- @param #bool cleanup -------------------------------- +-- -- @function [parent=#ParallaxNode] create -- @param self -- @return ParallaxNode#ParallaxNode ret (return value: cc.ParallaxNode) @@ -27,21 +30,23 @@ -- @overload self, cc.Node, int, int -- @function [parent=#ParallaxNode] addChild -- @param self --- @param #cc.Node node --- @param #int int --- @param #int int +-- @param #cc.Node child +-- @param #int zOrder +-- @param #int tag -------------------------------- +-- -- @function [parent=#ParallaxNode] visit -- @param self -- @param #cc.Renderer renderer --- @param #mat4_table mat4 --- @param #unsigned int int +-- @param #mat4_table parentTransform +-- @param #unsigned int parentFlags -------------------------------- +-- -- @function [parent=#ParallaxNode] removeChild -- @param self --- @param #cc.Node node --- @param #bool bool +-- @param #cc.Node child +-- @param #bool cleanup return nil diff --git a/cocos/scripting/lua-bindings/auto/api/ParticleBatchNode.lua b/cocos/scripting/lua-bindings/auto/api/ParticleBatchNode.lua index 1adde946b7..7207e4e41e 100644 --- a/cocos/scripting/lua-bindings/auto/api/ParticleBatchNode.lua +++ b/cocos/scripting/lua-bindings/auto/api/ParticleBatchNode.lua @@ -5,59 +5,69 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#ParticleBatchNode] setTexture -- @param self --- @param #cc.Texture2D texture2d +-- @param #cc.Texture2D texture -------------------------------- +-- disables a particle by inserting a 0'd quad into the texture atlas -- @function [parent=#ParticleBatchNode] disableParticle -- @param self --- @param #int int +-- @param #int particleIndex -------------------------------- +-- -- @function [parent=#ParticleBatchNode] getTexture -- @param self -- @return Texture2D#Texture2D ret (return value: cc.Texture2D) -------------------------------- +-- Sets the texture atlas used for drawing the quads -- @function [parent=#ParticleBatchNode] setTextureAtlas -- @param self --- @param #cc.TextureAtlas textureatlas +-- @param #cc.TextureAtlas atlas -------------------------------- +-- -- @function [parent=#ParticleBatchNode] removeAllChildrenWithCleanup -- @param self --- @param #bool bool +-- @param #bool doCleanup -------------------------------- +-- Gets the texture atlas used for drawing the quads -- @function [parent=#ParticleBatchNode] getTextureAtlas -- @param self -- @return TextureAtlas#TextureAtlas ret (return value: cc.TextureAtlas) -------------------------------- +-- Inserts a child into the ParticleBatchNode -- @function [parent=#ParticleBatchNode] insertChild -- @param self --- @param #cc.ParticleSystem particlesystem --- @param #int int +-- @param #cc.ParticleSystem system +-- @param #int index -------------------------------- +-- -- @function [parent=#ParticleBatchNode] removeChildAtIndex -- @param self --- @param #int int --- @param #bool bool +-- @param #int index +-- @param #bool doCleanup -------------------------------- +-- initializes the particle system with the name of a file on disk (for a list of supported formats look at the Texture2D class), a capacity of particles -- @function [parent=#ParticleBatchNode] create -- @param self --- @param #string str --- @param #int int +-- @param #string fileImage +-- @param #int capacity -- @return ParticleBatchNode#ParticleBatchNode ret (return value: cc.ParticleBatchNode) -------------------------------- +-- initializes the particle system with Texture2D, a capacity of particles, which particle system to use -- @function [parent=#ParticleBatchNode] createWithTexture -- @param self --- @param #cc.Texture2D texture2d --- @param #int int +-- @param #cc.Texture2D tex +-- @param #int capacity -- @return ParticleBatchNode#ParticleBatchNode ret (return value: cc.ParticleBatchNode) -------------------------------- @@ -65,34 +75,38 @@ -- @overload self, cc.Node, int, int -- @function [parent=#ParticleBatchNode] addChild -- @param self --- @param #cc.Node node --- @param #int int --- @param #int int +-- @param #cc.Node child +-- @param #int zOrder +-- @param #int tag -------------------------------- +-- -- @function [parent=#ParticleBatchNode] draw -- @param self -- @param #cc.Renderer renderer --- @param #mat4_table mat4 --- @param #unsigned int int +-- @param #mat4_table transform +-- @param #unsigned int flags -------------------------------- +-- -- @function [parent=#ParticleBatchNode] visit -- @param self -- @param #cc.Renderer renderer --- @param #mat4_table mat4 --- @param #unsigned int int +-- @param #mat4_table parentTransform +-- @param #unsigned int parentFlags -------------------------------- +-- -- @function [parent=#ParticleBatchNode] reorderChild -- @param self --- @param #cc.Node node --- @param #int int +-- @param #cc.Node child +-- @param #int zOrder -------------------------------- +-- -- @function [parent=#ParticleBatchNode] removeChild -- @param self --- @param #cc.Node node --- @param #bool bool +-- @param #cc.Node child +-- @param #bool cleanup return nil diff --git a/cocos/scripting/lua-bindings/auto/api/ParticleDisplayData.lua b/cocos/scripting/lua-bindings/auto/api/ParticleDisplayData.lua index d9f24aa9d7..7e2361d90e 100644 --- a/cocos/scripting/lua-bindings/auto/api/ParticleDisplayData.lua +++ b/cocos/scripting/lua-bindings/auto/api/ParticleDisplayData.lua @@ -5,11 +5,13 @@ -- @parent_module ccs -------------------------------- +-- -- @function [parent=#ParticleDisplayData] create -- @param self -- @return ParticleDisplayData#ParticleDisplayData ret (return value: ccs.ParticleDisplayData) -------------------------------- +-- js ctor -- @function [parent=#ParticleDisplayData] ParticleDisplayData -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/ParticleExplosion.lua b/cocos/scripting/lua-bindings/auto/api/ParticleExplosion.lua index 693f1ebd46..5fded9bb0f 100644 --- a/cocos/scripting/lua-bindings/auto/api/ParticleExplosion.lua +++ b/cocos/scripting/lua-bindings/auto/api/ParticleExplosion.lua @@ -5,14 +5,16 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#ParticleExplosion] create -- @param self -- @return ParticleExplosion#ParticleExplosion ret (return value: cc.ParticleExplosion) -------------------------------- +-- -- @function [parent=#ParticleExplosion] createWithTotalParticles -- @param self --- @param #int int +-- @param #int numberOfParticles -- @return ParticleExplosion#ParticleExplosion ret (return value: cc.ParticleExplosion) return nil diff --git a/cocos/scripting/lua-bindings/auto/api/ParticleFire.lua b/cocos/scripting/lua-bindings/auto/api/ParticleFire.lua index 1c9d89cda7..d26181214a 100644 --- a/cocos/scripting/lua-bindings/auto/api/ParticleFire.lua +++ b/cocos/scripting/lua-bindings/auto/api/ParticleFire.lua @@ -5,14 +5,16 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#ParticleFire] create -- @param self -- @return ParticleFire#ParticleFire ret (return value: cc.ParticleFire) -------------------------------- +-- -- @function [parent=#ParticleFire] createWithTotalParticles -- @param self --- @param #int int +-- @param #int numberOfParticles -- @return ParticleFire#ParticleFire ret (return value: cc.ParticleFire) return nil diff --git a/cocos/scripting/lua-bindings/auto/api/ParticleFireworks.lua b/cocos/scripting/lua-bindings/auto/api/ParticleFireworks.lua index 3a6549d5ab..cf8cc88409 100644 --- a/cocos/scripting/lua-bindings/auto/api/ParticleFireworks.lua +++ b/cocos/scripting/lua-bindings/auto/api/ParticleFireworks.lua @@ -5,14 +5,16 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#ParticleFireworks] create -- @param self -- @return ParticleFireworks#ParticleFireworks ret (return value: cc.ParticleFireworks) -------------------------------- +-- -- @function [parent=#ParticleFireworks] createWithTotalParticles -- @param self --- @param #int int +-- @param #int numberOfParticles -- @return ParticleFireworks#ParticleFireworks ret (return value: cc.ParticleFireworks) return nil diff --git a/cocos/scripting/lua-bindings/auto/api/ParticleFlower.lua b/cocos/scripting/lua-bindings/auto/api/ParticleFlower.lua index 55c7f9cd33..1d69ebf5ec 100644 --- a/cocos/scripting/lua-bindings/auto/api/ParticleFlower.lua +++ b/cocos/scripting/lua-bindings/auto/api/ParticleFlower.lua @@ -5,14 +5,16 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#ParticleFlower] create -- @param self -- @return ParticleFlower#ParticleFlower ret (return value: cc.ParticleFlower) -------------------------------- +-- -- @function [parent=#ParticleFlower] createWithTotalParticles -- @param self --- @param #int int +-- @param #int numberOfParticles -- @return ParticleFlower#ParticleFlower ret (return value: cc.ParticleFlower) return nil diff --git a/cocos/scripting/lua-bindings/auto/api/ParticleGalaxy.lua b/cocos/scripting/lua-bindings/auto/api/ParticleGalaxy.lua index c99c2ead77..5ec68f2b85 100644 --- a/cocos/scripting/lua-bindings/auto/api/ParticleGalaxy.lua +++ b/cocos/scripting/lua-bindings/auto/api/ParticleGalaxy.lua @@ -5,14 +5,16 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#ParticleGalaxy] create -- @param self -- @return ParticleGalaxy#ParticleGalaxy ret (return value: cc.ParticleGalaxy) -------------------------------- +-- -- @function [parent=#ParticleGalaxy] createWithTotalParticles -- @param self --- @param #int int +-- @param #int numberOfParticles -- @return ParticleGalaxy#ParticleGalaxy ret (return value: cc.ParticleGalaxy) return nil diff --git a/cocos/scripting/lua-bindings/auto/api/ParticleMeteor.lua b/cocos/scripting/lua-bindings/auto/api/ParticleMeteor.lua index 556a9f56ca..ed1c10d29f 100644 --- a/cocos/scripting/lua-bindings/auto/api/ParticleMeteor.lua +++ b/cocos/scripting/lua-bindings/auto/api/ParticleMeteor.lua @@ -5,14 +5,16 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#ParticleMeteor] create -- @param self -- @return ParticleMeteor#ParticleMeteor ret (return value: cc.ParticleMeteor) -------------------------------- +-- -- @function [parent=#ParticleMeteor] createWithTotalParticles -- @param self --- @param #int int +-- @param #int numberOfParticles -- @return ParticleMeteor#ParticleMeteor ret (return value: cc.ParticleMeteor) return nil diff --git a/cocos/scripting/lua-bindings/auto/api/ParticleRain.lua b/cocos/scripting/lua-bindings/auto/api/ParticleRain.lua index 36921412b2..602a43e5fc 100644 --- a/cocos/scripting/lua-bindings/auto/api/ParticleRain.lua +++ b/cocos/scripting/lua-bindings/auto/api/ParticleRain.lua @@ -5,14 +5,16 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#ParticleRain] create -- @param self -- @return ParticleRain#ParticleRain ret (return value: cc.ParticleRain) -------------------------------- +-- -- @function [parent=#ParticleRain] createWithTotalParticles -- @param self --- @param #int int +-- @param #int numberOfParticles -- @return ParticleRain#ParticleRain ret (return value: cc.ParticleRain) return nil diff --git a/cocos/scripting/lua-bindings/auto/api/ParticleSmoke.lua b/cocos/scripting/lua-bindings/auto/api/ParticleSmoke.lua index 61c5124bf6..8ba9f90ca0 100644 --- a/cocos/scripting/lua-bindings/auto/api/ParticleSmoke.lua +++ b/cocos/scripting/lua-bindings/auto/api/ParticleSmoke.lua @@ -5,14 +5,16 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#ParticleSmoke] create -- @param self -- @return ParticleSmoke#ParticleSmoke ret (return value: cc.ParticleSmoke) -------------------------------- +-- -- @function [parent=#ParticleSmoke] createWithTotalParticles -- @param self --- @param #int int +-- @param #int numberOfParticles -- @return ParticleSmoke#ParticleSmoke ret (return value: cc.ParticleSmoke) return nil diff --git a/cocos/scripting/lua-bindings/auto/api/ParticleSnow.lua b/cocos/scripting/lua-bindings/auto/api/ParticleSnow.lua index 9f72153785..4b872058bb 100644 --- a/cocos/scripting/lua-bindings/auto/api/ParticleSnow.lua +++ b/cocos/scripting/lua-bindings/auto/api/ParticleSnow.lua @@ -5,14 +5,16 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#ParticleSnow] create -- @param self -- @return ParticleSnow#ParticleSnow ret (return value: cc.ParticleSnow) -------------------------------- +-- -- @function [parent=#ParticleSnow] createWithTotalParticles -- @param self --- @param #int int +-- @param #int numberOfParticles -- @return ParticleSnow#ParticleSnow ret (return value: cc.ParticleSnow) return nil diff --git a/cocos/scripting/lua-bindings/auto/api/ParticleSpiral.lua b/cocos/scripting/lua-bindings/auto/api/ParticleSpiral.lua index 0179b56720..6f653e601d 100644 --- a/cocos/scripting/lua-bindings/auto/api/ParticleSpiral.lua +++ b/cocos/scripting/lua-bindings/auto/api/ParticleSpiral.lua @@ -5,14 +5,16 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#ParticleSpiral] create -- @param self -- @return ParticleSpiral#ParticleSpiral ret (return value: cc.ParticleSpiral) -------------------------------- +-- -- @function [parent=#ParticleSpiral] createWithTotalParticles -- @param self --- @param #int int +-- @param #int numberOfParticles -- @return ParticleSpiral#ParticleSpiral ret (return value: cc.ParticleSpiral) return nil diff --git a/cocos/scripting/lua-bindings/auto/api/ParticleSun.lua b/cocos/scripting/lua-bindings/auto/api/ParticleSun.lua index 93f07dafde..d702a58839 100644 --- a/cocos/scripting/lua-bindings/auto/api/ParticleSun.lua +++ b/cocos/scripting/lua-bindings/auto/api/ParticleSun.lua @@ -5,14 +5,16 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#ParticleSun] create -- @param self -- @return ParticleSun#ParticleSun ret (return value: cc.ParticleSun) -------------------------------- +-- -- @function [parent=#ParticleSun] createWithTotalParticles -- @param self --- @param #int int +-- @param #int numberOfParticles -- @return ParticleSun#ParticleSun ret (return value: cc.ParticleSun) return nil diff --git a/cocos/scripting/lua-bindings/auto/api/ParticleSystem.lua b/cocos/scripting/lua-bindings/auto/api/ParticleSystem.lua index 3a36b92a5c..5151144bb3 100644 --- a/cocos/scripting/lua-bindings/auto/api/ParticleSystem.lua +++ b/cocos/scripting/lua-bindings/auto/api/ParticleSystem.lua @@ -5,506 +5,613 @@ -- @parent_module cc -------------------------------- +-- size variance in pixels of each particle -- @function [parent=#ParticleSystem] getStartSizeVar -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#ParticleSystem] getTexture -- @param self -- @return Texture2D#Texture2D ret (return value: cc.Texture2D) -------------------------------- +-- whether or not the system is full -- @function [parent=#ParticleSystem] isFull -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#ParticleSystem] getBatchNode -- @param self -- @return ParticleBatchNode#ParticleBatchNode ret (return value: cc.ParticleBatchNode) -------------------------------- +-- start color of each particle -- @function [parent=#ParticleSystem] getStartColor -- @param self -- @return color4f_table#color4f_table ret (return value: color4f_table) -------------------------------- +-- particles movement type: Free or Grouped
+-- since v0.8 -- @function [parent=#ParticleSystem] getPositionType -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- -- @function [parent=#ParticleSystem] setPosVar -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table pos -------------------------------- +-- -- @function [parent=#ParticleSystem] getEndSpin -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#ParticleSystem] setRotatePerSecondVar -- @param self --- @param #float float +-- @param #float degrees -------------------------------- +-- -- @function [parent=#ParticleSystem] getStartSpinVar -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#ParticleSystem] getRadialAccelVar -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- end size variance in pixels of each particle -- @function [parent=#ParticleSystem] getEndSizeVar -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#ParticleSystem] setRotation -- @param self --- @param #float float +-- @param #float newRotation -------------------------------- +-- -- @function [parent=#ParticleSystem] setTangentialAccel -- @param self --- @param #float float +-- @param #float t -------------------------------- +-- -- @function [parent=#ParticleSystem] setScaleY -- @param self --- @param #float float +-- @param #float newScaleY -------------------------------- +-- -- @function [parent=#ParticleSystem] setScaleX -- @param self --- @param #float float +-- @param #float newScaleX -------------------------------- +-- -- @function [parent=#ParticleSystem] getRadialAccel -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#ParticleSystem] setStartRadius -- @param self --- @param #float float +-- @param #float startRadius -------------------------------- +-- -- @function [parent=#ParticleSystem] setRotatePerSecond -- @param self --- @param #float float +-- @param #float degrees -------------------------------- +-- -- @function [parent=#ParticleSystem] setEndSize -- @param self --- @param #float float +-- @param #float endSize -------------------------------- +-- -- @function [parent=#ParticleSystem] getGravity -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- -- @function [parent=#ParticleSystem] getTangentialAccel -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#ParticleSystem] setEndRadius -- @param self --- @param #float float +-- @param #float endRadius -------------------------------- +-- -- @function [parent=#ParticleSystem] getSpeed -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- angle and angle variation of each particle -- @function [parent=#ParticleSystem] getAngle -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#ParticleSystem] setEndColor -- @param self --- @param #color4f_table color4f +-- @param #color4f_table color -------------------------------- +-- -- @function [parent=#ParticleSystem] setStartSpin -- @param self --- @param #float float +-- @param #float spin -------------------------------- +-- -- @function [parent=#ParticleSystem] setDuration -- @param self --- @param #float float +-- @param #float duration -------------------------------- +-- -- @function [parent=#ParticleSystem] setTexture -- @param self --- @param #cc.Texture2D texture2d +-- @param #cc.Texture2D texture -------------------------------- +-- Position variance of the emitter -- @function [parent=#ParticleSystem] getPosVar -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- -- @function [parent=#ParticleSystem] updateWithNoTime -- @param self -------------------------------- +-- -- @function [parent=#ParticleSystem] isBlendAdditive -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#ParticleSystem] getSpeedVar -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#ParticleSystem] setPositionType -- @param self --- @param #int positiontype +-- @param #int type -------------------------------- +-- stop emitting particles. Running particles will continue to run until they die -- @function [parent=#ParticleSystem] stopSystem -- @param self -------------------------------- +-- sourcePosition of the emitter -- @function [parent=#ParticleSystem] getSourcePosition -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- -- @function [parent=#ParticleSystem] setLifeVar -- @param self --- @param #float float +-- @param #float lifeVar -------------------------------- +-- -- @function [parent=#ParticleSystem] setTotalParticles -- @param self --- @param #int int +-- @param #int totalParticles -------------------------------- +-- -- @function [parent=#ParticleSystem] setEndColorVar -- @param self --- @param #color4f_table color4f +-- @param #color4f_table color -------------------------------- +-- -- @function [parent=#ParticleSystem] getAtlasIndex -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- start size in pixels of each particle -- @function [parent=#ParticleSystem] getStartSize -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#ParticleSystem] setStartSpinVar -- @param self --- @param #float float +-- @param #float pinVar -------------------------------- +-- Kill all living particles. -- @function [parent=#ParticleSystem] resetSystem -- @param self -------------------------------- +-- -- @function [parent=#ParticleSystem] setAtlasIndex -- @param self --- @param #int int +-- @param #int index -------------------------------- +-- -- @function [parent=#ParticleSystem] setTangentialAccelVar -- @param self --- @param #float float +-- @param #float t -------------------------------- +-- -- @function [parent=#ParticleSystem] setEndRadiusVar -- @param self --- @param #float float +-- @param #float endRadiusVar -------------------------------- +-- -- @function [parent=#ParticleSystem] getEndRadius -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#ParticleSystem] isOpacityModifyRGB -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#ParticleSystem] isActive -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#ParticleSystem] setRadialAccelVar -- @param self --- @param #float float +-- @param #float t -------------------------------- +-- -- @function [parent=#ParticleSystem] setStartSize -- @param self --- @param #float float +-- @param #float startSize -------------------------------- +-- -- @function [parent=#ParticleSystem] setSpeed -- @param self --- @param #float float +-- @param #float speed -------------------------------- +-- -- @function [parent=#ParticleSystem] getStartSpin -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#ParticleSystem] getRotatePerSecond -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#ParticleSystem] setEmitterMode -- @param self -- @param #int mode -------------------------------- +-- How many seconds the emitter will run. -1 means 'forever' -- @function [parent=#ParticleSystem] getDuration -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#ParticleSystem] setSourcePosition -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table pos -------------------------------- +-- -- @function [parent=#ParticleSystem] getEndSpinVar -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#ParticleSystem] setBlendAdditive -- @param self --- @param #bool bool +-- @param #bool value -------------------------------- +-- -- @function [parent=#ParticleSystem] setLife -- @param self --- @param #float float +-- @param #float life -------------------------------- +-- -- @function [parent=#ParticleSystem] setAngleVar -- @param self --- @param #float float +-- @param #float angleVar -------------------------------- +-- -- @function [parent=#ParticleSystem] setRotationIsDir -- @param self --- @param #bool bool +-- @param #bool t -------------------------------- +-- -- @function [parent=#ParticleSystem] setEndSizeVar -- @param self --- @param #float float +-- @param #float sizeVar -------------------------------- +-- -- @function [parent=#ParticleSystem] setAngle -- @param self --- @param #float float +-- @param #float angle -------------------------------- +-- -- @function [parent=#ParticleSystem] setBatchNode -- @param self --- @param #cc.ParticleBatchNode particlebatchnode +-- @param #cc.ParticleBatchNode batchNode -------------------------------- +-- -- @function [parent=#ParticleSystem] getTangentialAccelVar -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- Switch between different kind of emitter modes:
+-- - kParticleModeGravity: uses gravity, speed, radial and tangential acceleration
+-- - kParticleModeRadius: uses radius movement + rotation -- @function [parent=#ParticleSystem] getEmitterMode -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- -- @function [parent=#ParticleSystem] setEndSpinVar -- @param self --- @param #float float +-- @param #float endSpinVar -------------------------------- +-- angle variance of each particle -- @function [parent=#ParticleSystem] getAngleVar -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#ParticleSystem] setStartColor -- @param self --- @param #color4f_table color4f +-- @param #color4f_table color -------------------------------- +-- -- @function [parent=#ParticleSystem] getRotatePerSecondVar -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- end size in pixels of each particle -- @function [parent=#ParticleSystem] getEndSize -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- life, and life variation of each particle -- @function [parent=#ParticleSystem] getLife -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#ParticleSystem] setSpeedVar -- @param self --- @param #float float +-- @param #float speed -------------------------------- +-- -- @function [parent=#ParticleSystem] setAutoRemoveOnFinish -- @param self --- @param #bool bool +-- @param #bool var -------------------------------- +-- -- @function [parent=#ParticleSystem] setGravity -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table g -------------------------------- +-- should be overridden by subclasses -- @function [parent=#ParticleSystem] postStep -- @param self -------------------------------- +-- -- @function [parent=#ParticleSystem] setEmissionRate -- @param self --- @param #float float +-- @param #float rate -------------------------------- +-- end color variance of each particle -- @function [parent=#ParticleSystem] getEndColorVar -- @param self -- @return color4f_table#color4f_table ret (return value: color4f_table) -------------------------------- +-- -- @function [parent=#ParticleSystem] getRotationIsDir -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#ParticleSystem] setScale -- @param self --- @param #float float +-- @param #float s -------------------------------- +-- emission rate of the particles -- @function [parent=#ParticleSystem] getEmissionRate -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- end color and end color variation of each particle -- @function [parent=#ParticleSystem] getEndColor -- @param self -- @return color4f_table#color4f_table ret (return value: color4f_table) -------------------------------- +-- life variance of each particle -- @function [parent=#ParticleSystem] getLifeVar -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#ParticleSystem] setStartSizeVar -- @param self --- @param #float float +-- @param #float sizeVar -------------------------------- +-- does the alpha value modify color -- @function [parent=#ParticleSystem] setOpacityModifyRGB -- @param self --- @param #bool bool +-- @param #bool opacityModifyRGB -------------------------------- +-- Add a particle to the emitter -- @function [parent=#ParticleSystem] addParticle -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#ParticleSystem] getStartRadius -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- Quantity of particles that are being simulated at the moment -- @function [parent=#ParticleSystem] getParticleCount -- @param self -- @return unsigned int#unsigned int ret (return value: unsigned int) -------------------------------- +-- -- @function [parent=#ParticleSystem] getStartRadiusVar -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#ParticleSystem] setStartColorVar -- @param self --- @param #color4f_table color4f +-- @param #color4f_table color -------------------------------- +-- -- @function [parent=#ParticleSystem] setEndSpin -- @param self --- @param #float float +-- @param #float endSpin -------------------------------- +-- -- @function [parent=#ParticleSystem] setRadialAccel -- @param self --- @param #float float +-- @param #float t -------------------------------- +-- -- @function [parent=#ParticleSystem] isAutoRemoveOnFinish -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- maximum particles of the system -- @function [parent=#ParticleSystem] getTotalParticles -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- -- @function [parent=#ParticleSystem] setStartRadiusVar -- @param self --- @param #float float +-- @param #float startRadiusVar -------------------------------- +-- -- @function [parent=#ParticleSystem] getEndRadiusVar -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- start color variance of each particle -- @function [parent=#ParticleSystem] getStartColorVar -- @param self -- @return color4f_table#color4f_table ret (return value: color4f_table) -------------------------------- +-- creates an initializes a ParticleSystem from a plist file.
+-- This plist files can be created manually or with Particle Designer:
+-- http:particledesigner.71squared.com/
+-- since v2.0 -- @function [parent=#ParticleSystem] create -- @param self --- @param #string str +-- @param #string plistFile -- @return ParticleSystem#ParticleSystem ret (return value: cc.ParticleSystem) -------------------------------- +-- create a system with a fixed number of particles -- @function [parent=#ParticleSystem] createWithTotalParticles -- @param self --- @param #int int +-- @param #int numberOfParticles -- @return ParticleSystem#ParticleSystem ret (return value: cc.ParticleSystem) -------------------------------- +-- -- @function [parent=#ParticleSystem] update -- @param self --- @param #float float +-- @param #float dt return nil diff --git a/cocos/scripting/lua-bindings/auto/api/ParticleSystemQuad.lua b/cocos/scripting/lua-bindings/auto/api/ParticleSystemQuad.lua index 92e7402676..b4efdc78a4 100644 --- a/cocos/scripting/lua-bindings/auto/api/ParticleSystemQuad.lua +++ b/cocos/scripting/lua-bindings/auto/api/ParticleSystemQuad.lua @@ -5,20 +5,30 @@ -- @parent_module cc -------------------------------- +-- Sets a new SpriteFrame as particle.
+-- WARNING: this method is experimental. Use setTextureWithRect instead.
+-- since v0.99.4 -- @function [parent=#ParticleSystemQuad] setDisplayFrame -- @param self --- @param #cc.SpriteFrame spriteframe +-- @param #cc.SpriteFrame spriteFrame -------------------------------- +-- Sets a new texture with a rect. The rect is in Points.
+-- since v0.99.4
+-- js NA
+-- lua NA -- @function [parent=#ParticleSystemQuad] setTextureWithRect -- @param self --- @param #cc.Texture2D texture2d +-- @param #cc.Texture2D texture -- @param #rect_table rect -------------------------------- +-- listen the event that renderer was recreated on Android/WP8
+-- js NA
+-- lua NA -- @function [parent=#ParticleSystemQuad] listenRendererRecreated -- @param self --- @param #cc.EventCustom eventcustom +-- @param #cc.EventCustom event -------------------------------- -- @overload self, string @@ -26,16 +36,18 @@ -- @overload self, map_table -- @function [parent=#ParticleSystemQuad] create -- @param self --- @param #map_table map +-- @param #map_table dictionary -- @return ParticleSystemQuad#ParticleSystemQuad ret (retunr value: cc.ParticleSystemQuad) -------------------------------- +-- creates a Particle Emitter with a number of particles -- @function [parent=#ParticleSystemQuad] createWithTotalParticles -- @param self --- @param #int int +-- @param #int numberOfParticles -- @return ParticleSystemQuad#ParticleSystemQuad ret (return value: cc.ParticleSystemQuad) -------------------------------- +-- -- @function [parent=#ParticleSystemQuad] getDescription -- @param self -- @return string#string ret (return value: string) diff --git a/cocos/scripting/lua-bindings/auto/api/PhysicsBody.lua b/cocos/scripting/lua-bindings/auto/api/PhysicsBody.lua index 6e90f80f52..62e4933a0b 100644 --- a/cocos/scripting/lua-bindings/auto/api/PhysicsBody.lua +++ b/cocos/scripting/lua-bindings/auto/api/PhysicsBody.lua @@ -5,45 +5,56 @@ -- @parent_module cc -------------------------------- +-- whether this physics body is affected by the physics world’s gravitational force. -- @function [parent=#PhysicsBody] isGravityEnabled -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- reset all the force applied to body. -- @function [parent=#PhysicsBody] resetForces -- @param self -------------------------------- +-- get the max of velocity -- @function [parent=#PhysicsBody] getVelocityLimit -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- set the group of body
+-- Collision groups let you specify an integral group index. You can have all fixtures with the same group index always collide (positive index) or never collide (negative index)
+-- it have high priority than bit masks -- @function [parent=#PhysicsBody] setGroup -- @param self --- @param #int int +-- @param #int group -------------------------------- +-- get the body mass. -- @function [parent=#PhysicsBody] getMass -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- Return bitmask of first shape, if there is no shape in body, return default value.(0xFFFFFFFF) -- @function [parent=#PhysicsBody] getCollisionBitmask -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- set the body rotation offset -- @function [parent=#PhysicsBody] getRotationOffset -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- get the body rotation. -- @function [parent=#PhysicsBody] getRotation -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- get the body moment of inertia. -- @function [parent=#PhysicsBody] getMoment -- @param self -- @return float#float ret (return value: float) @@ -53,166 +64,204 @@ -- @overload self, vec2_table -- @function [parent=#PhysicsBody] applyImpulse -- @param self --- @param #vec2_table vec2 --- @param #vec2_table vec2 +-- @param #vec2_table impulse +-- @param #vec2_table offset -------------------------------- +-- set body rotation offset, it's the rotation witch relative to node -- @function [parent=#PhysicsBody] setRotationOffset -- @param self --- @param #float float +-- @param #float rotation -------------------------------- -- @overload self, vec2_table, vec2_table -- @overload self, vec2_table -- @function [parent=#PhysicsBody] applyForce -- @param self --- @param #vec2_table vec2 --- @param #vec2_table vec2 +-- @param #vec2_table force +-- @param #vec2_table offset -------------------------------- +-- -- @function [parent=#PhysicsBody] addShape -- @param self --- @param #cc.PhysicsShape physicsshape --- @param #bool bool +-- @param #cc.PhysicsShape shape +-- @param #bool addMassAndMoment -- @return PhysicsShape#PhysicsShape ret (return value: cc.PhysicsShape) -------------------------------- +-- Applies a torque force to body. -- @function [parent=#PhysicsBody] applyTorque -- @param self --- @param #float float +-- @param #float torque -------------------------------- +-- get the max of angular velocity -- @function [parent=#PhysicsBody] getAngularVelocityLimit -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- set the max of angular velocity -- @function [parent=#PhysicsBody] setAngularVelocityLimit -- @param self --- @param #float float +-- @param #float limit -------------------------------- +-- get the velocity of a body -- @function [parent=#PhysicsBody] getVelocity -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- get linear damping. -- @function [parent=#PhysicsBody] getLinearDamping -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#PhysicsBody] removeAllShapes -- @param self -------------------------------- +-- set angular damping.
+-- it is used to simulate fluid or air friction forces on the body.
+-- the value is 0.0f to 1.0f. -- @function [parent=#PhysicsBody] setAngularDamping -- @param self --- @param #float float +-- @param #float damping -------------------------------- +-- set the max of velocity -- @function [parent=#PhysicsBody] setVelocityLimit -- @param self --- @param #float float +-- @param #float limit -------------------------------- +-- set body to rest -- @function [parent=#PhysicsBody] setResting -- @param self --- @param #bool bool +-- @param #bool rest -------------------------------- +-- get body position offset. -- @function [parent=#PhysicsBody] getPositionOffset -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- A mask that defines which categories this physics body belongs to.
+-- Every physics body in a scene can be assigned to up to 32 different categories, each corresponding to a bit in the bit mask. You define the mask values used in your game. In conjunction with the collisionBitMask and contactTestBitMask properties, you define which physics bodies interact with each other and when your game is notified of these interactions.
+-- The default value is 0xFFFFFFFF (all bits set). -- @function [parent=#PhysicsBody] setCategoryBitmask -- @param self --- @param #int int +-- @param #int bitmask -------------------------------- +-- get the world body added to. -- @function [parent=#PhysicsBody] getWorld -- @param self -- @return PhysicsWorld#PhysicsWorld ret (return value: cc.PhysicsWorld) -------------------------------- +-- get the angular velocity of a body -- @function [parent=#PhysicsBody] getAngularVelocity -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- get the body position. -- @function [parent=#PhysicsBody] getPosition -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- set the enable value.
+-- if the body it isn't enabled, it will not has simulation by world -- @function [parent=#PhysicsBody] setEnable -- @param self --- @param #bool bool +-- @param #bool enable -------------------------------- +-- set the body is affected by the physics world's gravitational force or not. -- @function [parent=#PhysicsBody] setGravityEnable -- @param self --- @param #bool bool +-- @param #bool enable -------------------------------- +-- Return group of first shape, if there is no shape in body, return default value.(0) -- @function [parent=#PhysicsBody] getGroup -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- brief set the body moment of inertia.
+-- note if you need add/subtract moment to body, don't use setMoment(getMoment() +/- moment), because the moment of body may be equal to PHYSICS_INFINITY, it will cause some unexpected result, please use addMoment() instead. -- @function [parent=#PhysicsBody] setMoment -- @param self --- @param #float float +-- @param #float moment -------------------------------- +-- get the body's tag -- @function [parent=#PhysicsBody] getTag -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- convert the local point to world -- @function [parent=#PhysicsBody] local2World -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table point -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- Return bitmask of first shape, if there is no shape in body, return default value.(0xFFFFFFFF) -- @function [parent=#PhysicsBody] getCategoryBitmask -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- brief set dynamic to body.
+-- a dynamic body will effect with gravity. -- @function [parent=#PhysicsBody] setDynamic -- @param self --- @param #bool bool +-- @param #bool dynamic -------------------------------- +-- -- @function [parent=#PhysicsBody] getFirstShape -- @param self -- @return PhysicsShape#PhysicsShape ret (return value: cc.PhysicsShape) -------------------------------- +-- -- @function [parent=#PhysicsBody] getShapes -- @param self -- @return array_table#array_table ret (return value: array_table) -------------------------------- +-- Return bitmask of first shape, if there is no shape in body, return default value.(0x00000000) -- @function [parent=#PhysicsBody] getContactTestBitmask -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- set the angular velocity of a body -- @function [parent=#PhysicsBody] setAngularVelocity -- @param self --- @param #float float +-- @param #float velocity -------------------------------- +-- convert the world point to local -- @function [parent=#PhysicsBody] world2Local -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table point -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- whether the body is enabled
+-- if the body it isn't enabled, it will not has simulation by world -- @function [parent=#PhysicsBody] isEnabled -- @param self -- @return bool#bool ret (return value: bool) @@ -222,121 +271,160 @@ -- @overload self, cc.PhysicsShape, bool -- @function [parent=#PhysicsBody] removeShape -- @param self --- @param #cc.PhysicsShape physicsshape --- @param #bool bool +-- @param #cc.PhysicsShape shape +-- @param #bool reduceMassAndMoment -------------------------------- +-- brief set the body mass.
+-- note if you need add/subtract mass to body, don't use setMass(getMass() +/- mass), because the mass of body may be equal to PHYSICS_INFINITY, it will cause some unexpected result, please use addMass() instead. -- @function [parent=#PhysicsBody] setMass -- @param self --- @param #float float +-- @param #float mass -------------------------------- +-- brief add moment of inertia to body.
+-- if _moment(moment of the body) == PHYSICS_INFINITY, it remains.
+-- if moment == PHYSICS_INFINITY, _moment will be PHYSICS_INFINITY.
+-- if moment == -PHYSICS_INFINITY, _moment will not change.
+-- if moment + _moment <= 0, _moment will equal to MASS_DEFAULT(1.0)
+-- other wise, moment = moment + _moment; -- @function [parent=#PhysicsBody] addMoment -- @param self --- @param #float float +-- @param #float moment -------------------------------- +-- set the velocity of a body -- @function [parent=#PhysicsBody] setVelocity -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table velocity -------------------------------- +-- set linear damping.
+-- it is used to simulate fluid or air friction forces on the body.
+-- the value is 0.0f to 1.0f. -- @function [parent=#PhysicsBody] setLinearDamping -- @param self --- @param #float float +-- @param #float damping -------------------------------- +-- A mask that defines which categories of physics bodies can collide with this physics body.
+-- When two physics bodies contact each other, a collision may occur. This body’s collision mask is compared to the other body’s category mask by performing a logical AND operation. If the result is a non-zero value, then this body is affected by the collision. Each body independently chooses whether it wants to be affected by the other body. For example, you might use this to avoid collision calculations that would make negligible changes to a body’s velocity.
+-- The default value is 0xFFFFFFFF (all bits set). -- @function [parent=#PhysicsBody] setCollisionBitmask -- @param self --- @param #int int +-- @param #int bitmask -------------------------------- +-- set body position offset, it's the position witch relative to node -- @function [parent=#PhysicsBody] setPositionOffset -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table position -------------------------------- +-- set the body is allow rotation or not -- @function [parent=#PhysicsBody] setRotationEnable -- @param self --- @param #bool bool +-- @param #bool enable -------------------------------- +-- whether the body can rotation -- @function [parent=#PhysicsBody] isRotationEnabled -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- get angular damping. -- @function [parent=#PhysicsBody] getAngularDamping -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- get the angular velocity of a body at a local point -- @function [parent=#PhysicsBody] getVelocityAtLocalPoint -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table point -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- whether the body is at rest -- @function [parent=#PhysicsBody] isResting -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- brief add mass to body.
+-- if _mass(mass of the body) == PHYSICS_INFINITY, it remains.
+-- if mass == PHYSICS_INFINITY, _mass will be PHYSICS_INFINITY.
+-- if mass == -PHYSICS_INFINITY, _mass will not change.
+-- if mass + _mass <= 0, _mass will equal to MASS_DEFAULT(1.0)
+-- other wise, mass = mass + _mass; -- @function [parent=#PhysicsBody] addMass -- @param self --- @param #float float +-- @param #float mass -------------------------------- +-- -- @function [parent=#PhysicsBody] getShape -- @param self --- @param #int int +-- @param #int tag -- @return PhysicsShape#PhysicsShape ret (return value: cc.PhysicsShape) -------------------------------- +-- set the body's tag -- @function [parent=#PhysicsBody] setTag -- @param self --- @param #int int +-- @param #int tag -------------------------------- +-- get the angular velocity of a body at a world point -- @function [parent=#PhysicsBody] getVelocityAtWorldPoint -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table point -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- A mask that defines which categories of bodies cause intersection notifications with this physics body.
+-- When two bodies share the same space, each body’s category mask is tested against the other body’s contact mask by performing a logical AND operation. If either comparison results in a non-zero value, an PhysicsContact object is created and passed to the physics world’s delegate. For best performance, only set bits in the contacts mask for interactions you are interested in.
+-- The default value is 0x00000000 (all bits cleared). -- @function [parent=#PhysicsBody] setContactTestBitmask -- @param self --- @param #int int +-- @param #int bitmask -------------------------------- +-- remove the body from the world it added to -- @function [parent=#PhysicsBody] removeFromWorld -- @param self -------------------------------- +-- brief test the body is dynamic or not.
+-- a dynamic body will effect with gravity. -- @function [parent=#PhysicsBody] isDynamic -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- get the sprite the body set to. -- @function [parent=#PhysicsBody] getNode -- @param self -- @return Node#Node ret (return value: cc.Node) -------------------------------- +-- Create a body contains a box shape. -- @function [parent=#PhysicsBody] createBox -- @param self -- @param #size_table size --- @param #cc.PhysicsMaterial physicsmaterial --- @param #vec2_table vec2 +-- @param #cc.PhysicsMaterial material +-- @param #vec2_table offset -- @return PhysicsBody#PhysicsBody ret (return value: cc.PhysicsBody) -------------------------------- +-- Create a body contains a EdgeSegment shape. -- @function [parent=#PhysicsBody] createEdgeSegment -- @param self --- @param #vec2_table vec2 --- @param #vec2_table vec2 --- @param #cc.PhysicsMaterial physicsmaterial --- @param #float float +-- @param #vec2_table a +-- @param #vec2_table b +-- @param #cc.PhysicsMaterial material +-- @param #float border -- @return PhysicsBody#PhysicsBody ret (return value: cc.PhysicsBody) -------------------------------- @@ -345,25 +433,27 @@ -- @overload self, float, float -- @function [parent=#PhysicsBody] create -- @param self --- @param #float float --- @param #float float +-- @param #float mass +-- @param #float moment -- @return PhysicsBody#PhysicsBody ret (retunr value: cc.PhysicsBody) -------------------------------- +-- Create a body contains a EdgeBox shape. -- @function [parent=#PhysicsBody] createEdgeBox -- @param self -- @param #size_table size --- @param #cc.PhysicsMaterial physicsmaterial --- @param #float float --- @param #vec2_table vec2 +-- @param #cc.PhysicsMaterial material +-- @param #float border +-- @param #vec2_table offset -- @return PhysicsBody#PhysicsBody ret (return value: cc.PhysicsBody) -------------------------------- +-- Create a body contains a circle shape. -- @function [parent=#PhysicsBody] createCircle -- @param self --- @param #float float --- @param #cc.PhysicsMaterial physicsmaterial --- @param #vec2_table vec2 +-- @param #float radius +-- @param #cc.PhysicsMaterial material +-- @param #vec2_table offset -- @return PhysicsBody#PhysicsBody ret (return value: cc.PhysicsBody) return nil diff --git a/cocos/scripting/lua-bindings/auto/api/PhysicsContact.lua b/cocos/scripting/lua-bindings/auto/api/PhysicsContact.lua index 30d6f985d3..c7fce04e0a 100644 --- a/cocos/scripting/lua-bindings/auto/api/PhysicsContact.lua +++ b/cocos/scripting/lua-bindings/auto/api/PhysicsContact.lua @@ -5,26 +5,31 @@ -- @parent_module cc -------------------------------- +-- get contact data -- @function [parent=#PhysicsContact] getContactData -- @param self -- @return PhysicsContactData#PhysicsContactData ret (return value: cc.PhysicsContactData) -------------------------------- +-- get the event code -- @function [parent=#PhysicsContact] getEventCode -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- get previous contact data -- @function [parent=#PhysicsContact] getPreContactData -- @param self -- @return PhysicsContactData#PhysicsContactData ret (return value: cc.PhysicsContactData) -------------------------------- +-- get contact shape A. -- @function [parent=#PhysicsContact] getShapeA -- @param self -- @return PhysicsShape#PhysicsShape ret (return value: cc.PhysicsShape) -------------------------------- +-- get contact shape B. -- @function [parent=#PhysicsContact] getShapeB -- @param self -- @return PhysicsShape#PhysicsShape ret (return value: cc.PhysicsShape) diff --git a/cocos/scripting/lua-bindings/auto/api/PhysicsContactPostSolve.lua b/cocos/scripting/lua-bindings/auto/api/PhysicsContactPostSolve.lua index 30efdef896..15b4e7932a 100644 --- a/cocos/scripting/lua-bindings/auto/api/PhysicsContactPostSolve.lua +++ b/cocos/scripting/lua-bindings/auto/api/PhysicsContactPostSolve.lua @@ -4,16 +4,19 @@ -- @parent_module cc -------------------------------- +-- get friction between two bodies -- @function [parent=#PhysicsContactPostSolve] getFriction -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- get surface velocity between two bodies -- @function [parent=#PhysicsContactPostSolve] getSurfaceVelocity -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- get restitution between two bodies -- @function [parent=#PhysicsContactPostSolve] getRestitution -- @param self -- @return float#float ret (return value: float) diff --git a/cocos/scripting/lua-bindings/auto/api/PhysicsContactPreSolve.lua b/cocos/scripting/lua-bindings/auto/api/PhysicsContactPreSolve.lua index fdf2df8e50..911ca67ece 100644 --- a/cocos/scripting/lua-bindings/auto/api/PhysicsContactPreSolve.lua +++ b/cocos/scripting/lua-bindings/auto/api/PhysicsContactPreSolve.lua @@ -4,37 +4,44 @@ -- @parent_module cc -------------------------------- +-- get friction between two bodies -- @function [parent=#PhysicsContactPreSolve] getFriction -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- get restitution between two bodies -- @function [parent=#PhysicsContactPreSolve] getRestitution -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- set the friction -- @function [parent=#PhysicsContactPreSolve] setFriction -- @param self --- @param #float float +-- @param #float friction -------------------------------- +-- ignore the rest of the contact presolve and postsolve callbacks -- @function [parent=#PhysicsContactPreSolve] ignore -- @param self -------------------------------- +-- get surface velocity between two bodies -- @function [parent=#PhysicsContactPreSolve] getSurfaceVelocity -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- set the surface velocity -- @function [parent=#PhysicsContactPreSolve] setSurfaceVelocity -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table velocity -------------------------------- +-- set the restitution -- @function [parent=#PhysicsContactPreSolve] setRestitution -- @param self --- @param #float float +-- @param #float restitution return nil diff --git a/cocos/scripting/lua-bindings/auto/api/PhysicsJoint.lua b/cocos/scripting/lua-bindings/auto/api/PhysicsJoint.lua index 93cffc0a79..bd755d2459 100644 --- a/cocos/scripting/lua-bindings/auto/api/PhysicsJoint.lua +++ b/cocos/scripting/lua-bindings/auto/api/PhysicsJoint.lua @@ -4,67 +4,80 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#PhysicsJoint] getBodyA -- @param self -- @return PhysicsBody#PhysicsBody ret (return value: cc.PhysicsBody) -------------------------------- +-- -- @function [parent=#PhysicsJoint] getBodyB -- @param self -- @return PhysicsBody#PhysicsBody ret (return value: cc.PhysicsBody) -------------------------------- +-- Get the max force setting -- @function [parent=#PhysicsJoint] getMaxForce -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- Set the max force between two bodies -- @function [parent=#PhysicsJoint] setMaxForce -- @param self --- @param #float float +-- @param #float force -------------------------------- +-- -- @function [parent=#PhysicsJoint] isEnabled -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- Enable/Disable the joint -- @function [parent=#PhysicsJoint] setEnable -- @param self --- @param #bool bool +-- @param #bool enable -------------------------------- +-- Enable/disable the collision between two bodies -- @function [parent=#PhysicsJoint] setCollisionEnable -- @param self --- @param #bool bool +-- @param #bool enable -------------------------------- +-- -- @function [parent=#PhysicsJoint] getWorld -- @param self -- @return PhysicsWorld#PhysicsWorld ret (return value: cc.PhysicsWorld) -------------------------------- +-- -- @function [parent=#PhysicsJoint] setTag -- @param self --- @param #int int +-- @param #int tag -------------------------------- +-- Remove the joint from the world -- @function [parent=#PhysicsJoint] removeFormWorld -- @param self -------------------------------- +-- -- @function [parent=#PhysicsJoint] isCollisionEnabled -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#PhysicsJoint] getTag -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- Distory the joint -- @function [parent=#PhysicsJoint] destroy -- @param self --- @param #cc.PhysicsJoint physicsjoint +-- @param #cc.PhysicsJoint joint return nil diff --git a/cocos/scripting/lua-bindings/auto/api/PhysicsJointDistance.lua b/cocos/scripting/lua-bindings/auto/api/PhysicsJointDistance.lua index 854ab0a0da..2bfabc2470 100644 --- a/cocos/scripting/lua-bindings/auto/api/PhysicsJointDistance.lua +++ b/cocos/scripting/lua-bindings/auto/api/PhysicsJointDistance.lua @@ -5,22 +5,25 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#PhysicsJointDistance] setDistance -- @param self --- @param #float float +-- @param #float distance -------------------------------- +-- -- @function [parent=#PhysicsJointDistance] getDistance -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#PhysicsJointDistance] construct -- @param self --- @param #cc.PhysicsBody physicsbody --- @param #cc.PhysicsBody physicsbody --- @param #vec2_table vec2 --- @param #vec2_table vec2 +-- @param #cc.PhysicsBody a +-- @param #cc.PhysicsBody b +-- @param #vec2_table anchr1 +-- @param #vec2_table anchr2 -- @return PhysicsJointDistance#PhysicsJointDistance ret (return value: cc.PhysicsJointDistance) return nil diff --git a/cocos/scripting/lua-bindings/auto/api/PhysicsJointFixed.lua b/cocos/scripting/lua-bindings/auto/api/PhysicsJointFixed.lua index b3daf9fcb2..a4f86b1dc5 100644 --- a/cocos/scripting/lua-bindings/auto/api/PhysicsJointFixed.lua +++ b/cocos/scripting/lua-bindings/auto/api/PhysicsJointFixed.lua @@ -5,11 +5,12 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#PhysicsJointFixed] construct -- @param self --- @param #cc.PhysicsBody physicsbody --- @param #cc.PhysicsBody physicsbody --- @param #vec2_table vec2 +-- @param #cc.PhysicsBody a +-- @param #cc.PhysicsBody b +-- @param #vec2_table anchr -- @return PhysicsJointFixed#PhysicsJointFixed ret (return value: cc.PhysicsJointFixed) return nil diff --git a/cocos/scripting/lua-bindings/auto/api/PhysicsJointGear.lua b/cocos/scripting/lua-bindings/auto/api/PhysicsJointGear.lua index 08c0c858cf..80c94bce3b 100644 --- a/cocos/scripting/lua-bindings/auto/api/PhysicsJointGear.lua +++ b/cocos/scripting/lua-bindings/auto/api/PhysicsJointGear.lua @@ -5,32 +5,37 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#PhysicsJointGear] setRatio -- @param self --- @param #float float +-- @param #float ratchet -------------------------------- +-- -- @function [parent=#PhysicsJointGear] getPhase -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#PhysicsJointGear] setPhase -- @param self --- @param #float float +-- @param #float phase -------------------------------- +-- -- @function [parent=#PhysicsJointGear] getRatio -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#PhysicsJointGear] construct -- @param self --- @param #cc.PhysicsBody physicsbody --- @param #cc.PhysicsBody physicsbody --- @param #float float --- @param #float float +-- @param #cc.PhysicsBody a +-- @param #cc.PhysicsBody b +-- @param #float phase +-- @param #float ratio -- @return PhysicsJointGear#PhysicsJointGear ret (return value: cc.PhysicsJointGear) return nil diff --git a/cocos/scripting/lua-bindings/auto/api/PhysicsJointGroove.lua b/cocos/scripting/lua-bindings/auto/api/PhysicsJointGroove.lua index 9f71e7cfc6..1e0c0f8b9e 100644 --- a/cocos/scripting/lua-bindings/auto/api/PhysicsJointGroove.lua +++ b/cocos/scripting/lua-bindings/auto/api/PhysicsJointGroove.lua @@ -5,43 +5,50 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#PhysicsJointGroove] setAnchr2 -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table anchr2 -------------------------------- +-- -- @function [parent=#PhysicsJointGroove] setGrooveA -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table grooveA -------------------------------- +-- -- @function [parent=#PhysicsJointGroove] setGrooveB -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table grooveB -------------------------------- +-- -- @function [parent=#PhysicsJointGroove] getGrooveA -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- -- @function [parent=#PhysicsJointGroove] getGrooveB -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- -- @function [parent=#PhysicsJointGroove] getAnchr2 -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- -- @function [parent=#PhysicsJointGroove] construct -- @param self --- @param #cc.PhysicsBody physicsbody --- @param #cc.PhysicsBody physicsbody --- @param #vec2_table vec2 --- @param #vec2_table vec2 --- @param #vec2_table vec2 +-- @param #cc.PhysicsBody a +-- @param #cc.PhysicsBody b +-- @param #vec2_table grooveA +-- @param #vec2_table grooveB +-- @param #vec2_table anchr2 -- @return PhysicsJointGroove#PhysicsJointGroove ret (return value: cc.PhysicsJointGroove) return nil diff --git a/cocos/scripting/lua-bindings/auto/api/PhysicsJointLimit.lua b/cocos/scripting/lua-bindings/auto/api/PhysicsJointLimit.lua index 796d4143c2..6b4a92acd8 100644 --- a/cocos/scripting/lua-bindings/auto/api/PhysicsJointLimit.lua +++ b/cocos/scripting/lua-bindings/auto/api/PhysicsJointLimit.lua @@ -5,56 +5,64 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#PhysicsJointLimit] setAnchr2 -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table anchr2 -------------------------------- +-- -- @function [parent=#PhysicsJointLimit] setAnchr1 -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table anchr1 -------------------------------- +-- -- @function [parent=#PhysicsJointLimit] setMax -- @param self --- @param #float float +-- @param #float max -------------------------------- +-- -- @function [parent=#PhysicsJointLimit] getAnchr2 -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- -- @function [parent=#PhysicsJointLimit] getAnchr1 -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- -- @function [parent=#PhysicsJointLimit] getMin -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#PhysicsJointLimit] getMax -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#PhysicsJointLimit] setMin -- @param self --- @param #float float +-- @param #float min -------------------------------- -- @overload self, cc.PhysicsBody, cc.PhysicsBody, vec2_table, vec2_table, float, float -- @overload self, cc.PhysicsBody, cc.PhysicsBody, vec2_table, vec2_table -- @function [parent=#PhysicsJointLimit] construct -- @param self --- @param #cc.PhysicsBody physicsbody --- @param #cc.PhysicsBody physicsbody --- @param #vec2_table vec2 --- @param #vec2_table vec2 --- @param #float float --- @param #float float +-- @param #cc.PhysicsBody a +-- @param #cc.PhysicsBody b +-- @param #vec2_table anchr1 +-- @param #vec2_table anchr2 +-- @param #float min +-- @param #float max -- @return PhysicsJointLimit#PhysicsJointLimit ret (retunr value: cc.PhysicsJointLimit) return nil diff --git a/cocos/scripting/lua-bindings/auto/api/PhysicsJointMotor.lua b/cocos/scripting/lua-bindings/auto/api/PhysicsJointMotor.lua index 733df66a22..27f44d36aa 100644 --- a/cocos/scripting/lua-bindings/auto/api/PhysicsJointMotor.lua +++ b/cocos/scripting/lua-bindings/auto/api/PhysicsJointMotor.lua @@ -5,21 +5,24 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#PhysicsJointMotor] setRate -- @param self --- @param #float float +-- @param #float rate -------------------------------- +-- -- @function [parent=#PhysicsJointMotor] getRate -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#PhysicsJointMotor] construct -- @param self --- @param #cc.PhysicsBody physicsbody --- @param #cc.PhysicsBody physicsbody --- @param #float float +-- @param #cc.PhysicsBody a +-- @param #cc.PhysicsBody b +-- @param #float rate -- @return PhysicsJointMotor#PhysicsJointMotor ret (return value: cc.PhysicsJointMotor) return nil diff --git a/cocos/scripting/lua-bindings/auto/api/PhysicsJointPin.lua b/cocos/scripting/lua-bindings/auto/api/PhysicsJointPin.lua index 0934a2f851..c45189c216 100644 --- a/cocos/scripting/lua-bindings/auto/api/PhysicsJointPin.lua +++ b/cocos/scripting/lua-bindings/auto/api/PhysicsJointPin.lua @@ -5,11 +5,12 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#PhysicsJointPin] construct -- @param self --- @param #cc.PhysicsBody physicsbody --- @param #cc.PhysicsBody physicsbody --- @param #vec2_table vec2 +-- @param #cc.PhysicsBody a +-- @param #cc.PhysicsBody b +-- @param #vec2_table anchr -- @return PhysicsJointPin#PhysicsJointPin ret (return value: cc.PhysicsJointPin) return nil diff --git a/cocos/scripting/lua-bindings/auto/api/PhysicsJointRatchet.lua b/cocos/scripting/lua-bindings/auto/api/PhysicsJointRatchet.lua index 7002033ba4..f61f444ffd 100644 --- a/cocos/scripting/lua-bindings/auto/api/PhysicsJointRatchet.lua +++ b/cocos/scripting/lua-bindings/auto/api/PhysicsJointRatchet.lua @@ -5,42 +5,49 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#PhysicsJointRatchet] getAngle -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#PhysicsJointRatchet] setAngle -- @param self --- @param #float float +-- @param #float angle -------------------------------- +-- -- @function [parent=#PhysicsJointRatchet] setPhase -- @param self --- @param #float float +-- @param #float phase -------------------------------- +-- -- @function [parent=#PhysicsJointRatchet] getPhase -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#PhysicsJointRatchet] setRatchet -- @param self --- @param #float float +-- @param #float ratchet -------------------------------- +-- -- @function [parent=#PhysicsJointRatchet] getRatchet -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#PhysicsJointRatchet] construct -- @param self --- @param #cc.PhysicsBody physicsbody --- @param #cc.PhysicsBody physicsbody --- @param #float float --- @param #float float +-- @param #cc.PhysicsBody a +-- @param #cc.PhysicsBody b +-- @param #float phase +-- @param #float ratchet -- @return PhysicsJointRatchet#PhysicsJointRatchet ret (return value: cc.PhysicsJointRatchet) return nil diff --git a/cocos/scripting/lua-bindings/auto/api/PhysicsJointRotaryLimit.lua b/cocos/scripting/lua-bindings/auto/api/PhysicsJointRotaryLimit.lua index db5d66222e..8feaf87785 100644 --- a/cocos/scripting/lua-bindings/auto/api/PhysicsJointRotaryLimit.lua +++ b/cocos/scripting/lua-bindings/auto/api/PhysicsJointRotaryLimit.lua @@ -5,21 +5,25 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#PhysicsJointRotaryLimit] getMax -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#PhysicsJointRotaryLimit] setMin -- @param self --- @param #float float +-- @param #float min -------------------------------- +-- -- @function [parent=#PhysicsJointRotaryLimit] setMax -- @param self --- @param #float float +-- @param #float max -------------------------------- +-- -- @function [parent=#PhysicsJointRotaryLimit] getMin -- @param self -- @return float#float ret (return value: float) @@ -29,10 +33,10 @@ -- @overload self, cc.PhysicsBody, cc.PhysicsBody, float, float -- @function [parent=#PhysicsJointRotaryLimit] construct -- @param self --- @param #cc.PhysicsBody physicsbody --- @param #cc.PhysicsBody physicsbody --- @param #float float --- @param #float float +-- @param #cc.PhysicsBody a +-- @param #cc.PhysicsBody b +-- @param #float min +-- @param #float max -- @return PhysicsJointRotaryLimit#PhysicsJointRotaryLimit ret (retunr value: cc.PhysicsJointRotaryLimit) return nil diff --git a/cocos/scripting/lua-bindings/auto/api/PhysicsJointRotarySpring.lua b/cocos/scripting/lua-bindings/auto/api/PhysicsJointRotarySpring.lua index 56e2bc4242..e8df535554 100644 --- a/cocos/scripting/lua-bindings/auto/api/PhysicsJointRotarySpring.lua +++ b/cocos/scripting/lua-bindings/auto/api/PhysicsJointRotarySpring.lua @@ -5,42 +5,49 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#PhysicsJointRotarySpring] getDamping -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#PhysicsJointRotarySpring] setRestAngle -- @param self --- @param #float float +-- @param #float restAngle -------------------------------- +-- -- @function [parent=#PhysicsJointRotarySpring] getStiffness -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#PhysicsJointRotarySpring] setStiffness -- @param self --- @param #float float +-- @param #float stiffness -------------------------------- +-- -- @function [parent=#PhysicsJointRotarySpring] setDamping -- @param self --- @param #float float +-- @param #float damping -------------------------------- +-- -- @function [parent=#PhysicsJointRotarySpring] getRestAngle -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#PhysicsJointRotarySpring] construct -- @param self --- @param #cc.PhysicsBody physicsbody --- @param #cc.PhysicsBody physicsbody --- @param #float float --- @param #float float +-- @param #cc.PhysicsBody a +-- @param #cc.PhysicsBody b +-- @param #float stiffness +-- @param #float damping -- @return PhysicsJointRotarySpring#PhysicsJointRotarySpring ret (return value: cc.PhysicsJointRotarySpring) return nil diff --git a/cocos/scripting/lua-bindings/auto/api/PhysicsJointSpring.lua b/cocos/scripting/lua-bindings/auto/api/PhysicsJointSpring.lua index b3c3b916b6..0b177ac1f4 100644 --- a/cocos/scripting/lua-bindings/auto/api/PhysicsJointSpring.lua +++ b/cocos/scripting/lua-bindings/auto/api/PhysicsJointSpring.lua @@ -5,64 +5,75 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#PhysicsJointSpring] setAnchr2 -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table anchr2 -------------------------------- +-- -- @function [parent=#PhysicsJointSpring] setAnchr1 -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table anchr1 -------------------------------- +-- -- @function [parent=#PhysicsJointSpring] getDamping -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#PhysicsJointSpring] setStiffness -- @param self --- @param #float float +-- @param #float stiffness -------------------------------- +-- -- @function [parent=#PhysicsJointSpring] getRestLength -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#PhysicsJointSpring] getAnchr2 -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- -- @function [parent=#PhysicsJointSpring] getAnchr1 -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- -- @function [parent=#PhysicsJointSpring] getStiffness -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#PhysicsJointSpring] setRestLength -- @param self --- @param #float float +-- @param #float restLength -------------------------------- +-- -- @function [parent=#PhysicsJointSpring] setDamping -- @param self --- @param #float float +-- @param #float damping -------------------------------- +-- -- @function [parent=#PhysicsJointSpring] construct -- @param self --- @param #cc.PhysicsBody physicsbody --- @param #cc.PhysicsBody physicsbody --- @param #vec2_table vec2 --- @param #vec2_table vec2 --- @param #float float --- @param #float float +-- @param #cc.PhysicsBody a +-- @param #cc.PhysicsBody b +-- @param #vec2_table anchr1 +-- @param #vec2_table anchr2 +-- @param #float stiffness +-- @param #float damping -- @return PhysicsJointSpring#PhysicsJointSpring ret (return value: cc.PhysicsJointSpring) return nil diff --git a/cocos/scripting/lua-bindings/auto/api/PhysicsShape.lua b/cocos/scripting/lua-bindings/auto/api/PhysicsShape.lua index 56d5538836..f3ee8f5126 100644 --- a/cocos/scripting/lua-bindings/auto/api/PhysicsShape.lua +++ b/cocos/scripting/lua-bindings/auto/api/PhysicsShape.lua @@ -5,147 +5,184 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#PhysicsShape] getFriction -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- set the group of body
+-- Collision groups let you specify an integral group index. You can have all fixtures with the same group index always collide (positive index) or never collide (negative index)
+-- it have high priority than bit masks -- @function [parent=#PhysicsShape] setGroup -- @param self --- @param #int int +-- @param #int group -------------------------------- +-- -- @function [parent=#PhysicsShape] setDensity -- @param self --- @param #float float +-- @param #float density -------------------------------- +-- get mass -- @function [parent=#PhysicsShape] getMass -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#PhysicsShape] getMaterial -- @param self -- @return PhysicsMaterial#PhysicsMaterial ret (return value: cc.PhysicsMaterial) -------------------------------- +-- -- @function [parent=#PhysicsShape] getCollisionBitmask -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- return the area of this shape -- @function [parent=#PhysicsShape] getArea -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- A mask that defines which categories this physics body belongs to.
+-- Every physics body in a scene can be assigned to up to 32 different categories, each corresponding to a bit in the bit mask. You define the mask values used in your game. In conjunction with the collisionBitMask and contactTestBitMask properties, you define which physics bodies interact with each other and when your game is notified of these interactions.
+-- The default value is 0xFFFFFFFF (all bits set). -- @function [parent=#PhysicsShape] setCategoryBitmask -- @param self --- @param #int int +-- @param #int bitmask -------------------------------- +-- -- @function [parent=#PhysicsShape] getGroup -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- Set moment, it will change the body's moment this shape attaches -- @function [parent=#PhysicsShape] setMoment -- @param self --- @param #float float +-- @param #float moment -------------------------------- +-- Test point is in shape or not -- @function [parent=#PhysicsShape] containsPoint -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table point -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#PhysicsShape] getCategoryBitmask -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- Return the type of this shape -- @function [parent=#PhysicsShape] getType -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- -- @function [parent=#PhysicsShape] getContactTestBitmask -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- Get center of this shape -- @function [parent=#PhysicsShape] getCenter -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- -- @function [parent=#PhysicsShape] getDensity -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- Set mass, it will change the body's mass this shape attaches -- @function [parent=#PhysicsShape] setMass -- @param self --- @param #float float +-- @param #float mass -------------------------------- +-- -- @function [parent=#PhysicsShape] getTag -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- Calculate the default moment value -- @function [parent=#PhysicsShape] calculateDefaultMoment -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- A mask that defines which categories of physics bodies can collide with this physics body.
+-- When two physics bodies contact each other, a collision may occur. This body’s collision mask is compared to the other body’s category mask by performing a logical AND operation. If the result is a non-zero value, then this body is affected by the collision. Each body independently chooses whether it wants to be affected by the other body. For example, you might use this to avoid collision calculations that would make negligible changes to a body’s velocity.
+-- The default value is 0xFFFFFFFF (all bits set). -- @function [parent=#PhysicsShape] setCollisionBitmask -- @param self --- @param #int int +-- @param #int bitmask -------------------------------- +-- get moment -- @function [parent=#PhysicsShape] getMoment -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- Get offset -- @function [parent=#PhysicsShape] getOffset -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- -- @function [parent=#PhysicsShape] getRestitution -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#PhysicsShape] setFriction -- @param self --- @param #float float +-- @param #float friction -------------------------------- +-- -- @function [parent=#PhysicsShape] setMaterial -- @param self --- @param #cc.PhysicsMaterial physicsmaterial +-- @param #cc.PhysicsMaterial material -------------------------------- +-- -- @function [parent=#PhysicsShape] setTag -- @param self --- @param #int int +-- @param #int tag -------------------------------- +-- A mask that defines which categories of bodies cause intersection notifications with this physics body.
+-- When two bodies share the same space, each body’s category mask is tested against the other body’s contact mask by performing a logical AND operation. If either comparison results in a non-zero value, an PhysicsContact object is created and passed to the physics world’s delegate. For best performance, only set bits in the contacts mask for interactions you are interested in.
+-- The default value is 0x00000000 (all bits cleared). -- @function [parent=#PhysicsShape] setContactTestBitmask -- @param self --- @param #int int +-- @param #int bitmask -------------------------------- +-- -- @function [parent=#PhysicsShape] setRestitution -- @param self --- @param #float float +-- @param #float restitution -------------------------------- +-- Get the body that this shape attaches -- @function [parent=#PhysicsShape] getBody -- @param self -- @return PhysicsBody#PhysicsBody ret (return value: cc.PhysicsBody) diff --git a/cocos/scripting/lua-bindings/auto/api/PhysicsShapeBox.lua b/cocos/scripting/lua-bindings/auto/api/PhysicsShapeBox.lua index 338ac5add2..a2a6c2a5ac 100644 --- a/cocos/scripting/lua-bindings/auto/api/PhysicsShapeBox.lua +++ b/cocos/scripting/lua-bindings/auto/api/PhysicsShapeBox.lua @@ -5,19 +5,22 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#PhysicsShapeBox] getSize -- @param self -- @return size_table#size_table ret (return value: size_table) -------------------------------- +-- -- @function [parent=#PhysicsShapeBox] create -- @param self -- @param #size_table size --- @param #cc.PhysicsMaterial physicsmaterial --- @param #vec2_table vec2 +-- @param #cc.PhysicsMaterial material +-- @param #vec2_table offset -- @return PhysicsShapeBox#PhysicsShapeBox ret (return value: cc.PhysicsShapeBox) -------------------------------- +-- -- @function [parent=#PhysicsShapeBox] getOffset -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) diff --git a/cocos/scripting/lua-bindings/auto/api/PhysicsShapeCircle.lua b/cocos/scripting/lua-bindings/auto/api/PhysicsShapeCircle.lua index 2fb52b6df9..324465d163 100644 --- a/cocos/scripting/lua-bindings/auto/api/PhysicsShapeCircle.lua +++ b/cocos/scripting/lua-bindings/auto/api/PhysicsShapeCircle.lua @@ -5,38 +5,44 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#PhysicsShapeCircle] getRadius -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#PhysicsShapeCircle] create -- @param self --- @param #float float --- @param #cc.PhysicsMaterial physicsmaterial --- @param #vec2_table vec2 +-- @param #float radius +-- @param #cc.PhysicsMaterial material +-- @param #vec2_table offset -- @return PhysicsShapeCircle#PhysicsShapeCircle ret (return value: cc.PhysicsShapeCircle) -------------------------------- +-- -- @function [parent=#PhysicsShapeCircle] calculateArea -- @param self --- @param #float float +-- @param #float radius -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#PhysicsShapeCircle] calculateMoment -- @param self --- @param #float float --- @param #float float --- @param #vec2_table vec2 +-- @param #float mass +-- @param #float radius +-- @param #vec2_table offset -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#PhysicsShapeCircle] getOffset -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- -- @function [parent=#PhysicsShapeCircle] calculateDefaultMoment -- @param self -- @return float#float ret (return value: float) diff --git a/cocos/scripting/lua-bindings/auto/api/PhysicsShapeEdgeBox.lua b/cocos/scripting/lua-bindings/auto/api/PhysicsShapeEdgeBox.lua index 6e879ad541..14fe760243 100644 --- a/cocos/scripting/lua-bindings/auto/api/PhysicsShapeEdgeBox.lua +++ b/cocos/scripting/lua-bindings/auto/api/PhysicsShapeEdgeBox.lua @@ -5,15 +5,17 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#PhysicsShapeEdgeBox] create -- @param self -- @param #size_table size --- @param #cc.PhysicsMaterial physicsmaterial --- @param #float float --- @param #vec2_table vec2 +-- @param #cc.PhysicsMaterial material +-- @param #float border +-- @param #vec2_table offset -- @return PhysicsShapeEdgeBox#PhysicsShapeEdgeBox ret (return value: cc.PhysicsShapeEdgeBox) -------------------------------- +-- -- @function [parent=#PhysicsShapeEdgeBox] getOffset -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) diff --git a/cocos/scripting/lua-bindings/auto/api/PhysicsShapeEdgeChain.lua b/cocos/scripting/lua-bindings/auto/api/PhysicsShapeEdgeChain.lua index d4dc91703e..40b42cf74a 100644 --- a/cocos/scripting/lua-bindings/auto/api/PhysicsShapeEdgeChain.lua +++ b/cocos/scripting/lua-bindings/auto/api/PhysicsShapeEdgeChain.lua @@ -5,11 +5,13 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#PhysicsShapeEdgeChain] getPointsCount -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- -- @function [parent=#PhysicsShapeEdgeChain] getCenter -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) diff --git a/cocos/scripting/lua-bindings/auto/api/PhysicsShapeEdgePolygon.lua b/cocos/scripting/lua-bindings/auto/api/PhysicsShapeEdgePolygon.lua index d2bbb2d42e..de1165c4ae 100644 --- a/cocos/scripting/lua-bindings/auto/api/PhysicsShapeEdgePolygon.lua +++ b/cocos/scripting/lua-bindings/auto/api/PhysicsShapeEdgePolygon.lua @@ -5,11 +5,13 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#PhysicsShapeEdgePolygon] getPointsCount -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- -- @function [parent=#PhysicsShapeEdgePolygon] getCenter -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) diff --git a/cocos/scripting/lua-bindings/auto/api/PhysicsShapeEdgeSegment.lua b/cocos/scripting/lua-bindings/auto/api/PhysicsShapeEdgeSegment.lua index c4588a7bf8..852c62a8af 100644 --- a/cocos/scripting/lua-bindings/auto/api/PhysicsShapeEdgeSegment.lua +++ b/cocos/scripting/lua-bindings/auto/api/PhysicsShapeEdgeSegment.lua @@ -5,25 +5,29 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#PhysicsShapeEdgeSegment] getPointB -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- -- @function [parent=#PhysicsShapeEdgeSegment] getPointA -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- -- @function [parent=#PhysicsShapeEdgeSegment] create -- @param self --- @param #vec2_table vec2 --- @param #vec2_table vec2 --- @param #cc.PhysicsMaterial physicsmaterial --- @param #float float +-- @param #vec2_table a +-- @param #vec2_table b +-- @param #cc.PhysicsMaterial material +-- @param #float border -- @return PhysicsShapeEdgeSegment#PhysicsShapeEdgeSegment ret (return value: cc.PhysicsShapeEdgeSegment) -------------------------------- +-- -- @function [parent=#PhysicsShapeEdgeSegment] getCenter -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) diff --git a/cocos/scripting/lua-bindings/auto/api/PhysicsShapePolygon.lua b/cocos/scripting/lua-bindings/auto/api/PhysicsShapePolygon.lua index c924c1a867..81c6bf76c1 100644 --- a/cocos/scripting/lua-bindings/auto/api/PhysicsShapePolygon.lua +++ b/cocos/scripting/lua-bindings/auto/api/PhysicsShapePolygon.lua @@ -5,22 +5,26 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#PhysicsShapePolygon] getPointsCount -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- -- @function [parent=#PhysicsShapePolygon] getPoint -- @param self --- @param #int int +-- @param #int i -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- -- @function [parent=#PhysicsShapePolygon] calculateDefaultMoment -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#PhysicsShapePolygon] getCenter -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) diff --git a/cocos/scripting/lua-bindings/auto/api/PhysicsWorld.lua b/cocos/scripting/lua-bindings/auto/api/PhysicsWorld.lua index 6c16ea6dc4..7a15ac9d59 100644 --- a/cocos/scripting/lua-bindings/auto/api/PhysicsWorld.lua +++ b/cocos/scripting/lua-bindings/auto/api/PhysicsWorld.lua @@ -4,35 +4,44 @@ -- @parent_module cc -------------------------------- +-- set the gravity value -- @function [parent=#PhysicsWorld] setGravity -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table gravity -------------------------------- +-- Get all the bodys that in the physics world. -- @function [parent=#PhysicsWorld] getAllBodies -- @param self -- @return array_table#array_table ret (return value: array_table) -------------------------------- +-- get the bebug draw mask -- @function [parent=#PhysicsWorld] getDebugDrawMask -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- To control the step of physics, if you want control it by yourself( fixed-timestep for example ), you can set this to false and call step by yourself.
+-- Defaut value is true.
+-- Note: if you set auto step to false, setSpeed and setUpdateRate won't work, you need to control the time step by yourself. -- @function [parent=#PhysicsWorld] setAutoStep -- @param self --- @param #bool bool +-- @param #bool autoStep -------------------------------- +-- Adds a joint to the physics world. -- @function [parent=#PhysicsWorld] addJoint -- @param self --- @param #cc.PhysicsJoint physicsjoint +-- @param #cc.PhysicsJoint joint -------------------------------- +-- Remove all joints from physics world. -- @function [parent=#PhysicsWorld] removeAllJoints -- @param self -------------------------------- +-- Get the auto step -- @function [parent=#PhysicsWorld] isAutoStep -- @param self -- @return bool#bool ret (return value: bool) @@ -42,69 +51,86 @@ -- @overload self, cc.PhysicsBody -- @function [parent=#PhysicsWorld] removeBody -- @param self --- @param #cc.PhysicsBody physicsbody +-- @param #cc.PhysicsBody body -------------------------------- +-- Remove a joint from physics world. -- @function [parent=#PhysicsWorld] removeJoint -- @param self --- @param #cc.PhysicsJoint physicsjoint --- @param #bool bool +-- @param #cc.PhysicsJoint joint +-- @param #bool destroy -------------------------------- +-- Get phsyics shapes that contains the point. -- @function [parent=#PhysicsWorld] getShapes -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table point -- @return array_table#array_table ret (return value: array_table) -------------------------------- +-- The step for physics world, The times passing for simulate the physics.
+-- Note: you need to setAutoStep(false) first before it can work. -- @function [parent=#PhysicsWorld] step -- @param self --- @param #float float +-- @param #float delta -------------------------------- +-- set the debug draw mask -- @function [parent=#PhysicsWorld] setDebugDrawMask -- @param self --- @param #int int +-- @param #int mask -------------------------------- +-- get the gravity value -- @function [parent=#PhysicsWorld] getGravity -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- set the update rate of physics world, update rate is the value of EngineUpdateTimes/PhysicsWorldUpdateTimes.
+-- set it higher can improve performance, set it lower can improve accuracy of physics world simulation.
+-- default value is 1.0
+-- Note: if you setAutoStep(false), this won't work. -- @function [parent=#PhysicsWorld] setUpdateRate -- @param self --- @param #int int +-- @param #int rate -------------------------------- +-- get the speed of physics world -- @function [parent=#PhysicsWorld] getSpeed -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- get the update rate -- @function [parent=#PhysicsWorld] getUpdateRate -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- Remove all bodies from physics world. -- @function [parent=#PhysicsWorld] removeAllBodies -- @param self -------------------------------- +-- Set the speed of physics world, speed is the rate at which the simulation executes. default value is 1.0
+-- Note: if you setAutoStep(false), this won't work. -- @function [parent=#PhysicsWorld] setSpeed -- @param self --- @param #float float +-- @param #float speed -------------------------------- +-- return physics shape that contains the point. -- @function [parent=#PhysicsWorld] getShape -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table point -- @return PhysicsShape#PhysicsShape ret (return value: cc.PhysicsShape) -------------------------------- +-- Get body by tag -- @function [parent=#PhysicsWorld] getBody -- @param self --- @param #int int +-- @param #int tag -- @return PhysicsBody#PhysicsBody ret (return value: cc.PhysicsBody) return nil diff --git a/cocos/scripting/lua-bindings/auto/api/Place.lua b/cocos/scripting/lua-bindings/auto/api/Place.lua index 11fb95222a..8592661d0f 100644 --- a/cocos/scripting/lua-bindings/auto/api/Place.lua +++ b/cocos/scripting/lua-bindings/auto/api/Place.lua @@ -5,22 +5,26 @@ -- @parent_module cc -------------------------------- +-- creates a Place action with a position -- @function [parent=#Place] create -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table pos -- @return Place#Place ret (return value: cc.Place) -------------------------------- +-- -- @function [parent=#Place] clone -- @param self -- @return Place#Place ret (return value: cc.Place) -------------------------------- +-- -- @function [parent=#Place] update -- @param self --- @param #float float +-- @param #float time -------------------------------- +-- -- @function [parent=#Place] reverse -- @param self -- @return Place#Place ret (return value: cc.Place) diff --git a/cocos/scripting/lua-bindings/auto/api/PositionFrame.lua b/cocos/scripting/lua-bindings/auto/api/PositionFrame.lua index 1fa6573504..8f31161282 100644 --- a/cocos/scripting/lua-bindings/auto/api/PositionFrame.lua +++ b/cocos/scripting/lua-bindings/auto/api/PositionFrame.lua @@ -5,51 +5,61 @@ -- @parent_module ccs -------------------------------- +-- -- @function [parent=#PositionFrame] getX -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#PositionFrame] getY -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#PositionFrame] setPosition -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table position -------------------------------- +-- -- @function [parent=#PositionFrame] setX -- @param self --- @param #float float +-- @param #float x -------------------------------- +-- -- @function [parent=#PositionFrame] setY -- @param self --- @param #float float +-- @param #float y -------------------------------- +-- -- @function [parent=#PositionFrame] getPosition -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- -- @function [parent=#PositionFrame] create -- @param self -- @return PositionFrame#PositionFrame ret (return value: ccs.PositionFrame) -------------------------------- +-- -- @function [parent=#PositionFrame] apply -- @param self --- @param #float float +-- @param #float percent -------------------------------- +-- -- @function [parent=#PositionFrame] clone -- @param self -- @return Frame#Frame ret (return value: ccs.Frame) -------------------------------- +-- -- @function [parent=#PositionFrame] PositionFrame -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/ProgressFromTo.lua b/cocos/scripting/lua-bindings/auto/api/ProgressFromTo.lua index 2b24b53b37..426f309feb 100644 --- a/cocos/scripting/lua-bindings/auto/api/ProgressFromTo.lua +++ b/cocos/scripting/lua-bindings/auto/api/ProgressFromTo.lua @@ -5,31 +5,36 @@ -- @parent_module cc -------------------------------- +-- Creates and initializes the action with a duration, a "from" percentage and a "to" percentage -- @function [parent=#ProgressFromTo] create -- @param self --- @param #float float --- @param #float float --- @param #float float +-- @param #float duration +-- @param #float fromPercentage +-- @param #float toPercentage -- @return ProgressFromTo#ProgressFromTo ret (return value: cc.ProgressFromTo) -------------------------------- +-- -- @function [parent=#ProgressFromTo] startWithTarget -- @param self --- @param #cc.Node node +-- @param #cc.Node target -------------------------------- +-- -- @function [parent=#ProgressFromTo] clone -- @param self -- @return ProgressFromTo#ProgressFromTo ret (return value: cc.ProgressFromTo) -------------------------------- +-- -- @function [parent=#ProgressFromTo] reverse -- @param self -- @return ProgressFromTo#ProgressFromTo ret (return value: cc.ProgressFromTo) -------------------------------- +-- -- @function [parent=#ProgressFromTo] update -- @param self --- @param #float float +-- @param #float time return nil diff --git a/cocos/scripting/lua-bindings/auto/api/ProgressTimer.lua b/cocos/scripting/lua-bindings/auto/api/ProgressTimer.lua index d19cf74354..7182839fc3 100644 --- a/cocos/scripting/lua-bindings/auto/api/ProgressTimer.lua +++ b/cocos/scripting/lua-bindings/auto/api/ProgressTimer.lua @@ -5,41 +5,59 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#ProgressTimer] isReverseDirection -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- This allows the bar type to move the component at a specific rate
+-- Set the component to 0 to make sure it stays at 100%.
+-- For example you want a left to right bar but not have the height stay 100%
+-- Set the rate to be Vec2(0,1); and set the midpoint to = Vec2(0,.5f); -- @function [parent=#ProgressTimer] setBarChangeRate -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table barChangeRate -------------------------------- +-- Percentages are from 0 to 100 -- @function [parent=#ProgressTimer] getPercentage -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#ProgressTimer] setSprite -- @param self -- @param #cc.Sprite sprite -------------------------------- +-- Change the percentage to change progress. -- @function [parent=#ProgressTimer] getType -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- The image to show the progress percentage, retain -- @function [parent=#ProgressTimer] getSprite -- @param self -- @return Sprite#Sprite ret (return value: cc.Sprite) -------------------------------- +-- Midpoint is used to modify the progress start position.
+-- If you're using radials type then the midpoint changes the center point
+-- If you're using bar type the the midpoint changes the bar growth
+-- it expands from the center but clamps to the sprites edge so:
+-- you want a left to right then set the midpoint all the way to Vec2(0,y)
+-- you want a right to left then set the midpoint all the way to Vec2(1,y)
+-- you want a bottom to top then set the midpoint all the way to Vec2(x,0)
+-- you want a top to bottom then set the midpoint all the way to Vec2(x,1) -- @function [parent=#ProgressTimer] setMidpoint -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table point -------------------------------- +-- Returns the BarChangeRate -- @function [parent=#ProgressTimer] getBarChangeRate -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) @@ -49,57 +67,67 @@ -- @overload self, bool -- @function [parent=#ProgressTimer] setReverseDirection -- @param self --- @param #bool bool +-- @param #bool reverse -------------------------------- +-- Returns the Midpoint -- @function [parent=#ProgressTimer] getMidpoint -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- -- @function [parent=#ProgressTimer] setPercentage -- @param self --- @param #float float +-- @param #float percentage -------------------------------- +-- -- @function [parent=#ProgressTimer] setType -- @param self -- @param #int type -------------------------------- +-- Creates a progress timer with the sprite as the shape the timer goes through -- @function [parent=#ProgressTimer] create -- @param self --- @param #cc.Sprite sprite +-- @param #cc.Sprite sp -- @return ProgressTimer#ProgressTimer ret (return value: cc.ProgressTimer) -------------------------------- +-- -- @function [parent=#ProgressTimer] setAnchorPoint -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table anchorPoint -------------------------------- +-- -- @function [parent=#ProgressTimer] draw -- @param self -- @param #cc.Renderer renderer --- @param #mat4_table mat4 --- @param #unsigned int int +-- @param #mat4_table transform +-- @param #unsigned int flags -------------------------------- +-- -- @function [parent=#ProgressTimer] setColor -- @param self --- @param #color3b_table color3b +-- @param #color3b_table color -------------------------------- +-- -- @function [parent=#ProgressTimer] getColor -- @param self -- @return color3b_table#color3b_table ret (return value: color3b_table) -------------------------------- +-- -- @function [parent=#ProgressTimer] setOpacity -- @param self --- @param #unsigned char char +-- @param #unsigned char opacity -------------------------------- +-- -- @function [parent=#ProgressTimer] getOpacity -- @param self -- @return unsigned char#unsigned char ret (return value: unsigned char) diff --git a/cocos/scripting/lua-bindings/auto/api/ProgressTo.lua b/cocos/scripting/lua-bindings/auto/api/ProgressTo.lua index 1eed2eefe4..1cf3d03f21 100644 --- a/cocos/scripting/lua-bindings/auto/api/ProgressTo.lua +++ b/cocos/scripting/lua-bindings/auto/api/ProgressTo.lua @@ -5,30 +5,35 @@ -- @parent_module cc -------------------------------- +-- Creates and initializes with a duration and a percent -- @function [parent=#ProgressTo] create -- @param self --- @param #float float --- @param #float float +-- @param #float duration +-- @param #float percent -- @return ProgressTo#ProgressTo ret (return value: cc.ProgressTo) -------------------------------- +-- -- @function [parent=#ProgressTo] startWithTarget -- @param self --- @param #cc.Node node +-- @param #cc.Node target -------------------------------- +-- -- @function [parent=#ProgressTo] clone -- @param self -- @return ProgressTo#ProgressTo ret (return value: cc.ProgressTo) -------------------------------- +-- -- @function [parent=#ProgressTo] reverse -- @param self -- @return ProgressTo#ProgressTo ret (return value: cc.ProgressTo) -------------------------------- +-- -- @function [parent=#ProgressTo] update -- @param self --- @param #float float +-- @param #float time return nil diff --git a/cocos/scripting/lua-bindings/auto/api/ProtectedNode.lua b/cocos/scripting/lua-bindings/auto/api/ProtectedNode.lua index 64c2d01165..c49c9574ad 100644 --- a/cocos/scripting/lua-bindings/auto/api/ProtectedNode.lua +++ b/cocos/scripting/lua-bindings/auto/api/ProtectedNode.lua @@ -10,78 +10,106 @@ -- @overload self, cc.Node, int, int -- @function [parent=#ProtectedNode] addProtectedChild -- @param self --- @param #cc.Node node --- @param #int int --- @param #int int +-- @param #cc.Node child +-- @param #int localZOrder +-- @param #int tag -------------------------------- +-- -- @function [parent=#ProtectedNode] disableCascadeColor -- @param self -------------------------------- +-- Removes a child from the container by tag value. It will also cleanup all running actions depending on the cleanup parameter
+-- param tag An interger number that identifies a child node
+-- param cleanup true if all running actions and callbacks on the child node will be cleanup, false otherwise. -- @function [parent=#ProtectedNode] removeProtectedChildByTag -- @param self --- @param #int int --- @param #bool bool +-- @param #int tag +-- @param #bool cleanup -------------------------------- +-- Reorders a child according to a new z value.
+-- param child An already added child node. It MUST be already added.
+-- param localZOrder Z order for drawing priority. Please refer to setLocalZOrder(int) -- @function [parent=#ProtectedNode] reorderProtectedChild -- @param self --- @param #cc.Node node --- @param #int int +-- @param #cc.Node child +-- @param #int localZOrder -------------------------------- +-- Removes all children from the container, and do a cleanup to all running actions depending on the cleanup parameter.
+-- param cleanup true if all running actions on all children nodes should be cleanup, false oterwise.
+-- js removeAllChildren
+-- lua removeAllChildren -- @function [parent=#ProtectedNode] removeAllProtectedChildrenWithCleanup -- @param self --- @param #bool bool +-- @param #bool cleanup -------------------------------- +-- -- @function [parent=#ProtectedNode] disableCascadeOpacity -- @param self -------------------------------- +-- Sorts the children array once before drawing, instead of every time when a child is added or reordered.
+-- This appraoch can improves the performance massively.
+-- note Don't call this manually unless a child added needs to be removed in the same frame -- @function [parent=#ProtectedNode] sortAllProtectedChildren -- @param self -------------------------------- +-- Gets a child from the container with its tag
+-- param tag An identifier to find the child node.
+-- return a Node object whose tag equals to the input parameter -- @function [parent=#ProtectedNode] getProtectedChildByTag -- @param self --- @param #int int +-- @param #int tag -- @return Node#Node ret (return value: cc.Node) -------------------------------- +-- Removes a child from the container. It will also cleanup all running actions depending on the cleanup parameter.
+-- param child The child node which will be removed.
+-- param cleanup true if all running actions and callbacks on the child node will be cleanup, false otherwise. -- @function [parent=#ProtectedNode] removeProtectedChild -- @param self --- @param #cc.Node node --- @param #bool bool +-- @param #cc.Node child +-- @param #bool cleanup -------------------------------- +-- Removes all children from the container with a cleanup.
+-- see `removeAllChildrenWithCleanup(bool)` -- @function [parent=#ProtectedNode] removeAllProtectedChildren -- @param self -------------------------------- +-- -- @function [parent=#ProtectedNode] create -- @param self -- @return ProtectedNode#ProtectedNode ret (return value: cc.ProtectedNode) -------------------------------- +-- / @} end of Children and Parent -- @function [parent=#ProtectedNode] visit -- @param self -- @param #cc.Renderer renderer --- @param #mat4_table mat4 --- @param #unsigned int int +-- @param #mat4_table parentTransform +-- @param #unsigned int parentFlags -------------------------------- +-- -- @function [parent=#ProtectedNode] updateDisplayedOpacity -- @param self --- @param #unsigned char char +-- @param #unsigned char parentOpacity -------------------------------- +-- -- @function [parent=#ProtectedNode] updateDisplayedColor -- @param self --- @param #color3b_table color3b +-- @param #color3b_table parentColor -------------------------------- +-- -- @function [parent=#ProtectedNode] cleanup -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/Ref.lua b/cocos/scripting/lua-bindings/auto/api/Ref.lua index 23aa688f85..8ab85e5d9f 100644 --- a/cocos/scripting/lua-bindings/auto/api/Ref.lua +++ b/cocos/scripting/lua-bindings/auto/api/Ref.lua @@ -4,14 +4,27 @@ -- @parent_module cc -------------------------------- +-- Releases the ownership immediately.
+-- This decrements the Ref's reference count.
+-- If the reference count reaches 0 after the descrement, this Ref is
+-- destructed.
+-- see retain, autorelease
+-- js NA -- @function [parent=#Ref] release -- @param self -------------------------------- +-- Retains the ownership.
+-- This increases the Ref's reference count.
+-- see release, autorelease
+-- js NA -- @function [parent=#Ref] retain -- @param self -------------------------------- +-- Returns the Ref's current reference count.
+-- returns The Ref's reference count.
+-- js NA -- @function [parent=#Ref] getReferenceCount -- @param self -- @return unsigned int#unsigned int ret (return value: unsigned int) diff --git a/cocos/scripting/lua-bindings/auto/api/RelativeBox.lua b/cocos/scripting/lua-bindings/auto/api/RelativeBox.lua index a12a3b8f4a..b919424813 100644 --- a/cocos/scripting/lua-bindings/auto/api/RelativeBox.lua +++ b/cocos/scripting/lua-bindings/auto/api/RelativeBox.lua @@ -13,6 +13,7 @@ -- @return RelativeBox#RelativeBox ret (retunr value: ccui.RelativeBox) -------------------------------- +-- Default constructor -- @function [parent=#RelativeBox] RelativeBox -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/RelativeLayoutParameter.lua b/cocos/scripting/lua-bindings/auto/api/RelativeLayoutParameter.lua index ec81d4f44e..d40ea5f727 100644 --- a/cocos/scripting/lua-bindings/auto/api/RelativeLayoutParameter.lua +++ b/cocos/scripting/lua-bindings/auto/api/RelativeLayoutParameter.lua @@ -5,51 +5,70 @@ -- @parent_module ccui -------------------------------- +-- Sets RelativeAlign parameter for LayoutParameter.
+-- see RelativeAlign
+-- param RelativeAlign -- @function [parent=#RelativeLayoutParameter] setAlign -- @param self --- @param #int relativealign +-- @param #int align -------------------------------- +-- Sets a key for LayoutParameter. Witch widget named this is relative to.
+-- param name -- @function [parent=#RelativeLayoutParameter] setRelativeToWidgetName -- @param self --- @param #string str +-- @param #string name -------------------------------- +-- Gets a name in Relative Layout of LayoutParameter.
+-- return name -- @function [parent=#RelativeLayoutParameter] getRelativeName -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- Gets the key of LayoutParameter. Witch widget named this is relative to.
+-- return name -- @function [parent=#RelativeLayoutParameter] getRelativeToWidgetName -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- Sets a name in Relative Layout for LayoutParameter.
+-- param name -- @function [parent=#RelativeLayoutParameter] setRelativeName -- @param self --- @param #string str +-- @param #string name -------------------------------- +-- Gets RelativeAlign parameter for LayoutParameter.
+-- see RelativeAlign
+-- return RelativeAlign -- @function [parent=#RelativeLayoutParameter] getAlign -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- Allocates and initializes.
+-- return A initialized LayoutParameter which is marked as "autorelease". -- @function [parent=#RelativeLayoutParameter] create -- @param self -- @return RelativeLayoutParameter#RelativeLayoutParameter ret (return value: ccui.RelativeLayoutParameter) -------------------------------- +-- -- @function [parent=#RelativeLayoutParameter] createCloneInstance -- @param self -- @return LayoutParameter#LayoutParameter ret (return value: ccui.LayoutParameter) -------------------------------- +-- -- @function [parent=#RelativeLayoutParameter] copyProperties -- @param self --- @param #ccui.LayoutParameter layoutparameter +-- @param #ccui.LayoutParameter model -------------------------------- +-- Default constructor -- @function [parent=#RelativeLayoutParameter] RelativeLayoutParameter -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/RemoveSelf.lua b/cocos/scripting/lua-bindings/auto/api/RemoveSelf.lua index 27ef10c677..c477540f27 100644 --- a/cocos/scripting/lua-bindings/auto/api/RemoveSelf.lua +++ b/cocos/scripting/lua-bindings/auto/api/RemoveSelf.lua @@ -5,21 +5,25 @@ -- @parent_module cc -------------------------------- +-- create the action -- @function [parent=#RemoveSelf] create -- @param self -- @return RemoveSelf#RemoveSelf ret (return value: cc.RemoveSelf) -------------------------------- +-- -- @function [parent=#RemoveSelf] clone -- @param self -- @return RemoveSelf#RemoveSelf ret (return value: cc.RemoveSelf) -------------------------------- +-- -- @function [parent=#RemoveSelf] update -- @param self --- @param #float float +-- @param #float time -------------------------------- +-- -- @function [parent=#RemoveSelf] reverse -- @param self -- @return RemoveSelf#RemoveSelf ret (return value: cc.RemoveSelf) diff --git a/cocos/scripting/lua-bindings/auto/api/RenderTexture.lua b/cocos/scripting/lua-bindings/auto/api/RenderTexture.lua index 661a25c17e..d7f705032c 100644 --- a/cocos/scripting/lua-bindings/auto/api/RenderTexture.lua +++ b/cocos/scripting/lua-bindings/auto/api/RenderTexture.lua @@ -5,62 +5,75 @@ -- @parent_module cc -------------------------------- +-- Used for grab part of screen to a texture.rtBegin: the position of renderTexture on the fullRectfullRect: the total size of screenfullViewport: the total viewportSize -- @function [parent=#RenderTexture] setVirtualViewport -- @param self --- @param #vec2_table vec2 --- @param #rect_table rect --- @param #rect_table rect +-- @param #vec2_table rtBegin +-- @param #rect_table fullRect +-- @param #rect_table fullViewport -------------------------------- +-- clears the texture with a specified stencil value -- @function [parent=#RenderTexture] clearStencil -- @param self --- @param #int int +-- @param #int stencilValue -------------------------------- +-- Value for clearDepth. Valid only when "autoDraw" is true. -- @function [parent=#RenderTexture] getClearDepth -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- Value for clear Stencil. Valid only when "autoDraw" is true -- @function [parent=#RenderTexture] getClearStencil -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- ends grabbing -- @function [parent=#RenderTexture] end -- @param self -------------------------------- +-- -- @function [parent=#RenderTexture] setClearStencil -- @param self --- @param #int int +-- @param #int clearStencil -------------------------------- +-- Sets the Sprite being used. -- @function [parent=#RenderTexture] setSprite -- @param self -- @param #cc.Sprite sprite -------------------------------- +-- Gets the Sprite being used. -- @function [parent=#RenderTexture] getSprite -- @param self -- @return Sprite#Sprite ret (return value: cc.Sprite) -------------------------------- +-- When enabled, it will render its children into the texture automatically. Disabled by default for compatiblity reasons.
+-- Will be enabled in the future. -- @function [parent=#RenderTexture] isAutoDraw -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#RenderTexture] setKeepMatrix -- @param self --- @param #bool bool +-- @param #bool keepMatrix -------------------------------- +-- -- @function [parent=#RenderTexture] setClearFlags -- @param self --- @param #unsigned int int +-- @param #unsigned int clearFlags -------------------------------- +-- starts grabbing -- @function [parent=#RenderTexture] begin -- @param self @@ -69,23 +82,26 @@ -- @overload self, string, bool, function -- @function [parent=#RenderTexture] saveToFile -- @param self --- @param #string str +-- @param #string filename -- @param #int format --- @param #bool bool --- @param #function func +-- @param #bool isRGBA +-- @param #function callback -- @return bool#bool ret (retunr value: bool) -------------------------------- +-- -- @function [parent=#RenderTexture] setAutoDraw -- @param self --- @param #bool bool +-- @param #bool isAutoDraw -------------------------------- +-- -- @function [parent=#RenderTexture] setClearColor -- @param self --- @param #color4f_table color4f +-- @param #color4f_table clearColor -------------------------------- +-- end is key word of lua, use other name to export to lua. -- @function [parent=#RenderTexture] endToLua -- @param self @@ -95,55 +111,61 @@ -- @overload self, float, float, float, float, float, int -- @function [parent=#RenderTexture] beginWithClear -- @param self --- @param #float float --- @param #float float --- @param #float float --- @param #float float --- @param #float float --- @param #int int +-- @param #float r +-- @param #float g +-- @param #float b +-- @param #float a +-- @param #float depthValue +-- @param #int stencilValue -------------------------------- +-- clears the texture with a specified depth value -- @function [parent=#RenderTexture] clearDepth -- @param self --- @param #float float +-- @param #float depthValue -------------------------------- +-- Clear color value. Valid only when "autoDraw" is true. -- @function [parent=#RenderTexture] getClearColor -- @param self -- @return color4f_table#color4f_table ret (return value: color4f_table) -------------------------------- +-- clears the texture with a color -- @function [parent=#RenderTexture] clear -- @param self --- @param #float float --- @param #float float --- @param #float float --- @param #float float +-- @param #float r +-- @param #float g +-- @param #float b +-- @param #float a -------------------------------- +-- Valid flags: GL_COLOR_BUFFER_BIT, GL_DEPTH_BUFFER_BIT, GL_STENCIL_BUFFER_BIT. They can be OR'ed. Valid when "autoDraw" is true. -- @function [parent=#RenderTexture] getClearFlags -- @param self -- @return unsigned int#unsigned int ret (return value: unsigned int) -------------------------------- +-- -- @function [parent=#RenderTexture] newImage -- @param self -- @return Image#Image ret (return value: cc.Image) -------------------------------- +-- -- @function [parent=#RenderTexture] setClearDepth -- @param self --- @param #float float +-- @param #float clearDepth -------------------------------- -- @overload self, int, int, int, unsigned int -- @overload self, int, int, int -- @function [parent=#RenderTexture] initWithWidthAndHeight -- @param self --- @param #int int --- @param #int int --- @param #int pixelformat --- @param #unsigned int int +-- @param #int w +-- @param #int h +-- @param #int format +-- @param #unsigned int depthStencilFormat -- @return bool#bool ret (retunr value: bool) -------------------------------- @@ -152,27 +174,30 @@ -- @overload self, int, int -- @function [parent=#RenderTexture] create -- @param self --- @param #int int --- @param #int int --- @param #int pixelformat --- @param #unsigned int int +-- @param #int w +-- @param #int h +-- @param #int format +-- @param #unsigned int depthStencilFormat -- @return RenderTexture#RenderTexture ret (retunr value: cc.RenderTexture) -------------------------------- +-- -- @function [parent=#RenderTexture] draw -- @param self -- @param #cc.Renderer renderer --- @param #mat4_table mat4 --- @param #unsigned int int +-- @param #mat4_table transform +-- @param #unsigned int flags -------------------------------- +-- -- @function [parent=#RenderTexture] visit -- @param self -- @param #cc.Renderer renderer --- @param #mat4_table mat4 --- @param #unsigned int int +-- @param #mat4_table parentTransform +-- @param #unsigned int parentFlags -------------------------------- +-- -- @function [parent=#RenderTexture] RenderTexture -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/Repeat.lua b/cocos/scripting/lua-bindings/auto/api/Repeat.lua index 0fceefb74c..6416570584 100644 --- a/cocos/scripting/lua-bindings/auto/api/Repeat.lua +++ b/cocos/scripting/lua-bindings/auto/api/Repeat.lua @@ -5,47 +5,56 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#Repeat] setInnerAction -- @param self --- @param #cc.FiniteTimeAction finitetimeaction +-- @param #cc.FiniteTimeAction action -------------------------------- +-- -- @function [parent=#Repeat] getInnerAction -- @param self -- @return FiniteTimeAction#FiniteTimeAction ret (return value: cc.FiniteTimeAction) -------------------------------- +-- creates a Repeat action. Times is an unsigned integer between 1 and pow(2,30) -- @function [parent=#Repeat] create -- @param self --- @param #cc.FiniteTimeAction finitetimeaction --- @param #unsigned int int +-- @param #cc.FiniteTimeAction action +-- @param #unsigned int times -- @return Repeat#Repeat ret (return value: cc.Repeat) -------------------------------- +-- -- @function [parent=#Repeat] startWithTarget -- @param self --- @param #cc.Node node +-- @param #cc.Node target -------------------------------- +-- -- @function [parent=#Repeat] reverse -- @param self -- @return Repeat#Repeat ret (return value: cc.Repeat) -------------------------------- +-- -- @function [parent=#Repeat] clone -- @param self -- @return Repeat#Repeat ret (return value: cc.Repeat) -------------------------------- +-- -- @function [parent=#Repeat] stop -- @param self -------------------------------- +-- -- @function [parent=#Repeat] update -- @param self --- @param #float float +-- @param #float dt -------------------------------- +-- -- @function [parent=#Repeat] isDone -- @param self -- @return bool#bool ret (return value: bool) diff --git a/cocos/scripting/lua-bindings/auto/api/RepeatForever.lua b/cocos/scripting/lua-bindings/auto/api/RepeatForever.lua index d846b49287..bd2f1b1b8f 100644 --- a/cocos/scripting/lua-bindings/auto/api/RepeatForever.lua +++ b/cocos/scripting/lua-bindings/auto/api/RepeatForever.lua @@ -5,44 +5,52 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#RepeatForever] setInnerAction -- @param self --- @param #cc.ActionInterval actioninterval +-- @param #cc.ActionInterval action -------------------------------- +-- -- @function [parent=#RepeatForever] getInnerAction -- @param self -- @return ActionInterval#ActionInterval ret (return value: cc.ActionInterval) -------------------------------- +-- creates the action -- @function [parent=#RepeatForever] create -- @param self --- @param #cc.ActionInterval actioninterval +-- @param #cc.ActionInterval action -- @return RepeatForever#RepeatForever ret (return value: cc.RepeatForever) -------------------------------- +-- -- @function [parent=#RepeatForever] startWithTarget -- @param self --- @param #cc.Node node +-- @param #cc.Node target -------------------------------- +-- -- @function [parent=#RepeatForever] clone -- @param self -- @return RepeatForever#RepeatForever ret (return value: cc.RepeatForever) -------------------------------- +-- -- @function [parent=#RepeatForever] isDone -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#RepeatForever] reverse -- @param self -- @return RepeatForever#RepeatForever ret (return value: cc.RepeatForever) -------------------------------- +-- -- @function [parent=#RepeatForever] step -- @param self --- @param #float float +-- @param #float dt return nil diff --git a/cocos/scripting/lua-bindings/auto/api/ReuseGrid.lua b/cocos/scripting/lua-bindings/auto/api/ReuseGrid.lua index d36121c163..d5d09ff12e 100644 --- a/cocos/scripting/lua-bindings/auto/api/ReuseGrid.lua +++ b/cocos/scripting/lua-bindings/auto/api/ReuseGrid.lua @@ -5,22 +5,26 @@ -- @parent_module cc -------------------------------- +-- creates an action with the number of times that the current grid will be reused -- @function [parent=#ReuseGrid] create -- @param self --- @param #int int +-- @param #int times -- @return ReuseGrid#ReuseGrid ret (return value: cc.ReuseGrid) -------------------------------- +-- -- @function [parent=#ReuseGrid] startWithTarget -- @param self --- @param #cc.Node node +-- @param #cc.Node target -------------------------------- +-- -- @function [parent=#ReuseGrid] clone -- @param self -- @return ReuseGrid#ReuseGrid ret (return value: cc.ReuseGrid) -------------------------------- +-- -- @function [parent=#ReuseGrid] reverse -- @param self -- @return ReuseGrid#ReuseGrid ret (return value: cc.ReuseGrid) diff --git a/cocos/scripting/lua-bindings/auto/api/RichElement.lua b/cocos/scripting/lua-bindings/auto/api/RichElement.lua index 6043d0bf08..dcb76df400 100644 --- a/cocos/scripting/lua-bindings/auto/api/RichElement.lua +++ b/cocos/scripting/lua-bindings/auto/api/RichElement.lua @@ -5,14 +5,16 @@ -- @parent_module ccui -------------------------------- +-- -- @function [parent=#RichElement] init -- @param self --- @param #int int --- @param #color3b_table color3b --- @param #unsigned char char +-- @param #int tag +-- @param #color3b_table color +-- @param #unsigned char opacity -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#RichElement] RichElement -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/RichElementCustomNode.lua b/cocos/scripting/lua-bindings/auto/api/RichElementCustomNode.lua index df0910149b..12663cbf56 100644 --- a/cocos/scripting/lua-bindings/auto/api/RichElementCustomNode.lua +++ b/cocos/scripting/lua-bindings/auto/api/RichElementCustomNode.lua @@ -5,24 +5,27 @@ -- @parent_module ccui -------------------------------- +-- -- @function [parent=#RichElementCustomNode] init -- @param self --- @param #int int --- @param #color3b_table color3b --- @param #unsigned char char --- @param #cc.Node node +-- @param #int tag +-- @param #color3b_table color +-- @param #unsigned char opacity +-- @param #cc.Node customNode -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#RichElementCustomNode] create -- @param self --- @param #int int --- @param #color3b_table color3b --- @param #unsigned char char --- @param #cc.Node node +-- @param #int tag +-- @param #color3b_table color +-- @param #unsigned char opacity +-- @param #cc.Node customNode -- @return RichElementCustomNode#RichElementCustomNode ret (return value: ccui.RichElementCustomNode) -------------------------------- +-- -- @function [parent=#RichElementCustomNode] RichElementCustomNode -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/RichElementImage.lua b/cocos/scripting/lua-bindings/auto/api/RichElementImage.lua index c94db3c5cc..bbccb743f8 100644 --- a/cocos/scripting/lua-bindings/auto/api/RichElementImage.lua +++ b/cocos/scripting/lua-bindings/auto/api/RichElementImage.lua @@ -5,24 +5,27 @@ -- @parent_module ccui -------------------------------- +-- -- @function [parent=#RichElementImage] init -- @param self --- @param #int int --- @param #color3b_table color3b --- @param #unsigned char char --- @param #string str +-- @param #int tag +-- @param #color3b_table color +-- @param #unsigned char opacity +-- @param #string filePath -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#RichElementImage] create -- @param self --- @param #int int --- @param #color3b_table color3b --- @param #unsigned char char --- @param #string str +-- @param #int tag +-- @param #color3b_table color +-- @param #unsigned char opacity +-- @param #string filePath -- @return RichElementImage#RichElementImage ret (return value: ccui.RichElementImage) -------------------------------- +-- -- @function [parent=#RichElementImage] RichElementImage -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/RichElementText.lua b/cocos/scripting/lua-bindings/auto/api/RichElementText.lua index e92a8c5916..35ceb7e869 100644 --- a/cocos/scripting/lua-bindings/auto/api/RichElementText.lua +++ b/cocos/scripting/lua-bindings/auto/api/RichElementText.lua @@ -5,28 +5,31 @@ -- @parent_module ccui -------------------------------- +-- -- @function [parent=#RichElementText] init -- @param self --- @param #int int --- @param #color3b_table color3b --- @param #unsigned char char --- @param #string str --- @param #string str --- @param #float float +-- @param #int tag +-- @param #color3b_table color +-- @param #unsigned char opacity +-- @param #string text +-- @param #string fontName +-- @param #float fontSize -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#RichElementText] create -- @param self --- @param #int int --- @param #color3b_table color3b --- @param #unsigned char char --- @param #string str --- @param #string str --- @param #float float +-- @param #int tag +-- @param #color3b_table color +-- @param #unsigned char opacity +-- @param #string text +-- @param #string fontName +-- @param #float fontSize -- @return RichElementText#RichElementText ret (return value: ccui.RichElementText) -------------------------------- +-- -- @function [parent=#RichElementText] RichElementText -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/RichText.lua b/cocos/scripting/lua-bindings/auto/api/RichText.lua index c332a6f8e7..ff84a62b20 100644 --- a/cocos/scripting/lua-bindings/auto/api/RichText.lua +++ b/cocos/scripting/lua-bindings/auto/api/RichText.lua @@ -5,32 +5,38 @@ -- @parent_module ccui -------------------------------- +-- -- @function [parent=#RichText] insertElement -- @param self --- @param #ccui.RichElement richelement --- @param #int int +-- @param #ccui.RichElement element +-- @param #int index -------------------------------- +-- -- @function [parent=#RichText] setAnchorPoint -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table pt -------------------------------- +-- -- @function [parent=#RichText] pushBackElement -- @param self --- @param #ccui.RichElement richelement +-- @param #ccui.RichElement element -------------------------------- +-- -- @function [parent=#RichText] ignoreContentAdaptWithSize -- @param self --- @param #bool bool +-- @param #bool ignore -------------------------------- +-- -- @function [parent=#RichText] setVerticalSpace -- @param self --- @param #float float +-- @param #float space -------------------------------- +-- -- @function [parent=#RichText] formatText -- @param self @@ -39,24 +45,28 @@ -- @overload self, int -- @function [parent=#RichText] removeElement -- @param self --- @param #int int +-- @param #int index -------------------------------- +-- -- @function [parent=#RichText] create -- @param self -- @return RichText#RichText ret (return value: ccui.RichText) -------------------------------- +-- -- @function [parent=#RichText] getDescription -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- -- @function [parent=#RichText] getVirtualRendererSize -- @param self -- @return size_table#size_table ret (return value: size_table) -------------------------------- +-- -- @function [parent=#RichText] RichText -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/Ripple3D.lua b/cocos/scripting/lua-bindings/auto/api/Ripple3D.lua index 22ecc16a89..d335042d84 100644 --- a/cocos/scripting/lua-bindings/auto/api/Ripple3D.lua +++ b/cocos/scripting/lua-bindings/auto/api/Ripple3D.lua @@ -5,54 +5,63 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#Ripple3D] setAmplitudeRate -- @param self --- @param #float float +-- @param #float fAmplitudeRate -------------------------------- +-- -- @function [parent=#Ripple3D] getAmplitudeRate -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#Ripple3D] setAmplitude -- @param self --- @param #float float +-- @param #float fAmplitude -------------------------------- +-- -- @function [parent=#Ripple3D] getAmplitude -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- set center position -- @function [parent=#Ripple3D] setPosition -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table position -------------------------------- +-- get center position -- @function [parent=#Ripple3D] getPosition -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- creates the action with radius, number of waves, amplitude, a grid size and duration -- @function [parent=#Ripple3D] create -- @param self --- @param #float float --- @param #size_table size --- @param #vec2_table vec2 --- @param #float float --- @param #unsigned int int --- @param #float float +-- @param #float duration +-- @param #size_table gridSize +-- @param #vec2_table position +-- @param #float radius +-- @param #unsigned int waves +-- @param #float amplitude -- @return Ripple3D#Ripple3D ret (return value: cc.Ripple3D) -------------------------------- +-- -- @function [parent=#Ripple3D] clone -- @param self -- @return Ripple3D#Ripple3D ret (return value: cc.Ripple3D) -------------------------------- +-- -- @function [parent=#Ripple3D] update -- @param self --- @param #float float +-- @param #float time return nil diff --git a/cocos/scripting/lua-bindings/auto/api/RotateBy.lua b/cocos/scripting/lua-bindings/auto/api/RotateBy.lua index 8d1d33c55e..05a24a7f5a 100644 --- a/cocos/scripting/lua-bindings/auto/api/RotateBy.lua +++ b/cocos/scripting/lua-bindings/auto/api/RotateBy.lua @@ -10,29 +10,33 @@ -- @overload self, float, vec3_table -- @function [parent=#RotateBy] create -- @param self --- @param #float float --- @param #float float --- @param #float float +-- @param #float duration +-- @param #float deltaAngleZ_X +-- @param #float deltaAngleZ_Y -- @return RotateBy#RotateBy ret (retunr value: cc.RotateBy) -------------------------------- +-- -- @function [parent=#RotateBy] startWithTarget -- @param self --- @param #cc.Node node +-- @param #cc.Node target -------------------------------- +-- -- @function [parent=#RotateBy] clone -- @param self -- @return RotateBy#RotateBy ret (return value: cc.RotateBy) -------------------------------- +-- -- @function [parent=#RotateBy] reverse -- @param self -- @return RotateBy#RotateBy ret (return value: cc.RotateBy) -------------------------------- +-- -- @function [parent=#RotateBy] update -- @param self --- @param #float float +-- @param #float time return nil diff --git a/cocos/scripting/lua-bindings/auto/api/RotateTo.lua b/cocos/scripting/lua-bindings/auto/api/RotateTo.lua index 1631a28fbd..9a03166d87 100644 --- a/cocos/scripting/lua-bindings/auto/api/RotateTo.lua +++ b/cocos/scripting/lua-bindings/auto/api/RotateTo.lua @@ -10,29 +10,33 @@ -- @overload self, float, vec3_table -- @function [parent=#RotateTo] create -- @param self --- @param #float float --- @param #float float --- @param #float float +-- @param #float duration +-- @param #float dstAngleX +-- @param #float dstAngleY -- @return RotateTo#RotateTo ret (retunr value: cc.RotateTo) -------------------------------- +-- -- @function [parent=#RotateTo] startWithTarget -- @param self --- @param #cc.Node node +-- @param #cc.Node target -------------------------------- +-- -- @function [parent=#RotateTo] clone -- @param self -- @return RotateTo#RotateTo ret (return value: cc.RotateTo) -------------------------------- +-- -- @function [parent=#RotateTo] reverse -- @param self -- @return RotateTo#RotateTo ret (return value: cc.RotateTo) -------------------------------- +-- -- @function [parent=#RotateTo] update -- @param self --- @param #float float +-- @param #float time return nil diff --git a/cocos/scripting/lua-bindings/auto/api/RotationFrame.lua b/cocos/scripting/lua-bindings/auto/api/RotationFrame.lua index 0d0e14cd48..6be076892d 100644 --- a/cocos/scripting/lua-bindings/auto/api/RotationFrame.lua +++ b/cocos/scripting/lua-bindings/auto/api/RotationFrame.lua @@ -5,31 +5,37 @@ -- @parent_module ccs -------------------------------- +-- -- @function [parent=#RotationFrame] setRotation -- @param self --- @param #float float +-- @param #float rotation -------------------------------- +-- -- @function [parent=#RotationFrame] getRotation -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#RotationFrame] create -- @param self -- @return RotationFrame#RotationFrame ret (return value: ccs.RotationFrame) -------------------------------- +-- -- @function [parent=#RotationFrame] apply -- @param self --- @param #float float +-- @param #float percent -------------------------------- +-- -- @function [parent=#RotationFrame] clone -- @param self -- @return Frame#Frame ret (return value: ccs.Frame) -------------------------------- +-- -- @function [parent=#RotationFrame] RotationFrame -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/RotationSkewFrame.lua b/cocos/scripting/lua-bindings/auto/api/RotationSkewFrame.lua index 7fb9190a5b..340f6f167e 100644 --- a/cocos/scripting/lua-bindings/auto/api/RotationSkewFrame.lua +++ b/cocos/scripting/lua-bindings/auto/api/RotationSkewFrame.lua @@ -5,21 +5,25 @@ -- @parent_module ccs -------------------------------- +-- -- @function [parent=#RotationSkewFrame] create -- @param self -- @return RotationSkewFrame#RotationSkewFrame ret (return value: ccs.RotationSkewFrame) -------------------------------- +-- -- @function [parent=#RotationSkewFrame] apply -- @param self --- @param #float float +-- @param #float percent -------------------------------- +-- -- @function [parent=#RotationSkewFrame] clone -- @param self -- @return Frame#Frame ret (return value: ccs.Frame) -------------------------------- +-- -- @function [parent=#RotationSkewFrame] RotationSkewFrame -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/Scale9Sprite.lua b/cocos/scripting/lua-bindings/auto/api/Scale9Sprite.lua index 3e353cf61d..6264f3826f 100644 --- a/cocos/scripting/lua-bindings/auto/api/Scale9Sprite.lua +++ b/cocos/scripting/lua-bindings/auto/api/Scale9Sprite.lua @@ -5,65 +5,82 @@ -- @parent_module ccui -------------------------------- +-- -- @function [parent=#Scale9Sprite] disableCascadeColor -- @param self -------------------------------- +-- -- @function [parent=#Scale9Sprite] updateWithSprite -- @param self -- @param #cc.Sprite sprite -- @param #rect_table rect --- @param #bool bool --- @param #rect_table rect +-- @param #bool rotated +-- @param #rect_table capInsets -- @return bool#bool ret (return value: bool) -------------------------------- +-- Returns the flag which indicates whether the widget is flipped horizontally or not.
+-- It only flips the texture of the widget, and not the texture of the widget's children.
+-- Also, flipping the texture doesn't alter the anchorPoint.
+-- If you want to flip the anchorPoint too, and/or to flip the children too use:
+-- widget->setScaleX(sprite->getScaleX() * -1);
+-- return true if the widget is flipped horizaontally, false otherwise. -- @function [parent=#Scale9Sprite] isFlippedX -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- Sets whether the widget should be flipped vertically or not.
+-- param bFlippedY true if the widget should be flipped vertically, flase otherwise. -- @function [parent=#Scale9Sprite] setFlippedY -- @param self --- @param #bool bool +-- @param #bool flippedY -------------------------------- +-- Sets whether the widget should be flipped horizontally or not.
+-- param bFlippedX true if the widget should be flipped horizaontally, false otherwise. -- @function [parent=#Scale9Sprite] setFlippedX -- @param self --- @param #bool bool +-- @param #bool flippedX -------------------------------- +-- -- @function [parent=#Scale9Sprite] setScale9Enabled -- @param self --- @param #bool bool +-- @param #bool enabled -------------------------------- +-- -- @function [parent=#Scale9Sprite] disableCascadeOpacity -- @param self -------------------------------- +-- -- @function [parent=#Scale9Sprite] setInsetBottom -- @param self --- @param #float float +-- @param #float bottomInset -------------------------------- -- @overload self, string -- @overload self, string, rect_table -- @function [parent=#Scale9Sprite] initWithSpriteFrameName -- @param self --- @param #string str --- @param #rect_table rect +-- @param #string spriteFrameName +-- @param #rect_table capInsets -- @return bool#bool ret (retunr value: bool) -------------------------------- +-- -- @function [parent=#Scale9Sprite] getSprite -- @param self -- @return Sprite#Sprite ret (return value: cc.Sprite) -------------------------------- +-- -- @function [parent=#Scale9Sprite] setInsetTop -- @param self --- @param #float float +-- @param #float topInset -------------------------------- -- @overload self, cc.Sprite, rect_table, bool, rect_table @@ -73,47 +90,59 @@ -- @param self -- @param #cc.Sprite sprite -- @param #rect_table rect --- @param #bool bool --- @param #rect_table rect +-- @param #bool rotated +-- @param #rect_table capInsets -- @return bool#bool ret (retunr value: bool) -------------------------------- +-- -- @function [parent=#Scale9Sprite] setPreferredSize -- @param self -- @param #size_table size -------------------------------- +-- -- @function [parent=#Scale9Sprite] getInsetRight -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#Scale9Sprite] setSpriteFrame -- @param self --- @param #cc.SpriteFrame spriteframe +-- @param #cc.SpriteFrame spriteFrame -------------------------------- +-- -- @function [parent=#Scale9Sprite] getInsetBottom -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- Creates and returns a new sprite object with the specified cap insets.
+-- You use this method to add cap insets to a sprite or to change the existing
+-- cap insets of a sprite. In both cases, you get back a new image and the
+-- original sprite remains untouched.
+-- param capInsets The values to use for the cap insets. -- @function [parent=#Scale9Sprite] resizableSpriteWithCapInsets -- @param self --- @param #rect_table rect +-- @param #rect_table capInsets -- @return Scale9Sprite#Scale9Sprite ret (return value: ccui.Scale9Sprite) -------------------------------- +-- -- @function [parent=#Scale9Sprite] isScale9Enabled -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#Scale9Sprite] getCapInsets -- @param self -- @return rect_table#rect_table ret (return value: rect_table) -------------------------------- +-- -- @function [parent=#Scale9Sprite] getOriginalSize -- @param self -- @return size_table#size_table ret (return value: size_table) @@ -125,54 +154,66 @@ -- @overload self, string -- @function [parent=#Scale9Sprite] initWithFile -- @param self --- @param #string str --- @param #rect_table rect +-- @param #string file -- @param #rect_table rect +-- @param #rect_table capInsets -- @return bool#bool ret (retunr value: bool) -------------------------------- +-- -- @function [parent=#Scale9Sprite] getInsetTop -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#Scale9Sprite] setInsetLeft -- @param self --- @param #float float +-- @param #float leftInset -------------------------------- -- @overload self, cc.SpriteFrame -- @overload self, cc.SpriteFrame, rect_table -- @function [parent=#Scale9Sprite] initWithSpriteFrame -- @param self --- @param #cc.SpriteFrame spriteframe --- @param #rect_table rect +-- @param #cc.SpriteFrame spriteFrame +-- @param #rect_table capInsets -- @return bool#bool ret (retunr value: bool) -------------------------------- +-- -- @function [parent=#Scale9Sprite] getPreferredSize -- @param self -- @return size_table#size_table ret (return value: size_table) -------------------------------- +-- -- @function [parent=#Scale9Sprite] setCapInsets -- @param self -- @param #rect_table rect -------------------------------- +-- Return the flag which indicates whether the widget is flipped vertically or not.
+-- It only flips the texture of the widget, and not the texture of the widget's children.
+-- Also, flipping the texture doesn't alter the anchorPoint.
+-- If you want to flip the anchorPoint too, and/or to flip the children too use:
+-- widget->setScaleY(widget->getScaleY() * -1);
+-- return true if the widget is flipped vertically, flase otherwise. -- @function [parent=#Scale9Sprite] isFlippedY -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#Scale9Sprite] getInsetLeft -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#Scale9Sprite] setInsetRight -- @param self --- @param #float float +-- @param #float rightInset -------------------------------- -- @overload self, string, rect_table, rect_table @@ -182,9 +223,9 @@ -- @overload self, string -- @function [parent=#Scale9Sprite] create -- @param self --- @param #string str --- @param #rect_table rect +-- @param #string file -- @param #rect_table rect +-- @param #rect_table capInsets -- @return Scale9Sprite#Scale9Sprite ret (retunr value: ccui.Scale9Sprite) -------------------------------- @@ -192,8 +233,8 @@ -- @overload self, string -- @function [parent=#Scale9Sprite] createWithSpriteFrameName -- @param self --- @param #string str --- @param #rect_table rect +-- @param #string spriteFrameName +-- @param #rect_table capInsets -- @return Scale9Sprite#Scale9Sprite ret (retunr value: ccui.Scale9Sprite) -------------------------------- @@ -201,35 +242,41 @@ -- @overload self, cc.SpriteFrame -- @function [parent=#Scale9Sprite] createWithSpriteFrame -- @param self --- @param #cc.SpriteFrame spriteframe --- @param #rect_table rect +-- @param #cc.SpriteFrame spriteFrame +-- @param #rect_table capInsets -- @return Scale9Sprite#Scale9Sprite ret (retunr value: ccui.Scale9Sprite) -------------------------------- +-- -- @function [parent=#Scale9Sprite] setAnchorPoint -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table anchorPoint -------------------------------- +-- -- @function [parent=#Scale9Sprite] updateDisplayedOpacity -- @param self --- @param #unsigned char char +-- @param #unsigned char parentOpacity -------------------------------- +-- -- @function [parent=#Scale9Sprite] cleanup -- @param self -------------------------------- +-- -- @function [parent=#Scale9Sprite] updateDisplayedColor -- @param self --- @param #color3b_table color3b +-- @param #color3b_table parentColor -------------------------------- +-- -- @function [parent=#Scale9Sprite] setContentSize -- @param self -- @param #size_table size -------------------------------- +-- js ctor -- @function [parent=#Scale9Sprite] Scale9Sprite -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/ScaleBy.lua b/cocos/scripting/lua-bindings/auto/api/ScaleBy.lua index 3d2e657b72..f7e93e6bfb 100644 --- a/cocos/scripting/lua-bindings/auto/api/ScaleBy.lua +++ b/cocos/scripting/lua-bindings/auto/api/ScaleBy.lua @@ -10,23 +10,26 @@ -- @overload self, float, float, float, float -- @function [parent=#ScaleBy] create -- @param self --- @param #float float --- @param #float float --- @param #float float --- @param #float float +-- @param #float duration +-- @param #float sx +-- @param #float sy +-- @param #float sz -- @return ScaleBy#ScaleBy ret (retunr value: cc.ScaleBy) -------------------------------- +-- -- @function [parent=#ScaleBy] startWithTarget -- @param self --- @param #cc.Node node +-- @param #cc.Node target -------------------------------- +-- -- @function [parent=#ScaleBy] clone -- @param self -- @return ScaleBy#ScaleBy ret (return value: cc.ScaleBy) -------------------------------- +-- -- @function [parent=#ScaleBy] reverse -- @param self -- @return ScaleBy#ScaleBy ret (return value: cc.ScaleBy) diff --git a/cocos/scripting/lua-bindings/auto/api/ScaleFrame.lua b/cocos/scripting/lua-bindings/auto/api/ScaleFrame.lua index d8fa8f909b..e7bca6756f 100644 --- a/cocos/scripting/lua-bindings/auto/api/ScaleFrame.lua +++ b/cocos/scripting/lua-bindings/auto/api/ScaleFrame.lua @@ -5,46 +5,55 @@ -- @parent_module ccs -------------------------------- +-- -- @function [parent=#ScaleFrame] setScaleY -- @param self --- @param #float float +-- @param #float scaleY -------------------------------- +-- -- @function [parent=#ScaleFrame] setScaleX -- @param self --- @param #float float +-- @param #float scaleX -------------------------------- +-- -- @function [parent=#ScaleFrame] getScaleY -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#ScaleFrame] getScaleX -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#ScaleFrame] setScale -- @param self --- @param #float float +-- @param #float scale -------------------------------- +-- -- @function [parent=#ScaleFrame] create -- @param self -- @return ScaleFrame#ScaleFrame ret (return value: ccs.ScaleFrame) -------------------------------- +-- -- @function [parent=#ScaleFrame] apply -- @param self --- @param #float float +-- @param #float percent -------------------------------- +-- -- @function [parent=#ScaleFrame] clone -- @param self -- @return Frame#Frame ret (return value: ccs.Frame) -------------------------------- +-- -- @function [parent=#ScaleFrame] ScaleFrame -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/ScaleTo.lua b/cocos/scripting/lua-bindings/auto/api/ScaleTo.lua index 3869dffc97..7709deadf1 100644 --- a/cocos/scripting/lua-bindings/auto/api/ScaleTo.lua +++ b/cocos/scripting/lua-bindings/auto/api/ScaleTo.lua @@ -10,30 +10,34 @@ -- @overload self, float, float, float, float -- @function [parent=#ScaleTo] create -- @param self --- @param #float float --- @param #float float --- @param #float float --- @param #float float +-- @param #float duration +-- @param #float sx +-- @param #float sy +-- @param #float sz -- @return ScaleTo#ScaleTo ret (retunr value: cc.ScaleTo) -------------------------------- +-- -- @function [parent=#ScaleTo] startWithTarget -- @param self --- @param #cc.Node node +-- @param #cc.Node target -------------------------------- +-- -- @function [parent=#ScaleTo] clone -- @param self -- @return ScaleTo#ScaleTo ret (return value: cc.ScaleTo) -------------------------------- +-- -- @function [parent=#ScaleTo] reverse -- @param self -- @return ScaleTo#ScaleTo ret (return value: cc.ScaleTo) -------------------------------- +-- -- @function [parent=#ScaleTo] update -- @param self --- @param #float float +-- @param #float time return nil diff --git a/cocos/scripting/lua-bindings/auto/api/Scene.lua b/cocos/scripting/lua-bindings/auto/api/Scene.lua index ba1bec9356..671e74d783 100644 --- a/cocos/scripting/lua-bindings/auto/api/Scene.lua +++ b/cocos/scripting/lua-bindings/auto/api/Scene.lua @@ -5,48 +5,55 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#Scene] getPhysicsWorld -- @param self -- @return PhysicsWorld#PhysicsWorld ret (return value: cc.PhysicsWorld) -------------------------------- +-- creates a new Scene object with a predefined Size -- @function [parent=#Scene] createWithSize -- @param self -- @param #size_table size -- @return Scene#Scene ret (return value: cc.Scene) -------------------------------- +-- creates a new Scene object -- @function [parent=#Scene] create -- @param self -- @return Scene#Scene ret (return value: cc.Scene) -------------------------------- +-- -- @function [parent=#Scene] createWithPhysics -- @param self -- @return Scene#Scene ret (return value: cc.Scene) -------------------------------- +-- -- @function [parent=#Scene] getDescription -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- -- @function [parent=#Scene] getScene -- @param self -- @return Scene#Scene ret (return value: cc.Scene) -------------------------------- +-- -- @function [parent=#Scene] update -- @param self --- @param #float float +-- @param #float delta -------------------------------- -- @overload self, cc.Node, int, string -- @overload self, cc.Node, int, int -- @function [parent=#Scene] addChild -- @param self --- @param #cc.Node node --- @param #int int --- @param #int int +-- @param #cc.Node child +-- @param #int zOrder +-- @param #int tag return nil diff --git a/cocos/scripting/lua-bindings/auto/api/SceneReader.lua b/cocos/scripting/lua-bindings/auto/api/SceneReader.lua index 7ea99e4d21..eb30a5ff16 100644 --- a/cocos/scripting/lua-bindings/auto/api/SceneReader.lua +++ b/cocos/scripting/lua-bindings/auto/api/SceneReader.lua @@ -4,38 +4,46 @@ -- @parent_module ccs -------------------------------- +-- -- @function [parent=#SceneReader] setTarget -- @param self --- @param #function func +-- @param #function selector -------------------------------- +-- -- @function [parent=#SceneReader] createNodeWithSceneFile -- @param self --- @param #string str --- @param #int attachcomponenttype +-- @param #string fileName +-- @param #int attachComponent -- @return Node#Node ret (return value: cc.Node) -------------------------------- +-- -- @function [parent=#SceneReader] getAttachComponentType -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- -- @function [parent=#SceneReader] getNodeByTag -- @param self --- @param #int int +-- @param #int nTag -- @return Node#Node ret (return value: cc.Node) -------------------------------- +-- js purge
+-- lua destroySceneReader -- @function [parent=#SceneReader] destroyInstance -- @param self -------------------------------- +-- -- @function [parent=#SceneReader] sceneReaderVersion -- @param self -- @return char#char ret (return value: char) -------------------------------- +-- -- @function [parent=#SceneReader] getInstance -- @param self -- @return SceneReader#SceneReader ret (return value: ccs.SceneReader) diff --git a/cocos/scripting/lua-bindings/auto/api/Scheduler.lua b/cocos/scripting/lua-bindings/auto/api/Scheduler.lua index 7a3870c4d6..b1b7d560f3 100644 --- a/cocos/scripting/lua-bindings/auto/api/Scheduler.lua +++ b/cocos/scripting/lua-bindings/auto/api/Scheduler.lua @@ -5,16 +5,24 @@ -- @parent_module cc -------------------------------- +-- Modifies the time of all scheduled callbacks.
+-- You can use this property to create a 'slow motion' or 'fast forward' effect.
+-- Default is 1.0. To create a 'slow motion' effect, use values below 1.0.
+-- To create a 'fast forward' effect, use values higher than 1.0.
+-- since v0.8
+-- warning It will affect EVERY scheduled selector / action. -- @function [parent=#Scheduler] setTimeScale -- @param self --- @param #float float +-- @param #float timeScale -------------------------------- +-- -- @function [parent=#Scheduler] getTimeScale -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- js ctor -- @function [parent=#Scheduler] Scheduler -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/ScrollView.lua b/cocos/scripting/lua-bindings/auto/api/ScrollView.lua index f1a9bab896..1cd19f24c4 100644 --- a/cocos/scripting/lua-bindings/auto/api/ScrollView.lua +++ b/cocos/scripting/lua-bindings/auto/api/ScrollView.lua @@ -5,177 +5,221 @@ -- @parent_module ccui -------------------------------- +-- Scroll inner container to top boundary of scrollview. -- @function [parent=#ScrollView] scrollToTop -- @param self --- @param #float float --- @param #bool bool +-- @param #float time +-- @param #bool attenuated -------------------------------- +-- Scroll inner container to horizontal percent position of scrollview. -- @function [parent=#ScrollView] scrollToPercentHorizontal -- @param self --- @param #float float --- @param #float float --- @param #bool bool +-- @param #float percent +-- @param #float time +-- @param #bool attenuated -------------------------------- +-- -- @function [parent=#ScrollView] isInertiaScrollEnabled -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- Scroll inner container to both direction percent position of scrollview. -- @function [parent=#ScrollView] scrollToPercentBothDirection -- @param self --- @param #vec2_table vec2 --- @param #float float --- @param #bool bool +-- @param #vec2_table percent +-- @param #float time +-- @param #bool attenuated -------------------------------- +-- Gets scroll direction of scrollview.
+-- see Direction Direction::VERTICAL means vertical scroll, Direction::HORIZONTAL means horizontal scroll
+-- return Direction -- @function [parent=#ScrollView] getDirection -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- Scroll inner container to bottom and left boundary of scrollview. -- @function [parent=#ScrollView] scrollToBottomLeft -- @param self --- @param #float float --- @param #bool bool +-- @param #float time +-- @param #bool attenuated -------------------------------- +-- Gets inner container of scrollview.
+-- Inner container is the container of scrollview's children.
+-- return inner container. -- @function [parent=#ScrollView] getInnerContainer -- @param self -- @return Layout#Layout ret (return value: ccui.Layout) -------------------------------- +-- Move inner container to bottom boundary of scrollview. -- @function [parent=#ScrollView] jumpToBottom -- @param self -------------------------------- +-- Changes scroll direction of scrollview.
+-- see Direction Direction::VERTICAL means vertical scroll, Direction::HORIZONTAL means horizontal scroll
+-- param dir -- @function [parent=#ScrollView] setDirection -- @param self --- @param #int direction +-- @param #int dir -------------------------------- +-- Scroll inner container to top and left boundary of scrollview. -- @function [parent=#ScrollView] scrollToTopLeft -- @param self --- @param #float float --- @param #bool bool +-- @param #float time +-- @param #bool attenuated -------------------------------- +-- Move inner container to top and right boundary of scrollview. -- @function [parent=#ScrollView] jumpToTopRight -- @param self -------------------------------- +-- Move inner container to bottom and left boundary of scrollview. -- @function [parent=#ScrollView] jumpToBottomLeft -- @param self -------------------------------- +-- Changes inner container size of scrollview.
+-- Inner container size must be larger than or equal scrollview's size.
+-- param inner container size. -- @function [parent=#ScrollView] setInnerContainerSize -- @param self -- @param #size_table size -------------------------------- +-- Gets inner container size of scrollview.
+-- Inner container size must be larger than or equal scrollview's size.
+-- return inner container size. -- @function [parent=#ScrollView] getInnerContainerSize -- @param self -- @return size_table#size_table ret (return value: size_table) -------------------------------- +-- -- @function [parent=#ScrollView] isBounceEnabled -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- Move inner container to vertical percent position of scrollview. -- @function [parent=#ScrollView] jumpToPercentVertical -- @param self --- @param #float float +-- @param #float percent -------------------------------- +-- -- @function [parent=#ScrollView] addEventListener -- @param self --- @param #function func +-- @param #function callback -------------------------------- +-- -- @function [parent=#ScrollView] setInertiaScrollEnabled -- @param self --- @param #bool bool +-- @param #bool enabled -------------------------------- +-- Move inner container to top and left boundary of scrollview. -- @function [parent=#ScrollView] jumpToTopLeft -- @param self -------------------------------- +-- Move inner container to horizontal percent position of scrollview. -- @function [parent=#ScrollView] jumpToPercentHorizontal -- @param self --- @param #float float +-- @param #float percent -------------------------------- +-- Move inner container to bottom and right boundary of scrollview. -- @function [parent=#ScrollView] jumpToBottomRight -- @param self -------------------------------- +-- -- @function [parent=#ScrollView] setBounceEnabled -- @param self --- @param #bool bool +-- @param #bool enabled -------------------------------- +-- Move inner container to top boundary of scrollview. -- @function [parent=#ScrollView] jumpToTop -- @param self -------------------------------- +-- Scroll inner container to left boundary of scrollview. -- @function [parent=#ScrollView] scrollToLeft -- @param self --- @param #float float --- @param #bool bool +-- @param #float time +-- @param #bool attenuated -------------------------------- +-- Move inner container to both direction percent position of scrollview. -- @function [parent=#ScrollView] jumpToPercentBothDirection -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table percent -------------------------------- +-- Scroll inner container to vertical percent position of scrollview. -- @function [parent=#ScrollView] scrollToPercentVertical -- @param self --- @param #float float --- @param #float float --- @param #bool bool +-- @param #float percent +-- @param #float time +-- @param #bool attenuated -------------------------------- +-- Scroll inner container to bottom boundary of scrollview. -- @function [parent=#ScrollView] scrollToBottom -- @param self --- @param #float float --- @param #bool bool +-- @param #float time +-- @param #bool attenuated -------------------------------- +-- Scroll inner container to bottom and right boundary of scrollview. -- @function [parent=#ScrollView] scrollToBottomRight -- @param self --- @param #float float --- @param #bool bool +-- @param #float time +-- @param #bool attenuated -------------------------------- +-- Move inner container to left boundary of scrollview. -- @function [parent=#ScrollView] jumpToLeft -- @param self -------------------------------- +-- Scroll inner container to right boundary of scrollview. -- @function [parent=#ScrollView] scrollToRight -- @param self --- @param #float float --- @param #bool bool +-- @param #float time +-- @param #bool attenuated -------------------------------- +-- Move inner container to right boundary of scrollview. -- @function [parent=#ScrollView] jumpToRight -- @param self -------------------------------- +-- Scroll inner container to top and right boundary of scrollview. -- @function [parent=#ScrollView] scrollToTopRight -- @param self --- @param #float float --- @param #bool bool +-- @param #float time +-- @param #bool attenuated -------------------------------- +-- Allocates and initializes. -- @function [parent=#ScrollView] create -- @param self -- @return ScrollView#ScrollView ret (return value: ccui.ScrollView) -------------------------------- +-- -- @function [parent=#ScrollView] createInstance -- @param self -- @return Ref#Ref ret (return value: cc.Ref) @@ -187,52 +231,66 @@ -- @overload self, cc.Node, int, string -- @function [parent=#ScrollView] addChild -- @param self --- @param #cc.Node node --- @param #int int --- @param #string str +-- @param #cc.Node child +-- @param #int zOrder +-- @param #string name -------------------------------- +-- -- @function [parent=#ScrollView] getChildByName -- @param self --- @param #string str +-- @param #string name -- @return Node#Node ret (return value: cc.Node) -------------------------------- +-- Returns the "class name" of widget. -- @function [parent=#ScrollView] getDescription -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- -- @function [parent=#ScrollView] update -- @param self --- @param #float float +-- @param #float dt -------------------------------- +-- Gets LayoutType.
+-- see LayoutType
+-- return LayoutType -- @function [parent=#ScrollView] getLayoutType -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- -- @function [parent=#ScrollView] removeAllChildrenWithCleanup -- @param self --- @param #bool bool +-- @param #bool cleanup -------------------------------- +-- -- @function [parent=#ScrollView] removeAllChildren -- @param self -------------------------------- +-- When a widget is in a layout, you could call this method to get the next focused widget within a specified direction.
+-- If the widget is not in a layout, it will return itself
+-- param dir the direction to look for the next focused widget in a layout
+-- param current the current focused widget
+-- return the next focused widget in a layout -- @function [parent=#ScrollView] findNextFocusedWidget -- @param self --- @param #int focusdirection --- @param #ccui.Widget widget +-- @param #int direction +-- @param #ccui.Widget current -- @return Widget#Widget ret (return value: ccui.Widget) -------------------------------- +-- -- @function [parent=#ScrollView] removeChild -- @param self --- @param #cc.Node node --- @param #bool bool +-- @param #cc.Node child +-- @param #bool cleaup -------------------------------- -- @overload self @@ -242,22 +300,28 @@ -- @return array_table#array_table ret (retunr value: array_table) -------------------------------- +-- -- @function [parent=#ScrollView] getChildByTag -- @param self --- @param #int int +-- @param #int tag -- @return Node#Node ret (return value: cc.Node) -------------------------------- +-- -- @function [parent=#ScrollView] getChildrenCount -- @param self -- @return long#long ret (return value: long) -------------------------------- +-- Sets LayoutType.
+-- see LayoutType
+-- param LayoutType -- @function [parent=#ScrollView] setLayoutType -- @param self -- @param #int type -------------------------------- +-- Default constructor -- @function [parent=#ScrollView] ScrollView -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/Sequence.lua b/cocos/scripting/lua-bindings/auto/api/Sequence.lua index feda1c3c1f..965c25b93d 100644 --- a/cocos/scripting/lua-bindings/auto/api/Sequence.lua +++ b/cocos/scripting/lua-bindings/auto/api/Sequence.lua @@ -5,27 +5,32 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#Sequence] startWithTarget -- @param self --- @param #cc.Node node +-- @param #cc.Node target -------------------------------- +-- -- @function [parent=#Sequence] clone -- @param self -- @return Sequence#Sequence ret (return value: cc.Sequence) -------------------------------- +-- -- @function [parent=#Sequence] stop -- @param self -------------------------------- +-- -- @function [parent=#Sequence] reverse -- @param self -- @return Sequence#Sequence ret (return value: cc.Sequence) -------------------------------- +-- -- @function [parent=#Sequence] update -- @param self --- @param #float float +-- @param #float t return nil diff --git a/cocos/scripting/lua-bindings/auto/api/Shaky3D.lua b/cocos/scripting/lua-bindings/auto/api/Shaky3D.lua index 2458883412..f16b0bca3f 100644 --- a/cocos/scripting/lua-bindings/auto/api/Shaky3D.lua +++ b/cocos/scripting/lua-bindings/auto/api/Shaky3D.lua @@ -5,22 +5,25 @@ -- @parent_module cc -------------------------------- +-- creates the action with a range, shake Z vertices, a grid and duration -- @function [parent=#Shaky3D] create -- @param self --- @param #float float --- @param #size_table size --- @param #int int --- @param #bool bool +-- @param #float duration +-- @param #size_table gridSize +-- @param #int range +-- @param #bool shakeZ -- @return Shaky3D#Shaky3D ret (return value: cc.Shaky3D) -------------------------------- +-- -- @function [parent=#Shaky3D] clone -- @param self -- @return Shaky3D#Shaky3D ret (return value: cc.Shaky3D) -------------------------------- +-- -- @function [parent=#Shaky3D] update -- @param self --- @param #float float +-- @param #float time return nil diff --git a/cocos/scripting/lua-bindings/auto/api/ShakyTiles3D.lua b/cocos/scripting/lua-bindings/auto/api/ShakyTiles3D.lua index dbf2de70f6..f8f94b06e4 100644 --- a/cocos/scripting/lua-bindings/auto/api/ShakyTiles3D.lua +++ b/cocos/scripting/lua-bindings/auto/api/ShakyTiles3D.lua @@ -5,22 +5,25 @@ -- @parent_module cc -------------------------------- +-- creates the action with a range, whether or not to shake Z vertices, a grid size, and duration -- @function [parent=#ShakyTiles3D] create -- @param self --- @param #float float --- @param #size_table size --- @param #int int --- @param #bool bool +-- @param #float duration +-- @param #size_table gridSize +-- @param #int range +-- @param #bool shakeZ -- @return ShakyTiles3D#ShakyTiles3D ret (return value: cc.ShakyTiles3D) -------------------------------- +-- -- @function [parent=#ShakyTiles3D] clone -- @param self -- @return ShakyTiles3D#ShakyTiles3D ret (return value: cc.ShakyTiles3D) -------------------------------- +-- -- @function [parent=#ShakyTiles3D] update -- @param self --- @param #float float +-- @param #float time return nil diff --git a/cocos/scripting/lua-bindings/auto/api/ShatteredTiles3D.lua b/cocos/scripting/lua-bindings/auto/api/ShatteredTiles3D.lua index 6e59cf6e15..68a37cd638 100644 --- a/cocos/scripting/lua-bindings/auto/api/ShatteredTiles3D.lua +++ b/cocos/scripting/lua-bindings/auto/api/ShatteredTiles3D.lua @@ -5,22 +5,25 @@ -- @parent_module cc -------------------------------- +-- creates the action with a range, whether of not to shatter Z vertices, a grid size and duration -- @function [parent=#ShatteredTiles3D] create -- @param self --- @param #float float --- @param #size_table size --- @param #int int --- @param #bool bool +-- @param #float duration +-- @param #size_table gridSize +-- @param #int range +-- @param #bool shatterZ -- @return ShatteredTiles3D#ShatteredTiles3D ret (return value: cc.ShatteredTiles3D) -------------------------------- +-- -- @function [parent=#ShatteredTiles3D] clone -- @param self -- @return ShatteredTiles3D#ShatteredTiles3D ret (return value: cc.ShatteredTiles3D) -------------------------------- +-- -- @function [parent=#ShatteredTiles3D] update -- @param self --- @param #float float +-- @param #float time return nil diff --git a/cocos/scripting/lua-bindings/auto/api/Show.lua b/cocos/scripting/lua-bindings/auto/api/Show.lua index a09d54705a..7b53551bf0 100644 --- a/cocos/scripting/lua-bindings/auto/api/Show.lua +++ b/cocos/scripting/lua-bindings/auto/api/Show.lua @@ -5,21 +5,25 @@ -- @parent_module cc -------------------------------- +-- Allocates and initializes the action -- @function [parent=#Show] create -- @param self -- @return Show#Show ret (return value: cc.Show) -------------------------------- +-- -- @function [parent=#Show] clone -- @param self -- @return Show#Show ret (return value: cc.Show) -------------------------------- +-- -- @function [parent=#Show] update -- @param self --- @param #float float +-- @param #float time -------------------------------- +-- -- @function [parent=#Show] reverse -- @param self -- @return ActionInstant#ActionInstant ret (return value: cc.ActionInstant) diff --git a/cocos/scripting/lua-bindings/auto/api/ShuffleTiles.lua b/cocos/scripting/lua-bindings/auto/api/ShuffleTiles.lua index 231f1e070b..c8e89ce80c 100644 --- a/cocos/scripting/lua-bindings/auto/api/ShuffleTiles.lua +++ b/cocos/scripting/lua-bindings/auto/api/ShuffleTiles.lua @@ -5,32 +5,37 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#ShuffleTiles] getDelta -- @param self --- @param #size_table size +-- @param #size_table pos -- @return size_table#size_table ret (return value: size_table) -------------------------------- +-- creates the action with a random seed, the grid size and the duration -- @function [parent=#ShuffleTiles] create -- @param self --- @param #float float --- @param #size_table size --- @param #unsigned int int +-- @param #float duration +-- @param #size_table gridSize +-- @param #unsigned int seed -- @return ShuffleTiles#ShuffleTiles ret (return value: cc.ShuffleTiles) -------------------------------- +-- -- @function [parent=#ShuffleTiles] startWithTarget -- @param self --- @param #cc.Node node +-- @param #cc.Node target -------------------------------- +-- -- @function [parent=#ShuffleTiles] clone -- @param self -- @return ShuffleTiles#ShuffleTiles ret (return value: cc.ShuffleTiles) -------------------------------- +-- -- @function [parent=#ShuffleTiles] update -- @param self --- @param #float float +-- @param #float time return nil diff --git a/cocos/scripting/lua-bindings/auto/api/SimpleAudioEngine.lua b/cocos/scripting/lua-bindings/auto/api/SimpleAudioEngine.lua index c56c9104b3..2cb9410358 100644 --- a/cocos/scripting/lua-bindings/auto/api/SimpleAudioEngine.lua +++ b/cocos/scripting/lua-bindings/auto/api/SimpleAudioEngine.lua @@ -4,114 +4,181 @@ -- @parent_module cc -------------------------------- +-- brief Preload background music
+-- param pszFilePath The path of the background music file.
+-- js preloadMusic
+-- lua preloadMusic -- @function [parent=#SimpleAudioEngine] preloadBackgroundMusic -- @param self --- @param #char char +-- @param #char pszFilePath -------------------------------- +-- brief Stop playing background music
+-- param bReleaseData If release the background music data or not.As default value is false
+-- js stopMusic
+-- lua stopMusic -- @function [parent=#SimpleAudioEngine] stopBackgroundMusic -- @param self -------------------------------- +-- brief Stop all playing sound effects -- @function [parent=#SimpleAudioEngine] stopAllEffects -- @param self -------------------------------- +-- brief The volume of the background music within the range of 0.0 as the minimum and 1.0 as the maximum.
+-- js getMusicVolume
+-- lua getMusicVolume -- @function [parent=#SimpleAudioEngine] getBackgroundMusicVolume -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- brief Resume playing background music
+-- js resumeMusic
+-- lua resumeMusic -- @function [parent=#SimpleAudioEngine] resumeBackgroundMusic -- @param self -------------------------------- +-- brief Set the volume of background music
+-- param volume must be within the range of 0.0 as the minimum and 1.0 as the maximum.
+-- js setMusicVolume
+-- lua setMusicVolume -- @function [parent=#SimpleAudioEngine] setBackgroundMusicVolume -- @param self --- @param #float float +-- @param #float volume -------------------------------- +-- brief preload a compressed audio file
+-- details the compressed audio will be decoded to wave, then written into an internal buffer in SimpleAudioEngine
+-- param pszFilePath The path of the effect file -- @function [parent=#SimpleAudioEngine] preloadEffect -- @param self --- @param #char char +-- @param #char pszFilePath -------------------------------- +-- brief Indicates whether the background music is playing
+-- return true if the background music is playing, otherwise false
+-- js isMusicPlaying
+-- lua isMusicPlaying -- @function [parent=#SimpleAudioEngine] isBackgroundMusicPlaying -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- brief The volume of the effects within the range of 0.0 as the minimum and 1.0 as the maximum. -- @function [parent=#SimpleAudioEngine] getEffectsVolume -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- brief Indicates whether any background music can be played or not.
+-- return true if background music can be played, otherwise false.
+-- js willPlayMusic
+-- lua willPlayMusic -- @function [parent=#SimpleAudioEngine] willPlayBackgroundMusic -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- brief Pause playing sound effect
+-- param nSoundId The return value of function playEffect -- @function [parent=#SimpleAudioEngine] pauseEffect -- @param self --- @param #unsigned int int +-- @param #unsigned int nSoundId -------------------------------- +-- brief Play sound effect with a file path, pitch, pan and gain
+-- param pszFilePath The path of the effect file.
+-- param bLoop Determines whether to loop the effect playing or not. The default value is false.
+-- param pitch Frequency, normal value is 1.0. Will also change effect play time.
+-- param pan Stereo effect, in the range of [-1..1] where -1 enables only left channel.
+-- param gain Volume, in the range of [0..1]. The normal value is 1.
+-- return the OpenAL source id
+-- note Full support is under development, now there are limitations:
+-- - no pitch effect on Samsung Galaxy S2 with OpenSL backend enabled;
+-- - no pitch/pan/gain on emscrippten, win32, marmalade. -- @function [parent=#SimpleAudioEngine] playEffect -- @param self --- @param #char char --- @param #bool bool --- @param #float float --- @param #float float --- @param #float float +-- @param #char pszFilePath +-- @param #bool bLoop +-- @param #float pitch +-- @param #float pan +-- @param #float gain -- @return unsigned int#unsigned int ret (return value: unsigned int) -------------------------------- +-- brief Rewind playing background music
+-- js rewindMusic
+-- lua rewindMusic -- @function [parent=#SimpleAudioEngine] rewindBackgroundMusic -- @param self -------------------------------- +-- brief Play background music
+-- param pszFilePath The path of the background music file,or the FileName of T_SoundResInfo
+-- param bLoop Whether the background music loop or not
+-- js playMusic
+-- lua playMusic -- @function [parent=#SimpleAudioEngine] playBackgroundMusic -- @param self --- @param #char char --- @param #bool bool +-- @param #char pszFilePath +-- @param #bool bLoop -------------------------------- +-- brief Resume all playing sound effect -- @function [parent=#SimpleAudioEngine] resumeAllEffects -- @param self -------------------------------- +-- brief Set the volume of sound effects
+-- param volume must be within the range of 0.0 as the minimum and 1.0 as the maximum. -- @function [parent=#SimpleAudioEngine] setEffectsVolume -- @param self --- @param #float float +-- @param #float volume -------------------------------- +-- brief Stop playing sound effect
+-- param nSoundId The return value of function playEffect -- @function [parent=#SimpleAudioEngine] stopEffect -- @param self --- @param #unsigned int int +-- @param #unsigned int nSoundId -------------------------------- +-- brief Pause playing background music
+-- js pauseMusic
+-- lua pauseMusic -- @function [parent=#SimpleAudioEngine] pauseBackgroundMusic -- @param self -------------------------------- +-- brief Pause all playing sound effect -- @function [parent=#SimpleAudioEngine] pauseAllEffects -- @param self -------------------------------- +-- brief unload the preloaded effect from internal buffer
+-- param pszFilePath The path of the effect file -- @function [parent=#SimpleAudioEngine] unloadEffect -- @param self --- @param #char char +-- @param #char pszFilePath -------------------------------- +-- brief Resume playing sound effect
+-- param nSoundId The return value of function playEffect -- @function [parent=#SimpleAudioEngine] resumeEffect -- @param self --- @param #unsigned int int +-- @param #unsigned int nSoundId -------------------------------- +-- brief Release the shared Engine object
+-- warning It must be called before the application exit, or a memory leak will be casued. -- @function [parent=#SimpleAudioEngine] end -- @param self -------------------------------- +-- brief Get the shared Engine object,it will new one when first time be called -- @function [parent=#SimpleAudioEngine] getInstance -- @param self -- @return SimpleAudioEngine#SimpleAudioEngine ret (return value: cc.SimpleAudioEngine) diff --git a/cocos/scripting/lua-bindings/auto/api/Skeleton.lua b/cocos/scripting/lua-bindings/auto/api/Skeleton.lua index 893bef22d1..51d4c7a9e6 100644 --- a/cocos/scripting/lua-bindings/auto/api/Skeleton.lua +++ b/cocos/scripting/lua-bindings/auto/api/Skeleton.lua @@ -5,49 +5,59 @@ -- @parent_module sp -------------------------------- +-- -- @function [parent=#Skeleton] setToSetupPose -- @param self -------------------------------- +-- -- @function [parent=#Skeleton] setBlendFunc -- @param self --- @param #cc.BlendFunc blendfunc +-- @param #cc.BlendFunc func -------------------------------- +-- -- @function [parent=#Skeleton] onDraw -- @param self --- @param #mat4_table mat4 --- @param #unsigned int int +-- @param #mat4_table transform +-- @param #unsigned int flags -------------------------------- +-- -- @function [parent=#Skeleton] setSlotsToSetupPose -- @param self -------------------------------- +-- -- @function [parent=#Skeleton] getBlendFunc -- @param self -- @return BlendFunc#BlendFunc ret (return value: cc.BlendFunc) -------------------------------- +-- -- @function [parent=#Skeleton] setSkin -- @param self --- @param #char char +-- @param #char skinName -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#Skeleton] setBonesToSetupPose -- @param self -------------------------------- +-- -- @function [parent=#Skeleton] getBoundingBox -- @param self -- @return rect_table#rect_table ret (return value: rect_table) -------------------------------- +-- -- @function [parent=#Skeleton] onEnter -- @param self -------------------------------- +-- -- @function [parent=#Skeleton] onExit -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/Skeleton3D.lua b/cocos/scripting/lua-bindings/auto/api/Skeleton3D.lua index 3f5fb38b02..b4271af29d 100644 --- a/cocos/scripting/lua-bindings/auto/api/Skeleton3D.lua +++ b/cocos/scripting/lua-bindings/auto/api/Skeleton3D.lua @@ -5,39 +5,46 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#Skeleton3D] getBoneByName -- @param self --- @param #string str +-- @param #string id -- @return Bone3D#Bone3D ret (return value: cc.Bone3D) -------------------------------- +-- -- @function [parent=#Skeleton3D] getRootBone -- @param self --- @param #int int +-- @param #int index -- @return Bone3D#Bone3D ret (return value: cc.Bone3D) -------------------------------- +-- refresh bone world matrix -- @function [parent=#Skeleton3D] updateBoneMatrix -- @param self -------------------------------- +-- get bone -- @function [parent=#Skeleton3D] getBoneByIndex -- @param self --- @param #unsigned int int +-- @param #unsigned int index -- @return Bone3D#Bone3D ret (return value: cc.Bone3D) -------------------------------- +-- get & set root bone -- @function [parent=#Skeleton3D] getRootCount -- @param self -- @return long#long ret (return value: long) -------------------------------- +-- get bone index -- @function [parent=#Skeleton3D] getBoneIndex -- @param self --- @param #cc.Bone3D bone3d +-- @param #cc.Bone3D bone -- @return int#int ret (return value: int) -------------------------------- +-- get total bone count -- @function [parent=#Skeleton3D] getBoneCount -- @param self -- @return long#long ret (return value: long) diff --git a/cocos/scripting/lua-bindings/auto/api/SkeletonAnimation.lua b/cocos/scripting/lua-bindings/auto/api/SkeletonAnimation.lua index a3cd0aad24..c57eb13010 100644 --- a/cocos/scripting/lua-bindings/auto/api/SkeletonAnimation.lua +++ b/cocos/scripting/lua-bindings/auto/api/SkeletonAnimation.lua @@ -5,17 +5,20 @@ -- @parent_module sp -------------------------------- +-- -- @function [parent=#SkeletonAnimation] setMix -- @param self --- @param #char char --- @param #char char --- @param #float float +-- @param #char fromAnimation +-- @param #char toAnimation +-- @param #float duration -------------------------------- +-- -- @function [parent=#SkeletonAnimation] clearTracks -- @param self -------------------------------- +-- -- @function [parent=#SkeletonAnimation] clearTrack -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/SkewBy.lua b/cocos/scripting/lua-bindings/auto/api/SkewBy.lua index 4aeb6a83ac..637696e2cc 100644 --- a/cocos/scripting/lua-bindings/auto/api/SkewBy.lua +++ b/cocos/scripting/lua-bindings/auto/api/SkewBy.lua @@ -5,24 +5,28 @@ -- @parent_module cc -------------------------------- +-- creates the action -- @function [parent=#SkewBy] create -- @param self --- @param #float float --- @param #float float --- @param #float float +-- @param #float t +-- @param #float deltaSkewX +-- @param #float deltaSkewY -- @return SkewBy#SkewBy ret (return value: cc.SkewBy) -------------------------------- +-- -- @function [parent=#SkewBy] startWithTarget -- @param self --- @param #cc.Node node +-- @param #cc.Node target -------------------------------- +-- -- @function [parent=#SkewBy] clone -- @param self -- @return SkewBy#SkewBy ret (return value: cc.SkewBy) -------------------------------- +-- -- @function [parent=#SkewBy] reverse -- @param self -- @return SkewBy#SkewBy ret (return value: cc.SkewBy) diff --git a/cocos/scripting/lua-bindings/auto/api/SkewFrame.lua b/cocos/scripting/lua-bindings/auto/api/SkewFrame.lua index 3616dd1b88..53b967470e 100644 --- a/cocos/scripting/lua-bindings/auto/api/SkewFrame.lua +++ b/cocos/scripting/lua-bindings/auto/api/SkewFrame.lua @@ -5,41 +5,49 @@ -- @parent_module ccs -------------------------------- +-- -- @function [parent=#SkewFrame] getSkewY -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#SkewFrame] setSkewX -- @param self --- @param #float float +-- @param #float skewx -------------------------------- +-- -- @function [parent=#SkewFrame] setSkewY -- @param self --- @param #float float +-- @param #float skewy -------------------------------- +-- -- @function [parent=#SkewFrame] getSkewX -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#SkewFrame] create -- @param self -- @return SkewFrame#SkewFrame ret (return value: ccs.SkewFrame) -------------------------------- +-- -- @function [parent=#SkewFrame] apply -- @param self --- @param #float float +-- @param #float percent -------------------------------- +-- -- @function [parent=#SkewFrame] clone -- @param self -- @return Frame#Frame ret (return value: ccs.Frame) -------------------------------- +-- -- @function [parent=#SkewFrame] SkewFrame -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/SkewTo.lua b/cocos/scripting/lua-bindings/auto/api/SkewTo.lua index 65979d1638..be1840199a 100644 --- a/cocos/scripting/lua-bindings/auto/api/SkewTo.lua +++ b/cocos/scripting/lua-bindings/auto/api/SkewTo.lua @@ -5,31 +5,36 @@ -- @parent_module cc -------------------------------- +-- creates the action -- @function [parent=#SkewTo] create -- @param self --- @param #float float --- @param #float float --- @param #float float +-- @param #float t +-- @param #float sx +-- @param #float sy -- @return SkewTo#SkewTo ret (return value: cc.SkewTo) -------------------------------- +-- -- @function [parent=#SkewTo] startWithTarget -- @param self --- @param #cc.Node node +-- @param #cc.Node target -------------------------------- +-- -- @function [parent=#SkewTo] clone -- @param self -- @return SkewTo#SkewTo ret (return value: cc.SkewTo) -------------------------------- +-- -- @function [parent=#SkewTo] reverse -- @param self -- @return SkewTo#SkewTo ret (return value: cc.SkewTo) -------------------------------- +-- -- @function [parent=#SkewTo] update -- @param self --- @param #float float +-- @param #float time return nil diff --git a/cocos/scripting/lua-bindings/auto/api/Skin.lua b/cocos/scripting/lua-bindings/auto/api/Skin.lua index 10b1e77183..c0f870f33f 100644 --- a/cocos/scripting/lua-bindings/auto/api/Skin.lua +++ b/cocos/scripting/lua-bindings/auto/api/Skin.lua @@ -5,37 +5,44 @@ -- @parent_module ccs -------------------------------- +-- -- @function [parent=#Skin] getBone -- @param self -- @return Bone#Bone ret (return value: ccs.Bone) -------------------------------- +-- -- @function [parent=#Skin] getNodeToWorldTransformAR -- @param self -- @return mat4_table#mat4_table ret (return value: mat4_table) -------------------------------- +-- -- @function [parent=#Skin] initWithFile -- @param self --- @param #string str +-- @param #string filename -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#Skin] getDisplayName -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- -- @function [parent=#Skin] updateArmatureTransform -- @param self -------------------------------- +-- -- @function [parent=#Skin] initWithSpriteFrameName -- @param self --- @param #string str +-- @param #string spriteFrameName -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#Skin] setBone -- @param self -- @param #ccs.Bone bone @@ -45,32 +52,37 @@ -- @overload self -- @function [parent=#Skin] create -- @param self --- @param #string str +-- @param #string pszFileName -- @return Skin#Skin ret (retunr value: ccs.Skin) -------------------------------- +-- -- @function [parent=#Skin] createWithSpriteFrameName -- @param self --- @param #string str +-- @param #string pszSpriteFrameName -- @return Skin#Skin ret (return value: ccs.Skin) -------------------------------- +-- -- @function [parent=#Skin] updateTransform -- @param self -------------------------------- +-- -- @function [parent=#Skin] getNodeToWorldTransform -- @param self -- @return mat4_table#mat4_table ret (return value: mat4_table) -------------------------------- +-- -- @function [parent=#Skin] draw -- @param self -- @param #cc.Renderer renderer --- @param #mat4_table mat4 --- @param #unsigned int int +-- @param #mat4_table transform +-- @param #unsigned int flags -------------------------------- +-- js ctor -- @function [parent=#Skin] Skin -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/Slider.lua b/cocos/scripting/lua-bindings/auto/api/Slider.lua index ade0016d08..69dc0e637e 100644 --- a/cocos/scripting/lua-bindings/auto/api/Slider.lua +++ b/cocos/scripting/lua-bindings/auto/api/Slider.lua @@ -5,130 +5,174 @@ -- @parent_module ccui -------------------------------- +-- Changes the progress direction of slider.
+-- param percent percent value from 1 to 100. -- @function [parent=#Slider] setPercent -- @param self --- @param #int int +-- @param #int percent -------------------------------- +-- Load dark state texture for slider ball.
+-- param disabled dark state texture.
+-- param texType @see TextureResType -- @function [parent=#Slider] loadSlidBallTextureDisabled -- @param self --- @param #string str --- @param #int texturerestype +-- @param #string disabled +-- @param #int texType -------------------------------- +-- Load normal state texture for slider ball.
+-- param normal normal state texture.
+-- param texType @see TextureResType -- @function [parent=#Slider] loadSlidBallTextureNormal -- @param self --- @param #string str --- @param #int texturerestype +-- @param #string normal +-- @param #int texType -------------------------------- +-- Load texture for slider bar.
+-- param fileName file name of texture.
+-- param texType @see TextureResType -- @function [parent=#Slider] loadBarTexture -- @param self --- @param #string str --- @param #int texturerestype +-- @param #string fileName +-- @param #int texType -------------------------------- +-- Load dark state texture for slider progress bar.
+-- param fileName file path of texture.
+-- param texType @see TextureResType -- @function [parent=#Slider] loadProgressBarTexture -- @param self --- @param #string str --- @param #int texturerestype +-- @param #string fileName +-- @param #int texType -------------------------------- +-- Load textures for slider ball.
+-- param slider ball normal normal state texture.
+-- param slider ball selected selected state texture.
+-- param slider ball disabled dark state texture.
+-- param texType @see TextureResType -- @function [parent=#Slider] loadSlidBallTextures -- @param self --- @param #string str --- @param #string str --- @param #string str --- @param #int texturerestype +-- @param #string normal +-- @param #string pressed +-- @param #string disabled +-- @param #int texType -------------------------------- +-- Sets capinsets for slider, if slider is using scale9 renderer.
+-- param capInsets capinsets for slider -- @function [parent=#Slider] setCapInsetProgressBarRebderer -- @param self --- @param #rect_table rect +-- @param #rect_table capInsets -------------------------------- +-- Sets capinsets for slider, if slider is using scale9 renderer.
+-- param capInsets capinsets for slider -- @function [parent=#Slider] setCapInsetsBarRenderer -- @param self --- @param #rect_table rect +-- @param #rect_table capInsets -------------------------------- +-- -- @function [parent=#Slider] getCapInsetsProgressBarRebderer -- @param self -- @return rect_table#rect_table ret (return value: rect_table) -------------------------------- +-- Sets if slider is using scale9 renderer.
+-- param true that using scale9 renderer, false otherwise. -- @function [parent=#Slider] setScale9Enabled -- @param self --- @param #bool bool +-- @param #bool able -------------------------------- +-- Sets capinsets for slider, if slider is using scale9 renderer.
+-- param capInsets capinsets for slider -- @function [parent=#Slider] setCapInsets -- @param self --- @param #rect_table rect +-- @param #rect_table capInsets -------------------------------- +-- -- @function [parent=#Slider] addEventListener -- @param self --- @param #function func +-- @param #function callback -------------------------------- +-- Load selected state texture for slider ball.
+-- param selected selected state texture.
+-- param texType @see TextureResType -- @function [parent=#Slider] loadSlidBallTexturePressed -- @param self --- @param #string str --- @param #int texturerestype +-- @param #string pressed +-- @param #int texType -------------------------------- +-- -- @function [parent=#Slider] isScale9Enabled -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#Slider] getCapInsetsBarRenderer -- @param self -- @return rect_table#rect_table ret (return value: rect_table) -------------------------------- +-- Gets the progress direction of slider.
+-- return percent percent value from 1 to 100. -- @function [parent=#Slider] getPercent -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- Allocates and initializes. -- @function [parent=#Slider] create -- @param self -- @return Slider#Slider ret (return value: ccui.Slider) -------------------------------- +-- -- @function [parent=#Slider] createInstance -- @param self -- @return Ref#Ref ret (return value: cc.Ref) -------------------------------- +-- -- @function [parent=#Slider] getVirtualRenderer -- @param self -- @return Node#Node ret (return value: cc.Node) -------------------------------- +-- -- @function [parent=#Slider] ignoreContentAdaptWithSize -- @param self --- @param #bool bool +-- @param #bool ignore -------------------------------- +-- Returns the "class name" of widget. -- @function [parent=#Slider] getDescription -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- -- @function [parent=#Slider] hitTest -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table pt -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#Slider] getVirtualRendererSize -- @param self -- @return size_table#size_table ret (return value: size_table) -------------------------------- +-- Default constructor -- @function [parent=#Slider] Slider -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/Spawn.lua b/cocos/scripting/lua-bindings/auto/api/Spawn.lua index 8188b52d7c..1bdc516a1d 100644 --- a/cocos/scripting/lua-bindings/auto/api/Spawn.lua +++ b/cocos/scripting/lua-bindings/auto/api/Spawn.lua @@ -5,27 +5,32 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#Spawn] startWithTarget -- @param self --- @param #cc.Node node +-- @param #cc.Node target -------------------------------- +-- -- @function [parent=#Spawn] clone -- @param self -- @return Spawn#Spawn ret (return value: cc.Spawn) -------------------------------- +-- -- @function [parent=#Spawn] stop -- @param self -------------------------------- +-- -- @function [parent=#Spawn] reverse -- @param self -- @return Spawn#Spawn ret (return value: cc.Spawn) -------------------------------- +-- -- @function [parent=#Spawn] update -- @param self --- @param #float float +-- @param #float time return nil diff --git a/cocos/scripting/lua-bindings/auto/api/Speed.lua b/cocos/scripting/lua-bindings/auto/api/Speed.lua index f45b157ffa..20fdf2985b 100644 --- a/cocos/scripting/lua-bindings/auto/api/Speed.lua +++ b/cocos/scripting/lua-bindings/auto/api/Speed.lua @@ -5,57 +5,68 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#Speed] setInnerAction -- @param self --- @param #cc.ActionInterval actioninterval +-- @param #cc.ActionInterval action -------------------------------- +-- alter the speed of the inner function in runtime -- @function [parent=#Speed] setSpeed -- @param self --- @param #float float +-- @param #float speed -------------------------------- +-- -- @function [parent=#Speed] getInnerAction -- @param self -- @return ActionInterval#ActionInterval ret (return value: cc.ActionInterval) -------------------------------- +-- -- @function [parent=#Speed] getSpeed -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- create the action -- @function [parent=#Speed] create -- @param self --- @param #cc.ActionInterval actioninterval --- @param #float float +-- @param #cc.ActionInterval action +-- @param #float speed -- @return Speed#Speed ret (return value: cc.Speed) -------------------------------- +-- -- @function [parent=#Speed] startWithTarget -- @param self --- @param #cc.Node node +-- @param #cc.Node target -------------------------------- +-- -- @function [parent=#Speed] reverse -- @param self -- @return Speed#Speed ret (return value: cc.Speed) -------------------------------- +-- -- @function [parent=#Speed] clone -- @param self -- @return Speed#Speed ret (return value: cc.Speed) -------------------------------- +-- -- @function [parent=#Speed] stop -- @param self -------------------------------- +-- -- @function [parent=#Speed] step -- @param self --- @param #float float +-- @param #float dt -------------------------------- +-- -- @function [parent=#Speed] isDone -- @param self -- @return bool#bool ret (return value: bool) diff --git a/cocos/scripting/lua-bindings/auto/api/SplitCols.lua b/cocos/scripting/lua-bindings/auto/api/SplitCols.lua index 96730e20c7..852bd2a2fc 100644 --- a/cocos/scripting/lua-bindings/auto/api/SplitCols.lua +++ b/cocos/scripting/lua-bindings/auto/api/SplitCols.lua @@ -5,25 +5,29 @@ -- @parent_module cc -------------------------------- +-- creates the action with the number of columns to split and the duration -- @function [parent=#SplitCols] create -- @param self --- @param #float float --- @param #unsigned int int +-- @param #float duration +-- @param #unsigned int cols -- @return SplitCols#SplitCols ret (return value: cc.SplitCols) -------------------------------- +-- -- @function [parent=#SplitCols] startWithTarget -- @param self --- @param #cc.Node node +-- @param #cc.Node target -------------------------------- +-- -- @function [parent=#SplitCols] clone -- @param self -- @return SplitCols#SplitCols ret (return value: cc.SplitCols) -------------------------------- +-- -- @function [parent=#SplitCols] update -- @param self --- @param #float float +-- @param #float time return nil diff --git a/cocos/scripting/lua-bindings/auto/api/SplitRows.lua b/cocos/scripting/lua-bindings/auto/api/SplitRows.lua index 1e362c2676..2dc41380a3 100644 --- a/cocos/scripting/lua-bindings/auto/api/SplitRows.lua +++ b/cocos/scripting/lua-bindings/auto/api/SplitRows.lua @@ -5,25 +5,29 @@ -- @parent_module cc -------------------------------- +-- creates the action with the number of rows to split and the duration -- @function [parent=#SplitRows] create -- @param self --- @param #float float --- @param #unsigned int int +-- @param #float duration +-- @param #unsigned int rows -- @return SplitRows#SplitRows ret (return value: cc.SplitRows) -------------------------------- +-- -- @function [parent=#SplitRows] startWithTarget -- @param self --- @param #cc.Node node +-- @param #cc.Node target -------------------------------- +-- -- @function [parent=#SplitRows] clone -- @param self -- @return SplitRows#SplitRows ret (return value: cc.SplitRows) -------------------------------- +-- -- @function [parent=#SplitRows] update -- @param self --- @param #float float +-- @param #float time return nil diff --git a/cocos/scripting/lua-bindings/auto/api/Sprite.lua b/cocos/scripting/lua-bindings/auto/api/Sprite.lua index 7be402618d..1450fafc8d 100644 --- a/cocos/scripting/lua-bindings/auto/api/Sprite.lua +++ b/cocos/scripting/lua-bindings/auto/api/Sprite.lua @@ -9,46 +9,57 @@ -- @overload self, string -- @function [parent=#Sprite] setSpriteFrame -- @param self --- @param #string str +-- @param #string spriteFrameName -------------------------------- -- @overload self, cc.Texture2D -- @overload self, string -- @function [parent=#Sprite] setTexture -- @param self --- @param #string str +-- @param #string filename -------------------------------- +-- returns the Texture2D object used by the sprite -- @function [parent=#Sprite] getTexture -- @param self -- @return Texture2D#Texture2D ret (return value: cc.Texture2D) -------------------------------- +-- Sets whether the sprite should be flipped vertically or not.
+-- param flippedY true if the sprite should be flipped vertically, false otherwise. -- @function [parent=#Sprite] setFlippedY -- @param self --- @param #bool bool +-- @param #bool flippedY -------------------------------- +-- Sets whether the sprite should be flipped horizontally or not.
+-- param flippedX true if the sprite should be flipped horizontally, false otherwise. -- @function [parent=#Sprite] setFlippedX -- @param self --- @param #bool bool +-- @param #bool flippedX -------------------------------- +-- Returns the batch node object if this sprite is rendered by SpriteBatchNode
+-- return The SpriteBatchNode object if this sprite is rendered by SpriteBatchNode,
+-- nullptr if the sprite isn't used batch node. -- @function [parent=#Sprite] getBatchNode -- @param self -- @return SpriteBatchNode#SpriteBatchNode ret (return value: cc.SpriteBatchNode) -------------------------------- +-- Gets the offset position of the sprite. Calculated automatically by editors like Zwoptex. -- @function [parent=#Sprite] getOffsetPosition -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- -- @function [parent=#Sprite] removeAllChildrenWithCleanup -- @param self --- @param #bool bool +-- @param #bool cleanup -------------------------------- +-- Updates the quad according the rotation, position, scale values. -- @function [parent=#Sprite] updateTransform -- @param self @@ -58,82 +69,121 @@ -- @function [parent=#Sprite] setTextureRect -- @param self -- @param #rect_table rect --- @param #bool bool --- @param #size_table size +-- @param #bool rotated +-- @param #size_table untrimmedSize -------------------------------- +-- Returns whether or not a SpriteFrame is being displayed -- @function [parent=#Sprite] isFrameDisplayed -- @param self --- @param #cc.SpriteFrame spriteframe +-- @param #cc.SpriteFrame pFrame -- @return bool#bool ret (return value: bool) -------------------------------- +-- Returns the index used on the TextureAtlas. -- @function [parent=#Sprite] getAtlasIndex -- @param self -- @return long#long ret (return value: long) -------------------------------- +-- Sets the batch node to sprite
+-- warning This method is not recommended for game developers. Sample code for using batch node
+-- code
+-- SpriteBatchNode *batch = SpriteBatchNode::create("Images/grossini_dance_atlas.png", 15);
+-- Sprite *sprite = Sprite::createWithTexture(batch->getTexture(), Rect(0, 0, 57, 57));
+-- batch->addChild(sprite);
+-- layer->addChild(batch);
+-- endcode -- @function [parent=#Sprite] setBatchNode -- @param self --- @param #cc.SpriteBatchNode spritebatchnode +-- @param #cc.SpriteBatchNode spriteBatchNode -------------------------------- +-- / @{/ @name Animation methods
+-- Changes the display frame with animation name and index.
+-- The animation name will be get from the AnimationCache -- @function [parent=#Sprite] setDisplayFrameWithAnimationName -- @param self --- @param #string str --- @param #long long +-- @param #string animationName +-- @param #long frameIndex -------------------------------- +-- Sets the weak reference of the TextureAtlas when the sprite is rendered using via SpriteBatchNode -- @function [parent=#Sprite] setTextureAtlas -- @param self --- @param #cc.TextureAtlas textureatlas +-- @param #cc.TextureAtlas pobTextureAtlas -------------------------------- +-- Returns the current displayed frame. -- @function [parent=#Sprite] getSpriteFrame -- @param self -- @return SpriteFrame#SpriteFrame ret (return value: cc.SpriteFrame) -------------------------------- +-- Whether or not the Sprite needs to be updated in the Atlas.
+-- return true if the sprite needs to be updated in the Atlas, false otherwise. -- @function [parent=#Sprite] isDirty -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- Sets the index used on the TextureAtlas.
+-- warning Don't modify this value unless you know what you are doing -- @function [parent=#Sprite] setAtlasIndex -- @param self --- @param #long long +-- @param #long atlasIndex -------------------------------- +-- Makes the Sprite to be updated in the Atlas. -- @function [parent=#Sprite] setDirty -- @param self --- @param #bool bool +-- @param #bool dirty -------------------------------- +-- Returns whether or not the texture rectangle is rotated. -- @function [parent=#Sprite] isTextureRectRotated -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- Returns the rect of the Sprite in points -- @function [parent=#Sprite] getTextureRect -- @param self -- @return rect_table#rect_table ret (return value: rect_table) -------------------------------- +-- Gets the weak reference of the TextureAtlas when the sprite is rendered using via SpriteBatchNode -- @function [parent=#Sprite] getTextureAtlas -- @param self -- @return TextureAtlas#TextureAtlas ret (return value: cc.TextureAtlas) -------------------------------- +-- Returns the flag which indicates whether the sprite is flipped horizontally or not.
+-- It only flips the texture of the sprite, and not the texture of the sprite's children.
+-- Also, flipping the texture doesn't alter the anchorPoint.
+-- If you want to flip the anchorPoint too, and/or to flip the children too use:
+-- sprite->setScaleX(sprite->getScaleX() * -1);
+-- return true if the sprite is flipped horizontally, false otherwise. -- @function [parent=#Sprite] isFlippedX -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- Return the flag which indicates whether the sprite is flipped vertically or not.
+-- It only flips the texture of the sprite, and not the texture of the sprite's children.
+-- Also, flipping the texture doesn't alter the anchorPoint.
+-- If you want to flip the anchorPoint too, and/or to flip the children too use:
+-- sprite->setScaleY(sprite->getScaleY() * -1);
+-- return true if the sprite is flipped vertically, false otherwise. -- @function [parent=#Sprite] isFlippedY -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- Sets the vertex rect.
+-- It will be called internally by setTextureRect.
+-- Useful if you want to create 2x images from SD images in Retina Display.
+-- Do not call it manually. Use setTextureRect instead. -- @function [parent=#Sprite] setVertexRect -- @param self -- @param #rect_table rect @@ -144,7 +194,7 @@ -- @overload self, string, rect_table -- @function [parent=#Sprite] create -- @param self --- @param #string str +-- @param #string filename -- @param #rect_table rect -- @return Sprite#Sprite ret (retunr value: cc.Sprite) @@ -153,131 +203,157 @@ -- @overload self, cc.Texture2D -- @function [parent=#Sprite] createWithTexture -- @param self --- @param #cc.Texture2D texture2d +-- @param #cc.Texture2D texture -- @param #rect_table rect --- @param #bool bool +-- @param #bool rotated -- @return Sprite#Sprite ret (retunr value: cc.Sprite) -------------------------------- +-- Creates a sprite with an sprite frame name.
+-- A SpriteFrame will be fetched from the SpriteFrameCache by spriteFrameName param.
+-- If the SpriteFrame doesn't exist it will raise an exception.
+-- param spriteFrameName A null terminated string which indicates the sprite frame name.
+-- return An autoreleased sprite object -- @function [parent=#Sprite] createWithSpriteFrameName -- @param self --- @param #string str +-- @param #string spriteFrameName -- @return Sprite#Sprite ret (return value: cc.Sprite) -------------------------------- +-- Creates a sprite with an sprite frame.
+-- param spriteFrame A sprite frame which involves a texture and a rect
+-- return An autoreleased sprite object -- @function [parent=#Sprite] createWithSpriteFrame -- @param self --- @param #cc.SpriteFrame spriteframe +-- @param #cc.SpriteFrame spriteFrame -- @return Sprite#Sprite ret (return value: cc.Sprite) -------------------------------- +-- -- @function [parent=#Sprite] draw -- @param self -- @param #cc.Renderer renderer --- @param #mat4_table mat4 --- @param #unsigned int int +-- @param #mat4_table transform +-- @param #unsigned int flags -------------------------------- -- @overload self, cc.Node, int, string -- @overload self, cc.Node, int, int -- @function [parent=#Sprite] addChild -- @param self --- @param #cc.Node node --- @param #int int --- @param #int int +-- @param #cc.Node child +-- @param #int zOrder +-- @param #int tag -------------------------------- +-- -- @function [parent=#Sprite] setScaleY -- @param self --- @param #float float +-- @param #float scaleY -------------------------------- +-- / @{/ @name Functions inherited from Node -- @function [parent=#Sprite] setScaleX -- @param self --- @param #float float +-- @param #float scaleX -------------------------------- +-- -- @function [parent=#Sprite] isOpacityModifyRGB -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#Sprite] setPositionZ -- @param self --- @param #float float +-- @param #float positionZ -------------------------------- +-- -- @function [parent=#Sprite] setAnchorPoint -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table anchor -------------------------------- +-- -- @function [parent=#Sprite] setRotationSkewX -- @param self --- @param #float float +-- @param #float rotationX -------------------------------- +-- / @} -- @function [parent=#Sprite] getDescription -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- -- @function [parent=#Sprite] setRotationSkewY -- @param self --- @param #float float +-- @param #float rotationY -------------------------------- -- @overload self, float -- @overload self, float, float -- @function [parent=#Sprite] setScale -- @param self --- @param #float float --- @param #float float +-- @param #float scaleX +-- @param #float scaleY -------------------------------- +-- -- @function [parent=#Sprite] reorderChild -- @param self --- @param #cc.Node node --- @param #int int +-- @param #cc.Node child +-- @param #int zOrder -------------------------------- +-- -- @function [parent=#Sprite] removeChild -- @param self --- @param #cc.Node node --- @param #bool bool +-- @param #cc.Node child +-- @param #bool cleanup -------------------------------- +-- -- @function [parent=#Sprite] sortAllChildren -- @param self -------------------------------- +-- -- @function [parent=#Sprite] setOpacityModifyRGB -- @param self --- @param #bool bool +-- @param #bool modify -------------------------------- +-- -- @function [parent=#Sprite] setRotation -- @param self --- @param #float float +-- @param #float rotation -------------------------------- +-- -- @function [parent=#Sprite] setSkewY -- @param self --- @param #float float +-- @param #float sy -------------------------------- +-- -- @function [parent=#Sprite] setVisible -- @param self --- @param #bool bool +-- @param #bool bVisible -------------------------------- +-- -- @function [parent=#Sprite] setSkewX -- @param self --- @param #float float +-- @param #float sx -------------------------------- +-- -- @function [parent=#Sprite] ignoreAnchorPointForPosition -- @param self --- @param #bool bool +-- @param #bool value return nil diff --git a/cocos/scripting/lua-bindings/auto/api/Sprite3D.lua b/cocos/scripting/lua-bindings/auto/api/Sprite3D.lua index 281ad2ac27..002556c277 100644 --- a/cocos/scripting/lua-bindings/auto/api/Sprite3D.lua +++ b/cocos/scripting/lua-bindings/auto/api/Sprite3D.lua @@ -5,67 +5,78 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#Sprite3D] setCullFaceEnabled -- @param self --- @param #bool bool +-- @param #bool enable -------------------------------- -- @overload self, cc.Texture2D -- @overload self, string -- @function [parent=#Sprite3D] setTexture -- @param self --- @param #string str +-- @param #string texFile -------------------------------- +-- remove all attach nodes -- @function [parent=#Sprite3D] removeAllAttachNode -- @param self -------------------------------- +-- -- @function [parent=#Sprite3D] setBlendFunc -- @param self --- @param #cc.BlendFunc blendfunc +-- @param #cc.BlendFunc blendFunc -------------------------------- +-- get mesh -- @function [parent=#Sprite3D] getMesh -- @param self -- @return Mesh#Mesh ret (return value: cc.Mesh) -------------------------------- +-- -- @function [parent=#Sprite3D] getBlendFunc -- @param self -- @return BlendFunc#BlendFunc ret (return value: cc.BlendFunc) -------------------------------- +-- -- @function [parent=#Sprite3D] setCullFace -- @param self --- @param #unsigned int int +-- @param #unsigned int cullFace -------------------------------- +-- remove attach node -- @function [parent=#Sprite3D] removeAttachNode -- @param self --- @param #string str +-- @param #string boneName -------------------------------- +-- get SubMeshState by index -- @function [parent=#Sprite3D] getMeshByIndex -- @param self --- @param #int int +-- @param #int index -- @return Mesh#Mesh ret (return value: cc.Mesh) -------------------------------- +-- get SubMeshState by Name -- @function [parent=#Sprite3D] getMeshByName -- @param self --- @param #string str +-- @param #string name -- @return Mesh#Mesh ret (return value: cc.Mesh) -------------------------------- +-- -- @function [parent=#Sprite3D] getSkeleton -- @param self -- @return Skeleton3D#Skeleton3D ret (return value: cc.Skeleton3D) -------------------------------- +-- get AttachNode by bone name, return nullptr if not exist -- @function [parent=#Sprite3D] getAttachNode -- @param self --- @param #string str +-- @param #string boneName -- @return AttachNode#AttachNode ret (return value: cc.AttachNode) -------------------------------- @@ -73,21 +84,25 @@ -- @overload self, string -- @function [parent=#Sprite3D] create -- @param self --- @param #string str --- @param #string str +-- @param #string modelPath +-- @param #string texturePath -- @return Sprite3D#Sprite3D ret (retunr value: cc.Sprite3D) -------------------------------- +-- Returns 2d bounding-box
+-- Note: the bouding-box is just get from the AABB which as Z=0, so that is not very accurate. -- @function [parent=#Sprite3D] getBoundingBox -- @param self -- @return rect_table#rect_table ret (return value: rect_table) -------------------------------- +-- set GLProgramState, you should bind attributes by yourself -- @function [parent=#Sprite3D] setGLProgramState -- @param self --- @param #cc.GLProgramState glprogramstate +-- @param #cc.GLProgramState glProgramState -------------------------------- +-- just rember bind attributes -- @function [parent=#Sprite3D] setGLProgram -- @param self -- @param #cc.GLProgram glprogram diff --git a/cocos/scripting/lua-bindings/auto/api/SpriteBatchNode.lua b/cocos/scripting/lua-bindings/auto/api/SpriteBatchNode.lua index 66321568dd..51e356b39d 100644 --- a/cocos/scripting/lua-bindings/auto/api/SpriteBatchNode.lua +++ b/cocos/scripting/lua-bindings/auto/api/SpriteBatchNode.lua @@ -5,107 +5,131 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#SpriteBatchNode] appendChild -- @param self -- @param #cc.Sprite sprite -------------------------------- +-- -- @function [parent=#SpriteBatchNode] addSpriteWithoutQuad -- @param self --- @param #cc.Sprite sprite --- @param #int int --- @param #int int +-- @param #cc.Sprite child +-- @param #int z +-- @param #int aTag -- @return SpriteBatchNode#SpriteBatchNode ret (return value: cc.SpriteBatchNode) -------------------------------- +-- -- @function [parent=#SpriteBatchNode] reorderBatch -- @param self --- @param #bool bool +-- @param #bool reorder -------------------------------- +-- -- @function [parent=#SpriteBatchNode] removeAllChildrenWithCleanup -- @param self --- @param #bool bool +-- @param #bool cleanup -------------------------------- +-- -- @function [parent=#SpriteBatchNode] lowestAtlasIndexInChild -- @param self -- @param #cc.Sprite sprite -- @return long#long ret (return value: long) -------------------------------- +-- -- @function [parent=#SpriteBatchNode] atlasIndexForChild -- @param self -- @param #cc.Sprite sprite --- @param #int int +-- @param #int z -- @return long#long ret (return value: long) -------------------------------- +-- sets the TextureAtlas object -- @function [parent=#SpriteBatchNode] setTextureAtlas -- @param self --- @param #cc.TextureAtlas textureatlas +-- @param #cc.TextureAtlas textureAtlas -------------------------------- +-- -- @function [parent=#SpriteBatchNode] getTexture -- @param self -- @return Texture2D#Texture2D ret (return value: cc.Texture2D) -------------------------------- +-- -- @function [parent=#SpriteBatchNode] increaseAtlasCapacity -- @param self -------------------------------- +-- returns the TextureAtlas object -- @function [parent=#SpriteBatchNode] getTextureAtlas -- @param self -- @return TextureAtlas#TextureAtlas ret (return value: cc.TextureAtlas) -------------------------------- +-- Inserts a quad at a certain index into the texture atlas. The Sprite won't be added into the children array.
+-- This method should be called only when you are dealing with very big AtlasSrite and when most of the Sprite won't be updated.
+-- For example: a tile map (TMXMap) or a label with lots of characters (LabelBMFont) -- @function [parent=#SpriteBatchNode] insertQuadFromSprite -- @param self -- @param #cc.Sprite sprite --- @param #long long +-- @param #long index -------------------------------- +-- -- @function [parent=#SpriteBatchNode] setTexture -- @param self --- @param #cc.Texture2D texture2d +-- @param #cc.Texture2D texture -------------------------------- +-- -- @function [parent=#SpriteBatchNode] rebuildIndexInOrder -- @param self --- @param #cc.Sprite sprite --- @param #long long +-- @param #cc.Sprite parent +-- @param #long index -- @return long#long ret (return value: long) -------------------------------- +-- -- @function [parent=#SpriteBatchNode] highestAtlasIndexInChild -- @param self -- @param #cc.Sprite sprite -- @return long#long ret (return value: long) -------------------------------- +-- removes a child given a certain index. It will also cleanup the running actions depending on the cleanup parameter.
+-- warning Removing a child from a SpriteBatchNode is very slow -- @function [parent=#SpriteBatchNode] removeChildAtIndex -- @param self --- @param #long long --- @param #bool bool +-- @param #long index +-- @param #bool doCleanup -------------------------------- +-- -- @function [parent=#SpriteBatchNode] removeSpriteFromAtlas -- @param self -- @param #cc.Sprite sprite -------------------------------- +-- creates a SpriteBatchNode with a file image (.png, .jpeg, .pvr, etc) and capacity of children.
+-- The capacity will be increased in 33% in runtime if it run out of space.
+-- The file will be loaded using the TextureMgr. -- @function [parent=#SpriteBatchNode] create -- @param self --- @param #string str --- @param #long long +-- @param #string fileImage +-- @param #long capacity -- @return SpriteBatchNode#SpriteBatchNode ret (return value: cc.SpriteBatchNode) -------------------------------- +-- creates a SpriteBatchNode with a texture2d and capacity of children.
+-- The capacity will be increased in 33% in runtime if it run out of space. -- @function [parent=#SpriteBatchNode] createWithTexture -- @param self --- @param #cc.Texture2D texture2d --- @param #long long +-- @param #cc.Texture2D tex +-- @param #long capacity -- @return SpriteBatchNode#SpriteBatchNode ret (return value: cc.SpriteBatchNode) -------------------------------- @@ -113,43 +137,49 @@ -- @overload self, cc.Node, int, int -- @function [parent=#SpriteBatchNode] addChild -- @param self --- @param #cc.Node node --- @param #int int --- @param #int int +-- @param #cc.Node child +-- @param #int zOrder +-- @param #int tag -------------------------------- +-- -- @function [parent=#SpriteBatchNode] draw -- @param self -- @param #cc.Renderer renderer --- @param #mat4_table mat4 --- @param #unsigned int int +-- @param #mat4_table transform +-- @param #unsigned int flags -------------------------------- +-- -- @function [parent=#SpriteBatchNode] getDescription -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- -- @function [parent=#SpriteBatchNode] visit -- @param self -- @param #cc.Renderer renderer --- @param #mat4_table mat4 --- @param #unsigned int int +-- @param #mat4_table parentTransform +-- @param #unsigned int parentFlags -------------------------------- +-- -- @function [parent=#SpriteBatchNode] sortAllChildren -- @param self -------------------------------- +-- -- @function [parent=#SpriteBatchNode] removeChild -- @param self --- @param #cc.Node node --- @param #bool bool +-- @param #cc.Node child +-- @param #bool cleanup -------------------------------- +-- -- @function [parent=#SpriteBatchNode] reorderChild -- @param self --- @param #cc.Node node --- @param #int int +-- @param #cc.Node child +-- @param #int zOrder return nil diff --git a/cocos/scripting/lua-bindings/auto/api/SpriteDisplayData.lua b/cocos/scripting/lua-bindings/auto/api/SpriteDisplayData.lua index 1f7cc32b52..4b0c6c07bc 100644 --- a/cocos/scripting/lua-bindings/auto/api/SpriteDisplayData.lua +++ b/cocos/scripting/lua-bindings/auto/api/SpriteDisplayData.lua @@ -5,16 +5,19 @@ -- @parent_module ccs -------------------------------- +-- -- @function [parent=#SpriteDisplayData] copy -- @param self --- @param #ccs.DisplayData displaydata +-- @param #ccs.DisplayData displayData -------------------------------- +-- -- @function [parent=#SpriteDisplayData] create -- @param self -- @return SpriteDisplayData#SpriteDisplayData ret (return value: ccs.SpriteDisplayData) -------------------------------- +-- js ctor -- @function [parent=#SpriteDisplayData] SpriteDisplayData -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/SpriteFrame.lua b/cocos/scripting/lua-bindings/auto/api/SpriteFrame.lua index cca90af1d0..b71c6eeaad 100644 --- a/cocos/scripting/lua-bindings/auto/api/SpriteFrame.lua +++ b/cocos/scripting/lua-bindings/auto/api/SpriteFrame.lua @@ -5,86 +5,103 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#SpriteFrame] clone -- @param self -- @return SpriteFrame#SpriteFrame ret (return value: cc.SpriteFrame) -------------------------------- +-- -- @function [parent=#SpriteFrame] setRotated -- @param self --- @param #bool bool +-- @param #bool rotated -------------------------------- +-- set texture of the frame, the texture is retained -- @function [parent=#SpriteFrame] setTexture -- @param self --- @param #cc.Texture2D texture2d +-- @param #cc.Texture2D pobTexture -------------------------------- +-- -- @function [parent=#SpriteFrame] getOffset -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- -- @function [parent=#SpriteFrame] setRectInPixels -- @param self --- @param #rect_table rect +-- @param #rect_table rectInPixels -------------------------------- +-- get texture of the frame -- @function [parent=#SpriteFrame] getTexture -- @param self -- @return Texture2D#Texture2D ret (return value: cc.Texture2D) -------------------------------- +-- get rect of the frame -- @function [parent=#SpriteFrame] getRect -- @param self -- @return rect_table#rect_table ret (return value: rect_table) -------------------------------- +-- set offset of the frame -- @function [parent=#SpriteFrame] setOffsetInPixels -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table offsetInPixels -------------------------------- +-- -- @function [parent=#SpriteFrame] getRectInPixels -- @param self -- @return rect_table#rect_table ret (return value: rect_table) -------------------------------- +-- set original size of the trimmed image -- @function [parent=#SpriteFrame] setOriginalSize -- @param self --- @param #size_table size +-- @param #size_table sizeInPixels -------------------------------- +-- get original size of the trimmed image -- @function [parent=#SpriteFrame] getOriginalSizeInPixels -- @param self -- @return size_table#size_table ret (return value: size_table) -------------------------------- +-- set original size of the trimmed image -- @function [parent=#SpriteFrame] setOriginalSizeInPixels -- @param self --- @param #size_table size +-- @param #size_table sizeInPixels -------------------------------- +-- -- @function [parent=#SpriteFrame] setOffset -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table offsets -------------------------------- +-- -- @function [parent=#SpriteFrame] isRotated -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- set rect of the frame -- @function [parent=#SpriteFrame] setRect -- @param self -- @param #rect_table rect -------------------------------- +-- get offset of the frame -- @function [parent=#SpriteFrame] getOffsetInPixels -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- get original size of the trimmed image -- @function [parent=#SpriteFrame] getOriginalSize -- @param self -- @return size_table#size_table ret (return value: size_table) @@ -94,11 +111,11 @@ -- @overload self, string, rect_table -- @function [parent=#SpriteFrame] create -- @param self --- @param #string str +-- @param #string filename -- @param #rect_table rect --- @param #bool bool --- @param #vec2_table vec2 --- @param #size_table size +-- @param #bool rotated +-- @param #vec2_table offset +-- @param #size_table originalSize -- @return SpriteFrame#SpriteFrame ret (retunr value: cc.SpriteFrame) -------------------------------- @@ -106,11 +123,11 @@ -- @overload self, cc.Texture2D, rect_table -- @function [parent=#SpriteFrame] createWithTexture -- @param self --- @param #cc.Texture2D texture2d +-- @param #cc.Texture2D pobTexture -- @param #rect_table rect --- @param #bool bool --- @param #vec2_table vec2 --- @param #size_table size +-- @param #bool rotated +-- @param #vec2_table offset +-- @param #size_table originalSize -- @return SpriteFrame#SpriteFrame ret (retunr value: cc.SpriteFrame) return nil diff --git a/cocos/scripting/lua-bindings/auto/api/SpriteFrameCache.lua b/cocos/scripting/lua-bindings/auto/api/SpriteFrameCache.lua index 33e686b786..8b6ceba0a9 100644 --- a/cocos/scripting/lua-bindings/auto/api/SpriteFrameCache.lua +++ b/cocos/scripting/lua-bindings/auto/api/SpriteFrameCache.lua @@ -5,10 +5,13 @@ -- @parent_module cc -------------------------------- +-- Adds multiple Sprite Frames from a plist file content. The texture will be associated with the created sprite frames.
+-- js addSpriteFrames
+-- lua addSpriteFrames -- @function [parent=#SpriteFrameCache] addSpriteFramesWithFileContent -- @param self --- @param #string str --- @param #cc.Texture2D texture2d +-- @param #string plist_content +-- @param #cc.Texture2D texture -------------------------------- -- @overload self, string, string @@ -16,59 +19,88 @@ -- @overload self, string, cc.Texture2D -- @function [parent=#SpriteFrameCache] addSpriteFramesWithFile -- @param self --- @param #string str --- @param #cc.Texture2D texture2d +-- @param #string plist +-- @param #cc.Texture2D texture -------------------------------- +-- Adds an sprite frame with a given name.
+-- If the name already exists, then the contents of the old name will be replaced with the new one. -- @function [parent=#SpriteFrameCache] addSpriteFrame -- @param self --- @param #cc.SpriteFrame spriteframe --- @param #string str +-- @param #cc.SpriteFrame frame +-- @param #string frameName -------------------------------- +-- Removes unused sprite frames.
+-- Sprite Frames that have a retain count of 1 will be deleted.
+-- It is convenient to call this method after when starting a new Scene. -- @function [parent=#SpriteFrameCache] removeUnusedSpriteFrames -- @param self -------------------------------- +-- Returns an Sprite Frame that was previously added.
+-- If the name is not found it will return nil.
+-- You should retain the returned copy if you are going to use it.
+-- js getSpriteFrame
+-- lua getSpriteFrame -- @function [parent=#SpriteFrameCache] getSpriteFrameByName -- @param self --- @param #string str +-- @param #string name -- @return SpriteFrame#SpriteFrame ret (return value: cc.SpriteFrame) -------------------------------- +-- Removes multiple Sprite Frames from a plist file.
+-- Sprite Frames stored in this file will be removed.
+-- It is convenient to call this method when a specific texture needs to be removed.
+-- since v0.99.5 -- @function [parent=#SpriteFrameCache] removeSpriteFramesFromFile -- @param self --- @param #string str +-- @param #string plist -------------------------------- +-- -- @function [parent=#SpriteFrameCache] init -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- Purges the dictionary of loaded sprite frames.
+-- Call this method if you receive the "Memory Warning".
+-- In the short term: it will free some resources preventing your app from being killed.
+-- In the medium term: it will allocate more resources.
+-- In the long term: it will be the same. -- @function [parent=#SpriteFrameCache] removeSpriteFrames -- @param self -------------------------------- +-- Removes all Sprite Frames associated with the specified textures.
+-- It is convenient to call this method when a specific texture needs to be removed.
+-- since v0.995. -- @function [parent=#SpriteFrameCache] removeSpriteFramesFromTexture -- @param self --- @param #cc.Texture2D texture2d +-- @param #cc.Texture2D texture -------------------------------- +-- Removes multiple Sprite Frames from a plist file content.
+-- Sprite Frames stored in this file will be removed.
+-- It is convenient to call this method when a specific texture needs to be removed. -- @function [parent=#SpriteFrameCache] removeSpriteFramesFromFileContent -- @param self --- @param #string str +-- @param #string plist_content -------------------------------- +-- Deletes an sprite frame from the sprite frame cache. -- @function [parent=#SpriteFrameCache] removeSpriteFrameByName -- @param self --- @param #string str +-- @param #string name -------------------------------- +-- Destroys the cache. It releases all the Sprite Frames and the retained instance. -- @function [parent=#SpriteFrameCache] destroyInstance -- @param self -------------------------------- +-- Returns the shared instance of the Sprite Frame cache -- @function [parent=#SpriteFrameCache] getInstance -- @param self -- @return SpriteFrameCache#SpriteFrameCache ret (return value: cc.SpriteFrameCache) diff --git a/cocos/scripting/lua-bindings/auto/api/StopGrid.lua b/cocos/scripting/lua-bindings/auto/api/StopGrid.lua index 7dd7245795..7859d30d7f 100644 --- a/cocos/scripting/lua-bindings/auto/api/StopGrid.lua +++ b/cocos/scripting/lua-bindings/auto/api/StopGrid.lua @@ -5,21 +5,25 @@ -- @parent_module cc -------------------------------- +-- Allocates and initializes the action -- @function [parent=#StopGrid] create -- @param self -- @return StopGrid#StopGrid ret (return value: cc.StopGrid) -------------------------------- +-- -- @function [parent=#StopGrid] startWithTarget -- @param self --- @param #cc.Node node +-- @param #cc.Node target -------------------------------- +-- -- @function [parent=#StopGrid] clone -- @param self -- @return StopGrid#StopGrid ret (return value: cc.StopGrid) -------------------------------- +-- -- @function [parent=#StopGrid] reverse -- @param self -- @return StopGrid#StopGrid ret (return value: cc.StopGrid) diff --git a/cocos/scripting/lua-bindings/auto/api/TMXLayer.lua b/cocos/scripting/lua-bindings/auto/api/TMXLayer.lua index 315b1a4f20..92d5b7e46b 100644 --- a/cocos/scripting/lua-bindings/auto/api/TMXLayer.lua +++ b/cocos/scripting/lua-bindings/auto/api/TMXLayer.lua @@ -5,45 +5,53 @@ -- @parent_module ccexp -------------------------------- +-- returns the position in points of a given tile coordinate -- @function [parent=#TMXLayer] getPositionAt -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table tileCoordinate -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- -- @function [parent=#TMXLayer] setLayerOrientation -- @param self --- @param #int int +-- @param #int orientation -------------------------------- +-- size of the layer in tiles -- @function [parent=#TMXLayer] getLayerSize -- @param self -- @return size_table#size_table ret (return value: size_table) -------------------------------- +-- -- @function [parent=#TMXLayer] setMapTileSize -- @param self -- @param #size_table size -------------------------------- +-- Layer orientation, which is the same as the map orientation -- @function [parent=#TMXLayer] getLayerOrientation -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- -- @function [parent=#TMXLayer] setProperties -- @param self --- @param #map_table map +-- @param #map_table properties -------------------------------- +-- -- @function [parent=#TMXLayer] setLayerName -- @param self --- @param #string str +-- @param #string layerName -------------------------------- +-- removes a tile at given tile coordinate -- @function [parent=#TMXLayer] removeTileAt -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table tileCoordinate -------------------------------- -- @overload self @@ -53,89 +61,107 @@ -- @return map_table#map_table ret (retunr value: map_table) -------------------------------- +-- Creates the tiles -- @function [parent=#TMXLayer] setupTiles -- @param self -------------------------------- +-- -- @function [parent=#TMXLayer] setupTileSprite -- @param self -- @param #cc.Sprite sprite --- @param #vec2_table vec2 --- @param #int int +-- @param #vec2_table pos +-- @param #int gid -------------------------------- -- @overload self, int, vec2_table, int -- @overload self, int, vec2_table -- @function [parent=#TMXLayer] setTileGID -- @param self --- @param #int int --- @param #vec2_table vec2 --- @param #int tmxtileflags_ +-- @param #int gid +-- @param #vec2_table tileCoordinate +-- @param #int flags -------------------------------- +-- size of the map's tile (could be different from the tile's size) -- @function [parent=#TMXLayer] getMapTileSize -- @param self -- @return size_table#size_table ret (return value: size_table) -------------------------------- +-- return the value for the specific property name -- @function [parent=#TMXLayer] getProperty -- @param self --- @param #string str +-- @param #string propertyName -- @return Value#Value ret (return value: cc.Value) -------------------------------- +-- -- @function [parent=#TMXLayer] setLayerSize -- @param self -- @param #size_table size -------------------------------- +-- -- @function [parent=#TMXLayer] getLayerName -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- -- @function [parent=#TMXLayer] setTileSet -- @param self --- @param #cc.TMXTilesetInfo tmxtilesetinfo +-- @param #cc.TMXTilesetInfo info -------------------------------- +-- Tileset information for the layer -- @function [parent=#TMXLayer] getTileSet -- @param self -- @return TMXTilesetInfo#TMXTilesetInfo ret (return value: cc.TMXTilesetInfo) -------------------------------- +-- returns the tile (Sprite) at a given a tile coordinate.
+-- The returned Sprite will be already added to the TMXLayer. Don't add it again.
+-- The Sprite can be treated like any other Sprite: rotated, scaled, translated, opacity, color, etc.
+-- You can remove either by calling:
+-- - layer->removeChild(sprite, cleanup); -- @function [parent=#TMXLayer] getTileAt -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table tileCoordinate -- @return Sprite#Sprite ret (return value: cc.Sprite) -------------------------------- +-- creates a FastTMXLayer with an tileset info, a layer info and a map info -- @function [parent=#TMXLayer] create -- @param self --- @param #cc.TMXTilesetInfo tmxtilesetinfo --- @param #cc.TMXLayerInfo tmxlayerinfo --- @param #cc.TMXMapInfo map +-- @param #cc.TMXTilesetInfo tilesetInfo +-- @param #cc.TMXLayerInfo layerInfo +-- @param #cc.TMXMapInfo mapInfo -- @return experimental::TMXLayer#experimental::TMXLayer ret (return value: cc.experimental::TMXLayer) -------------------------------- +-- -- @function [parent=#TMXLayer] removeChild -- @param self --- @param #cc.Node node --- @param #bool bool +-- @param #cc.Node child +-- @param #bool cleanup -------------------------------- +-- -- @function [parent=#TMXLayer] draw -- @param self -- @param #cc.Renderer renderer --- @param #mat4_table mat4 --- @param #unsigned int int +-- @param #mat4_table transform +-- @param #unsigned int flags -------------------------------- +-- -- @function [parent=#TMXLayer] getDescription -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- js ctor -- @function [parent=#TMXLayer] TMXLayer -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/TMXLayerInfo.lua b/cocos/scripting/lua-bindings/auto/api/TMXLayerInfo.lua index fad88388e2..acb406eb7a 100644 --- a/cocos/scripting/lua-bindings/auto/api/TMXLayerInfo.lua +++ b/cocos/scripting/lua-bindings/auto/api/TMXLayerInfo.lua @@ -5,16 +5,19 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#TMXLayerInfo] setProperties -- @param self --- @param #map_table map +-- @param #map_table properties -------------------------------- +-- -- @function [parent=#TMXLayerInfo] getProperties -- @param self -- @return map_table#map_table ret (return value: map_table) -------------------------------- +-- js ctor -- @function [parent=#TMXLayerInfo] TMXLayerInfo -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/TMXMapInfo.lua b/cocos/scripting/lua-bindings/auto/api/TMXMapInfo.lua index ef098ce6f2..3a77a877b5 100644 --- a/cocos/scripting/lua-bindings/auto/api/TMXMapInfo.lua +++ b/cocos/scripting/lua-bindings/auto/api/TMXMapInfo.lua @@ -4,56 +4,66 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#TMXMapInfo] setObjectGroups -- @param self --- @param #array_table array +-- @param #array_table groups -------------------------------- +-- -- @function [parent=#TMXMapInfo] setTileSize -- @param self --- @param #size_table size +-- @param #size_table tileSize -------------------------------- +-- initializes a TMX format with a tmx file -- @function [parent=#TMXMapInfo] initWithTMXFile -- @param self --- @param #string str +-- @param #string tmxFile -- @return bool#bool ret (return value: bool) -------------------------------- +-- / map orientation -- @function [parent=#TMXMapInfo] getOrientation -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- / is storing characters? -- @function [parent=#TMXMapInfo] isStoringCharacters -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#TMXMapInfo] setLayers -- @param self --- @param #array_table array +-- @param #array_table layers -------------------------------- +-- initializes parsing of an XML file, either a tmx (Map) file or tsx (Tileset) file -- @function [parent=#TMXMapInfo] parseXMLFile -- @param self --- @param #string str +-- @param #string xmlFilename -- @return bool#bool ret (return value: bool) -------------------------------- +-- / parent element -- @function [parent=#TMXMapInfo] getParentElement -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- -- @function [parent=#TMXMapInfo] setTMXFileName -- @param self --- @param #string str +-- @param #string fileName -------------------------------- +-- -- @function [parent=#TMXMapInfo] parseXMLString -- @param self --- @param #string str +-- @param #string xmlString -- @return bool#bool ret (return value: bool) -------------------------------- @@ -71,38 +81,45 @@ -- @return array_table#array_table ret (retunr value: array_table) -------------------------------- +-- / parent GID -- @function [parent=#TMXMapInfo] getParentGID -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- -- @function [parent=#TMXMapInfo] setParentElement -- @param self --- @param #int int +-- @param #int element -------------------------------- +-- initializes a TMX format with an XML string and a TMX resource path -- @function [parent=#TMXMapInfo] initWithXML -- @param self --- @param #string str --- @param #string str +-- @param #string tmxString +-- @param #string resourcePath -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#TMXMapInfo] setParentGID -- @param self --- @param #int int +-- @param #int gid -------------------------------- +-- / layer attribs -- @function [parent=#TMXMapInfo] getLayerAttribs -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- / tiles width & height -- @function [parent=#TMXMapInfo] getTileSize -- @param self -- @return size_table#size_table ret (return value: size_table) -------------------------------- +-- -- @function [parent=#TMXMapInfo] getTileProperties -- @param self -- @return map_table#map_table ret (return value: map_table) @@ -115,49 +132,58 @@ -- @return array_table#array_table ret (retunr value: array_table) -------------------------------- +-- -- @function [parent=#TMXMapInfo] getTMXFileName -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- -- @function [parent=#TMXMapInfo] setCurrentString -- @param self --- @param #string str +-- @param #string currentString -------------------------------- +-- -- @function [parent=#TMXMapInfo] setProperties -- @param self --- @param #map_table map +-- @param #map_table properties -------------------------------- +-- -- @function [parent=#TMXMapInfo] setOrientation -- @param self --- @param #int int +-- @param #int orientation -------------------------------- +-- -- @function [parent=#TMXMapInfo] setTileProperties -- @param self --- @param #map_table map +-- @param #map_table tileProperties -------------------------------- +-- -- @function [parent=#TMXMapInfo] setMapSize -- @param self --- @param #size_table size +-- @param #size_table mapSize -------------------------------- +-- -- @function [parent=#TMXMapInfo] setStoringCharacters -- @param self --- @param #bool bool +-- @param #bool storingCharacters -------------------------------- +-- / map width & height -- @function [parent=#TMXMapInfo] getMapSize -- @param self -- @return size_table#size_table ret (return value: size_table) -------------------------------- +-- -- @function [parent=#TMXMapInfo] setTilesets -- @param self --- @param #array_table array +-- @param #array_table tilesets -------------------------------- -- @overload self @@ -167,29 +193,34 @@ -- @return map_table#map_table ret (retunr value: map_table) -------------------------------- +-- -- @function [parent=#TMXMapInfo] getCurrentString -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- -- @function [parent=#TMXMapInfo] setLayerAttribs -- @param self --- @param #int int +-- @param #int layerAttribs -------------------------------- +-- creates a TMX Format with a tmx file -- @function [parent=#TMXMapInfo] create -- @param self --- @param #string str +-- @param #string tmxFile -- @return TMXMapInfo#TMXMapInfo ret (return value: cc.TMXMapInfo) -------------------------------- +-- creates a TMX Format with an XML string and a TMX resource path -- @function [parent=#TMXMapInfo] createWithXML -- @param self --- @param #string str --- @param #string str +-- @param #string tmxString +-- @param #string resourcePath -- @return TMXMapInfo#TMXMapInfo ret (return value: cc.TMXMapInfo) -------------------------------- +-- js ctor -- @function [parent=#TMXMapInfo] TMXMapInfo -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/TMXObjectGroup.lua b/cocos/scripting/lua-bindings/auto/api/TMXObjectGroup.lua index 2a2330d036..3d6c1ebed2 100644 --- a/cocos/scripting/lua-bindings/auto/api/TMXObjectGroup.lua +++ b/cocos/scripting/lua-bindings/auto/api/TMXObjectGroup.lua @@ -5,25 +5,30 @@ -- @parent_module cc -------------------------------- +-- Sets the offset position of child objects -- @function [parent=#TMXObjectGroup] setPositionOffset -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table offset -------------------------------- +-- return the value for the specific property name -- @function [parent=#TMXObjectGroup] getProperty -- @param self --- @param #string str +-- @param #string propertyName -- @return Value#Value ret (return value: cc.Value) -------------------------------- +-- Gets the offset position of child objects -- @function [parent=#TMXObjectGroup] getPositionOffset -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- return the dictionary for the specific object name.
+-- It will return the 1st object found on the array for the given name. -- @function [parent=#TMXObjectGroup] getObject -- @param self --- @param #string str +-- @param #string objectName -- @return map_table#map_table ret (return value: map_table) -------------------------------- @@ -34,9 +39,10 @@ -- @return array_table#array_table ret (retunr value: array_table) -------------------------------- +-- -- @function [parent=#TMXObjectGroup] setGroupName -- @param self --- @param #string str +-- @param #string groupName -------------------------------- -- @overload self @@ -46,21 +52,25 @@ -- @return map_table#map_table ret (retunr value: map_table) -------------------------------- +-- -- @function [parent=#TMXObjectGroup] getGroupName -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- Sets the list of properties -- @function [parent=#TMXObjectGroup] setProperties -- @param self --- @param #map_table map +-- @param #map_table properties -------------------------------- +-- Sets the array of the objects -- @function [parent=#TMXObjectGroup] setObjects -- @param self --- @param #array_table array +-- @param #array_table objects -------------------------------- +-- js ctor -- @function [parent=#TMXObjectGroup] TMXObjectGroup -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/TMXTiledMap.lua b/cocos/scripting/lua-bindings/auto/api/TMXTiledMap.lua index 86175d51f4..1e36be8fd4 100644 --- a/cocos/scripting/lua-bindings/auto/api/TMXTiledMap.lua +++ b/cocos/scripting/lua-bindings/auto/api/TMXTiledMap.lua @@ -5,25 +5,29 @@ -- @parent_module ccexp -------------------------------- +-- -- @function [parent=#TMXTiledMap] setObjectGroups -- @param self --- @param #array_table array +-- @param #array_table groups -------------------------------- +-- return the value for the specific property name -- @function [parent=#TMXTiledMap] getProperty -- @param self --- @param #string str +-- @param #string propertyName -- @return Value#Value ret (return value: cc.Value) -------------------------------- +-- -- @function [parent=#TMXTiledMap] setMapSize -- @param self --- @param #size_table size +-- @param #size_table mapSize -------------------------------- +-- return the TMXObjectGroup for the specific group -- @function [parent=#TMXTiledMap] getObjectGroup -- @param self --- @param #string str +-- @param #string groupName -- @return TMXObjectGroup#TMXObjectGroup ret (return value: cc.TMXObjectGroup) -------------------------------- @@ -34,66 +38,78 @@ -- @return array_table#array_table ret (retunr value: array_table) -------------------------------- +-- the tiles's size property measured in pixels -- @function [parent=#TMXTiledMap] getTileSize -- @param self -- @return size_table#size_table ret (return value: size_table) -------------------------------- +-- the map's size property measured in tiles -- @function [parent=#TMXTiledMap] getMapSize -- @param self -- @return size_table#size_table ret (return value: size_table) -------------------------------- +-- properties -- @function [parent=#TMXTiledMap] getProperties -- @param self -- @return map_table#map_table ret (return value: map_table) -------------------------------- +-- return properties dictionary for tile GID -- @function [parent=#TMXTiledMap] getPropertiesForGID -- @param self --- @param #int int +-- @param #int GID -- @return Value#Value ret (return value: cc.Value) -------------------------------- +-- -- @function [parent=#TMXTiledMap] setTileSize -- @param self --- @param #size_table size +-- @param #size_table tileSize -------------------------------- +-- -- @function [parent=#TMXTiledMap] setProperties -- @param self --- @param #map_table map +-- @param #map_table properties -------------------------------- +-- return the FastTMXLayer for the specific layer -- @function [parent=#TMXTiledMap] getLayer -- @param self --- @param #string str +-- @param #string layerName -- @return experimental::TMXLayer#experimental::TMXLayer ret (return value: cc.experimental::TMXLayer) -------------------------------- +-- map orientation -- @function [parent=#TMXTiledMap] getMapOrientation -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- -- @function [parent=#TMXTiledMap] setMapOrientation -- @param self --- @param #int int +-- @param #int mapOrientation -------------------------------- +-- creates a TMX Tiled Map with a TMX file. -- @function [parent=#TMXTiledMap] create -- @param self --- @param #string str +-- @param #string tmxFile -- @return experimental::TMXTiledMap#experimental::TMXTiledMap ret (return value: cc.experimental::TMXTiledMap) -------------------------------- +-- initializes a TMX Tiled Map with a TMX formatted XML string and a path to TMX resources -- @function [parent=#TMXTiledMap] createWithXML -- @param self --- @param #string str --- @param #string str +-- @param #string tmxString +-- @param #string resourcePath -- @return experimental::TMXTiledMap#experimental::TMXTiledMap ret (return value: cc.experimental::TMXTiledMap) -------------------------------- +-- -- @function [parent=#TMXTiledMap] getDescription -- @param self -- @return string#string ret (return value: string) diff --git a/cocos/scripting/lua-bindings/auto/api/TMXTilesetInfo.lua b/cocos/scripting/lua-bindings/auto/api/TMXTilesetInfo.lua index 3d07264e37..b782adde5f 100644 --- a/cocos/scripting/lua-bindings/auto/api/TMXTilesetInfo.lua +++ b/cocos/scripting/lua-bindings/auto/api/TMXTilesetInfo.lua @@ -5,12 +5,14 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#TMXTilesetInfo] getRectForGID -- @param self --- @param #unsigned int int +-- @param #unsigned int gid -- @return rect_table#rect_table ret (return value: rect_table) -------------------------------- +-- js ctor -- @function [parent=#TMXTilesetInfo] TMXTilesetInfo -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/TableView.lua b/cocos/scripting/lua-bindings/auto/api/TableView.lua index 2efa32f127..21e38bd249 100644 --- a/cocos/scripting/lua-bindings/auto/api/TableView.lua +++ b/cocos/scripting/lua-bindings/auto/api/TableView.lua @@ -5,92 +5,115 @@ -- @parent_module cc -------------------------------- +-- Updates the content of the cell at a given index.
+-- param idx index to find a cell -- @function [parent=#TableView] updateCellAtIndex -- @param self --- @param #long long +-- @param #long idx -------------------------------- +-- determines how cell is ordered and filled in the view. -- @function [parent=#TableView] setVerticalFillOrder -- @param self --- @param #int verticalfillorder +-- @param #int order -------------------------------- +-- -- @function [parent=#TableView] scrollViewDidZoom -- @param self --- @param #cc.ScrollView scrollview +-- @param #cc.ScrollView view -------------------------------- +-- -- @function [parent=#TableView] _updateContentSize -- @param self -------------------------------- +-- -- @function [parent=#TableView] getVerticalFillOrder -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- Removes a cell at a given index
+-- param idx index to find a cell -- @function [parent=#TableView] removeCellAtIndex -- @param self --- @param #long long +-- @param #long idx -------------------------------- +-- -- @function [parent=#TableView] initWithViewSize -- @param self -- @param #size_table size --- @param #cc.Node node +-- @param #cc.Node container -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#TableView] scrollViewDidScroll -- @param self --- @param #cc.ScrollView scrollview +-- @param #cc.ScrollView view -------------------------------- +-- reloads data from data source. the view will be refreshed. -- @function [parent=#TableView] reloadData -- @param self -------------------------------- +-- Inserts a new cell at a given index
+-- param idx location to insert -- @function [parent=#TableView] insertCellAtIndex -- @param self --- @param #long long +-- @param #long idx -------------------------------- +-- Returns an existing cell at a given index. Returns nil if a cell is nonexistent at the moment of query.
+-- param idx index
+-- return a cell at a given index -- @function [parent=#TableView] cellAtIndex -- @param self --- @param #long long +-- @param #long idx -- @return TableViewCell#TableViewCell ret (return value: cc.TableViewCell) -------------------------------- +-- Dequeues a free cell if available. nil if not.
+-- return free cell -- @function [parent=#TableView] dequeueCell -- @param self -- @return TableViewCell#TableViewCell ret (return value: cc.TableViewCell) -------------------------------- +-- -- @function [parent=#TableView] onTouchMoved -- @param self --- @param #cc.Touch touch --- @param #cc.Event event +-- @param #cc.Touch pTouch +-- @param #cc.Event pEvent -------------------------------- +-- -- @function [parent=#TableView] onTouchEnded -- @param self --- @param #cc.Touch touch --- @param #cc.Event event +-- @param #cc.Touch pTouch +-- @param #cc.Event pEvent -------------------------------- +-- -- @function [parent=#TableView] onTouchCancelled -- @param self --- @param #cc.Touch touch --- @param #cc.Event event +-- @param #cc.Touch pTouch +-- @param #cc.Event pEvent -------------------------------- +-- -- @function [parent=#TableView] onTouchBegan -- @param self --- @param #cc.Touch touch --- @param #cc.Event event +-- @param #cc.Touch pTouch +-- @param #cc.Event pEvent -- @return bool#bool ret (return value: bool) -------------------------------- +-- js ctor -- @function [parent=#TableView] TableView -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/TableViewCell.lua b/cocos/scripting/lua-bindings/auto/api/TableViewCell.lua index dc649d0806..8b243b0548 100644 --- a/cocos/scripting/lua-bindings/auto/api/TableViewCell.lua +++ b/cocos/scripting/lua-bindings/auto/api/TableViewCell.lua @@ -5,25 +5,30 @@ -- @parent_module cc -------------------------------- +-- Cleans up any resources linked to this cell and resets idx property. -- @function [parent=#TableViewCell] reset -- @param self -------------------------------- +-- The index used internally by SWTableView and its subclasses -- @function [parent=#TableViewCell] getIdx -- @param self -- @return long#long ret (return value: long) -------------------------------- +-- -- @function [parent=#TableViewCell] setIdx -- @param self --- @param #long long +-- @param #long uIdx -------------------------------- +-- -- @function [parent=#TableViewCell] create -- @param self -- @return TableViewCell#TableViewCell ret (return value: cc.TableViewCell) -------------------------------- +-- -- @function [parent=#TableViewCell] TableViewCell -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/TargetedAction.lua b/cocos/scripting/lua-bindings/auto/api/TargetedAction.lua index 82d934aab5..432a7b9a50 100644 --- a/cocos/scripting/lua-bindings/auto/api/TargetedAction.lua +++ b/cocos/scripting/lua-bindings/auto/api/TargetedAction.lua @@ -12,39 +12,46 @@ -- @return Node#Node ret (retunr value: cc.Node) -------------------------------- +-- Sets the target that the action will be forced to run with -- @function [parent=#TargetedAction] setForcedTarget -- @param self --- @param #cc.Node node +-- @param #cc.Node forcedTarget -------------------------------- +-- Create an action with the specified action and forced target -- @function [parent=#TargetedAction] create -- @param self --- @param #cc.Node node --- @param #cc.FiniteTimeAction finitetimeaction +-- @param #cc.Node target +-- @param #cc.FiniteTimeAction action -- @return TargetedAction#TargetedAction ret (return value: cc.TargetedAction) -------------------------------- +-- -- @function [parent=#TargetedAction] startWithTarget -- @param self --- @param #cc.Node node +-- @param #cc.Node target -------------------------------- +-- -- @function [parent=#TargetedAction] clone -- @param self -- @return TargetedAction#TargetedAction ret (return value: cc.TargetedAction) -------------------------------- +-- -- @function [parent=#TargetedAction] stop -- @param self -------------------------------- +-- -- @function [parent=#TargetedAction] reverse -- @param self -- @return TargetedAction#TargetedAction ret (return value: cc.TargetedAction) -------------------------------- +-- -- @function [parent=#TargetedAction] update -- @param self --- @param #float float +-- @param #float time return nil diff --git a/cocos/scripting/lua-bindings/auto/api/Text.lua b/cocos/scripting/lua-bindings/auto/api/Text.lua index b6b97605b6..7b1945dc30 100644 --- a/cocos/scripting/lua-bindings/auto/api/Text.lua +++ b/cocos/scripting/lua-bindings/auto/api/Text.lua @@ -5,145 +5,186 @@ -- @parent_module ccui -------------------------------- +-- Enable shadow for the label
+-- todo support blur for shadow effect -- @function [parent=#Text] enableShadow -- @param self -------------------------------- +-- -- @function [parent=#Text] getFontSize -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- -- @function [parent=#Text] getString -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- disable shadow/outline/glow rendering -- @function [parent=#Text] disableEffect -- @param self -------------------------------- +-- -- @function [parent=#Text] getTextColor -- @param self -- @return color4b_table#color4b_table ret (return value: color4b_table) -------------------------------- +-- -- @function [parent=#Text] setTextVerticalAlignment -- @param self --- @param #int textvalignment +-- @param #int alignment -------------------------------- +-- Sets the font name of label.
+-- If you are trying to use a system font, you could just pass a font name
+-- If you are trying to use a TTF, you should pass a file path to the TTF file
+-- Usage: Text *text = Text::create("Hello", "Arial", 20);create a system font UIText
+-- text->setFontName("Marfelt"); it will change the font to system font no matter the previous font type is TTF or system font
+-- text->setFontName("xxxx/xxx.ttf");it will change the font to TTF font no matter the previous font type is TTF or system font
+-- param name font name. -- @function [parent=#Text] setFontName -- @param self --- @param #string str +-- @param #string name -------------------------------- +-- Sets the touch scale enabled of label.
+-- param enabled touch scale enabled of label. -- @function [parent=#Text] setTouchScaleChangeEnabled -- @param self --- @param #bool bool +-- @param #bool enabled -------------------------------- +-- -- @function [parent=#Text] setString -- @param self --- @param #string str +-- @param #string text -------------------------------- +-- Gets the touch scale enabled of label.
+-- return touch scale enabled of label. -- @function [parent=#Text] isTouchScaleChangeEnabled -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#Text] getFontName -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- -- @function [parent=#Text] setTextAreaSize -- @param self -- @param #size_table size -------------------------------- +-- Gets the string length of the label.
+-- Note: This length will be larger than the raw string length,
+-- if you want to get the raw string length, you should call this->getString().size() instead
+-- return string length. -- @function [parent=#Text] getStringLength -- @param self -- @return long#long ret (return value: long) -------------------------------- +-- Enable outline for the label
+-- It only works on IOS and Android when you use System fonts -- @function [parent=#Text] enableOutline -- @param self --- @param #color4b_table color4b --- @param #int int +-- @param #color4b_table outlineColor +-- @param #int outlineSize -------------------------------- +-- -- @function [parent=#Text] getType -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- -- @function [parent=#Text] getTextHorizontalAlignment -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- Sets the font size of label.
+-- param size font size. -- @function [parent=#Text] setFontSize -- @param self --- @param #int int +-- @param #int size -------------------------------- +-- -- @function [parent=#Text] setTextColor -- @param self --- @param #color4b_table color4b +-- @param #color4b_table color -------------------------------- +-- only support for TTF -- @function [parent=#Text] enableGlow -- @param self --- @param #color4b_table color4b +-- @param #color4b_table glowColor -------------------------------- +-- -- @function [parent=#Text] getTextVerticalAlignment -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- -- @function [parent=#Text] getTextAreaSize -- @param self -- @return size_table#size_table ret (return value: size_table) -------------------------------- +-- -- @function [parent=#Text] setTextHorizontalAlignment -- @param self --- @param #int texthalignment +-- @param #int alignment -------------------------------- -- @overload self, string, string, int -- @overload self -- @function [parent=#Text] create -- @param self --- @param #string str --- @param #string str --- @param #int int +-- @param #string textContent +-- @param #string fontName +-- @param #int fontSize -- @return Text#Text ret (retunr value: ccui.Text) -------------------------------- +-- -- @function [parent=#Text] createInstance -- @param self -- @return Ref#Ref ret (return value: cc.Ref) -------------------------------- +-- -- @function [parent=#Text] getVirtualRenderer -- @param self -- @return Node#Node ret (return value: cc.Node) -------------------------------- +-- Returns the "class name" of widget. -- @function [parent=#Text] getDescription -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- -- @function [parent=#Text] getVirtualRendererSize -- @param self -- @return size_table#size_table ret (return value: size_table) -------------------------------- +-- Default constructor -- @function [parent=#Text] Text -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/TextAtlas.lua b/cocos/scripting/lua-bindings/auto/api/TextAtlas.lua index 2ee69b8e6e..7a23761192 100644 --- a/cocos/scripting/lua-bindings/auto/api/TextAtlas.lua +++ b/cocos/scripting/lua-bindings/auto/api/TextAtlas.lua @@ -5,30 +5,38 @@ -- @parent_module ccui -------------------------------- +-- Gets the string length of the label.
+-- Note: This length will be larger than the raw string length,
+-- if you want to get the raw string length, you should call this->getString().size() instead
+-- return string length. -- @function [parent=#TextAtlas] getStringLength -- @param self -- @return long#long ret (return value: long) -------------------------------- +-- -- @function [parent=#TextAtlas] getString -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- -- @function [parent=#TextAtlas] setString -- @param self --- @param #string str +-- @param #string value -------------------------------- +-- initializes the LabelAtlas with a string, a char map file(the atlas), the width and height of each element and the starting char of the atlas -- @function [parent=#TextAtlas] setProperty -- @param self --- @param #string str --- @param #string str --- @param #int int --- @param #int int --- @param #string str +-- @param #string stringValue +-- @param #string charMapFile +-- @param #int itemWidth +-- @param #int itemHeight +-- @param #string startCharMap -------------------------------- +-- -- @function [parent=#TextAtlas] adaptRenderers -- @param self @@ -37,34 +45,39 @@ -- @overload self -- @function [parent=#TextAtlas] create -- @param self --- @param #string str --- @param #string str --- @param #int int --- @param #int int --- @param #string str +-- @param #string stringValue +-- @param #string charMapFile +-- @param #int itemWidth +-- @param #int itemHeight +-- @param #string startCharMap -- @return TextAtlas#TextAtlas ret (retunr value: ccui.TextAtlas) -------------------------------- +-- -- @function [parent=#TextAtlas] createInstance -- @param self -- @return Ref#Ref ret (return value: cc.Ref) -------------------------------- +-- -- @function [parent=#TextAtlas] getVirtualRenderer -- @param self -- @return Node#Node ret (return value: cc.Node) -------------------------------- +-- Returns the "class name" of widget. -- @function [parent=#TextAtlas] getDescription -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- -- @function [parent=#TextAtlas] getVirtualRendererSize -- @param self -- @return size_table#size_table ret (return value: size_table) -------------------------------- +-- Default constructor -- @function [parent=#TextAtlas] TextAtlas -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/TextBMFont.lua b/cocos/scripting/lua-bindings/auto/api/TextBMFont.lua index 424c43eda3..7903e704e1 100644 --- a/cocos/scripting/lua-bindings/auto/api/TextBMFont.lua +++ b/cocos/scripting/lua-bindings/auto/api/TextBMFont.lua @@ -5,21 +5,28 @@ -- @parent_module ccui -------------------------------- +-- init a bitmap font atlas with an initial string and the FNT file -- @function [parent=#TextBMFont] setFntFile -- @param self --- @param #string str +-- @param #string fileName -------------------------------- +-- Gets the string length of the label.
+-- Note: This length will be larger than the raw string length,
+-- if you want to get the raw string length, you should call this->getString().size() instead
+-- return string length. -- @function [parent=#TextBMFont] getStringLength -- @param self -- @return long#long ret (return value: long) -------------------------------- +-- -- @function [parent=#TextBMFont] setString -- @param self --- @param #string str +-- @param #string value -------------------------------- +-- -- @function [parent=#TextBMFont] getString -- @param self -- @return string#string ret (return value: string) @@ -29,31 +36,36 @@ -- @overload self -- @function [parent=#TextBMFont] create -- @param self --- @param #string str --- @param #string str +-- @param #string text +-- @param #string filename -- @return TextBMFont#TextBMFont ret (retunr value: ccui.TextBMFont) -------------------------------- +-- -- @function [parent=#TextBMFont] createInstance -- @param self -- @return Ref#Ref ret (return value: cc.Ref) -------------------------------- +-- -- @function [parent=#TextBMFont] getVirtualRenderer -- @param self -- @return Node#Node ret (return value: cc.Node) -------------------------------- +-- Returns the "class name" of widget. -- @function [parent=#TextBMFont] getDescription -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- -- @function [parent=#TextBMFont] getVirtualRendererSize -- @param self -- @return size_table#size_table ret (return value: size_table) -------------------------------- +-- Default constructor -- @function [parent=#TextBMFont] TextBMFont -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/TextField.lua b/cocos/scripting/lua-bindings/auto/api/TextField.lua index c4e22b25bc..eb5014b7c7 100644 --- a/cocos/scripting/lua-bindings/auto/api/TextField.lua +++ b/cocos/scripting/lua-bindings/auto/api/TextField.lua @@ -5,192 +5,229 @@ -- @parent_module ccui -------------------------------- +-- -- @function [parent=#TextField] setAttachWithIME -- @param self --- @param #bool bool +-- @param #bool attach -------------------------------- +-- -- @function [parent=#TextField] getFontSize -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- -- @function [parent=#TextField] getStringValue -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- -- @function [parent=#TextField] setPasswordStyleText -- @param self --- @param #char char +-- @param #char styleText -------------------------------- +-- -- @function [parent=#TextField] getDeleteBackward -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#TextField] getPlaceHolder -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- -- @function [parent=#TextField] getAttachWithIME -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#TextField] setFontName -- @param self --- @param #string str +-- @param #string name -------------------------------- +-- -- @function [parent=#TextField] getInsertText -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#TextField] setInsertText -- @param self --- @param #bool bool +-- @param #bool insertText -------------------------------- +-- -- @function [parent=#TextField] getDetachWithIME -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#TextField] setTextVerticalAlignment -- @param self --- @param #int textvalignment +-- @param #int alignment -------------------------------- +-- -- @function [parent=#TextField] addEventListener -- @param self --- @param #function func +-- @param #function callback -------------------------------- +-- -- @function [parent=#TextField] didNotSelectSelf -- @param self -------------------------------- +-- -- @function [parent=#TextField] getFontName -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- -- @function [parent=#TextField] setTextAreaSize -- @param self -- @param #size_table size -------------------------------- +-- -- @function [parent=#TextField] attachWithIME -- @param self -------------------------------- +-- -- @function [parent=#TextField] getStringLength -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- -- @function [parent=#TextField] setPasswordEnabled -- @param self --- @param #bool bool +-- @param #bool enable -------------------------------- +-- -- @function [parent=#TextField] getPlaceHolderColor -- @param self -- @return color4b_table#color4b_table ret (return value: color4b_table) -------------------------------- +-- -- @function [parent=#TextField] getPasswordStyleText -- @param self -- @return char#char ret (return value: char) -------------------------------- +-- -- @function [parent=#TextField] setMaxLengthEnabled -- @param self --- @param #bool bool +-- @param #bool enable -------------------------------- +-- -- @function [parent=#TextField] isPasswordEnabled -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#TextField] setDeleteBackward -- @param self --- @param #bool bool +-- @param #bool deleteBackward -------------------------------- +-- -- @function [parent=#TextField] setFontSize -- @param self --- @param #int int +-- @param #int size -------------------------------- +-- -- @function [parent=#TextField] setPlaceHolder -- @param self --- @param #string str +-- @param #string value -------------------------------- -- @overload self, color4b_table -- @overload self, color3b_table -- @function [parent=#TextField] setPlaceHolderColor -- @param self --- @param #color3b_table color3b +-- @param #color3b_table color -------------------------------- +-- -- @function [parent=#TextField] setTextHorizontalAlignment -- @param self --- @param #int texthalignment +-- @param #int alignment -------------------------------- +-- -- @function [parent=#TextField] setTextColor -- @param self --- @param #color4b_table color4b +-- @param #color4b_table textColor -------------------------------- +-- -- @function [parent=#TextField] getMaxLength -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- -- @function [parent=#TextField] isMaxLengthEnabled -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#TextField] setDetachWithIME -- @param self --- @param #bool bool +-- @param #bool detach -------------------------------- +-- -- @function [parent=#TextField] setText -- @param self --- @param #string str +-- @param #string text -------------------------------- +-- -- @function [parent=#TextField] setTouchAreaEnabled -- @param self --- @param #bool bool +-- @param #bool enable -------------------------------- +-- -- @function [parent=#TextField] hitTest -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table pt -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#TextField] setMaxLength -- @param self --- @param #int int +-- @param #int length -------------------------------- +-- -- @function [parent=#TextField] setTouchSize -- @param self -- @param #size_table size -------------------------------- +-- -- @function [parent=#TextField] getTouchSize -- @param self -- @return size_table#size_table ret (return value: size_table) @@ -200,37 +237,43 @@ -- @overload self -- @function [parent=#TextField] create -- @param self --- @param #string str --- @param #string str --- @param #int int +-- @param #string placeholder +-- @param #string fontName +-- @param #int fontSize -- @return TextField#TextField ret (retunr value: ccui.TextField) -------------------------------- +-- -- @function [parent=#TextField] createInstance -- @param self -- @return Ref#Ref ret (return value: cc.Ref) -------------------------------- +-- -- @function [parent=#TextField] getVirtualRenderer -- @param self -- @return Node#Node ret (return value: cc.Node) -------------------------------- +-- Returns the "class name" of widget. -- @function [parent=#TextField] getDescription -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- -- @function [parent=#TextField] update -- @param self --- @param #float float +-- @param #float dt -------------------------------- +-- -- @function [parent=#TextField] getVirtualRendererSize -- @param self -- @return size_table#size_table ret (return value: size_table) -------------------------------- +-- -- @function [parent=#TextField] TextField -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/Texture2D.lua b/cocos/scripting/lua-bindings/auto/api/Texture2D.lua index c7c1456291..77a95a5282 100644 --- a/cocos/scripting/lua-bindings/auto/api/Texture2D.lua +++ b/cocos/scripting/lua-bindings/auto/api/Texture2D.lua @@ -5,11 +5,14 @@ -- @parent_module cc -------------------------------- +-- Gets max T -- @function [parent=#Texture2D] getMaxT -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- returns the pixel format.
+-- since v2.0 -- @function [parent=#Texture2D] getStringForFormat -- @param self -- @return char#char ret (return value: char) @@ -20,24 +23,30 @@ -- @function [parent=#Texture2D] initWithImage -- @param self -- @param #cc.Image image --- @param #int pixelformat +-- @param #int format -- @return bool#bool ret (retunr value: bool) -------------------------------- +-- Gets max S -- @function [parent=#Texture2D] getMaxS -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- release only the gl texture.
+-- js NA
+-- lua NA -- @function [parent=#Texture2D] releaseGLTexture -- @param self -------------------------------- +-- -- @function [parent=#Texture2D] hasPremultipliedAlpha -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- Gets the height of the texture in pixels -- @function [parent=#Texture2D] getPixelsHigh -- @param self -- @return int#int ret (return value: int) @@ -47,10 +56,11 @@ -- @overload self -- @function [parent=#Texture2D] getBitsPerPixelForFormat -- @param self --- @param #int pixelformat +-- @param #int format -- @return unsigned int#unsigned int ret (retunr value: unsigned int) -------------------------------- +-- Gets the texture name -- @function [parent=#Texture2D] getName -- @param self -- @return unsigned int#unsigned int ret (return value: unsigned int) @@ -60,97 +70,141 @@ -- @overload self, char, string, float, size_table, int, int -- @function [parent=#Texture2D] initWithString -- @param self --- @param #char char --- @param #string str --- @param #float float --- @param #size_table size --- @param #int texthalignment --- @param #int textvalignment +-- @param #char text +-- @param #string fontName +-- @param #float fontSize +-- @param #size_table dimensions +-- @param #int hAlignment +-- @param #int vAlignment -- @return bool#bool ret (retunr value: bool) -------------------------------- +-- Sets max T -- @function [parent=#Texture2D] setMaxT -- @param self --- @param #float float +-- @param #float maxT -------------------------------- +-- draws a texture inside a rect -- @function [parent=#Texture2D] drawInRect -- @param self -- @param #rect_table rect -------------------------------- +-- -- @function [parent=#Texture2D] getContentSize -- @param self -- @return size_table#size_table ret (return value: size_table) -------------------------------- +-- sets alias texture parameters:
+-- - GL_TEXTURE_MIN_FILTER = GL_NEAREST
+-- - GL_TEXTURE_MAG_FILTER = GL_NEAREST
+-- warning Calling this method could allocate additional texture memory.
+-- since v0.8 -- @function [parent=#Texture2D] setAliasTexParameters -- @param self -------------------------------- +-- sets antialias texture parameters:
+-- - GL_TEXTURE_MIN_FILTER = GL_LINEAR
+-- - GL_TEXTURE_MAG_FILTER = GL_LINEAR
+-- warning Calling this method could allocate additional texture memory.
+-- since v0.8 -- @function [parent=#Texture2D] setAntiAliasTexParameters -- @param self -------------------------------- +-- Generates mipmap images for the texture.
+-- It only works if the texture size is POT (power of 2).
+-- since v0.99.0 -- @function [parent=#Texture2D] generateMipmap -- @param self -------------------------------- +-- js NA
+-- lua NA -- @function [parent=#Texture2D] getDescription -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- Gets the pixel format of the texture -- @function [parent=#Texture2D] getPixelFormat -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- -- @function [parent=#Texture2D] setGLProgram -- @param self --- @param #cc.GLProgram glprogram +-- @param #cc.GLProgram program -------------------------------- +-- content size -- @function [parent=#Texture2D] getContentSizeInPixels -- @param self -- @return size_table#size_table ret (return value: size_table) -------------------------------- +-- Gets the width of the texture in pixels -- @function [parent=#Texture2D] getPixelsWide -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- Drawing extensions to make it easy to draw basic quads using a Texture2D object.
+-- These functions require GL_TEXTURE_2D and both GL_VERTEX_ARRAY and GL_TEXTURE_COORD_ARRAY client states to be enabled.
+-- draws a texture at a given point -- @function [parent=#Texture2D] drawAtPoint -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table point -------------------------------- +-- -- @function [parent=#Texture2D] getGLProgram -- @param self -- @return GLProgram#GLProgram ret (return value: cc.GLProgram) -------------------------------- +-- -- @function [parent=#Texture2D] hasMipmaps -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- Sets max S -- @function [parent=#Texture2D] setMaxS -- @param self --- @param #float float +-- @param #float maxS -------------------------------- +-- sets the default pixel format for UIImagescontains alpha channel.
+-- If the UIImage contains alpha channel, then the options are:
+-- - generate 32-bit textures: Texture2D::PixelFormat::RGBA8888 (default one)
+-- - generate 24-bit textures: Texture2D::PixelFormat::RGB888
+-- - generate 16-bit textures: Texture2D::PixelFormat::RGBA4444
+-- - generate 16-bit textures: Texture2D::PixelFormat::RGB5A1
+-- - generate 16-bit textures: Texture2D::PixelFormat::RGB565
+-- - generate 8-bit textures: Texture2D::PixelFormat::A8 (only use it if you use just 1 color)
+-- How does it work ?
+-- - If the image is an RGBA (with Alpha) then the default pixel format will be used (it can be a 8-bit, 16-bit or 32-bit texture)
+-- - If the image is an RGB (without Alpha) then: If the default pixel format is RGBA8888 then a RGBA8888 (32-bit) will be used. Otherwise a RGB565 (16-bit texture) will be used.
+-- This parameter is not valid for PVR / PVR.CCZ images.
+-- since v0.8 -- @function [parent=#Texture2D] setDefaultAlphaPixelFormat -- @param self --- @param #int pixelformat +-- @param #int format -------------------------------- +-- returns the alpha pixel format
+-- since v0.8 -- @function [parent=#Texture2D] getDefaultAlphaPixelFormat -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- js ctor -- @function [parent=#Texture2D] Texture2D -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/TextureCache.lua b/cocos/scripting/lua-bindings/auto/api/TextureCache.lua index fbcaadd1ac..bcbc70498f 100644 --- a/cocos/scripting/lua-bindings/auto/api/TextureCache.lua +++ b/cocos/scripting/lua-bindings/auto/api/TextureCache.lua @@ -5,30 +5,48 @@ -- @parent_module cc -------------------------------- +-- Reload texture from the image file
+-- If the file image hasn't loaded before, load it.
+-- Otherwise the texture will be reloaded from the file image.
+-- The "filenName" parameter is the related/absolute path of the file image.
+-- Return true if the reloading is succeed, otherwise return false. -- @function [parent=#TextureCache] reloadTexture -- @param self --- @param #string str +-- @param #string fileName -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#TextureCache] unbindAllImageAsync -- @param self -------------------------------- +-- Deletes a texture from the cache given a its key name
+-- since v0.99.4 -- @function [parent=#TextureCache] removeTextureForKey -- @param self --- @param #string str +-- @param #string key -------------------------------- +-- Purges the dictionary of loaded textures.
+-- Call this method if you receive the "Memory Warning"
+-- In the short term: it will free some resources preventing your app from being killed
+-- In the medium term: it will allocate more resources
+-- In the long term: it will be the same -- @function [parent=#TextureCache] removeAllTextures -- @param self -------------------------------- +-- js NA
+-- lua NA -- @function [parent=#TextureCache] getDescription -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- Output to CCLOG the current contents of this TextureCache
+-- This will attempt to calculate the size of each texture, and the total texture memory in use
+-- since v1.0 -- @function [parent=#TextureCache] getCachedTextureInfo -- @param self -- @return string#string ret (return value: string) @@ -39,34 +57,44 @@ -- @function [parent=#TextureCache] addImage -- @param self -- @param #cc.Image image --- @param #string str +-- @param #string key -- @return Texture2D#Texture2D ret (retunr value: cc.Texture2D) -------------------------------- +-- -- @function [parent=#TextureCache] unbindImageAsync -- @param self --- @param #string str +-- @param #string filename -------------------------------- +-- Returns an already created texture. Returns nil if the texture doesn't exist.
+-- since v0.99.5 -- @function [parent=#TextureCache] getTextureForKey -- @param self --- @param #string str +-- @param #string key -- @return Texture2D#Texture2D ret (return value: cc.Texture2D) -------------------------------- +-- Removes unused textures
+-- Textures that have a retain count of 1 will be deleted
+-- It is convenient to call this method after when starting a new Scene
+-- since v0.8 -- @function [parent=#TextureCache] removeUnusedTextures -- @param self -------------------------------- +-- Deletes a texture from the cache given a texture -- @function [parent=#TextureCache] removeTexture -- @param self --- @param #cc.Texture2D texture2d +-- @param #cc.Texture2D texture -------------------------------- +-- -- @function [parent=#TextureCache] waitForQuit -- @param self -------------------------------- +-- js ctor -- @function [parent=#TextureCache] TextureCache -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/TextureData.lua b/cocos/scripting/lua-bindings/auto/api/TextureData.lua index 5f1ea092e6..75e2950598 100644 --- a/cocos/scripting/lua-bindings/auto/api/TextureData.lua +++ b/cocos/scripting/lua-bindings/auto/api/TextureData.lua @@ -5,27 +5,32 @@ -- @parent_module ccs -------------------------------- +-- -- @function [parent=#TextureData] getContourData -- @param self --- @param #int int +-- @param #int index -- @return ContourData#ContourData ret (return value: ccs.ContourData) -------------------------------- +-- -- @function [parent=#TextureData] init -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#TextureData] addContourData -- @param self --- @param #ccs.ContourData contourdata +-- @param #ccs.ContourData contourData -------------------------------- +-- -- @function [parent=#TextureData] create -- @param self -- @return TextureData#TextureData ret (return value: ccs.TextureData) -------------------------------- +-- js ctor -- @function [parent=#TextureData] TextureData -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/TextureFrame.lua b/cocos/scripting/lua-bindings/auto/api/TextureFrame.lua index 32222d5bae..77b400ece7 100644 --- a/cocos/scripting/lua-bindings/auto/api/TextureFrame.lua +++ b/cocos/scripting/lua-bindings/auto/api/TextureFrame.lua @@ -5,31 +5,37 @@ -- @parent_module ccs -------------------------------- +-- -- @function [parent=#TextureFrame] getTextureName -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- -- @function [parent=#TextureFrame] setNode -- @param self -- @param #cc.Node node -------------------------------- +-- -- @function [parent=#TextureFrame] setTextureName -- @param self --- @param #string str +-- @param #string textureName -------------------------------- +-- -- @function [parent=#TextureFrame] create -- @param self -- @return TextureFrame#TextureFrame ret (return value: ccs.TextureFrame) -------------------------------- +-- -- @function [parent=#TextureFrame] clone -- @param self -- @return Frame#Frame ret (return value: ccs.Frame) -------------------------------- +-- -- @function [parent=#TextureFrame] TextureFrame -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/TileMapAtlas.lua b/cocos/scripting/lua-bindings/auto/api/TileMapAtlas.lua index 4ea1ba0663..02831ff73f 100644 --- a/cocos/scripting/lua-bindings/auto/api/TileMapAtlas.lua +++ b/cocos/scripting/lua-bindings/auto/api/TileMapAtlas.lua @@ -5,40 +5,50 @@ -- @parent_module cc -------------------------------- +-- initializes a TileMap with a tile file (atlas) with a map file and the width and height of each tile in points.
+-- The file will be loaded using the TextureMgr. -- @function [parent=#TileMapAtlas] initWithTileFile -- @param self --- @param #string str --- @param #string str --- @param #int int --- @param #int int +-- @param #string tile +-- @param #string mapFile +-- @param #int tileWidth +-- @param #int tileHeight -- @return bool#bool ret (return value: bool) -------------------------------- +-- dealloc the map from memory -- @function [parent=#TileMapAtlas] releaseMap -- @param self -------------------------------- +-- returns a tile from position x,y.
+-- For the moment only channel R is used -- @function [parent=#TileMapAtlas] getTileAt -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table position -- @return color3b_table#color3b_table ret (return value: color3b_table) -------------------------------- +-- sets a tile at position x,y.
+-- For the moment only channel R is used -- @function [parent=#TileMapAtlas] setTile -- @param self --- @param #color3b_table color3b --- @param #vec2_table vec2 +-- @param #color3b_table tile +-- @param #vec2_table position -------------------------------- +-- creates a TileMap with a tile file (atlas) with a map file and the width and height of each tile in points.
+-- The tile file will be loaded using the TextureMgr. -- @function [parent=#TileMapAtlas] create -- @param self --- @param #string str --- @param #string str --- @param #int int --- @param #int int +-- @param #string tile +-- @param #string mapFile +-- @param #int tileWidth +-- @param #int tileHeight -- @return TileMapAtlas#TileMapAtlas ret (return value: cc.TileMapAtlas) -------------------------------- +-- js ctor -- @function [parent=#TileMapAtlas] TileMapAtlas -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/TiledGrid3D.lua b/cocos/scripting/lua-bindings/auto/api/TiledGrid3D.lua index 53ad06354a..2d459cac13 100644 --- a/cocos/scripting/lua-bindings/auto/api/TiledGrid3D.lua +++ b/cocos/scripting/lua-bindings/auto/api/TiledGrid3D.lua @@ -9,24 +9,28 @@ -- @overload self, size_table, cc.Texture2D, bool -- @function [parent=#TiledGrid3D] create -- @param self --- @param #size_table size --- @param #cc.Texture2D texture2d --- @param #bool bool +-- @param #size_table gridSize +-- @param #cc.Texture2D texture +-- @param #bool flipped -- @return TiledGrid3D#TiledGrid3D ret (retunr value: cc.TiledGrid3D) -------------------------------- +-- -- @function [parent=#TiledGrid3D] calculateVertexPoints -- @param self -------------------------------- +-- -- @function [parent=#TiledGrid3D] blit -- @param self -------------------------------- +-- -- @function [parent=#TiledGrid3D] reuse -- @param self -------------------------------- +-- js ctor -- @function [parent=#TiledGrid3D] TiledGrid3D -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/TiledGrid3DAction.lua b/cocos/scripting/lua-bindings/auto/api/TiledGrid3DAction.lua index 638777d75d..41ef90697f 100644 --- a/cocos/scripting/lua-bindings/auto/api/TiledGrid3DAction.lua +++ b/cocos/scripting/lua-bindings/auto/api/TiledGrid3DAction.lua @@ -5,11 +5,13 @@ -- @parent_module cc -------------------------------- +-- returns the grid -- @function [parent=#TiledGrid3DAction] getGrid -- @param self -- @return GridBase#GridBase ret (return value: cc.GridBase) -------------------------------- +-- -- @function [parent=#TiledGrid3DAction] clone -- @param self -- @return TiledGrid3DAction#TiledGrid3DAction ret (return value: cc.TiledGrid3DAction) diff --git a/cocos/scripting/lua-bindings/auto/api/Timeline.lua b/cocos/scripting/lua-bindings/auto/api/Timeline.lua index e469f6528e..a22a39f028 100644 --- a/cocos/scripting/lua-bindings/auto/api/Timeline.lua +++ b/cocos/scripting/lua-bindings/auto/api/Timeline.lua @@ -5,77 +5,92 @@ -- @parent_module ccs -------------------------------- +-- -- @function [parent=#Timeline] clone -- @param self -- @return Timeline#Timeline ret (return value: ccs.Timeline) -------------------------------- +-- -- @function [parent=#Timeline] gotoFrame -- @param self --- @param #int int +-- @param #int frameIndex -------------------------------- +-- -- @function [parent=#Timeline] setNode -- @param self -- @param #cc.Node node -------------------------------- +-- -- @function [parent=#Timeline] getActionTimeline -- @param self -- @return ActionTimeline#ActionTimeline ret (return value: ccs.ActionTimeline) -------------------------------- +-- -- @function [parent=#Timeline] insertFrame -- @param self -- @param #ccs.Frame frame --- @param #int int +-- @param #int index -------------------------------- +-- -- @function [parent=#Timeline] setActionTag -- @param self --- @param #int int +-- @param #int tag -------------------------------- +-- -- @function [parent=#Timeline] addFrame -- @param self -- @param #ccs.Frame frame -------------------------------- +-- -- @function [parent=#Timeline] getFrames -- @param self -- @return array_table#array_table ret (return value: array_table) -------------------------------- +-- -- @function [parent=#Timeline] getActionTag -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- -- @function [parent=#Timeline] getNode -- @param self -- @return Node#Node ret (return value: cc.Node) -------------------------------- +-- -- @function [parent=#Timeline] removeFrame -- @param self -- @param #ccs.Frame frame -------------------------------- +-- -- @function [parent=#Timeline] setActionTimeline -- @param self --- @param #ccs.ActionTimeline actiontimeline +-- @param #ccs.ActionTimeline action -------------------------------- +-- -- @function [parent=#Timeline] stepToFrame -- @param self --- @param #int int +-- @param #int frameIndex -------------------------------- +-- -- @function [parent=#Timeline] create -- @param self -- @return Timeline#Timeline ret (return value: ccs.Timeline) -------------------------------- +-- -- @function [parent=#Timeline] Timeline -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/Timer.lua b/cocos/scripting/lua-bindings/auto/api/Timer.lua index 2e44e70281..eed23459cd 100644 --- a/cocos/scripting/lua-bindings/auto/api/Timer.lua +++ b/cocos/scripting/lua-bindings/auto/api/Timer.lua @@ -5,32 +5,38 @@ -- @parent_module cc -------------------------------- +-- get interval in seconds -- @function [parent=#Timer] getInterval -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#Timer] setupTimerWithInterval -- @param self --- @param #float float --- @param #unsigned int int --- @param #float float +-- @param #float seconds +-- @param #unsigned int repeat +-- @param #float delay -------------------------------- +-- set interval in seconds -- @function [parent=#Timer] setInterval -- @param self --- @param #float float +-- @param #float interval -------------------------------- +-- triggers the timer -- @function [parent=#Timer] update -- @param self --- @param #float float +-- @param #float dt -------------------------------- +-- -- @function [parent=#Timer] trigger -- @param self -------------------------------- +-- -- @function [parent=#Timer] cancel -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/TintBy.lua b/cocos/scripting/lua-bindings/auto/api/TintBy.lua index 4eba544dc5..f86cbde3c1 100644 --- a/cocos/scripting/lua-bindings/auto/api/TintBy.lua +++ b/cocos/scripting/lua-bindings/auto/api/TintBy.lua @@ -5,32 +5,37 @@ -- @parent_module cc -------------------------------- +-- creates an action with duration and color -- @function [parent=#TintBy] create -- @param self --- @param #float float --- @param #short short --- @param #short short --- @param #short short +-- @param #float duration +-- @param #short deltaRed +-- @param #short deltaGreen +-- @param #short deltaBlue -- @return TintBy#TintBy ret (return value: cc.TintBy) -------------------------------- +-- -- @function [parent=#TintBy] startWithTarget -- @param self --- @param #cc.Node node +-- @param #cc.Node target -------------------------------- +-- -- @function [parent=#TintBy] clone -- @param self -- @return TintBy#TintBy ret (return value: cc.TintBy) -------------------------------- +-- -- @function [parent=#TintBy] reverse -- @param self -- @return TintBy#TintBy ret (return value: cc.TintBy) -------------------------------- +-- -- @function [parent=#TintBy] update -- @param self --- @param #float float +-- @param #float time return nil diff --git a/cocos/scripting/lua-bindings/auto/api/TintTo.lua b/cocos/scripting/lua-bindings/auto/api/TintTo.lua index 25a5fe6a09..ec78c9aaa2 100644 --- a/cocos/scripting/lua-bindings/auto/api/TintTo.lua +++ b/cocos/scripting/lua-bindings/auto/api/TintTo.lua @@ -5,32 +5,37 @@ -- @parent_module cc -------------------------------- +-- creates an action with duration and color -- @function [parent=#TintTo] create -- @param self --- @param #float float --- @param #unsigned char char --- @param #unsigned char char --- @param #unsigned char char +-- @param #float duration +-- @param #unsigned char red +-- @param #unsigned char green +-- @param #unsigned char blue -- @return TintTo#TintTo ret (return value: cc.TintTo) -------------------------------- +-- -- @function [parent=#TintTo] startWithTarget -- @param self --- @param #cc.Node node +-- @param #cc.Node target -------------------------------- +-- -- @function [parent=#TintTo] clone -- @param self -- @return TintTo#TintTo ret (return value: cc.TintTo) -------------------------------- +-- -- @function [parent=#TintTo] reverse -- @param self -- @return TintTo#TintTo ret (return value: cc.TintTo) -------------------------------- +-- -- @function [parent=#TintTo] update -- @param self --- @param #float float +-- @param #float time return nil diff --git a/cocos/scripting/lua-bindings/auto/api/ToggleVisibility.lua b/cocos/scripting/lua-bindings/auto/api/ToggleVisibility.lua index 21307c0a00..8898cdff27 100644 --- a/cocos/scripting/lua-bindings/auto/api/ToggleVisibility.lua +++ b/cocos/scripting/lua-bindings/auto/api/ToggleVisibility.lua @@ -5,21 +5,25 @@ -- @parent_module cc -------------------------------- +-- Allocates and initializes the action -- @function [parent=#ToggleVisibility] create -- @param self -- @return ToggleVisibility#ToggleVisibility ret (return value: cc.ToggleVisibility) -------------------------------- +-- -- @function [parent=#ToggleVisibility] clone -- @param self -- @return ToggleVisibility#ToggleVisibility ret (return value: cc.ToggleVisibility) -------------------------------- +-- -- @function [parent=#ToggleVisibility] update -- @param self --- @param #float float +-- @param #float time -------------------------------- +-- -- @function [parent=#ToggleVisibility] reverse -- @param self -- @return ToggleVisibility#ToggleVisibility ret (return value: cc.ToggleVisibility) diff --git a/cocos/scripting/lua-bindings/auto/api/Touch.lua b/cocos/scripting/lua-bindings/auto/api/Touch.lua index d56df32267..0f2b51afcd 100644 --- a/cocos/scripting/lua-bindings/auto/api/Touch.lua +++ b/cocos/scripting/lua-bindings/auto/api/Touch.lua @@ -5,53 +5,64 @@ -- @parent_module cc -------------------------------- +-- returns the previous touch location in screen coordinates -- @function [parent=#Touch] getPreviousLocationInView -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- returns the current touch location in OpenGL coordinates -- @function [parent=#Touch] getLocation -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- returns the delta of 2 current touches locations in screen coordinates -- @function [parent=#Touch] getDelta -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- returns the start touch location in screen coordinates -- @function [parent=#Touch] getStartLocationInView -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- returns the start touch location in OpenGL coordinates -- @function [parent=#Touch] getStartLocation -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- js getId
+-- lua getId -- @function [parent=#Touch] getID -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- -- @function [parent=#Touch] setTouchInfo -- @param self --- @param #int int --- @param #float float --- @param #float float +-- @param #int id +-- @param #float x +-- @param #float y -------------------------------- +-- returns the current touch location in screen coordinates -- @function [parent=#Touch] getLocationInView -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- returns the previous touch location in OpenGL coordinates -- @function [parent=#Touch] getPreviousLocation -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- -- @function [parent=#Touch] Touch -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/TransitionCrossFade.lua b/cocos/scripting/lua-bindings/auto/api/TransitionCrossFade.lua index e39e8adec7..5d03d65da6 100644 --- a/cocos/scripting/lua-bindings/auto/api/TransitionCrossFade.lua +++ b/cocos/scripting/lua-bindings/auto/api/TransitionCrossFade.lua @@ -5,17 +5,20 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#TransitionCrossFade] create -- @param self --- @param #float float +-- @param #float t -- @param #cc.Scene scene -- @return TransitionCrossFade#TransitionCrossFade ret (return value: cc.TransitionCrossFade) -------------------------------- +-- js NA
+-- lua NA -- @function [parent=#TransitionCrossFade] draw -- @param self -- @param #cc.Renderer renderer --- @param #mat4_table mat4 --- @param #unsigned int int +-- @param #mat4_table transform +-- @param #unsigned int flags return nil diff --git a/cocos/scripting/lua-bindings/auto/api/TransitionEaseScene.lua b/cocos/scripting/lua-bindings/auto/api/TransitionEaseScene.lua index 4afd77786d..2fe8fe717c 100644 --- a/cocos/scripting/lua-bindings/auto/api/TransitionEaseScene.lua +++ b/cocos/scripting/lua-bindings/auto/api/TransitionEaseScene.lua @@ -4,9 +4,11 @@ -- @parent_module cc -------------------------------- +-- returns the Ease action that will be performed on a linear action.
+-- since v0.8.2 -- @function [parent=#TransitionEaseScene] easeActionWithAction -- @param self --- @param #cc.ActionInterval actioninterval +-- @param #cc.ActionInterval action -- @return ActionInterval#ActionInterval ret (return value: cc.ActionInterval) return nil diff --git a/cocos/scripting/lua-bindings/auto/api/TransitionFade.lua b/cocos/scripting/lua-bindings/auto/api/TransitionFade.lua index 73bd19113b..7e98445787 100644 --- a/cocos/scripting/lua-bindings/auto/api/TransitionFade.lua +++ b/cocos/scripting/lua-bindings/auto/api/TransitionFade.lua @@ -9,9 +9,9 @@ -- @overload self, float, cc.Scene, color3b_table -- @function [parent=#TransitionFade] create -- @param self --- @param #float float +-- @param #float duration -- @param #cc.Scene scene --- @param #color3b_table color3b +-- @param #color3b_table color -- @return TransitionFade#TransitionFade ret (retunr value: cc.TransitionFade) return nil diff --git a/cocos/scripting/lua-bindings/auto/api/TransitionFadeBL.lua b/cocos/scripting/lua-bindings/auto/api/TransitionFadeBL.lua index de2a9b5079..6412b19e34 100644 --- a/cocos/scripting/lua-bindings/auto/api/TransitionFadeBL.lua +++ b/cocos/scripting/lua-bindings/auto/api/TransitionFadeBL.lua @@ -5,13 +5,15 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#TransitionFadeBL] create -- @param self --- @param #float float +-- @param #float t -- @param #cc.Scene scene -- @return TransitionFadeBL#TransitionFadeBL ret (return value: cc.TransitionFadeBL) -------------------------------- +-- -- @function [parent=#TransitionFadeBL] actionWithSize -- @param self -- @param #size_table size diff --git a/cocos/scripting/lua-bindings/auto/api/TransitionFadeDown.lua b/cocos/scripting/lua-bindings/auto/api/TransitionFadeDown.lua index dbcb62a2e9..435efe63a8 100644 --- a/cocos/scripting/lua-bindings/auto/api/TransitionFadeDown.lua +++ b/cocos/scripting/lua-bindings/auto/api/TransitionFadeDown.lua @@ -5,13 +5,15 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#TransitionFadeDown] create -- @param self --- @param #float float +-- @param #float t -- @param #cc.Scene scene -- @return TransitionFadeDown#TransitionFadeDown ret (return value: cc.TransitionFadeDown) -------------------------------- +-- -- @function [parent=#TransitionFadeDown] actionWithSize -- @param self -- @param #size_table size diff --git a/cocos/scripting/lua-bindings/auto/api/TransitionFadeTR.lua b/cocos/scripting/lua-bindings/auto/api/TransitionFadeTR.lua index 3e7160fd6b..cb1e539ea4 100644 --- a/cocos/scripting/lua-bindings/auto/api/TransitionFadeTR.lua +++ b/cocos/scripting/lua-bindings/auto/api/TransitionFadeTR.lua @@ -5,29 +5,33 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#TransitionFadeTR] easeActionWithAction -- @param self --- @param #cc.ActionInterval actioninterval +-- @param #cc.ActionInterval action -- @return ActionInterval#ActionInterval ret (return value: cc.ActionInterval) -------------------------------- +-- -- @function [parent=#TransitionFadeTR] actionWithSize -- @param self -- @param #size_table size -- @return ActionInterval#ActionInterval ret (return value: cc.ActionInterval) -------------------------------- +-- -- @function [parent=#TransitionFadeTR] create -- @param self --- @param #float float +-- @param #float t -- @param #cc.Scene scene -- @return TransitionFadeTR#TransitionFadeTR ret (return value: cc.TransitionFadeTR) -------------------------------- +-- -- @function [parent=#TransitionFadeTR] draw -- @param self -- @param #cc.Renderer renderer --- @param #mat4_table mat4 --- @param #unsigned int int +-- @param #mat4_table transform +-- @param #unsigned int flags return nil diff --git a/cocos/scripting/lua-bindings/auto/api/TransitionFadeUp.lua b/cocos/scripting/lua-bindings/auto/api/TransitionFadeUp.lua index 9e3bc4ac28..19c7b91167 100644 --- a/cocos/scripting/lua-bindings/auto/api/TransitionFadeUp.lua +++ b/cocos/scripting/lua-bindings/auto/api/TransitionFadeUp.lua @@ -5,13 +5,15 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#TransitionFadeUp] create -- @param self --- @param #float float +-- @param #float t -- @param #cc.Scene scene -- @return TransitionFadeUp#TransitionFadeUp ret (return value: cc.TransitionFadeUp) -------------------------------- +-- -- @function [parent=#TransitionFadeUp] actionWithSize -- @param self -- @param #size_table size diff --git a/cocos/scripting/lua-bindings/auto/api/TransitionFlipAngular.lua b/cocos/scripting/lua-bindings/auto/api/TransitionFlipAngular.lua index e8be2f3f92..9765783694 100644 --- a/cocos/scripting/lua-bindings/auto/api/TransitionFlipAngular.lua +++ b/cocos/scripting/lua-bindings/auto/api/TransitionFlipAngular.lua @@ -9,9 +9,9 @@ -- @overload self, float, cc.Scene, int -- @function [parent=#TransitionFlipAngular] create -- @param self --- @param #float float --- @param #cc.Scene scene --- @param #int orientation +-- @param #float t +-- @param #cc.Scene s +-- @param #int o -- @return TransitionFlipAngular#TransitionFlipAngular ret (retunr value: cc.TransitionFlipAngular) return nil diff --git a/cocos/scripting/lua-bindings/auto/api/TransitionFlipX.lua b/cocos/scripting/lua-bindings/auto/api/TransitionFlipX.lua index bd3d3d3660..b27aa235b0 100644 --- a/cocos/scripting/lua-bindings/auto/api/TransitionFlipX.lua +++ b/cocos/scripting/lua-bindings/auto/api/TransitionFlipX.lua @@ -9,9 +9,9 @@ -- @overload self, float, cc.Scene, int -- @function [parent=#TransitionFlipX] create -- @param self --- @param #float float --- @param #cc.Scene scene --- @param #int orientation +-- @param #float t +-- @param #cc.Scene s +-- @param #int o -- @return TransitionFlipX#TransitionFlipX ret (retunr value: cc.TransitionFlipX) return nil diff --git a/cocos/scripting/lua-bindings/auto/api/TransitionFlipY.lua b/cocos/scripting/lua-bindings/auto/api/TransitionFlipY.lua index eebe6b56bc..5973c5b1f1 100644 --- a/cocos/scripting/lua-bindings/auto/api/TransitionFlipY.lua +++ b/cocos/scripting/lua-bindings/auto/api/TransitionFlipY.lua @@ -9,9 +9,9 @@ -- @overload self, float, cc.Scene, int -- @function [parent=#TransitionFlipY] create -- @param self --- @param #float float --- @param #cc.Scene scene --- @param #int orientation +-- @param #float t +-- @param #cc.Scene s +-- @param #int o -- @return TransitionFlipY#TransitionFlipY ret (retunr value: cc.TransitionFlipY) return nil diff --git a/cocos/scripting/lua-bindings/auto/api/TransitionJumpZoom.lua b/cocos/scripting/lua-bindings/auto/api/TransitionJumpZoom.lua index 915c89cfa0..3bb200c538 100644 --- a/cocos/scripting/lua-bindings/auto/api/TransitionJumpZoom.lua +++ b/cocos/scripting/lua-bindings/auto/api/TransitionJumpZoom.lua @@ -5,9 +5,10 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#TransitionJumpZoom] create -- @param self --- @param #float float +-- @param #float t -- @param #cc.Scene scene -- @return TransitionJumpZoom#TransitionJumpZoom ret (return value: cc.TransitionJumpZoom) diff --git a/cocos/scripting/lua-bindings/auto/api/TransitionMoveInB.lua b/cocos/scripting/lua-bindings/auto/api/TransitionMoveInB.lua index 799212f087..7da02d0375 100644 --- a/cocos/scripting/lua-bindings/auto/api/TransitionMoveInB.lua +++ b/cocos/scripting/lua-bindings/auto/api/TransitionMoveInB.lua @@ -5,9 +5,10 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#TransitionMoveInB] create -- @param self --- @param #float float +-- @param #float t -- @param #cc.Scene scene -- @return TransitionMoveInB#TransitionMoveInB ret (return value: cc.TransitionMoveInB) diff --git a/cocos/scripting/lua-bindings/auto/api/TransitionMoveInL.lua b/cocos/scripting/lua-bindings/auto/api/TransitionMoveInL.lua index dced884285..834ccdf1f2 100644 --- a/cocos/scripting/lua-bindings/auto/api/TransitionMoveInL.lua +++ b/cocos/scripting/lua-bindings/auto/api/TransitionMoveInL.lua @@ -5,20 +5,23 @@ -- @parent_module cc -------------------------------- +-- returns the action that will be performed -- @function [parent=#TransitionMoveInL] action -- @param self -- @return ActionInterval#ActionInterval ret (return value: cc.ActionInterval) -------------------------------- +-- -- @function [parent=#TransitionMoveInL] easeActionWithAction -- @param self --- @param #cc.ActionInterval actioninterval +-- @param #cc.ActionInterval action -- @return ActionInterval#ActionInterval ret (return value: cc.ActionInterval) -------------------------------- +-- -- @function [parent=#TransitionMoveInL] create -- @param self --- @param #float float +-- @param #float t -- @param #cc.Scene scene -- @return TransitionMoveInL#TransitionMoveInL ret (return value: cc.TransitionMoveInL) diff --git a/cocos/scripting/lua-bindings/auto/api/TransitionMoveInR.lua b/cocos/scripting/lua-bindings/auto/api/TransitionMoveInR.lua index 2b67b9a3e4..adc3bd97a4 100644 --- a/cocos/scripting/lua-bindings/auto/api/TransitionMoveInR.lua +++ b/cocos/scripting/lua-bindings/auto/api/TransitionMoveInR.lua @@ -5,9 +5,10 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#TransitionMoveInR] create -- @param self --- @param #float float +-- @param #float t -- @param #cc.Scene scene -- @return TransitionMoveInR#TransitionMoveInR ret (return value: cc.TransitionMoveInR) diff --git a/cocos/scripting/lua-bindings/auto/api/TransitionMoveInT.lua b/cocos/scripting/lua-bindings/auto/api/TransitionMoveInT.lua index 40030fdda8..b71c1de3bb 100644 --- a/cocos/scripting/lua-bindings/auto/api/TransitionMoveInT.lua +++ b/cocos/scripting/lua-bindings/auto/api/TransitionMoveInT.lua @@ -5,9 +5,10 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#TransitionMoveInT] create -- @param self --- @param #float float +-- @param #float t -- @param #cc.Scene scene -- @return TransitionMoveInT#TransitionMoveInT ret (return value: cc.TransitionMoveInT) diff --git a/cocos/scripting/lua-bindings/auto/api/TransitionPageTurn.lua b/cocos/scripting/lua-bindings/auto/api/TransitionPageTurn.lua index 1c655d6fab..65982e0145 100644 --- a/cocos/scripting/lua-bindings/auto/api/TransitionPageTurn.lua +++ b/cocos/scripting/lua-bindings/auto/api/TransitionPageTurn.lua @@ -5,32 +5,40 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#TransitionPageTurn] actionWithSize -- @param self --- @param #size_table size +-- @param #size_table vector -- @return ActionInterval#ActionInterval ret (return value: cc.ActionInterval) -------------------------------- +-- Creates a base transition with duration and incoming scene.
+-- If back is true then the effect is reversed to appear as if the incoming
+-- scene is being turned from left over the outgoing scene. -- @function [parent=#TransitionPageTurn] initWithDuration -- @param self --- @param #float float +-- @param #float t -- @param #cc.Scene scene --- @param #bool bool +-- @param #bool backwards -- @return bool#bool ret (return value: bool) -------------------------------- +-- Creates a base transition with duration and incoming scene.
+-- If back is true then the effect is reversed to appear as if the incoming
+-- scene is being turned from left over the outgoing scene. -- @function [parent=#TransitionPageTurn] create -- @param self --- @param #float float +-- @param #float t -- @param #cc.Scene scene --- @param #bool bool +-- @param #bool backwards -- @return TransitionPageTurn#TransitionPageTurn ret (return value: cc.TransitionPageTurn) -------------------------------- +-- -- @function [parent=#TransitionPageTurn] draw -- @param self -- @param #cc.Renderer renderer --- @param #mat4_table mat4 --- @param #unsigned int int +-- @param #mat4_table transform +-- @param #unsigned int flags return nil diff --git a/cocos/scripting/lua-bindings/auto/api/TransitionProgress.lua b/cocos/scripting/lua-bindings/auto/api/TransitionProgress.lua index d05379f82b..6b4ee9c9b3 100644 --- a/cocos/scripting/lua-bindings/auto/api/TransitionProgress.lua +++ b/cocos/scripting/lua-bindings/auto/api/TransitionProgress.lua @@ -5,9 +5,10 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#TransitionProgress] create -- @param self --- @param #float float +-- @param #float t -- @param #cc.Scene scene -- @return TransitionProgress#TransitionProgress ret (return value: cc.TransitionProgress) diff --git a/cocos/scripting/lua-bindings/auto/api/TransitionProgressHorizontal.lua b/cocos/scripting/lua-bindings/auto/api/TransitionProgressHorizontal.lua index 917c7be032..2de10c764d 100644 --- a/cocos/scripting/lua-bindings/auto/api/TransitionProgressHorizontal.lua +++ b/cocos/scripting/lua-bindings/auto/api/TransitionProgressHorizontal.lua @@ -5,9 +5,10 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#TransitionProgressHorizontal] create -- @param self --- @param #float float +-- @param #float t -- @param #cc.Scene scene -- @return TransitionProgressHorizontal#TransitionProgressHorizontal ret (return value: cc.TransitionProgressHorizontal) diff --git a/cocos/scripting/lua-bindings/auto/api/TransitionProgressInOut.lua b/cocos/scripting/lua-bindings/auto/api/TransitionProgressInOut.lua index d60be89302..24a1e3ee1c 100644 --- a/cocos/scripting/lua-bindings/auto/api/TransitionProgressInOut.lua +++ b/cocos/scripting/lua-bindings/auto/api/TransitionProgressInOut.lua @@ -5,9 +5,10 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#TransitionProgressInOut] create -- @param self --- @param #float float +-- @param #float t -- @param #cc.Scene scene -- @return TransitionProgressInOut#TransitionProgressInOut ret (return value: cc.TransitionProgressInOut) diff --git a/cocos/scripting/lua-bindings/auto/api/TransitionProgressOutIn.lua b/cocos/scripting/lua-bindings/auto/api/TransitionProgressOutIn.lua index c5f4e9fe18..5df3e5b9f1 100644 --- a/cocos/scripting/lua-bindings/auto/api/TransitionProgressOutIn.lua +++ b/cocos/scripting/lua-bindings/auto/api/TransitionProgressOutIn.lua @@ -5,9 +5,10 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#TransitionProgressOutIn] create -- @param self --- @param #float float +-- @param #float t -- @param #cc.Scene scene -- @return TransitionProgressOutIn#TransitionProgressOutIn ret (return value: cc.TransitionProgressOutIn) diff --git a/cocos/scripting/lua-bindings/auto/api/TransitionProgressRadialCCW.lua b/cocos/scripting/lua-bindings/auto/api/TransitionProgressRadialCCW.lua index cf95079265..9886d6ebfe 100644 --- a/cocos/scripting/lua-bindings/auto/api/TransitionProgressRadialCCW.lua +++ b/cocos/scripting/lua-bindings/auto/api/TransitionProgressRadialCCW.lua @@ -5,9 +5,10 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#TransitionProgressRadialCCW] create -- @param self --- @param #float float +-- @param #float t -- @param #cc.Scene scene -- @return TransitionProgressRadialCCW#TransitionProgressRadialCCW ret (return value: cc.TransitionProgressRadialCCW) diff --git a/cocos/scripting/lua-bindings/auto/api/TransitionProgressRadialCW.lua b/cocos/scripting/lua-bindings/auto/api/TransitionProgressRadialCW.lua index 83c2370933..795e2047ab 100644 --- a/cocos/scripting/lua-bindings/auto/api/TransitionProgressRadialCW.lua +++ b/cocos/scripting/lua-bindings/auto/api/TransitionProgressRadialCW.lua @@ -5,9 +5,10 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#TransitionProgressRadialCW] create -- @param self --- @param #float float +-- @param #float t -- @param #cc.Scene scene -- @return TransitionProgressRadialCW#TransitionProgressRadialCW ret (return value: cc.TransitionProgressRadialCW) diff --git a/cocos/scripting/lua-bindings/auto/api/TransitionProgressVertical.lua b/cocos/scripting/lua-bindings/auto/api/TransitionProgressVertical.lua index 7874cd3a6f..b2d75100bf 100644 --- a/cocos/scripting/lua-bindings/auto/api/TransitionProgressVertical.lua +++ b/cocos/scripting/lua-bindings/auto/api/TransitionProgressVertical.lua @@ -5,9 +5,10 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#TransitionProgressVertical] create -- @param self --- @param #float float +-- @param #float t -- @param #cc.Scene scene -- @return TransitionProgressVertical#TransitionProgressVertical ret (return value: cc.TransitionProgressVertical) diff --git a/cocos/scripting/lua-bindings/auto/api/TransitionRotoZoom.lua b/cocos/scripting/lua-bindings/auto/api/TransitionRotoZoom.lua index b6d5f70e6f..388ff0b06f 100644 --- a/cocos/scripting/lua-bindings/auto/api/TransitionRotoZoom.lua +++ b/cocos/scripting/lua-bindings/auto/api/TransitionRotoZoom.lua @@ -5,9 +5,10 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#TransitionRotoZoom] create -- @param self --- @param #float float +-- @param #float t -- @param #cc.Scene scene -- @return TransitionRotoZoom#TransitionRotoZoom ret (return value: cc.TransitionRotoZoom) diff --git a/cocos/scripting/lua-bindings/auto/api/TransitionScene.lua b/cocos/scripting/lua-bindings/auto/api/TransitionScene.lua index 1a03e181d9..4b5f3be37a 100644 --- a/cocos/scripting/lua-bindings/auto/api/TransitionScene.lua +++ b/cocos/scripting/lua-bindings/auto/api/TransitionScene.lua @@ -5,28 +5,33 @@ -- @parent_module cc -------------------------------- +-- called after the transition finishes -- @function [parent=#TransitionScene] finish -- @param self -------------------------------- +-- used by some transitions to hide the outer scene -- @function [parent=#TransitionScene] hideOutShowIn -- @param self -------------------------------- +-- creates a base transition with duration and incoming scene -- @function [parent=#TransitionScene] create -- @param self --- @param #float float +-- @param #float t -- @param #cc.Scene scene -- @return TransitionScene#TransitionScene ret (return value: cc.TransitionScene) -------------------------------- +-- -- @function [parent=#TransitionScene] draw -- @param self -- @param #cc.Renderer renderer --- @param #mat4_table mat4 --- @param #unsigned int int +-- @param #mat4_table transform +-- @param #unsigned int flags -------------------------------- +-- -- @function [parent=#TransitionScene] cleanup -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/TransitionSceneOriented.lua b/cocos/scripting/lua-bindings/auto/api/TransitionSceneOriented.lua index 965126e682..d34be6be7e 100644 --- a/cocos/scripting/lua-bindings/auto/api/TransitionSceneOriented.lua +++ b/cocos/scripting/lua-bindings/auto/api/TransitionSceneOriented.lua @@ -5,9 +5,10 @@ -- @parent_module cc -------------------------------- +-- creates a base transition with duration and incoming scene -- @function [parent=#TransitionSceneOriented] create -- @param self --- @param #float float +-- @param #float t -- @param #cc.Scene scene -- @param #int orientation -- @return TransitionSceneOriented#TransitionSceneOriented ret (return value: cc.TransitionSceneOriented) diff --git a/cocos/scripting/lua-bindings/auto/api/TransitionShrinkGrow.lua b/cocos/scripting/lua-bindings/auto/api/TransitionShrinkGrow.lua index 28493ed5f2..2a9835a35e 100644 --- a/cocos/scripting/lua-bindings/auto/api/TransitionShrinkGrow.lua +++ b/cocos/scripting/lua-bindings/auto/api/TransitionShrinkGrow.lua @@ -5,15 +5,17 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#TransitionShrinkGrow] easeActionWithAction -- @param self --- @param #cc.ActionInterval actioninterval +-- @param #cc.ActionInterval action -- @return ActionInterval#ActionInterval ret (return value: cc.ActionInterval) -------------------------------- +-- -- @function [parent=#TransitionShrinkGrow] create -- @param self --- @param #float float +-- @param #float t -- @param #cc.Scene scene -- @return TransitionShrinkGrow#TransitionShrinkGrow ret (return value: cc.TransitionShrinkGrow) diff --git a/cocos/scripting/lua-bindings/auto/api/TransitionSlideInB.lua b/cocos/scripting/lua-bindings/auto/api/TransitionSlideInB.lua index 511ac8c25b..0cc097f834 100644 --- a/cocos/scripting/lua-bindings/auto/api/TransitionSlideInB.lua +++ b/cocos/scripting/lua-bindings/auto/api/TransitionSlideInB.lua @@ -5,14 +5,16 @@ -- @parent_module cc -------------------------------- +-- returns the action that will be performed by the incoming and outgoing scene -- @function [parent=#TransitionSlideInB] action -- @param self -- @return ActionInterval#ActionInterval ret (return value: cc.ActionInterval) -------------------------------- +-- -- @function [parent=#TransitionSlideInB] create -- @param self --- @param #float float +-- @param #float t -- @param #cc.Scene scene -- @return TransitionSlideInB#TransitionSlideInB ret (return value: cc.TransitionSlideInB) diff --git a/cocos/scripting/lua-bindings/auto/api/TransitionSlideInL.lua b/cocos/scripting/lua-bindings/auto/api/TransitionSlideInL.lua index dce81f4ece..ab682254c8 100644 --- a/cocos/scripting/lua-bindings/auto/api/TransitionSlideInL.lua +++ b/cocos/scripting/lua-bindings/auto/api/TransitionSlideInL.lua @@ -5,20 +5,23 @@ -- @parent_module cc -------------------------------- +-- returns the action that will be performed by the incoming and outgoing scene -- @function [parent=#TransitionSlideInL] action -- @param self -- @return ActionInterval#ActionInterval ret (return value: cc.ActionInterval) -------------------------------- +-- -- @function [parent=#TransitionSlideInL] easeActionWithAction -- @param self --- @param #cc.ActionInterval actioninterval +-- @param #cc.ActionInterval action -- @return ActionInterval#ActionInterval ret (return value: cc.ActionInterval) -------------------------------- +-- -- @function [parent=#TransitionSlideInL] create -- @param self --- @param #float float +-- @param #float t -- @param #cc.Scene scene -- @return TransitionSlideInL#TransitionSlideInL ret (return value: cc.TransitionSlideInL) diff --git a/cocos/scripting/lua-bindings/auto/api/TransitionSlideInR.lua b/cocos/scripting/lua-bindings/auto/api/TransitionSlideInR.lua index 10c78150b1..3de6ed9172 100644 --- a/cocos/scripting/lua-bindings/auto/api/TransitionSlideInR.lua +++ b/cocos/scripting/lua-bindings/auto/api/TransitionSlideInR.lua @@ -5,14 +5,16 @@ -- @parent_module cc -------------------------------- +-- returns the action that will be performed by the incoming and outgoing scene -- @function [parent=#TransitionSlideInR] action -- @param self -- @return ActionInterval#ActionInterval ret (return value: cc.ActionInterval) -------------------------------- +-- -- @function [parent=#TransitionSlideInR] create -- @param self --- @param #float float +-- @param #float t -- @param #cc.Scene scene -- @return TransitionSlideInR#TransitionSlideInR ret (return value: cc.TransitionSlideInR) diff --git a/cocos/scripting/lua-bindings/auto/api/TransitionSlideInT.lua b/cocos/scripting/lua-bindings/auto/api/TransitionSlideInT.lua index 57dfa51ce4..c04116778f 100644 --- a/cocos/scripting/lua-bindings/auto/api/TransitionSlideInT.lua +++ b/cocos/scripting/lua-bindings/auto/api/TransitionSlideInT.lua @@ -5,14 +5,16 @@ -- @parent_module cc -------------------------------- +-- returns the action that will be performed by the incoming and outgoing scene -- @function [parent=#TransitionSlideInT] action -- @param self -- @return ActionInterval#ActionInterval ret (return value: cc.ActionInterval) -------------------------------- +-- -- @function [parent=#TransitionSlideInT] create -- @param self --- @param #float float +-- @param #float t -- @param #cc.Scene scene -- @return TransitionSlideInT#TransitionSlideInT ret (return value: cc.TransitionSlideInT) diff --git a/cocos/scripting/lua-bindings/auto/api/TransitionSplitCols.lua b/cocos/scripting/lua-bindings/auto/api/TransitionSplitCols.lua index a421599f70..6242195882 100644 --- a/cocos/scripting/lua-bindings/auto/api/TransitionSplitCols.lua +++ b/cocos/scripting/lua-bindings/auto/api/TransitionSplitCols.lua @@ -5,28 +5,32 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#TransitionSplitCols] action -- @param self -- @return ActionInterval#ActionInterval ret (return value: cc.ActionInterval) -------------------------------- +-- -- @function [parent=#TransitionSplitCols] easeActionWithAction -- @param self --- @param #cc.ActionInterval actioninterval +-- @param #cc.ActionInterval action -- @return ActionInterval#ActionInterval ret (return value: cc.ActionInterval) -------------------------------- +-- -- @function [parent=#TransitionSplitCols] create -- @param self --- @param #float float +-- @param #float t -- @param #cc.Scene scene -- @return TransitionSplitCols#TransitionSplitCols ret (return value: cc.TransitionSplitCols) -------------------------------- +-- -- @function [parent=#TransitionSplitCols] draw -- @param self -- @param #cc.Renderer renderer --- @param #mat4_table mat4 --- @param #unsigned int int +-- @param #mat4_table transform +-- @param #unsigned int flags return nil diff --git a/cocos/scripting/lua-bindings/auto/api/TransitionSplitRows.lua b/cocos/scripting/lua-bindings/auto/api/TransitionSplitRows.lua index fdcbaf1feb..0c9ccd61b1 100644 --- a/cocos/scripting/lua-bindings/auto/api/TransitionSplitRows.lua +++ b/cocos/scripting/lua-bindings/auto/api/TransitionSplitRows.lua @@ -5,13 +5,15 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#TransitionSplitRows] create -- @param self --- @param #float float +-- @param #float t -- @param #cc.Scene scene -- @return TransitionSplitRows#TransitionSplitRows ret (return value: cc.TransitionSplitRows) -------------------------------- +-- -- @function [parent=#TransitionSplitRows] action -- @param self -- @return ActionInterval#ActionInterval ret (return value: cc.ActionInterval) diff --git a/cocos/scripting/lua-bindings/auto/api/TransitionTurnOffTiles.lua b/cocos/scripting/lua-bindings/auto/api/TransitionTurnOffTiles.lua index e9a4d6fc81..a3523d3c10 100644 --- a/cocos/scripting/lua-bindings/auto/api/TransitionTurnOffTiles.lua +++ b/cocos/scripting/lua-bindings/auto/api/TransitionTurnOffTiles.lua @@ -5,23 +5,26 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#TransitionTurnOffTiles] easeActionWithAction -- @param self --- @param #cc.ActionInterval actioninterval +-- @param #cc.ActionInterval action -- @return ActionInterval#ActionInterval ret (return value: cc.ActionInterval) -------------------------------- +-- -- @function [parent=#TransitionTurnOffTiles] create -- @param self --- @param #float float +-- @param #float t -- @param #cc.Scene scene -- @return TransitionTurnOffTiles#TransitionTurnOffTiles ret (return value: cc.TransitionTurnOffTiles) -------------------------------- +-- -- @function [parent=#TransitionTurnOffTiles] draw -- @param self -- @param #cc.Renderer renderer --- @param #mat4_table mat4 --- @param #unsigned int int +-- @param #mat4_table transform +-- @param #unsigned int flags return nil diff --git a/cocos/scripting/lua-bindings/auto/api/TransitionZoomFlipAngular.lua b/cocos/scripting/lua-bindings/auto/api/TransitionZoomFlipAngular.lua index 10360d5cf8..d726097c07 100644 --- a/cocos/scripting/lua-bindings/auto/api/TransitionZoomFlipAngular.lua +++ b/cocos/scripting/lua-bindings/auto/api/TransitionZoomFlipAngular.lua @@ -9,9 +9,9 @@ -- @overload self, float, cc.Scene, int -- @function [parent=#TransitionZoomFlipAngular] create -- @param self --- @param #float float --- @param #cc.Scene scene --- @param #int orientation +-- @param #float t +-- @param #cc.Scene s +-- @param #int o -- @return TransitionZoomFlipAngular#TransitionZoomFlipAngular ret (retunr value: cc.TransitionZoomFlipAngular) return nil diff --git a/cocos/scripting/lua-bindings/auto/api/TransitionZoomFlipX.lua b/cocos/scripting/lua-bindings/auto/api/TransitionZoomFlipX.lua index fa6ed5fd29..0da39fdee8 100644 --- a/cocos/scripting/lua-bindings/auto/api/TransitionZoomFlipX.lua +++ b/cocos/scripting/lua-bindings/auto/api/TransitionZoomFlipX.lua @@ -9,9 +9,9 @@ -- @overload self, float, cc.Scene, int -- @function [parent=#TransitionZoomFlipX] create -- @param self --- @param #float float --- @param #cc.Scene scene --- @param #int orientation +-- @param #float t +-- @param #cc.Scene s +-- @param #int o -- @return TransitionZoomFlipX#TransitionZoomFlipX ret (retunr value: cc.TransitionZoomFlipX) return nil diff --git a/cocos/scripting/lua-bindings/auto/api/TransitionZoomFlipY.lua b/cocos/scripting/lua-bindings/auto/api/TransitionZoomFlipY.lua index d137a545e9..397e989ffd 100644 --- a/cocos/scripting/lua-bindings/auto/api/TransitionZoomFlipY.lua +++ b/cocos/scripting/lua-bindings/auto/api/TransitionZoomFlipY.lua @@ -9,9 +9,9 @@ -- @overload self, float, cc.Scene, int -- @function [parent=#TransitionZoomFlipY] create -- @param self --- @param #float float --- @param #cc.Scene scene --- @param #int orientation +-- @param #float t +-- @param #cc.Scene s +-- @param #int o -- @return TransitionZoomFlipY#TransitionZoomFlipY ret (retunr value: cc.TransitionZoomFlipY) return nil diff --git a/cocos/scripting/lua-bindings/auto/api/TurnOffTiles.lua b/cocos/scripting/lua-bindings/auto/api/TurnOffTiles.lua index c7ffd3d8f4..7798a1f952 100644 --- a/cocos/scripting/lua-bindings/auto/api/TurnOffTiles.lua +++ b/cocos/scripting/lua-bindings/auto/api/TurnOffTiles.lua @@ -5,38 +5,43 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#TurnOffTiles] turnOnTile -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table pos -------------------------------- +-- -- @function [parent=#TurnOffTiles] turnOffTile -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table pos -------------------------------- -- @overload self, float, size_table, unsigned int -- @overload self, float, size_table -- @function [parent=#TurnOffTiles] create -- @param self --- @param #float float --- @param #size_table size --- @param #unsigned int int +-- @param #float duration +-- @param #size_table gridSize +-- @param #unsigned int seed -- @return TurnOffTiles#TurnOffTiles ret (retunr value: cc.TurnOffTiles) -------------------------------- +-- -- @function [parent=#TurnOffTiles] startWithTarget -- @param self --- @param #cc.Node node +-- @param #cc.Node target -------------------------------- +-- -- @function [parent=#TurnOffTiles] clone -- @param self -- @return TurnOffTiles#TurnOffTiles ret (return value: cc.TurnOffTiles) -------------------------------- +-- -- @function [parent=#TurnOffTiles] update -- @param self --- @param #float float +-- @param #float time return nil diff --git a/cocos/scripting/lua-bindings/auto/api/Tween.lua b/cocos/scripting/lua-bindings/auto/api/Tween.lua index e4791051a9..923aef489d 100644 --- a/cocos/scripting/lua-bindings/auto/api/Tween.lua +++ b/cocos/scripting/lua-bindings/auto/api/Tween.lua @@ -5,47 +5,70 @@ -- @parent_module ccs -------------------------------- +-- -- @function [parent=#Tween] getAnimation -- @param self -- @return ArmatureAnimation#ArmatureAnimation ret (return value: ccs.ArmatureAnimation) -------------------------------- +-- -- @function [parent=#Tween] gotoAndPause -- @param self --- @param #int int +-- @param #int frameIndex -------------------------------- +-- Start the Process
+-- param movementBoneData the MovementBoneData include all FrameData
+-- param durationTo the number of frames changing to this animation needs.
+-- param durationTween the number of frames this animation actual last.
+-- param loop whether the animation is loop
+-- loop < 0 : use the value from MovementData get from Action Editor
+-- loop = 0 : this animation is not loop
+-- loop > 0 : this animation is loop
+-- param tweenEasing tween easing is used for calculate easing effect
+-- TWEEN_EASING_MAX : use the value from MovementData get from Action Editor
+-- -1 : fade out
+-- 0 : line
+-- 1 : fade in
+-- 2 : fade in and out -- @function [parent=#Tween] play -- @param self --- @param #ccs.MovementBoneData movementbonedata --- @param #int int --- @param #int int --- @param #int int --- @param #int int +-- @param #ccs.MovementBoneData movementBoneData +-- @param #int durationTo +-- @param #int durationTween +-- @param #int loop +-- @param #int tweenEasing -------------------------------- +-- -- @function [parent=#Tween] gotoAndPlay -- @param self --- @param #int int +-- @param #int frameIndex -------------------------------- +-- Init with a Bone
+-- param bone the Bone Tween will bind to -- @function [parent=#Tween] init -- @param self -- @param #ccs.Bone bone -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#Tween] setAnimation -- @param self --- @param #ccs.ArmatureAnimation armatureanimation +-- @param #ccs.ArmatureAnimation animation -------------------------------- +-- Create with a Bone
+-- param bone the Bone Tween will bind to -- @function [parent=#Tween] create -- @param self -- @param #ccs.Bone bone -- @return Tween#Tween ret (return value: ccs.Tween) -------------------------------- +-- -- @function [parent=#Tween] Tween -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/Twirl.lua b/cocos/scripting/lua-bindings/auto/api/Twirl.lua index cfb9105cde..8b3574ae80 100644 --- a/cocos/scripting/lua-bindings/auto/api/Twirl.lua +++ b/cocos/scripting/lua-bindings/auto/api/Twirl.lua @@ -5,53 +5,62 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#Twirl] setAmplitudeRate -- @param self --- @param #float float +-- @param #float amplitudeRate -------------------------------- +-- -- @function [parent=#Twirl] getAmplitudeRate -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#Twirl] setAmplitude -- @param self --- @param #float float +-- @param #float amplitude -------------------------------- +-- -- @function [parent=#Twirl] getAmplitude -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- set twirl center -- @function [parent=#Twirl] setPosition -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table position -------------------------------- +-- get twirl center -- @function [parent=#Twirl] getPosition -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- creates the action with center position, number of twirls, amplitude, a grid size and duration -- @function [parent=#Twirl] create -- @param self --- @param #float float --- @param #size_table size --- @param #vec2_table vec2 --- @param #unsigned int int --- @param #float float +-- @param #float duration +-- @param #size_table gridSize +-- @param #vec2_table position +-- @param #unsigned int twirls +-- @param #float amplitude -- @return Twirl#Twirl ret (return value: cc.Twirl) -------------------------------- +-- -- @function [parent=#Twirl] clone -- @param self -- @return Twirl#Twirl ret (return value: cc.Twirl) -------------------------------- +-- -- @function [parent=#Twirl] update -- @param self --- @param #float float +-- @param #float time return nil diff --git a/cocos/scripting/lua-bindings/auto/api/UserDefault.lua b/cocos/scripting/lua-bindings/auto/api/UserDefault.lua index 173263c472..3b80444050 100644 --- a/cocos/scripting/lua-bindings/auto/api/UserDefault.lua +++ b/cocos/scripting/lua-bindings/auto/api/UserDefault.lua @@ -4,18 +4,20 @@ -- @parent_module cc -------------------------------- +-- brief Set integer value by key.
+-- js NA -- @function [parent=#UserDefault] setIntegerForKey -- @param self --- @param #char char --- @param #int int +-- @param #char pKey +-- @param #int value -------------------------------- -- @overload self, char, float -- @overload self, char -- @function [parent=#UserDefault] getFloatForKey -- @param self --- @param #char char --- @param #float float +-- @param #char pKey +-- @param #float defaultValue -- @return float#float ret (retunr value: float) -------------------------------- @@ -23,38 +25,46 @@ -- @overload self, char -- @function [parent=#UserDefault] getBoolForKey -- @param self --- @param #char char --- @param #bool bool +-- @param #char pKey +-- @param #bool defaultValue -- @return bool#bool ret (retunr value: bool) -------------------------------- +-- brief Set double value by key.
+-- js NA -- @function [parent=#UserDefault] setDoubleForKey -- @param self --- @param #char char --- @param #double double +-- @param #char pKey +-- @param #double value -------------------------------- +-- brief Set float value by key.
+-- js NA -- @function [parent=#UserDefault] setFloatForKey -- @param self --- @param #char char --- @param #float float +-- @param #char pKey +-- @param #float value -------------------------------- -- @overload self, char, string -- @overload self, char -- @function [parent=#UserDefault] getStringForKey -- @param self --- @param #char char --- @param #string str +-- @param #char pKey +-- @param #string defaultValue -- @return string#string ret (retunr value: string) -------------------------------- +-- brief Set string value by key.
+-- js NA -- @function [parent=#UserDefault] setStringForKey -- @param self --- @param #char char --- @param #string str +-- @param #char pKey +-- @param #string value -------------------------------- +-- brief Save content to xml file
+-- js NA -- @function [parent=#UserDefault] flush -- @param self @@ -63,8 +73,8 @@ -- @overload self, char -- @function [parent=#UserDefault] getIntegerForKey -- @param self --- @param #char char --- @param #int int +-- @param #char pKey +-- @param #int defaultValue -- @return int#int ret (retunr value: int) -------------------------------- @@ -72,26 +82,31 @@ -- @overload self, char -- @function [parent=#UserDefault] getDoubleForKey -- @param self --- @param #char char --- @param #double double +-- @param #char pKey +-- @param #double defaultValue -- @return double#double ret (retunr value: double) -------------------------------- +-- brief Set bool value by key.
+-- js NA -- @function [parent=#UserDefault] setBoolForKey -- @param self --- @param #char char --- @param #bool bool +-- @param #char pKey +-- @param #bool value -------------------------------- +-- js NA -- @function [parent=#UserDefault] destroyInstance -- @param self -------------------------------- +-- js NA -- @function [parent=#UserDefault] getXMLFilePath -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- js NA -- @function [parent=#UserDefault] isXMLFileExist -- @param self -- @return bool#bool ret (return value: bool) diff --git a/cocos/scripting/lua-bindings/auto/api/VBox.lua b/cocos/scripting/lua-bindings/auto/api/VBox.lua index 0955ae7c9e..4f94fe822e 100644 --- a/cocos/scripting/lua-bindings/auto/api/VBox.lua +++ b/cocos/scripting/lua-bindings/auto/api/VBox.lua @@ -13,6 +13,7 @@ -- @return VBox#VBox ret (retunr value: ccui.VBox) -------------------------------- +-- Default constructor -- @function [parent=#VBox] VBox -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/VideoPlayer.lua b/cocos/scripting/lua-bindings/auto/api/VideoPlayer.lua index 36954f071d..4812de8cee 100644 --- a/cocos/scripting/lua-bindings/auto/api/VideoPlayer.lua +++ b/cocos/scripting/lua-bindings/auto/api/VideoPlayer.lua @@ -5,91 +5,109 @@ -- @parent_module ccexp -------------------------------- +-- -- @function [parent=#VideoPlayer] getFileName -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- -- @function [parent=#VideoPlayer] getURL -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- -- @function [parent=#VideoPlayer] play -- @param self -------------------------------- +-- -- @function [parent=#VideoPlayer] pause -- @param self -------------------------------- +-- -- @function [parent=#VideoPlayer] setKeepAspectRatioEnabled -- @param self --- @param #bool bool +-- @param #bool enable -------------------------------- +-- -- @function [parent=#VideoPlayer] resume -- @param self -------------------------------- +-- -- @function [parent=#VideoPlayer] stop -- @param self -------------------------------- +-- -- @function [parent=#VideoPlayer] setFullScreenEnabled -- @param self --- @param #bool bool +-- @param #bool enabled -------------------------------- +-- -- @function [parent=#VideoPlayer] setFileName -- @param self --- @param #string str +-- @param #string videoPath -------------------------------- +-- -- @function [parent=#VideoPlayer] setURL -- @param self --- @param #string str +-- @param #string _videoURL -------------------------------- +-- -- @function [parent=#VideoPlayer] isKeepAspectRatioEnabled -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#VideoPlayer] onPlayEvent -- @param self --- @param #int int +-- @param #int event -------------------------------- +-- -- @function [parent=#VideoPlayer] isFullScreenEnabled -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#VideoPlayer] isPlaying -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#VideoPlayer] seekTo -- @param self --- @param #float float +-- @param #float sec -------------------------------- +-- -- @function [parent=#VideoPlayer] create -- @param self -- @return experimental::ui::VideoPlayer#experimental::ui::VideoPlayer ret (return value: cc.experimental::ui::VideoPlayer) -------------------------------- +-- -- @function [parent=#VideoPlayer] draw -- @param self -- @param #cc.Renderer renderer --- @param #mat4_table mat4 --- @param #unsigned int int +-- @param #mat4_table transform +-- @param #unsigned int flags -------------------------------- +-- -- @function [parent=#VideoPlayer] setVisible -- @param self --- @param #bool bool +-- @param #bool visible return nil diff --git a/cocos/scripting/lua-bindings/auto/api/VisibleFrame.lua b/cocos/scripting/lua-bindings/auto/api/VisibleFrame.lua index 2ca2917585..3d7b5e1115 100644 --- a/cocos/scripting/lua-bindings/auto/api/VisibleFrame.lua +++ b/cocos/scripting/lua-bindings/auto/api/VisibleFrame.lua @@ -5,26 +5,31 @@ -- @parent_module ccs -------------------------------- +-- -- @function [parent=#VisibleFrame] isVisible -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#VisibleFrame] setVisible -- @param self --- @param #bool bool +-- @param #bool visible -------------------------------- +-- -- @function [parent=#VisibleFrame] create -- @param self -- @return VisibleFrame#VisibleFrame ret (return value: ccs.VisibleFrame) -------------------------------- +-- -- @function [parent=#VisibleFrame] clone -- @param self -- @return Frame#Frame ret (return value: ccs.Frame) -------------------------------- +-- -- @function [parent=#VisibleFrame] VisibleFrame -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/Waves.lua b/cocos/scripting/lua-bindings/auto/api/Waves.lua index e8de3e0b5c..53569100b4 100644 --- a/cocos/scripting/lua-bindings/auto/api/Waves.lua +++ b/cocos/scripting/lua-bindings/auto/api/Waves.lua @@ -5,44 +5,51 @@ -- @parent_module cc -------------------------------- +-- -- @function [parent=#Waves] getAmplitudeRate -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#Waves] setAmplitude -- @param self --- @param #float float +-- @param #float amplitude -------------------------------- +-- -- @function [parent=#Waves] setAmplitudeRate -- @param self --- @param #float float +-- @param #float amplitudeRate -------------------------------- +-- -- @function [parent=#Waves] getAmplitude -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- initializes the action with amplitude, horizontal sin, vertical sin, a grid and duration -- @function [parent=#Waves] create -- @param self --- @param #float float --- @param #size_table size --- @param #unsigned int int --- @param #float float --- @param #bool bool --- @param #bool bool +-- @param #float duration +-- @param #size_table gridSize +-- @param #unsigned int waves +-- @param #float amplitude +-- @param #bool horizontal +-- @param #bool vertical -- @return Waves#Waves ret (return value: cc.Waves) -------------------------------- +-- -- @function [parent=#Waves] clone -- @param self -- @return Waves#Waves ret (return value: cc.Waves) -------------------------------- +-- -- @function [parent=#Waves] update -- @param self --- @param #float float +-- @param #float time return nil diff --git a/cocos/scripting/lua-bindings/auto/api/Waves3D.lua b/cocos/scripting/lua-bindings/auto/api/Waves3D.lua index 6eb07c8021..7ffc9ed324 100644 --- a/cocos/scripting/lua-bindings/auto/api/Waves3D.lua +++ b/cocos/scripting/lua-bindings/auto/api/Waves3D.lua @@ -5,42 +5,49 @@ -- @parent_module cc -------------------------------- +-- returns the amplitude rate -- @function [parent=#Waves3D] getAmplitudeRate -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- sets the amplitude to the effect -- @function [parent=#Waves3D] setAmplitude -- @param self --- @param #float float +-- @param #float amplitude -------------------------------- +-- sets the ampliture rate -- @function [parent=#Waves3D] setAmplitudeRate -- @param self --- @param #float float +-- @param #float amplitudeRate -------------------------------- +-- returns the amplitude of the effect -- @function [parent=#Waves3D] getAmplitude -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- creates an action with duration, grid size, waves and amplitude -- @function [parent=#Waves3D] create -- @param self --- @param #float float --- @param #size_table size --- @param #unsigned int int --- @param #float float +-- @param #float duration +-- @param #size_table gridSize +-- @param #unsigned int waves +-- @param #float amplitude -- @return Waves3D#Waves3D ret (return value: cc.Waves3D) -------------------------------- +-- -- @function [parent=#Waves3D] clone -- @param self -- @return Waves3D#Waves3D ret (return value: cc.Waves3D) -------------------------------- +-- -- @function [parent=#Waves3D] update -- @param self --- @param #float float +-- @param #float time return nil diff --git a/cocos/scripting/lua-bindings/auto/api/WavesTiles3D.lua b/cocos/scripting/lua-bindings/auto/api/WavesTiles3D.lua index 35c8de579e..14e5255895 100644 --- a/cocos/scripting/lua-bindings/auto/api/WavesTiles3D.lua +++ b/cocos/scripting/lua-bindings/auto/api/WavesTiles3D.lua @@ -5,42 +5,49 @@ -- @parent_module cc -------------------------------- +-- waves amplitude rate -- @function [parent=#WavesTiles3D] getAmplitudeRate -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- -- @function [parent=#WavesTiles3D] setAmplitude -- @param self --- @param #float float +-- @param #float amplitude -------------------------------- +-- -- @function [parent=#WavesTiles3D] setAmplitudeRate -- @param self --- @param #float float +-- @param #float amplitudeRate -------------------------------- +-- waves amplitude -- @function [parent=#WavesTiles3D] getAmplitude -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- creates the action with a number of waves, the waves amplitude, the grid size and the duration -- @function [parent=#WavesTiles3D] create -- @param self --- @param #float float --- @param #size_table size --- @param #unsigned int int --- @param #float float +-- @param #float duration +-- @param #size_table gridSize +-- @param #unsigned int waves +-- @param #float amplitude -- @return WavesTiles3D#WavesTiles3D ret (return value: cc.WavesTiles3D) -------------------------------- +-- -- @function [parent=#WavesTiles3D] clone -- @param self -- @return WavesTiles3D#WavesTiles3D ret (return value: cc.WavesTiles3D) -------------------------------- +-- -- @function [parent=#WavesTiles3D] update -- @param self --- @param #float float +-- @param #float time return nil diff --git a/cocos/scripting/lua-bindings/auto/api/Widget.lua b/cocos/scripting/lua-bindings/auto/api/Widget.lua index b473cb3332..e840a16900 100644 --- a/cocos/scripting/lua-bindings/auto/api/Widget.lua +++ b/cocos/scripting/lua-bindings/auto/api/Widget.lua @@ -5,219 +5,304 @@ -- @parent_module ccui -------------------------------- +-- Changes the percent that is widget's percent size
+-- param percent that is widget's percent size -- @function [parent=#Widget] setSizePercent -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table percent -------------------------------- +-- -- @function [parent=#Widget] getCustomSize -- @param self -- @return size_table#size_table ret (return value: size_table) -------------------------------- +-- -- @function [parent=#Widget] getLeftBoundary -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- Sets whether the widget should be flipped horizontally or not.
+-- param bFlippedX true if the widget should be flipped horizaontally, false otherwise. -- @function [parent=#Widget] setFlippedX -- @param self --- @param #bool bool +-- @param #bool flippedX -------------------------------- +-- Gets the Virtual Renderer of widget.
+-- For example, a button's Virtual Renderer is it's texture renderer.
+-- return Node pointer. -- @function [parent=#Widget] getVirtualRenderer -- @param self -- @return Node#Node ret (return value: cc.Node) -------------------------------- +-- brief Allow widget touch events to propagate to its parents. Set false will disable propagation -- @function [parent=#Widget] setPropagateTouchEvents -- @param self --- @param #bool bool +-- @param #bool isPropagate -------------------------------- +-- Returns size percent of widget
+-- return size percent -- @function [parent=#Widget] getSizePercent -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- Set the percent(x,y) of the widget in OpenGL coordinates
+-- param percent The percent (x,y) of the widget in OpenGL coordinates -- @function [parent=#Widget] setPositionPercent -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table percent -------------------------------- +-- brief Specify widget to swallow touches or not -- @function [parent=#Widget] setSwallowTouches -- @param self --- @param #bool bool +-- @param #bool swallow -------------------------------- +-- -- @function [parent=#Widget] getLayoutSize -- @param self -- @return size_table#size_table ret (return value: size_table) -------------------------------- +-- Sets whether the widget is hilighted
+-- The default value is false, a widget is default to not hilighted
+-- param hilight true if the widget is hilighted, false if the widget is not hilighted. -- @function [parent=#Widget] setHighlighted -- @param self --- @param #bool bool +-- @param #bool hilight -------------------------------- +-- Changes the position type of the widget
+-- see PositionType
+-- param type the position type of widget -- @function [parent=#Widget] setPositionType -- @param self --- @param #int positiontype +-- @param #int type -------------------------------- +-- Query whether the widget ignores user deinfed content size or not
+-- return bool -- @function [parent=#Widget] isIgnoreContentAdaptWithSize -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#Widget] getVirtualRendererSize -- @param self -- @return size_table#size_table ret (return value: size_table) -------------------------------- +-- Determines if the widget is highlighted
+-- return true if the widget is highlighted, false if the widget is not hignlighted . -- @function [parent=#Widget] isHighlighted -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- Gets LayoutParameter of widget.
+-- see LayoutParameter
+-- param type Relative or Linear
+-- return LayoutParameter -- @function [parent=#Widget] getLayoutParameter -- @param self -- @return LayoutParameter#LayoutParameter ret (return value: ccui.LayoutParameter) -------------------------------- +-- Checks a point if is in widget's space
+-- param point
+-- return true if the point is in widget's space, flase otherwise. -- @function [parent=#Widget] hitTest -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table pt -- @return bool#bool ret (return value: bool) -------------------------------- +-- Gets the position type of the widget
+-- see PositionType
+-- return type the position type of widget -- @function [parent=#Widget] getPositionType -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- -- @function [parent=#Widget] getTopBoundary -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- Note: when you set _ignoreSize to true, no matther you call setContentSize or not,
+-- the widget size is always equal to the return value of the member function getVirtualRendererSize.
+-- param ignore, set member variabl _ignoreSize to ignore -- @function [parent=#Widget] ignoreContentAdaptWithSize -- @param self --- @param #bool bool +-- @param #bool ignore -------------------------------- +-- When a widget is in a layout, you could call this method to get the next focused widget within a specified direction.
+-- If the widget is not in a layout, it will return itself
+-- param dir the direction to look for the next focused widget in a layout
+-- param current the current focused widget
+-- return the next focused widget in a layout -- @function [parent=#Widget] findNextFocusedWidget -- @param self --- @param #int focusdirection --- @param #ccui.Widget widget +-- @param #int direction +-- @param #ccui.Widget current -- @return Widget#Widget ret (return value: ccui.Widget) -------------------------------- +-- Determines if the widget is enabled
+-- return true if the widget is enabled, false if the widget is disabled. -- @function [parent=#Widget] isEnabled -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- return whether the widget is focused or not -- @function [parent=#Widget] isFocused -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#Widget] getTouchBeganPosition -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- Determines if the widget is touch enabled
+-- return true if the widget is touch enabled, false if the widget is touch disabled. -- @function [parent=#Widget] isTouchEnabled -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#Widget] getActionTag -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- Gets world position of widget.
+-- return world position of widget. -- @function [parent=#Widget] getWorldPosition -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- return true represent the widget could accept focus, false represent the widget couldn't accept focus -- @function [parent=#Widget] isFocusEnabled -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- param focus pass true to let the widget get focus or pass false to let the widget lose focus
+-- return void -- @function [parent=#Widget] setFocused -- @param self --- @param #bool bool +-- @param #bool focus -------------------------------- +-- -- @function [parent=#Widget] setActionTag -- @param self --- @param #int int +-- @param #int tag -------------------------------- +-- Sets whether the widget is touch enabled
+-- The default value is false, a widget is default to touch disabled
+-- param visible true if the widget is touch enabled, false if the widget is touch disabled. -- @function [parent=#Widget] setTouchEnabled -- @param self --- @param #bool bool +-- @param #bool enabled -------------------------------- +-- Sets whether the widget should be flipped vertically or not.
+-- param bFlippedY true if the widget should be flipped vertically, flase otherwise. -- @function [parent=#Widget] setFlippedY -- @param self --- @param #bool bool +-- @param #bool flippedY -------------------------------- +-- Sets whether the widget is enabled
+-- true if the widget is enabled, widget may be touched , false if the widget is disabled, widget cannot be touched.
+-- The default value is true, a widget is default to enabled
+-- param enabled -- @function [parent=#Widget] setEnabled -- @param self --- @param #bool bool +-- @param #bool enabled -------------------------------- +-- -- @function [parent=#Widget] getRightBoundary -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- To set the bright style of widget.
+-- see BrightStyle
+-- param style BrightStyle::NORMAL means the widget is in normal state, BrightStyle::HIGHLIGHT means the widget is in highlight state. -- @function [parent=#Widget] setBrightStyle -- @param self --- @param #int brightstyle +-- @param #int style -------------------------------- +-- Sets a LayoutParameter to widget.
+-- see LayoutParameter
+-- param LayoutParameter pointer
+-- param type Relative or Linear -- @function [parent=#Widget] setLayoutParameter -- @param self --- @param #ccui.LayoutParameter layoutparameter +-- @param #ccui.LayoutParameter parameter -------------------------------- +-- -- @function [parent=#Widget] clone -- @param self -- @return Widget#Widget ret (return value: ccui.Widget) -------------------------------- +-- param enable pass true/false to enable/disable the focus ability of a widget
+-- return void -- @function [parent=#Widget] setFocusEnabled -- @param self --- @param #bool bool +-- @param #bool enable -------------------------------- +-- -- @function [parent=#Widget] getBottomBoundary -- @param self -- @return float#float ret (return value: float) -------------------------------- +-- Determines if the widget is bright
+-- return true if the widget is bright, false if the widget is dark. -- @function [parent=#Widget] isBright -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#Widget] isPropagateTouchEvents -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#Widget] getCurrentFocusedWidget -- @param self -- @return Widget#Widget ret (return value: ccui.Widget) -------------------------------- +-- when a widget calls this method, it will get focus immediately. -- @function [parent=#Widget] requestFocus -- @param self @@ -226,95 +311,134 @@ -- @overload self -- @function [parent=#Widget] updateSizeAndPosition -- @param self --- @param #size_table size +-- @param #size_table parentSize -------------------------------- +-- -- @function [parent=#Widget] getTouchMovePosition -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- Gets the size type of widget.
+-- see SizeType
+-- param type that is widget's size type -- @function [parent=#Widget] getSizeType -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- -- @function [parent=#Widget] addTouchEventListener -- @param self --- @param #function func +-- @param #function callback -------------------------------- +-- -- @function [parent=#Widget] getTouchEndPosition -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- Gets the percent (x,y) of the widget in OpenGL coordinates
+-- see setPosition(const Vec2&)
+-- return The percent (x,y) of the widget in OpenGL coordinates -- @function [parent=#Widget] getPositionPercent -- @param self -- @return vec2_table#vec2_table ret (return value: vec2_table) -------------------------------- +-- Set a click event handler to the widget -- @function [parent=#Widget] addClickEventListener -- @param self --- @param #function func +-- @param #function callback -------------------------------- +-- Returns the flag which indicates whether the widget is flipped horizontally or not.
+-- It only flips the texture of the widget, and not the texture of the widget's children.
+-- Also, flipping the texture doesn't alter the anchorPoint.
+-- If you want to flip the anchorPoint too, and/or to flip the children too use:
+-- widget->setScaleX(sprite->getScaleX() * -1);
+-- return true if the widget is flipped horizaontally, false otherwise. -- @function [parent=#Widget] isFlippedX -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- Return the flag which indicates whether the widget is flipped vertically or not.
+-- It only flips the texture of the widget, and not the texture of the widget's children.
+-- Also, flipping the texture doesn't alter the anchorPoint.
+-- If you want to flip the anchorPoint too, and/or to flip the children too use:
+-- widget->setScaleY(widget->getScaleY() * -1);
+-- return true if the widget is flipped vertically, flase otherwise. -- @function [parent=#Widget] isFlippedY -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#Widget] isClippingParentContainsPoint -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table pt -- @return bool#bool ret (return value: bool) -------------------------------- +-- Changes the size type of widget.
+-- see SizeType
+-- param type that is widget's size type -- @function [parent=#Widget] setSizeType -- @param self --- @param #int sizetype +-- @param #int type -------------------------------- +-- Sets whether the widget is bright
+-- The default value is true, a widget is default to bright
+-- param visible true if the widget is bright, false if the widget is dark. -- @function [parent=#Widget] setBright -- @param self --- @param #bool bool +-- @param #bool bright -------------------------------- +-- -- @function [parent=#Widget] isSwallowTouches -- @param self -- @return bool#bool ret (return value: bool) -------------------------------- +-- -- @function [parent=#Widget] enableDpadNavigation -- @param self --- @param #bool bool +-- @param #bool enable -------------------------------- +-- Allocates and initializes a widget. -- @function [parent=#Widget] create -- @param self -- @return Widget#Widget ret (return value: ccui.Widget) -------------------------------- +-- Returns the "class name" of widget. -- @function [parent=#Widget] getDescription -- @param self -- @return string#string ret (return value: string) -------------------------------- +-- Changes the position (x,y) of the widget in OpenGL coordinates
+-- Usually we use p(x,y) to compose Vec2 object.
+-- The original point (0,0) is at the left-bottom corner of screen.
+-- param position The position (x,y) of the widget in OpenGL coordinates -- @function [parent=#Widget] setPosition -- @param self --- @param #vec2_table vec2 +-- @param #vec2_table pos -------------------------------- +-- -- @function [parent=#Widget] setContentSize -- @param self --- @param #size_table size +-- @param #size_table contentSize -------------------------------- +-- Default constructor -- @function [parent=#Widget] Widget -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/ZOrderFrame.lua b/cocos/scripting/lua-bindings/auto/api/ZOrderFrame.lua index aa0999498e..6a89744ead 100644 --- a/cocos/scripting/lua-bindings/auto/api/ZOrderFrame.lua +++ b/cocos/scripting/lua-bindings/auto/api/ZOrderFrame.lua @@ -5,26 +5,31 @@ -- @parent_module ccs -------------------------------- +-- -- @function [parent=#ZOrderFrame] getZOrder -- @param self -- @return int#int ret (return value: int) -------------------------------- +-- -- @function [parent=#ZOrderFrame] setZOrder -- @param self --- @param #int int +-- @param #int zorder -------------------------------- +-- -- @function [parent=#ZOrderFrame] create -- @param self -- @return ZOrderFrame#ZOrderFrame ret (return value: ccs.ZOrderFrame) -------------------------------- +-- -- @function [parent=#ZOrderFrame] clone -- @param self -- @return Frame#Frame ret (return value: ccs.Frame) -------------------------------- +-- -- @function [parent=#ZOrderFrame] ZOrderFrame -- @param self diff --git a/cocos/scripting/lua-bindings/auto/api/lua_cocos2dx_extension_auto_api.lua b/cocos/scripting/lua-bindings/auto/api/lua_cocos2dx_extension_auto_api.lua index 6798a0b06d..99a0edbd12 100644 --- a/cocos/scripting/lua-bindings/auto/api/lua_cocos2dx_extension_auto_api.lua +++ b/cocos/scripting/lua-bindings/auto/api/lua_cocos2dx_extension_auto_api.lua @@ -1,11 +1,6 @@ -------------------------------- -- @module cc --------------------------------------------------------- --- the cc Scale9Sprite --- @field [parent=#cc] Scale9Sprite#Scale9Sprite Scale9Sprite preloaded module - - -------------------------------------------------------- -- the cc Control -- @field [parent=#cc] Control#Control Control preloaded module @@ -66,11 +61,6 @@ -- @field [parent=#cc] TableView#TableView TableView preloaded module --------------------------------------------------------- --- the cc EditBox --- @field [parent=#cc] EditBox#EditBox EditBox preloaded module - - -------------------------------------------------------- -- the cc AssetsManager -- @field [parent=#cc] AssetsManager#AssetsManager AssetsManager preloaded module diff --git a/cocos/scripting/lua-bindings/auto/lua_cocos2dx_3d_auto.cpp b/cocos/scripting/lua-bindings/auto/lua_cocos2dx_3d_auto.cpp index 77190063f7..312a5dfe3e 100644 --- a/cocos/scripting/lua-bindings/auto/lua_cocos2dx_3d_auto.cpp +++ b/cocos/scripting/lua-bindings/auto/lua_cocos2dx_3d_auto.cpp @@ -522,7 +522,8 @@ int lua_cocos2dx_3d_Sprite3D_setBlendFunc(lua_State* tolua_S) { cocos2d::BlendFunc arg0; - #pragma warning NO CONVERSION TO NATIVE FOR BlendFunc; + #pragma warning NO CONVERSION TO NATIVE FOR BlendFunc + ok = false; if(!ok) return 0; cobj->setBlendFunc(arg0); @@ -1289,7 +1290,8 @@ int lua_cocos2dx_3d_Mesh_setBlendFunc(lua_State* tolua_S) { cocos2d::BlendFunc arg0; - #pragma warning NO CONVERSION TO NATIVE FOR BlendFunc; + #pragma warning NO CONVERSION TO NATIVE FOR BlendFunc + ok = false; if(!ok) return 0; cobj->setBlendFunc(arg0); diff --git a/cocos/scripting/lua-bindings/auto/lua_cocos2dx_auto.cpp b/cocos/scripting/lua-bindings/auto/lua_cocos2dx_auto.cpp index 3f90a87db1..74a9ae1232 100644 --- a/cocos/scripting/lua-bindings/auto/lua_cocos2dx_auto.cpp +++ b/cocos/scripting/lua-bindings/auto/lua_cocos2dx_auto.cpp @@ -10539,7 +10539,8 @@ int lua_cocos2dx_GLView_setGLContextAttrs(lua_State* tolua_S) if (argc == 1) { GLContextAttrs arg0; - #pragma warning NO CONVERSION TO NATIVE FOR GLContextAttrs; + #pragma warning NO CONVERSION TO NATIVE FOR GLContextAttrs + ok = false; if(!ok) return 0; cocos2d::GLView::setGLContextAttrs(arg0); diff --git a/cocos/scripting/lua-bindings/auto/lua_cocos2dx_extension_auto.cpp b/cocos/scripting/lua-bindings/auto/lua_cocos2dx_extension_auto.cpp index 81f1c26626..6958a28aa3 100644 --- a/cocos/scripting/lua-bindings/auto/lua_cocos2dx_extension_auto.cpp +++ b/cocos/scripting/lua-bindings/auto/lua_cocos2dx_extension_auto.cpp @@ -5,1347 +5,6 @@ -int lua_cocos2dx_extension_Scale9Sprite_resizableSpriteWithCapInsets(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::extension::Scale9Sprite* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.Scale9Sprite",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::extension::Scale9Sprite*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_extension_Scale9Sprite_resizableSpriteWithCapInsets'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 1) - { - cocos2d::Rect arg0; - - ok &= luaval_to_rect(tolua_S, 2, &arg0, "cc.Scale9Sprite:resizableSpriteWithCapInsets"); - if(!ok) - return 0; - cocos2d::extension::Scale9Sprite* ret = cobj->resizableSpriteWithCapInsets(arg0); - object_to_luaval(tolua_S, "cc.Scale9Sprite",(cocos2d::extension::Scale9Sprite*)ret); - return 1; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "cc.Scale9Sprite:resizableSpriteWithCapInsets",argc, 1); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_extension_Scale9Sprite_resizableSpriteWithCapInsets'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_extension_Scale9Sprite_setInsetBottom(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::extension::Scale9Sprite* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.Scale9Sprite",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::extension::Scale9Sprite*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_extension_Scale9Sprite_setInsetBottom'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 1) - { - double arg0; - - ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Scale9Sprite:setInsetBottom"); - if(!ok) - return 0; - cobj->setInsetBottom(arg0); - return 0; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "cc.Scale9Sprite:setInsetBottom",argc, 1); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_extension_Scale9Sprite_setInsetBottom'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_extension_Scale9Sprite_initWithSpriteFrameName(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::extension::Scale9Sprite* cobj = nullptr; - bool ok = true; -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.Scale9Sprite",0,&tolua_err)) goto tolua_lerror; -#endif - cobj = (cocos2d::extension::Scale9Sprite*)tolua_tousertype(tolua_S,1,0); -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_extension_Scale9Sprite_initWithSpriteFrameName'", nullptr); - return 0; - } -#endif - argc = lua_gettop(tolua_S)-1; - do{ - if (argc == 1) { - std::string arg0; - ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Scale9Sprite:initWithSpriteFrameName"); - - if (!ok) { break; } - bool ret = cobj->initWithSpriteFrameName(arg0); - tolua_pushboolean(tolua_S,(bool)ret); - return 1; - } - }while(0); - ok = true; - do{ - if (argc == 2) { - std::string arg0; - ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Scale9Sprite:initWithSpriteFrameName"); - - if (!ok) { break; } - cocos2d::Rect arg1; - ok &= luaval_to_rect(tolua_S, 3, &arg1, "cc.Scale9Sprite:initWithSpriteFrameName"); - - if (!ok) { break; } - bool ret = cobj->initWithSpriteFrameName(arg0, arg1); - tolua_pushboolean(tolua_S,(bool)ret); - return 1; - } - }while(0); - ok = true; - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "cc.Scale9Sprite:initWithSpriteFrameName",argc, 2); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_extension_Scale9Sprite_initWithSpriteFrameName'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_extension_Scale9Sprite_setInsetTop(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::extension::Scale9Sprite* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.Scale9Sprite",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::extension::Scale9Sprite*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_extension_Scale9Sprite_setInsetTop'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 1) - { - double arg0; - - ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Scale9Sprite:setInsetTop"); - if(!ok) - return 0; - cobj->setInsetTop(arg0); - return 0; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "cc.Scale9Sprite:setInsetTop",argc, 1); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_extension_Scale9Sprite_setInsetTop'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_extension_Scale9Sprite_init(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::extension::Scale9Sprite* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.Scale9Sprite",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::extension::Scale9Sprite*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_extension_Scale9Sprite_init'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 0) - { - if(!ok) - return 0; - bool ret = cobj->init(); - tolua_pushboolean(tolua_S,(bool)ret); - return 1; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "cc.Scale9Sprite:init",argc, 0); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_extension_Scale9Sprite_init'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_extension_Scale9Sprite_setPreferredSize(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::extension::Scale9Sprite* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.Scale9Sprite",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::extension::Scale9Sprite*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_extension_Scale9Sprite_setPreferredSize'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 1) - { - cocos2d::Size arg0; - - ok &= luaval_to_size(tolua_S, 2, &arg0, "cc.Scale9Sprite:setPreferredSize"); - if(!ok) - return 0; - cobj->setPreferredSize(arg0); - return 0; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "cc.Scale9Sprite:setPreferredSize",argc, 1); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_extension_Scale9Sprite_setPreferredSize'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_extension_Scale9Sprite_setSpriteFrame(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::extension::Scale9Sprite* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.Scale9Sprite",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::extension::Scale9Sprite*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_extension_Scale9Sprite_setSpriteFrame'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 1) - { - cocos2d::SpriteFrame* arg0; - - ok &= luaval_to_object(tolua_S, 2, "cc.SpriteFrame",&arg0); - if(!ok) - return 0; - cobj->setSpriteFrame(arg0); - return 0; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "cc.Scale9Sprite:setSpriteFrame",argc, 1); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_extension_Scale9Sprite_setSpriteFrame'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_extension_Scale9Sprite_initWithBatchNode(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::extension::Scale9Sprite* cobj = nullptr; - bool ok = true; -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.Scale9Sprite",0,&tolua_err)) goto tolua_lerror; -#endif - cobj = (cocos2d::extension::Scale9Sprite*)tolua_tousertype(tolua_S,1,0); -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_extension_Scale9Sprite_initWithBatchNode'", nullptr); - return 0; - } -#endif - argc = lua_gettop(tolua_S)-1; - do{ - if (argc == 3) { - cocos2d::SpriteBatchNode* arg0; - ok &= luaval_to_object(tolua_S, 2, "cc.SpriteBatchNode",&arg0); - - if (!ok) { break; } - cocos2d::Rect arg1; - ok &= luaval_to_rect(tolua_S, 3, &arg1, "cc.Scale9Sprite:initWithBatchNode"); - - if (!ok) { break; } - cocos2d::Rect arg2; - ok &= luaval_to_rect(tolua_S, 4, &arg2, "cc.Scale9Sprite:initWithBatchNode"); - - if (!ok) { break; } - bool ret = cobj->initWithBatchNode(arg0, arg1, arg2); - tolua_pushboolean(tolua_S,(bool)ret); - return 1; - } - }while(0); - ok = true; - do{ - if (argc == 4) { - cocos2d::SpriteBatchNode* arg0; - ok &= luaval_to_object(tolua_S, 2, "cc.SpriteBatchNode",&arg0); - - if (!ok) { break; } - cocos2d::Rect arg1; - ok &= luaval_to_rect(tolua_S, 3, &arg1, "cc.Scale9Sprite:initWithBatchNode"); - - if (!ok) { break; } - bool arg2; - ok &= luaval_to_boolean(tolua_S, 4,&arg2, "cc.Scale9Sprite:initWithBatchNode"); - - if (!ok) { break; } - cocos2d::Rect arg3; - ok &= luaval_to_rect(tolua_S, 5, &arg3, "cc.Scale9Sprite:initWithBatchNode"); - - if (!ok) { break; } - bool ret = cobj->initWithBatchNode(arg0, arg1, arg2, arg3); - tolua_pushboolean(tolua_S,(bool)ret); - return 1; - } - }while(0); - ok = true; - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "cc.Scale9Sprite:initWithBatchNode",argc, 4); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_extension_Scale9Sprite_initWithBatchNode'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_extension_Scale9Sprite_getInsetBottom(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::extension::Scale9Sprite* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.Scale9Sprite",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::extension::Scale9Sprite*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_extension_Scale9Sprite_getInsetBottom'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 0) - { - if(!ok) - return 0; - double ret = cobj->getInsetBottom(); - tolua_pushnumber(tolua_S,(lua_Number)ret); - return 1; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "cc.Scale9Sprite:getInsetBottom",argc, 0); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_extension_Scale9Sprite_getInsetBottom'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_extension_Scale9Sprite_getCapInsets(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::extension::Scale9Sprite* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.Scale9Sprite",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::extension::Scale9Sprite*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_extension_Scale9Sprite_getCapInsets'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 0) - { - if(!ok) - return 0; - cocos2d::Rect ret = cobj->getCapInsets(); - rect_to_luaval(tolua_S, ret); - return 1; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "cc.Scale9Sprite:getCapInsets",argc, 0); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_extension_Scale9Sprite_getCapInsets'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_extension_Scale9Sprite_updateWithBatchNode(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::extension::Scale9Sprite* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.Scale9Sprite",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::extension::Scale9Sprite*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_extension_Scale9Sprite_updateWithBatchNode'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 4) - { - cocos2d::SpriteBatchNode* arg0; - cocos2d::Rect arg1; - bool arg2; - cocos2d::Rect arg3; - - ok &= luaval_to_object(tolua_S, 2, "cc.SpriteBatchNode",&arg0); - - ok &= luaval_to_rect(tolua_S, 3, &arg1, "cc.Scale9Sprite:updateWithBatchNode"); - - ok &= luaval_to_boolean(tolua_S, 4,&arg2, "cc.Scale9Sprite:updateWithBatchNode"); - - ok &= luaval_to_rect(tolua_S, 5, &arg3, "cc.Scale9Sprite:updateWithBatchNode"); - if(!ok) - return 0; - bool ret = cobj->updateWithBatchNode(arg0, arg1, arg2, arg3); - tolua_pushboolean(tolua_S,(bool)ret); - return 1; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "cc.Scale9Sprite:updateWithBatchNode",argc, 4); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_extension_Scale9Sprite_updateWithBatchNode'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_extension_Scale9Sprite_getInsetRight(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::extension::Scale9Sprite* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.Scale9Sprite",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::extension::Scale9Sprite*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_extension_Scale9Sprite_getInsetRight'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 0) - { - if(!ok) - return 0; - double ret = cobj->getInsetRight(); - tolua_pushnumber(tolua_S,(lua_Number)ret); - return 1; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "cc.Scale9Sprite:getInsetRight",argc, 0); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_extension_Scale9Sprite_getInsetRight'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_extension_Scale9Sprite_getOriginalSize(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::extension::Scale9Sprite* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.Scale9Sprite",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::extension::Scale9Sprite*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_extension_Scale9Sprite_getOriginalSize'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 0) - { - if(!ok) - return 0; - cocos2d::Size ret = cobj->getOriginalSize(); - size_to_luaval(tolua_S, ret); - return 1; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "cc.Scale9Sprite:getOriginalSize",argc, 0); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_extension_Scale9Sprite_getOriginalSize'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_extension_Scale9Sprite_initWithFile(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::extension::Scale9Sprite* cobj = nullptr; - bool ok = true; -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.Scale9Sprite",0,&tolua_err)) goto tolua_lerror; -#endif - cobj = (cocos2d::extension::Scale9Sprite*)tolua_tousertype(tolua_S,1,0); -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_extension_Scale9Sprite_initWithFile'", nullptr); - return 0; - } -#endif - argc = lua_gettop(tolua_S)-1; - do{ - if (argc == 2) { - std::string arg0; - ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Scale9Sprite:initWithFile"); - - if (!ok) { break; } - cocos2d::Rect arg1; - ok &= luaval_to_rect(tolua_S, 3, &arg1, "cc.Scale9Sprite:initWithFile"); - - if (!ok) { break; } - bool ret = cobj->initWithFile(arg0, arg1); - tolua_pushboolean(tolua_S,(bool)ret); - return 1; - } - }while(0); - ok = true; - do{ - if (argc == 3) { - std::string arg0; - ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Scale9Sprite:initWithFile"); - - if (!ok) { break; } - cocos2d::Rect arg1; - ok &= luaval_to_rect(tolua_S, 3, &arg1, "cc.Scale9Sprite:initWithFile"); - - if (!ok) { break; } - cocos2d::Rect arg2; - ok &= luaval_to_rect(tolua_S, 4, &arg2, "cc.Scale9Sprite:initWithFile"); - - if (!ok) { break; } - bool ret = cobj->initWithFile(arg0, arg1, arg2); - tolua_pushboolean(tolua_S,(bool)ret); - return 1; - } - }while(0); - ok = true; - do{ - if (argc == 2) { - cocos2d::Rect arg0; - ok &= luaval_to_rect(tolua_S, 2, &arg0, "cc.Scale9Sprite:initWithFile"); - - if (!ok) { break; } - std::string arg1; - ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.Scale9Sprite:initWithFile"); - - if (!ok) { break; } - bool ret = cobj->initWithFile(arg0, arg1); - tolua_pushboolean(tolua_S,(bool)ret); - return 1; - } - }while(0); - ok = true; - do{ - if (argc == 1) { - std::string arg0; - ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Scale9Sprite:initWithFile"); - - if (!ok) { break; } - bool ret = cobj->initWithFile(arg0); - tolua_pushboolean(tolua_S,(bool)ret); - return 1; - } - }while(0); - ok = true; - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "cc.Scale9Sprite:initWithFile",argc, 1); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_extension_Scale9Sprite_initWithFile'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_extension_Scale9Sprite_getInsetTop(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::extension::Scale9Sprite* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.Scale9Sprite",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::extension::Scale9Sprite*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_extension_Scale9Sprite_getInsetTop'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 0) - { - if(!ok) - return 0; - double ret = cobj->getInsetTop(); - tolua_pushnumber(tolua_S,(lua_Number)ret); - return 1; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "cc.Scale9Sprite:getInsetTop",argc, 0); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_extension_Scale9Sprite_getInsetTop'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_extension_Scale9Sprite_setInsetLeft(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::extension::Scale9Sprite* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.Scale9Sprite",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::extension::Scale9Sprite*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_extension_Scale9Sprite_setInsetLeft'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 1) - { - double arg0; - - ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Scale9Sprite:setInsetLeft"); - if(!ok) - return 0; - cobj->setInsetLeft(arg0); - return 0; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "cc.Scale9Sprite:setInsetLeft",argc, 1); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_extension_Scale9Sprite_setInsetLeft'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_extension_Scale9Sprite_initWithSpriteFrame(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::extension::Scale9Sprite* cobj = nullptr; - bool ok = true; -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.Scale9Sprite",0,&tolua_err)) goto tolua_lerror; -#endif - cobj = (cocos2d::extension::Scale9Sprite*)tolua_tousertype(tolua_S,1,0); -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_extension_Scale9Sprite_initWithSpriteFrame'", nullptr); - return 0; - } -#endif - argc = lua_gettop(tolua_S)-1; - do{ - if (argc == 1) { - cocos2d::SpriteFrame* arg0; - ok &= luaval_to_object(tolua_S, 2, "cc.SpriteFrame",&arg0); - - if (!ok) { break; } - bool ret = cobj->initWithSpriteFrame(arg0); - tolua_pushboolean(tolua_S,(bool)ret); - return 1; - } - }while(0); - ok = true; - do{ - if (argc == 2) { - cocos2d::SpriteFrame* arg0; - ok &= luaval_to_object(tolua_S, 2, "cc.SpriteFrame",&arg0); - - if (!ok) { break; } - cocos2d::Rect arg1; - ok &= luaval_to_rect(tolua_S, 3, &arg1, "cc.Scale9Sprite:initWithSpriteFrame"); - - if (!ok) { break; } - bool ret = cobj->initWithSpriteFrame(arg0, arg1); - tolua_pushboolean(tolua_S,(bool)ret); - return 1; - } - }while(0); - ok = true; - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "cc.Scale9Sprite:initWithSpriteFrame",argc, 2); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_extension_Scale9Sprite_initWithSpriteFrame'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_extension_Scale9Sprite_getPreferredSize(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::extension::Scale9Sprite* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.Scale9Sprite",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::extension::Scale9Sprite*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_extension_Scale9Sprite_getPreferredSize'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 0) - { - if(!ok) - return 0; - cocos2d::Size ret = cobj->getPreferredSize(); - size_to_luaval(tolua_S, ret); - return 1; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "cc.Scale9Sprite:getPreferredSize",argc, 0); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_extension_Scale9Sprite_getPreferredSize'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_extension_Scale9Sprite_setCapInsets(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::extension::Scale9Sprite* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.Scale9Sprite",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::extension::Scale9Sprite*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_extension_Scale9Sprite_setCapInsets'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 1) - { - cocos2d::Rect arg0; - - ok &= luaval_to_rect(tolua_S, 2, &arg0, "cc.Scale9Sprite:setCapInsets"); - if(!ok) - return 0; - cobj->setCapInsets(arg0); - return 0; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "cc.Scale9Sprite:setCapInsets",argc, 1); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_extension_Scale9Sprite_setCapInsets'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_extension_Scale9Sprite_getInsetLeft(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::extension::Scale9Sprite* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.Scale9Sprite",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::extension::Scale9Sprite*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_extension_Scale9Sprite_getInsetLeft'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 0) - { - if(!ok) - return 0; - double ret = cobj->getInsetLeft(); - tolua_pushnumber(tolua_S,(lua_Number)ret); - return 1; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "cc.Scale9Sprite:getInsetLeft",argc, 0); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_extension_Scale9Sprite_getInsetLeft'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_extension_Scale9Sprite_setInsetRight(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::extension::Scale9Sprite* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.Scale9Sprite",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::extension::Scale9Sprite*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_extension_Scale9Sprite_setInsetRight'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 1) - { - double arg0; - - ok &= luaval_to_number(tolua_S, 2,&arg0, "cc.Scale9Sprite:setInsetRight"); - if(!ok) - return 0; - cobj->setInsetRight(arg0); - return 0; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "cc.Scale9Sprite:setInsetRight",argc, 1); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_extension_Scale9Sprite_setInsetRight'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_extension_Scale9Sprite_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,1,"cc.Scale9Sprite",0,&tolua_err)) goto tolua_lerror; -#endif - - argc = lua_gettop(tolua_S)-1; - - do - { - if (argc == 3) - { - std::string arg0; - ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Scale9Sprite:create"); - if (!ok) { break; } - cocos2d::Rect arg1; - ok &= luaval_to_rect(tolua_S, 3, &arg1, "cc.Scale9Sprite:create"); - if (!ok) { break; } - cocos2d::Rect arg2; - ok &= luaval_to_rect(tolua_S, 4, &arg2, "cc.Scale9Sprite:create"); - if (!ok) { break; } - cocos2d::extension::Scale9Sprite* ret = cocos2d::extension::Scale9Sprite::create(arg0, arg1, arg2); - object_to_luaval(tolua_S, "cc.Scale9Sprite",(cocos2d::extension::Scale9Sprite*)ret); - return 1; - } - } while (0); - ok = true; - do - { - if (argc == 0) - { - cocos2d::extension::Scale9Sprite* ret = cocos2d::extension::Scale9Sprite::create(); - object_to_luaval(tolua_S, "cc.Scale9Sprite",(cocos2d::extension::Scale9Sprite*)ret); - return 1; - } - } while (0); - ok = true; - do - { - if (argc == 2) - { - cocos2d::Rect arg0; - ok &= luaval_to_rect(tolua_S, 2, &arg0, "cc.Scale9Sprite:create"); - if (!ok) { break; } - std::string arg1; - ok &= luaval_to_std_string(tolua_S, 3,&arg1, "cc.Scale9Sprite:create"); - if (!ok) { break; } - cocos2d::extension::Scale9Sprite* ret = cocos2d::extension::Scale9Sprite::create(arg0, arg1); - object_to_luaval(tolua_S, "cc.Scale9Sprite",(cocos2d::extension::Scale9Sprite*)ret); - return 1; - } - } while (0); - ok = true; - do - { - if (argc == 2) - { - std::string arg0; - ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Scale9Sprite:create"); - if (!ok) { break; } - cocos2d::Rect arg1; - ok &= luaval_to_rect(tolua_S, 3, &arg1, "cc.Scale9Sprite:create"); - if (!ok) { break; } - cocos2d::extension::Scale9Sprite* ret = cocos2d::extension::Scale9Sprite::create(arg0, arg1); - object_to_luaval(tolua_S, "cc.Scale9Sprite",(cocos2d::extension::Scale9Sprite*)ret); - return 1; - } - } while (0); - ok = true; - do - { - if (argc == 1) - { - std::string arg0; - ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Scale9Sprite:create"); - if (!ok) { break; } - cocos2d::extension::Scale9Sprite* ret = cocos2d::extension::Scale9Sprite::create(arg0); - object_to_luaval(tolua_S, "cc.Scale9Sprite",(cocos2d::extension::Scale9Sprite*)ret); - return 1; - } - } while (0); - ok = true; - CCLOG("%s has wrong number of arguments: %d, was expecting %d", "cc.Scale9Sprite:create",argc, 1); - return 0; -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_extension_Scale9Sprite_create'.",&tolua_err); -#endif - return 0; -} -int lua_cocos2dx_extension_Scale9Sprite_createWithSpriteFrameName(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,1,"cc.Scale9Sprite",0,&tolua_err)) goto tolua_lerror; -#endif - - argc = lua_gettop(tolua_S)-1; - - do - { - if (argc == 2) - { - std::string arg0; - ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Scale9Sprite:createWithSpriteFrameName"); - if (!ok) { break; } - cocos2d::Rect arg1; - ok &= luaval_to_rect(tolua_S, 3, &arg1, "cc.Scale9Sprite:createWithSpriteFrameName"); - if (!ok) { break; } - cocos2d::extension::Scale9Sprite* ret = cocos2d::extension::Scale9Sprite::createWithSpriteFrameName(arg0, arg1); - object_to_luaval(tolua_S, "cc.Scale9Sprite",(cocos2d::extension::Scale9Sprite*)ret); - return 1; - } - } while (0); - ok = true; - do - { - if (argc == 1) - { - std::string arg0; - ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.Scale9Sprite:createWithSpriteFrameName"); - if (!ok) { break; } - cocos2d::extension::Scale9Sprite* ret = cocos2d::extension::Scale9Sprite::createWithSpriteFrameName(arg0); - object_to_luaval(tolua_S, "cc.Scale9Sprite",(cocos2d::extension::Scale9Sprite*)ret); - return 1; - } - } while (0); - ok = true; - CCLOG("%s has wrong number of arguments: %d, was expecting %d", "cc.Scale9Sprite:createWithSpriteFrameName",argc, 1); - return 0; -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_extension_Scale9Sprite_createWithSpriteFrameName'.",&tolua_err); -#endif - return 0; -} -int lua_cocos2dx_extension_Scale9Sprite_createWithSpriteFrame(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,1,"cc.Scale9Sprite",0,&tolua_err)) goto tolua_lerror; -#endif - - argc = lua_gettop(tolua_S)-1; - - do - { - if (argc == 2) - { - cocos2d::SpriteFrame* arg0; - ok &= luaval_to_object(tolua_S, 2, "cc.SpriteFrame",&arg0); - if (!ok) { break; } - cocos2d::Rect arg1; - ok &= luaval_to_rect(tolua_S, 3, &arg1, "cc.Scale9Sprite:createWithSpriteFrame"); - if (!ok) { break; } - cocos2d::extension::Scale9Sprite* ret = cocos2d::extension::Scale9Sprite::createWithSpriteFrame(arg0, arg1); - object_to_luaval(tolua_S, "cc.Scale9Sprite",(cocos2d::extension::Scale9Sprite*)ret); - return 1; - } - } while (0); - ok = true; - do - { - if (argc == 1) - { - cocos2d::SpriteFrame* arg0; - ok &= luaval_to_object(tolua_S, 2, "cc.SpriteFrame",&arg0); - if (!ok) { break; } - cocos2d::extension::Scale9Sprite* ret = cocos2d::extension::Scale9Sprite::createWithSpriteFrame(arg0); - object_to_luaval(tolua_S, "cc.Scale9Sprite",(cocos2d::extension::Scale9Sprite*)ret); - return 1; - } - } while (0); - ok = true; - CCLOG("%s has wrong number of arguments: %d, was expecting %d", "cc.Scale9Sprite:createWithSpriteFrame",argc, 1); - return 0; -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_extension_Scale9Sprite_createWithSpriteFrame'.",&tolua_err); -#endif - return 0; -} -int lua_cocos2dx_extension_Scale9Sprite_constructor(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::extension::Scale9Sprite* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - - - argc = lua_gettop(tolua_S)-1; - if (argc == 0) - { - if(!ok) - return 0; - cobj = new cocos2d::extension::Scale9Sprite(); - cobj->autorelease(); - int ID = (int)cobj->_ID ; - int* luaID = &cobj->_luaID ; - toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.Scale9Sprite"); - return 1; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "cc.Scale9Sprite:Scale9Sprite",argc, 0); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_extension_Scale9Sprite_constructor'.",&tolua_err); -#endif - - return 0; -} - -static int lua_cocos2dx_extension_Scale9Sprite_finalize(lua_State* tolua_S) -{ - printf("luabindings: finalizing LUA object (Scale9Sprite)"); - return 0; -} - -int lua_register_cocos2dx_extension_Scale9Sprite(lua_State* tolua_S) -{ - tolua_usertype(tolua_S,"cc.Scale9Sprite"); - tolua_cclass(tolua_S,"Scale9Sprite","cc.Scale9Sprite","cc.Node",nullptr); - - tolua_beginmodule(tolua_S,"Scale9Sprite"); - tolua_function(tolua_S,"new",lua_cocos2dx_extension_Scale9Sprite_constructor); - tolua_function(tolua_S,"resizableSpriteWithCapInsets",lua_cocos2dx_extension_Scale9Sprite_resizableSpriteWithCapInsets); - tolua_function(tolua_S,"setInsetBottom",lua_cocos2dx_extension_Scale9Sprite_setInsetBottom); - tolua_function(tolua_S,"initWithSpriteFrameName",lua_cocos2dx_extension_Scale9Sprite_initWithSpriteFrameName); - tolua_function(tolua_S,"setInsetTop",lua_cocos2dx_extension_Scale9Sprite_setInsetTop); - tolua_function(tolua_S,"init",lua_cocos2dx_extension_Scale9Sprite_init); - tolua_function(tolua_S,"setPreferredSize",lua_cocos2dx_extension_Scale9Sprite_setPreferredSize); - tolua_function(tolua_S,"setSpriteFrame",lua_cocos2dx_extension_Scale9Sprite_setSpriteFrame); - tolua_function(tolua_S,"initWithBatchNode",lua_cocos2dx_extension_Scale9Sprite_initWithBatchNode); - tolua_function(tolua_S,"getInsetBottom",lua_cocos2dx_extension_Scale9Sprite_getInsetBottom); - tolua_function(tolua_S,"getCapInsets",lua_cocos2dx_extension_Scale9Sprite_getCapInsets); - tolua_function(tolua_S,"updateWithBatchNode",lua_cocos2dx_extension_Scale9Sprite_updateWithBatchNode); - tolua_function(tolua_S,"getInsetRight",lua_cocos2dx_extension_Scale9Sprite_getInsetRight); - tolua_function(tolua_S,"getOriginalSize",lua_cocos2dx_extension_Scale9Sprite_getOriginalSize); - tolua_function(tolua_S,"initWithFile",lua_cocos2dx_extension_Scale9Sprite_initWithFile); - tolua_function(tolua_S,"getInsetTop",lua_cocos2dx_extension_Scale9Sprite_getInsetTop); - tolua_function(tolua_S,"setInsetLeft",lua_cocos2dx_extension_Scale9Sprite_setInsetLeft); - tolua_function(tolua_S,"initWithSpriteFrame",lua_cocos2dx_extension_Scale9Sprite_initWithSpriteFrame); - tolua_function(tolua_S,"getPreferredSize",lua_cocos2dx_extension_Scale9Sprite_getPreferredSize); - tolua_function(tolua_S,"setCapInsets",lua_cocos2dx_extension_Scale9Sprite_setCapInsets); - tolua_function(tolua_S,"getInsetLeft",lua_cocos2dx_extension_Scale9Sprite_getInsetLeft); - tolua_function(tolua_S,"setInsetRight",lua_cocos2dx_extension_Scale9Sprite_setInsetRight); - tolua_function(tolua_S,"create", lua_cocos2dx_extension_Scale9Sprite_create); - tolua_function(tolua_S,"createWithSpriteFrameName", lua_cocos2dx_extension_Scale9Sprite_createWithSpriteFrameName); - tolua_function(tolua_S,"createWithSpriteFrame", lua_cocos2dx_extension_Scale9Sprite_createWithSpriteFrame); - tolua_endmodule(tolua_S); - std::string typeName = typeid(cocos2d::extension::Scale9Sprite).name(); - g_luaType[typeName] = "cc.Scale9Sprite"; - g_typeCast["Scale9Sprite"] = "cc.Scale9Sprite"; - return 1; -} - int lua_cocos2dx_extension_Control_setEnabled(lua_State* tolua_S) { int argc = 0; @@ -2927,8 +1586,8 @@ int lua_cocos2dx_extension_ControlButton_getBackgroundSpriteForState(lua_State* ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.ControlButton:getBackgroundSpriteForState"); if(!ok) return 0; - cocos2d::extension::Scale9Sprite* ret = cobj->getBackgroundSpriteForState(arg0); - object_to_luaval(tolua_S, "cc.Scale9Sprite",(cocos2d::extension::Scale9Sprite*)ret); + cocos2d::ui::Scale9Sprite* ret = cobj->getBackgroundSpriteForState(arg0); + object_to_luaval(tolua_S, "ccui.Scale9Sprite",(cocos2d::ui::Scale9Sprite*)ret); return 1; } CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "cc.ControlButton:getBackgroundSpriteForState",argc, 1); @@ -3196,8 +1855,8 @@ int lua_cocos2dx_extension_ControlButton_getBackgroundSprite(lua_State* tolua_S) { if(!ok) return 0; - cocos2d::extension::Scale9Sprite* ret = cobj->getBackgroundSprite(); - object_to_luaval(tolua_S, "cc.Scale9Sprite",(cocos2d::extension::Scale9Sprite*)ret); + cocos2d::ui::Scale9Sprite* ret = cobj->getBackgroundSprite(); + object_to_luaval(tolua_S, "ccui.Scale9Sprite",(cocos2d::ui::Scale9Sprite*)ret); return 1; } CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "cc.ControlButton:getBackgroundSprite",argc, 0); @@ -3427,10 +2086,10 @@ int lua_cocos2dx_extension_ControlButton_setBackgroundSpriteForState(lua_State* argc = lua_gettop(tolua_S)-1; if (argc == 2) { - cocos2d::extension::Scale9Sprite* arg0; + cocos2d::ui::Scale9Sprite* arg0; cocos2d::extension::Control::State arg1; - ok &= luaval_to_object(tolua_S, 2, "cc.Scale9Sprite",&arg0); + ok &= luaval_to_object(tolua_S, 2, "ccui.Scale9Sprite",&arg0); ok &= luaval_to_int32(tolua_S, 3,(int *)&arg1, "cc.ControlButton:setBackgroundSpriteForState"); if(!ok) @@ -3522,9 +2181,9 @@ int lua_cocos2dx_extension_ControlButton_setBackgroundSprite(lua_State* tolua_S) argc = lua_gettop(tolua_S)-1; if (argc == 1) { - cocos2d::extension::Scale9Sprite* arg0; + cocos2d::ui::Scale9Sprite* arg0; - ok &= luaval_to_object(tolua_S, 2, "cc.Scale9Sprite",&arg0); + ok &= luaval_to_object(tolua_S, 2, "ccui.Scale9Sprite",&arg0); if(!ok) return 0; cobj->setBackgroundSprite(arg0); @@ -3973,8 +2632,8 @@ int lua_cocos2dx_extension_ControlButton_create(lua_State* tolua_S) { if (argc == 1) { - cocos2d::extension::Scale9Sprite* arg0; - ok &= luaval_to_object(tolua_S, 2, "cc.Scale9Sprite",&arg0); + cocos2d::ui::Scale9Sprite* arg0; + ok &= luaval_to_object(tolua_S, 2, "ccui.Scale9Sprite",&arg0); if (!ok) { break; } cocos2d::extension::ControlButton* ret = cocos2d::extension::ControlButton::create(arg0); object_to_luaval(tolua_S, "cc.ControlButton",(cocos2d::extension::ControlButton*)ret); @@ -3999,8 +2658,8 @@ int lua_cocos2dx_extension_ControlButton_create(lua_State* tolua_S) cocos2d::Node* arg0; ok &= luaval_to_object(tolua_S, 2, "cc.Node",&arg0); if (!ok) { break; } - cocos2d::extension::Scale9Sprite* arg1; - ok &= luaval_to_object(tolua_S, 3, "cc.Scale9Sprite",&arg1); + cocos2d::ui::Scale9Sprite* arg1; + ok &= luaval_to_object(tolua_S, 3, "ccui.Scale9Sprite",&arg1); if (!ok) { break; } cocos2d::extension::ControlButton* ret = cocos2d::extension::ControlButton::create(arg0, arg1); object_to_luaval(tolua_S, "cc.ControlButton",(cocos2d::extension::ControlButton*)ret); @@ -12160,976 +10819,6 @@ int lua_register_cocos2dx_extension_TableView(lua_State* tolua_S) return 1; } -int lua_cocos2dx_extension_EditBox_getText(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::extension::EditBox* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.EditBox",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::extension::EditBox*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_extension_EditBox_getText'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 0) - { - if(!ok) - return 0; - const char* ret = cobj->getText(); - tolua_pushstring(tolua_S,(const char*)ret); - return 1; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "cc.EditBox:getText",argc, 0); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_extension_EditBox_getText'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_extension_EditBox_setPlaceholderFontName(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::extension::EditBox* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.EditBox",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::extension::EditBox*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_extension_EditBox_setPlaceholderFontName'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 1) - { - const char* arg0; - - std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.EditBox:setPlaceholderFontName"); arg0 = arg0_tmp.c_str(); - if(!ok) - return 0; - cobj->setPlaceholderFontName(arg0); - return 0; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "cc.EditBox:setPlaceholderFontName",argc, 1); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_extension_EditBox_setPlaceholderFontName'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_extension_EditBox_getPlaceHolder(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::extension::EditBox* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.EditBox",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::extension::EditBox*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_extension_EditBox_getPlaceHolder'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 0) - { - if(!ok) - return 0; - const char* ret = cobj->getPlaceHolder(); - tolua_pushstring(tolua_S,(const char*)ret); - return 1; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "cc.EditBox:getPlaceHolder",argc, 0); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_extension_EditBox_getPlaceHolder'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_extension_EditBox_setFontName(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::extension::EditBox* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.EditBox",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::extension::EditBox*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_extension_EditBox_setFontName'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 1) - { - const char* arg0; - - std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.EditBox:setFontName"); arg0 = arg0_tmp.c_str(); - if(!ok) - return 0; - cobj->setFontName(arg0); - return 0; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "cc.EditBox:setFontName",argc, 1); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_extension_EditBox_setFontName'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_extension_EditBox_setPlaceholderFontSize(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::extension::EditBox* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.EditBox",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::extension::EditBox*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_extension_EditBox_setPlaceholderFontSize'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 1) - { - int arg0; - - ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.EditBox:setPlaceholderFontSize"); - if(!ok) - return 0; - cobj->setPlaceholderFontSize(arg0); - return 0; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "cc.EditBox:setPlaceholderFontSize",argc, 1); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_extension_EditBox_setPlaceholderFontSize'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_extension_EditBox_setInputMode(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::extension::EditBox* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.EditBox",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::extension::EditBox*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_extension_EditBox_setInputMode'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 1) - { - cocos2d::extension::EditBox::InputMode arg0; - - ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.EditBox:setInputMode"); - if(!ok) - return 0; - cobj->setInputMode(arg0); - return 0; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "cc.EditBox:setInputMode",argc, 1); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_extension_EditBox_setInputMode'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_extension_EditBox_setPlaceholderFontColor(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::extension::EditBox* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.EditBox",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::extension::EditBox*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_extension_EditBox_setPlaceholderFontColor'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 1) - { - cocos2d::Color3B arg0; - - ok &= luaval_to_color3b(tolua_S, 2, &arg0, "cc.EditBox:setPlaceholderFontColor"); - if(!ok) - return 0; - cobj->setPlaceholderFontColor(arg0); - return 0; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "cc.EditBox:setPlaceholderFontColor",argc, 1); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_extension_EditBox_setPlaceholderFontColor'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_extension_EditBox_setFontColor(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::extension::EditBox* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.EditBox",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::extension::EditBox*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_extension_EditBox_setFontColor'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 1) - { - cocos2d::Color3B arg0; - - ok &= luaval_to_color3b(tolua_S, 2, &arg0, "cc.EditBox:setFontColor"); - if(!ok) - return 0; - cobj->setFontColor(arg0); - return 0; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "cc.EditBox:setFontColor",argc, 1); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_extension_EditBox_setFontColor'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_extension_EditBox_setPlaceholderFont(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::extension::EditBox* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.EditBox",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::extension::EditBox*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_extension_EditBox_setPlaceholderFont'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 2) - { - const char* arg0; - int arg1; - - std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.EditBox:setPlaceholderFont"); arg0 = arg0_tmp.c_str(); - - ok &= luaval_to_int32(tolua_S, 3,(int *)&arg1, "cc.EditBox:setPlaceholderFont"); - if(!ok) - return 0; - cobj->setPlaceholderFont(arg0, arg1); - return 0; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "cc.EditBox:setPlaceholderFont",argc, 2); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_extension_EditBox_setPlaceholderFont'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_extension_EditBox_setFontSize(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::extension::EditBox* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.EditBox",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::extension::EditBox*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_extension_EditBox_setFontSize'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 1) - { - int arg0; - - ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.EditBox:setFontSize"); - if(!ok) - return 0; - cobj->setFontSize(arg0); - return 0; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "cc.EditBox:setFontSize",argc, 1); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_extension_EditBox_setFontSize'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_extension_EditBox_initWithSizeAndBackgroundSprite(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::extension::EditBox* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.EditBox",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::extension::EditBox*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_extension_EditBox_initWithSizeAndBackgroundSprite'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 2) - { - cocos2d::Size arg0; - cocos2d::extension::Scale9Sprite* arg1; - - ok &= luaval_to_size(tolua_S, 2, &arg0, "cc.EditBox:initWithSizeAndBackgroundSprite"); - - ok &= luaval_to_object(tolua_S, 3, "cc.Scale9Sprite",&arg1); - if(!ok) - return 0; - bool ret = cobj->initWithSizeAndBackgroundSprite(arg0, arg1); - tolua_pushboolean(tolua_S,(bool)ret); - return 1; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "cc.EditBox:initWithSizeAndBackgroundSprite",argc, 2); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_extension_EditBox_initWithSizeAndBackgroundSprite'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_extension_EditBox_setPlaceHolder(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::extension::EditBox* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.EditBox",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::extension::EditBox*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_extension_EditBox_setPlaceHolder'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 1) - { - const char* arg0; - - std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.EditBox:setPlaceHolder"); arg0 = arg0_tmp.c_str(); - if(!ok) - return 0; - cobj->setPlaceHolder(arg0); - return 0; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "cc.EditBox:setPlaceHolder",argc, 1); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_extension_EditBox_setPlaceHolder'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_extension_EditBox_setReturnType(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::extension::EditBox* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.EditBox",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::extension::EditBox*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_extension_EditBox_setReturnType'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 1) - { - cocos2d::extension::EditBox::KeyboardReturnType arg0; - - ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.EditBox:setReturnType"); - if(!ok) - return 0; - cobj->setReturnType(arg0); - return 0; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "cc.EditBox:setReturnType",argc, 1); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_extension_EditBox_setReturnType'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_extension_EditBox_setInputFlag(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::extension::EditBox* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.EditBox",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::extension::EditBox*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_extension_EditBox_setInputFlag'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 1) - { - cocos2d::extension::EditBox::InputFlag arg0; - - ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.EditBox:setInputFlag"); - if(!ok) - return 0; - cobj->setInputFlag(arg0); - return 0; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "cc.EditBox:setInputFlag",argc, 1); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_extension_EditBox_setInputFlag'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_extension_EditBox_getMaxLength(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::extension::EditBox* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.EditBox",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::extension::EditBox*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_extension_EditBox_getMaxLength'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 0) - { - if(!ok) - return 0; - int ret = cobj->getMaxLength(); - tolua_pushnumber(tolua_S,(lua_Number)ret); - return 1; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "cc.EditBox:getMaxLength",argc, 0); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_extension_EditBox_getMaxLength'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_extension_EditBox_setText(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::extension::EditBox* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.EditBox",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::extension::EditBox*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_extension_EditBox_setText'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 1) - { - const char* arg0; - - std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.EditBox:setText"); arg0 = arg0_tmp.c_str(); - if(!ok) - return 0; - cobj->setText(arg0); - return 0; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "cc.EditBox:setText",argc, 1); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_extension_EditBox_setText'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_extension_EditBox_setMaxLength(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::extension::EditBox* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.EditBox",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::extension::EditBox*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_extension_EditBox_setMaxLength'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 1) - { - int arg0; - - ok &= luaval_to_int32(tolua_S, 2,(int *)&arg0, "cc.EditBox:setMaxLength"); - if(!ok) - return 0; - cobj->setMaxLength(arg0); - return 0; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "cc.EditBox:setMaxLength",argc, 1); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_extension_EditBox_setMaxLength'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_extension_EditBox_setFont(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::extension::EditBox* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - -#if COCOS2D_DEBUG >= 1 - if (!tolua_isusertype(tolua_S,1,"cc.EditBox",0,&tolua_err)) goto tolua_lerror; -#endif - - cobj = (cocos2d::extension::EditBox*)tolua_tousertype(tolua_S,1,0); - -#if COCOS2D_DEBUG >= 1 - if (!cobj) - { - tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_extension_EditBox_setFont'", nullptr); - return 0; - } -#endif - - argc = lua_gettop(tolua_S)-1; - if (argc == 2) - { - const char* arg0; - int arg1; - - std::string arg0_tmp; ok &= luaval_to_std_string(tolua_S, 2, &arg0_tmp, "cc.EditBox:setFont"); arg0 = arg0_tmp.c_str(); - - ok &= luaval_to_int32(tolua_S, 3,(int *)&arg1, "cc.EditBox:setFont"); - if(!ok) - return 0; - cobj->setFont(arg0, arg1); - return 0; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "cc.EditBox:setFont",argc, 2); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_extension_EditBox_setFont'.",&tolua_err); -#endif - - return 0; -} -int lua_cocos2dx_extension_EditBox_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,1,"cc.EditBox",0,&tolua_err)) goto tolua_lerror; -#endif - - argc = lua_gettop(tolua_S) - 1; - - if (argc == 2) - { - cocos2d::Size arg0; - cocos2d::extension::Scale9Sprite* arg1; - ok &= luaval_to_size(tolua_S, 2, &arg0, "cc.EditBox:create"); - ok &= luaval_to_object(tolua_S, 3, "cc.Scale9Sprite",&arg1); - if(!ok) - return 0; - cocos2d::extension::EditBox* ret = cocos2d::extension::EditBox::create(arg0, arg1); - object_to_luaval(tolua_S, "cc.EditBox",(cocos2d::extension::EditBox*)ret); - return 1; - } - if (argc == 3) - { - cocos2d::Size arg0; - cocos2d::extension::Scale9Sprite* arg1; - cocos2d::extension::Scale9Sprite* arg2; - ok &= luaval_to_size(tolua_S, 2, &arg0, "cc.EditBox:create"); - ok &= luaval_to_object(tolua_S, 3, "cc.Scale9Sprite",&arg1); - ok &= luaval_to_object(tolua_S, 4, "cc.Scale9Sprite",&arg2); - if(!ok) - return 0; - cocos2d::extension::EditBox* ret = cocos2d::extension::EditBox::create(arg0, arg1, arg2); - object_to_luaval(tolua_S, "cc.EditBox",(cocos2d::extension::EditBox*)ret); - return 1; - } - if (argc == 4) - { - cocos2d::Size arg0; - cocos2d::extension::Scale9Sprite* arg1; - cocos2d::extension::Scale9Sprite* arg2; - cocos2d::extension::Scale9Sprite* arg3; - ok &= luaval_to_size(tolua_S, 2, &arg0, "cc.EditBox:create"); - ok &= luaval_to_object(tolua_S, 3, "cc.Scale9Sprite",&arg1); - ok &= luaval_to_object(tolua_S, 4, "cc.Scale9Sprite",&arg2); - ok &= luaval_to_object(tolua_S, 5, "cc.Scale9Sprite",&arg3); - if(!ok) - return 0; - cocos2d::extension::EditBox* ret = cocos2d::extension::EditBox::create(arg0, arg1, arg2, arg3); - object_to_luaval(tolua_S, "cc.EditBox",(cocos2d::extension::EditBox*)ret); - return 1; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d\n ", "cc.EditBox:create",argc, 2); - return 0; -#if COCOS2D_DEBUG >= 1 - tolua_lerror: - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_extension_EditBox_create'.",&tolua_err); -#endif - return 0; -} -int lua_cocos2dx_extension_EditBox_constructor(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::extension::EditBox* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - - - argc = lua_gettop(tolua_S)-1; - if (argc == 0) - { - if(!ok) - return 0; - cobj = new cocos2d::extension::EditBox(); - cobj->autorelease(); - int ID = (int)cobj->_ID ; - int* luaID = &cobj->_luaID ; - toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.EditBox"); - return 1; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "cc.EditBox:EditBox",argc, 0); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_extension_EditBox_constructor'.",&tolua_err); -#endif - - return 0; -} - -static int lua_cocos2dx_extension_EditBox_finalize(lua_State* tolua_S) -{ - printf("luabindings: finalizing LUA object (EditBox)"); - return 0; -} - -int lua_register_cocos2dx_extension_EditBox(lua_State* tolua_S) -{ - tolua_usertype(tolua_S,"cc.EditBox"); - tolua_cclass(tolua_S,"EditBox","cc.EditBox","cc.ControlButton",nullptr); - - tolua_beginmodule(tolua_S,"EditBox"); - tolua_function(tolua_S,"new",lua_cocos2dx_extension_EditBox_constructor); - tolua_function(tolua_S,"getText",lua_cocos2dx_extension_EditBox_getText); - tolua_function(tolua_S,"setPlaceholderFontName",lua_cocos2dx_extension_EditBox_setPlaceholderFontName); - tolua_function(tolua_S,"getPlaceHolder",lua_cocos2dx_extension_EditBox_getPlaceHolder); - tolua_function(tolua_S,"setFontName",lua_cocos2dx_extension_EditBox_setFontName); - tolua_function(tolua_S,"setPlaceholderFontSize",lua_cocos2dx_extension_EditBox_setPlaceholderFontSize); - tolua_function(tolua_S,"setInputMode",lua_cocos2dx_extension_EditBox_setInputMode); - tolua_function(tolua_S,"setPlaceholderFontColor",lua_cocos2dx_extension_EditBox_setPlaceholderFontColor); - tolua_function(tolua_S,"setFontColor",lua_cocos2dx_extension_EditBox_setFontColor); - tolua_function(tolua_S,"setPlaceholderFont",lua_cocos2dx_extension_EditBox_setPlaceholderFont); - tolua_function(tolua_S,"setFontSize",lua_cocos2dx_extension_EditBox_setFontSize); - tolua_function(tolua_S,"initWithSizeAndBackgroundSprite",lua_cocos2dx_extension_EditBox_initWithSizeAndBackgroundSprite); - tolua_function(tolua_S,"setPlaceHolder",lua_cocos2dx_extension_EditBox_setPlaceHolder); - tolua_function(tolua_S,"setReturnType",lua_cocos2dx_extension_EditBox_setReturnType); - tolua_function(tolua_S,"setInputFlag",lua_cocos2dx_extension_EditBox_setInputFlag); - tolua_function(tolua_S,"getMaxLength",lua_cocos2dx_extension_EditBox_getMaxLength); - tolua_function(tolua_S,"setText",lua_cocos2dx_extension_EditBox_setText); - tolua_function(tolua_S,"setMaxLength",lua_cocos2dx_extension_EditBox_setMaxLength); - tolua_function(tolua_S,"setFont",lua_cocos2dx_extension_EditBox_setFont); - tolua_function(tolua_S,"create", lua_cocos2dx_extension_EditBox_create); - tolua_endmodule(tolua_S); - std::string typeName = typeid(cocos2d::extension::EditBox).name(); - g_luaType[typeName] = "cc.EditBox"; - g_typeCast["EditBox"] = "cc.EditBox"; - return 1; -} - int lua_cocos2dx_extension_AssetsManager_setStoragePath(lua_State* tolua_S) { int argc = 0; @@ -13845,19 +11534,17 @@ TOLUA_API int register_all_cocos2dx_extension(lua_State* tolua_S) lua_register_cocos2dx_extension_Control(tolua_S); lua_register_cocos2dx_extension_TableViewCell(tolua_S); - lua_register_cocos2dx_extension_Scale9Sprite(tolua_S); + lua_register_cocos2dx_extension_ControlStepper(tolua_S); lua_register_cocos2dx_extension_ControlSwitch(tolua_S); lua_register_cocos2dx_extension_ScrollView(tolua_S); lua_register_cocos2dx_extension_TableView(tolua_S); - lua_register_cocos2dx_extension_AssetsManager(tolua_S); - lua_register_cocos2dx_extension_ControlButton(tolua_S); - lua_register_cocos2dx_extension_EditBox(tolua_S); lua_register_cocos2dx_extension_ControlSlider(tolua_S); - lua_register_cocos2dx_extension_ControlStepper(tolua_S); lua_register_cocos2dx_extension_ControlSaturationBrightnessPicker(tolua_S); lua_register_cocos2dx_extension_ControlColourPicker(tolua_S); lua_register_cocos2dx_extension_ControlPotentiometer(tolua_S); + lua_register_cocos2dx_extension_ControlButton(tolua_S); lua_register_cocos2dx_extension_ControlHuePicker(tolua_S); + lua_register_cocos2dx_extension_AssetsManager(tolua_S); tolua_endmodule(tolua_S); return 1; diff --git a/cocos/scripting/lua-bindings/auto/lua_cocos2dx_extension_auto.hpp b/cocos/scripting/lua-bindings/auto/lua_cocos2dx_extension_auto.hpp index ce1bfeebc3..cbd41e6a6b 100644 --- a/cocos/scripting/lua-bindings/auto/lua_cocos2dx_extension_auto.hpp +++ b/cocos/scripting/lua-bindings/auto/lua_cocos2dx_extension_auto.hpp @@ -243,53 +243,6 @@ int register_all_cocos2dx_extension(lua_State* tolua_S); - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/cocos/scripting/lua-bindings/auto/lua_cocos2dx_spine_auto.cpp b/cocos/scripting/lua-bindings/auto/lua_cocos2dx_spine_auto.cpp index e9a0cc19d0..8d94bee826 100644 --- a/cocos/scripting/lua-bindings/auto/lua_cocos2dx_spine_auto.cpp +++ b/cocos/scripting/lua-bindings/auto/lua_cocos2dx_spine_auto.cpp @@ -78,7 +78,8 @@ int lua_cocos2dx_spine_Skeleton_setBlendFunc(lua_State* tolua_S) { cocos2d::BlendFunc arg0; - #pragma warning NO CONVERSION TO NATIVE FOR BlendFunc; + #pragma warning NO CONVERSION TO NATIVE FOR BlendFunc + ok = false; if(!ok) return 0; cobj->setBlendFunc(arg0); diff --git a/cocos/scripting/lua-bindings/manual/LuaBasicConversions.cpp b/cocos/scripting/lua-bindings/manual/LuaBasicConversions.cpp index da15b71819..e8da5290ee 100644 --- a/cocos/scripting/lua-bindings/manual/LuaBasicConversions.cpp +++ b/cocos/scripting/lua-bindings/manual/LuaBasicConversions.cpp @@ -1995,23 +1995,23 @@ void vec3_to_luaval(lua_State* L,const cocos2d::Vec3& vec3) lua_rawset(L, -3); } -void vec4_to_luaval(lua_State* L,const cocos2d::Vec4& vec3) +void vec4_to_luaval(lua_State* L,const cocos2d::Vec4& vec4) { if (NULL == L) return; lua_newtable(L); /* L: table */ lua_pushstring(L, "x"); /* L: table key */ - lua_pushnumber(L, (lua_Number) vec3.x); /* L: table key value*/ + lua_pushnumber(L, (lua_Number) vec4.x); /* L: table key value*/ lua_rawset(L, -3); /* table[key] = value, L: table */ lua_pushstring(L, "y"); /* L: table key */ - lua_pushnumber(L, (lua_Number) vec3.y); /* L: table key value*/ + lua_pushnumber(L, (lua_Number) vec4.y); /* L: table key value*/ lua_rawset(L, -3); lua_pushstring(L, "z"); /* L: table key */ - lua_pushnumber(L, (lua_Number) vec3.z); /* L: table key value*/ + lua_pushnumber(L, (lua_Number) vec4.z); /* L: table key value*/ lua_rawset(L, -3); lua_pushstring(L, "w"); /* L: table key */ - lua_pushnumber(L, (lua_Number) vec3.z); /* L: table key value*/ + lua_pushnumber(L, (lua_Number) vec4.w); /* L: table key value*/ lua_rawset(L, -3); } diff --git a/cocos/scripting/lua-bindings/manual/LuaBasicConversions.h b/cocos/scripting/lua-bindings/manual/LuaBasicConversions.h index 2d07f4a2f2..6626ecad1c 100644 --- a/cocos/scripting/lua-bindings/manual/LuaBasicConversions.h +++ b/cocos/scripting/lua-bindings/manual/LuaBasicConversions.h @@ -240,7 +240,7 @@ extern bool luaval_to_std_vector_ushort(lua_State* L, int lo, std::vectorv110 v110_xp v120 - v120_xp + v110_xp StaticLibrary @@ -217,7 +217,7 @@ v110 v110_xp v120 - v120_xp + v110_xp diff --git a/cocos/ui/Android.mk b/cocos/ui/Android.mk index 221315e578..a76af6d91a 100644 --- a/cocos/ui/Android.mk +++ b/cocos/ui/Android.mk @@ -33,6 +33,9 @@ UIDeprecated.cpp \ UIScale9Sprite.cpp \ UIWebView.cpp \ UIWebViewImpl_android.cpp \ +UIEditBox/UIEditBox.cpp \ +UIEditBox/UIEditBoxImplAndroid.cpp \ + LOCAL_EXPORT_C_INCLUDES := $(LOCAL_PATH)/.. \ $(LOCAL_PATH)/../editor-support diff --git a/cocos/ui/CocosGUI.h b/cocos/ui/CocosGUI.h index 04ce980bd5..5d12b2186e 100644 --- a/cocos/ui/CocosGUI.h +++ b/cocos/ui/CocosGUI.h @@ -52,7 +52,7 @@ THE SOFTWARE. #include "ui/UIDeprecated.h" #include "ui/GUIExport.h" #include "ui/UIScale9Sprite.h" - +#include "ui/UIEditBox/UIEditBox.h" NS_CC_BEGIN namespace ui { diff --git a/extensions/GUI/CCEditBox/CCEditBox.cpp b/cocos/ui/UIEditBox/UIEditBox.cpp similarity index 75% rename from extensions/GUI/CCEditBox/CCEditBox.cpp rename to cocos/ui/UIEditBox/UIEditBox.cpp index bbb42be42d..27e4ccc95b 100644 --- a/extensions/GUI/CCEditBox/CCEditBox.cpp +++ b/cocos/ui/UIEditBox/UIEditBox.cpp @@ -23,10 +23,12 @@ THE SOFTWARE. ****************************************************************************/ -#include "CCEditBox.h" -#include "CCEditBoxImpl.h" +#include "UIEditBox.h" +#include "UIEditBoxImpl.h" -NS_CC_EXT_BEGIN +NS_CC_BEGIN + +namespace ui { static const float CHECK_EDITBOX_POSITION_INTERVAL = 0.1f; @@ -42,6 +44,7 @@ EditBox::EditBox(void) , _colPlaceHolder(Color3B::GRAY) , _maxLength(0) , _adjustHeight(0.0f) +, _backgroundSprite(nullptr) #if CC_ENABLE_SCRIPT_BINDING , _scriptEditBoxHandler(0) #endif @@ -57,26 +60,21 @@ EditBox::~EditBox(void) } -void EditBox::touchDownAction(Ref *sender, Control::EventType controlEvent) +void EditBox::touchDownAction(Ref *sender, TouchEventType controlEvent) { - _editBoxImpl->openKeyboard(); + if (controlEvent == Widget::TouchEventType::ENDED) { + _editBoxImpl->openKeyboard(); + } } -EditBox* EditBox::create(const Size& size, Scale9Sprite* pNormal9SpriteBg, Scale9Sprite* pPressed9SpriteBg/* = nullptr*/, Scale9Sprite* pDisabled9SpriteBg/* = nullptr*/) +EditBox* EditBox::create(const Size& size, + const std::string& normalSprite, + TextureResType texType /*= TextureResType::LOCAL*/) { - EditBox* pRet = new (std::nothrow) EditBox(); + EditBox* pRet = new EditBox(); - if (pRet != nullptr && pRet->initWithSizeAndBackgroundSprite(size, pNormal9SpriteBg)) + if (pRet != nullptr && pRet->initWithSizeAndBackgroundSprite(size, normalSprite, texType)) { - if (pPressed9SpriteBg != nullptr) - { - pRet->setBackgroundSpriteForState(pPressed9SpriteBg, Control::State::HIGH_LIGHTED); - } - - if (pDisabled9SpriteBg != nullptr) - { - pRet->setBackgroundSpriteForState(pDisabled9SpriteBg, Control::State::DISABLED); - } pRet->autorelease(); } else @@ -86,19 +84,79 @@ EditBox* EditBox::create(const Size& size, Scale9Sprite* pNormal9SpriteBg, Scale return pRet; } - -bool EditBox::initWithSizeAndBackgroundSprite(const Size& size, Scale9Sprite* pPressed9SpriteBg) + + +EditBox* EditBox::create(const cocos2d::Size &size, cocos2d::ui::Scale9Sprite *normalSprite, ui::Scale9Sprite *pressedSprite, Scale9Sprite* disabledSprite) { - if (ControlButton::initWithBackgroundSprite(pPressed9SpriteBg)) + EditBox* pRet = new (std::nothrow) EditBox(); + + if (pRet != nullptr && pRet->initWithSizeAndBackgroundSprite(size, normalSprite)) + { + pRet->autorelease(); + } + else + { + CC_SAFE_DELETE(pRet); + } + + return pRet; +} + +bool EditBox::initWithSizeAndBackgroundSprite(const cocos2d::Size &size, cocos2d::ui::Scale9Sprite *pNormal9SpriteBg) +{ + if (Widget::init()) { _editBoxImpl = __createSystemEditBox(this); _editBoxImpl->initWithSize(size); _editBoxImpl->setInputMode(EditBox::InputMode::ANY); - this->setZoomOnTouchDown(false); - this->setPreferredSize(size); + _backgroundSprite = pNormal9SpriteBg; + + this->setContentSize(size); this->setPosition(Vec2(0, 0)); - this->addTargetWithActionForControlEvent(this, cccontrol_selector(EditBox::touchDownAction), Control::EventType::TOUCH_UP_INSIDE); + + _backgroundSprite->setPosition(Vec2(_contentSize.width/2, _contentSize.height/2)); + _backgroundSprite->setContentSize(size); + this->addProtectedChild(_backgroundSprite); + + this->setTouchEnabled(true); + + this->addTouchEventListener(CC_CALLBACK_2(EditBox::touchDownAction, this)); + + return true; + } + return false; +} + + +bool EditBox::initWithSizeAndBackgroundSprite(const Size& size, + const std::string& pNormal9SpriteBg, + TextureResType texType) +{ + if (Widget::init()) + { + _editBoxImpl = __createSystemEditBox(this); + _editBoxImpl->initWithSize(size); + _editBoxImpl->setInputMode(EditBox::InputMode::ANY); + + if (texType == Widget::TextureResType::LOCAL) + { + _backgroundSprite = Scale9Sprite::create(pNormal9SpriteBg); + } + else + { + _backgroundSprite = Scale9Sprite::createWithSpriteFrameName(pNormal9SpriteBg); + } + this->setContentSize(size); + this->setPosition(Vec2(0, 0)); + + _backgroundSprite->setPosition(Vec2(_contentSize.width/2, _contentSize.height/2)); + _backgroundSprite->setContentSize(size); + this->addProtectedChild(_backgroundSprite); + + this->setTouchEnabled(true); + + this->addTouchEventListener(CC_CALLBACK_2(EditBox::touchDownAction, this)); return true; } @@ -284,7 +342,7 @@ void EditBox::setReturnType(EditBox::KeyboardReturnType returnType) /* override function */ void EditBox::setPosition(const Vec2& pos) { - ControlButton::setPosition(pos); + Widget::setPosition(pos); if (_editBoxImpl != nullptr) { _editBoxImpl->setPosition(pos); @@ -293,7 +351,7 @@ void EditBox::setPosition(const Vec2& pos) void EditBox::setVisible(bool visible) { - ControlButton::setVisible(visible); + Widget::setVisible(visible); if (_editBoxImpl != nullptr) { _editBoxImpl->setVisible(visible); @@ -302,16 +360,25 @@ void EditBox::setVisible(bool visible) void EditBox::setContentSize(const Size& size) { - ControlButton::setContentSize(size); + Widget::setContentSize(size); if (_editBoxImpl != nullptr) { _editBoxImpl->setContentSize(size); } } + +void EditBox::adaptRenderers() +{ + if (_contentSizeDirty) + { + _backgroundSprite->setContentSize(_contentSize); + _backgroundSprite->setPosition(Vec2(_contentSize.width/2, _contentSize.height/2)); + } +} void EditBox::setAnchorPoint(const Vec2& anchorPoint) { - ControlButton::setAnchorPoint(anchorPoint); + Widget::setAnchorPoint(anchorPoint); if (_editBoxImpl != nullptr) { _editBoxImpl->setAnchorPoint(anchorPoint); @@ -320,7 +387,7 @@ void EditBox::setAnchorPoint(const Vec2& anchorPoint) void EditBox::visit(Renderer *renderer, const Mat4 &parentTransform, uint32_t parentFlags) { - ControlButton::visit(renderer, parentTransform, parentFlags); + Widget::visit(renderer, parentTransform, parentFlags); if (_editBoxImpl != nullptr) { _editBoxImpl->visit(); @@ -337,7 +404,7 @@ void EditBox::onEnter(void) } #endif - ControlButton::onEnter(); + Widget::onEnter(); if (_editBoxImpl != nullptr) { _editBoxImpl->onEnter(); @@ -357,7 +424,7 @@ void EditBox::updatePosition(float dt) void EditBox::onExit(void) { - ControlButton::onExit(); + Widget::onExit(); if (_editBoxImpl != nullptr) { // remove system edit control @@ -432,4 +499,6 @@ void EditBox::unregisterScriptEditBoxHandler(void) } #endif -NS_CC_EXT_END +} + +NS_CC_END diff --git a/cocos/ui/UIEditBox/UIEditBox.h b/cocos/ui/UIEditBox/UIEditBox.h new file mode 100644 index 0000000000..72af4a2627 --- /dev/null +++ b/cocos/ui/UIEditBox/UIEditBox.h @@ -0,0 +1,474 @@ +/**************************************************************************** + Copyright (c) 2010-2012 cocos2d-x.org + Copyright (c) 2012 James Chen + + http://www.cocos2d-x.org + + Permission is hereby granted, free of charge, to any person obtaining a copy + of this software and associated documentation files (the "Software"), to deal + in the Software without restriction, including without limitation the rights + to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + copies of the Software, and to permit persons to whom the Software is + furnished to do so, subject to the following conditions: + + The above copyright notice and this permission notice shall be included in + all copies or substantial portions of the Software. + + THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN + THE SOFTWARE. + ****************************************************************************/ + +#ifndef __UIEDITTEXT_H__ +#define __UIEDITTEXT_H__ + +#include "base/CCIMEDelegate.h" +#include "ui/GUIDefine.h" +#include "ui/UIButton.h" +#include "ui/UIScale9Sprite.h" + +NS_CC_BEGIN + +namespace ui { + + class EditBox; + class EditBoxImpl; + + + class CC_GUI_DLL EditBoxDelegate + { + public: + /** + * @js NA + * @lua NA + */ + virtual ~EditBoxDelegate() {}; + + /** + * This method is called when an edit box gains focus after keyboard is shown. + * @param editBox The edit box object that generated the event. + * @js NA + * @lua NA + */ + virtual void editBoxEditingDidBegin(EditBox* editBox) {}; + + + /** + * This method is called when an edit box loses focus after keyboard is hidden. + * @param editBox The edit box object that generated the event. + * @js NA + * @lua NA + */ + virtual void editBoxEditingDidEnd(EditBox* editBox) {}; + + /** + * This method is called when the edit box text was changed. + * @param editBox The edit box object that generated the event. + * @param text The new text. + * @js NA + * @lua NA + */ + virtual void editBoxTextChanged(EditBox* editBox, const std::string& text) {}; + + /** + * This method is called when the return button was pressed or the outside area of keyboard was touched. + * @param editBox The edit box object that generated the event. + * @js NA + * @lua NA + */ + virtual void editBoxReturn(EditBox* editBox) = 0; + + }; + + /** + * \brief Class for edit box. + * + * You can use this widget to gather small amounts of text from the user. + * + */ + + class CC_GUI_DLL EditBox + : public Widget + , public IMEDelegate + { + public: + enum class KeyboardReturnType + { + DEFAULT, + DONE, + SEND, + SEARCH, + GO + }; + + /** + * \brief The EditBox::InputMode defines the type of text that the user is allowed + * to enter. + */ + enum class InputMode + { + /** + * The user is allowed to enter any text, including line breaks. + */ + ANY, + + /** + * The user is allowed to enter an e-mail address. + */ + EMAIL_ADDRESS, + + /** + * The user is allowed to enter an integer value. + */ + NUMERIC, + + /** + * The user is allowed to enter a phone number. + */ + PHONE_NUMBER, + + /** + * The user is allowed to enter a URL. + */ + URL, + + /** + * The user is allowed to enter a real number value. + * This extends kEditBoxInputModeNumeric by allowing a decimal point. + */ + DECIMAL, + + /** + * The user is allowed to enter any text, except for line breaks. + */ + SINGLE_LINE, + }; + + /** + * \brief The EditBox::InputFlag defines how the input text is displayed/formatted. + */ + enum class InputFlag + { + /** + * Indicates that the text entered is confidential data that should be + * obscured whenever possible. This implies EDIT_BOX_INPUT_FLAG_SENSITIVE. + */ + PASSWORD, + + /** + * Indicates that the text entered is sensitive data that the + * implementation must never store into a dictionary or table for use + * in predictive, auto-completing, or other accelerated input schemes. + * A credit card number is an example of sensitive data. + */ + SENSITIVE, + + /** + * This flag is a hint to the implementation that during text editing, + * the initial letter of each word should be capitalized. + */ + INITIAL_CAPS_WORD, + + /** + * This flag is a hint to the implementation that during text editing, + * the initial letter of each sentence should be capitalized. + */ + INITIAL_CAPS_SENTENCE, + + /** + * Capitalize all characters automatically. + */ + INTIAL_CAPS_ALL_CHARACTERS, + }; + + /** + * create a edit box with size. + * @return An autorelease pointer of EditBox, you don't need to release it only if you retain it again. + */ + static EditBox* create(const Size& size, + Scale9Sprite* normalSprite, + Scale9Sprite* pressedSprite = nullptr, + Scale9Sprite* disabledSprite = nullptr); + + + /** + * create a edit box with size. + * @return An autorelease pointer of EditBox, you don't need to release it only if you retain it again. + */ + static EditBox* create(const Size& size, + const std::string& pNormal9SpriteBg, + TextureResType texType = TextureResType::LOCAL); + + /** + * Constructor. + * @js ctor + */ + EditBox(void); + + /** + * Destructor. + * @js NA + * @lua NA + */ + virtual ~EditBox(void); + + /** + * Init edit box with specified size. This method should be invoked right after constructor. + * @param size The size of edit box. + */ + bool initWithSizeAndBackgroundSprite(const Size& size, + const std::string& pNormal9SpriteBg, + TextureResType texType = TextureResType::LOCAL); + + bool initWithSizeAndBackgroundSprite(const Size& size, Scale9Sprite* pNormal9SpriteBg); + + /** + * Gets/Sets the delegate for edit box. + * @lua NA + */ + void setDelegate(EditBoxDelegate* pDelegate); + /** + * @js NA + * @lua NA + */ + EditBoxDelegate* getDelegate(); + +#if CC_ENABLE_SCRIPT_BINDING + /** + * Registers a script function that will be called for EditBox events. + * + * This handler will be removed automatically after onExit() called. + * @code + * -- lua sample + * local function editboxEventHandler(eventType) + * if eventType == "began" then + * -- triggered when an edit box gains focus after keyboard is shown + * elseif eventType == "ended" then + * -- triggered when an edit box loses focus after keyboard is hidden. + * elseif eventType == "changed" then + * -- triggered when the edit box text was changed. + * elseif eventType == "return" then + * -- triggered when the return button was pressed or the outside area of keyboard was touched. + * end + * end + * + * local editbox = EditBox:create(Size(...), Scale9Sprite:create(...)) + * editbox = registerScriptEditBoxHandler(editboxEventHandler) + * @endcode + * + * @param handler A number that indicates a lua function. + * @js NA + * @lua NA + */ + void registerScriptEditBoxHandler(int handler); + + /** + * Unregisters a script function that will be called for EditBox events. + * @js NA + * @lua NA + */ + void unregisterScriptEditBoxHandler(void); + /** + * get a script Handler + * @js NA + * @lua NA + */ + int getScriptEditBoxHandler(void){ return _scriptEditBoxHandler ;} + +#endif // #if CC_ENABLE_SCRIPT_BINDING + + /** + * Set the text entered in the edit box. + * @param pText The given text. + */ + void setText(const char* pText); + + /** + * Get the text entered in the edit box. + * @return The text entered in the edit box. + */ + const char* getText(void); + + /** + * Set the font. + * @param pFontName The font name. + * @param fontSize The font size. + */ + void setFont(const char* pFontName, int fontSize); + + /** + * Set the font name. + * @param pFontName The font name. + */ + void setFontName(const char* pFontName); + + /** + * Set the font size. + * @param fontSize The font size. + */ + void setFontSize(int fontSize); + + /** + * Set the font color of the widget's text. + */ + void setFontColor(const Color3B& color); + + /** + * Set the placeholder's font. + * @param pFontName The font name. + * @param fontSize The font size. + */ + void setPlaceholderFont(const char* pFontName, int fontSize); + + /** + * Set the placeholder's font name. + * @param pFontName The font name. + */ + void setPlaceholderFontName(const char* pFontName); + + /** + * Set the placeholder's font size. + * @param fontSize The font size. + */ + void setPlaceholderFontSize(int fontSize); + + /** + * Set the font color of the placeholder text when the edit box is empty. + * Not supported on IOS. + */ + void setPlaceholderFontColor(const Color3B& color); + + /** + * Set a text in the edit box that acts as a placeholder when an + * edit box is empty. + * @param pText The given text. + */ + void setPlaceHolder(const char* pText); + + /** + * Get a text in the edit box that acts as a placeholder when an + * edit box is empty. + */ + const char* getPlaceHolder(void); + + /** + * Set the input mode of the edit box. + * @param inputMode One of the EditBox::InputMode constants. + */ + void setInputMode(InputMode inputMode); + + /** + * Sets the maximum input length of the edit box. + * Setting this value enables multiline input mode by default. + * Available on Android, iOS and Windows Phone. + * + * @param maxLength The maximum length. + */ + void setMaxLength(int maxLength); + + /** + * Gets the maximum input length of the edit box. + * + * @return Maximum input length. + */ + int getMaxLength(); + + /** + * Set the input flags that are to be applied to the edit box. + * @param inputFlag One of the EditBox::InputFlag constants. + */ + void setInputFlag(InputFlag inputFlag); + + /** + * Set the return type that are to be applied to the edit box. + * @param returnType One of the EditBox::KeyboardReturnType constants. + */ + void setReturnType(EditBox::KeyboardReturnType returnType); + + /* override functions */ + virtual void setPosition(const Vec2& pos) override; + virtual void setVisible(bool visible) override; + virtual void setContentSize(const Size& size) override; + virtual void setAnchorPoint(const Vec2& anchorPoint) override; + /** + * @js NA + * @lua NA + */ + virtual void visit(Renderer *renderer, const Mat4 &parentTransform, uint32_t parentFlags) override; + /** + * @js NA + * @lua NA + */ + virtual void onEnter(void) override; + /** + * @js NA + * @lua NA + */ + virtual void onExit(void) override; + /** + * @js NA + * @lua NA + */ + virtual void keyboardWillShow(IMEKeyboardNotificationInfo& info) override; + /** + * @js NA + * @lua NA + */ + virtual void keyboardDidShow(IMEKeyboardNotificationInfo& info) override; + /** + * @js NA + * @lua NA + */ + virtual void keyboardWillHide(IMEKeyboardNotificationInfo& info) override; + /** + * @js NA + * @lua NA + */ + virtual void keyboardDidHide(IMEKeyboardNotificationInfo& info) override; + + /* callback funtions + * @js NA + * @lua NA + */ + void touchDownAction(Ref *sender, TouchEventType controlEvent); + + protected: + virtual void adaptRenderers(); + + void updatePosition(float dt); + EditBoxImpl* _editBoxImpl; + EditBoxDelegate* _delegate; + + InputMode _editBoxInputMode; + InputFlag _editBoxInputFlag; + EditBox::KeyboardReturnType _keyboardReturnType; + + Scale9Sprite *_backgroundSprite; + std::string _text; + std::string _placeHolder; + + std::string _fontName; + std::string _placeholderFontName; + + int _fontSize; + int _placeholderFontSize; + + Color3B _colText; + Color3B _colPlaceHolder; + + int _maxLength; + float _adjustHeight; +#if CC_ENABLE_SCRIPT_BINDING + int _scriptEditBoxHandler; +#endif + }; +} + +NS_CC_END + +#endif /* __UIEDITTEXT_H__ */ + diff --git a/cocos/ui/UIEditBox/UIEditBoxImpl.h b/cocos/ui/UIEditBox/UIEditBoxImpl.h new file mode 100644 index 0000000000..8413b62bae --- /dev/null +++ b/cocos/ui/UIEditBox/UIEditBoxImpl.h @@ -0,0 +1,103 @@ +/**************************************************************************** + Copyright (c) 2010-2012 cocos2d-x.org + Copyright (c) 2012 James Chen + + http://www.cocos2d-x.org + + Permission is hereby granted, free of charge, to any person obtaining a copy + of this software and associated documentation files (the "Software"), to deal + in the Software without restriction, including without limitation the rights + to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + copies of the Software, and to permit persons to whom the Software is + furnished to do so, subject to the following conditions: + + The above copyright notice and this permission notice shall be included in + all copies or substantial portions of the Software. + + THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN + THE SOFTWARE. + ****************************************************************************/ + +#ifndef __UIEditBoxIMPL_H__ +#define __UIEditBoxIMPL_H__ + +#include "UIEditBox.h" + + +namespace cocos2d { + namespace ui{ + + class CC_GUI_DLL EditBoxImpl + { + public: + /** + * @js NA + */ + EditBoxImpl(EditBox* pEditBox) : _delegate(nullptr),_editBox(pEditBox) {} + /** + * @js NA + * @lua NA + */ + virtual ~EditBoxImpl() {} + + virtual bool initWithSize(const Size& size) = 0; + virtual void setFont(const char* pFontName, int fontSize) = 0; + virtual void setFontColor(const Color3B& color) = 0; + virtual void setPlaceholderFont(const char* pFontName, int fontSize) = 0; + virtual void setPlaceholderFontColor(const Color3B& color) = 0; + virtual void setInputMode(EditBox::InputMode inputMode) = 0; + virtual void setInputFlag(EditBox::InputFlag inputFlag) = 0; + virtual void setMaxLength(int maxLength) = 0; + virtual int getMaxLength() = 0; + virtual void setReturnType(EditBox::KeyboardReturnType returnType) = 0; + virtual bool isEditing() = 0; + + virtual void setText(const char* pText) = 0; + virtual const char* getText(void) = 0; + virtual void setPlaceHolder(const char* pText) = 0; + virtual void doAnimationWhenKeyboardMove(float duration, float distance) = 0; + + virtual void openKeyboard() = 0; + virtual void closeKeyboard() = 0; + + virtual void setPosition(const Vec2& pos) = 0; + virtual void setVisible(bool visible) = 0; + virtual void setContentSize(const Size& size) = 0; + virtual void setAnchorPoint(const Vec2& anchorPoint) = 0; + + /** + * check the editbox's position, update it when needed + */ + virtual void updatePosition(float dt){}; + /** + * @js NA + * @lua NA + */ + virtual void visit(void) = 0; + /** + * @js NA + * @lua NA + */ + virtual void onEnter(void) = 0; + + + void setDelegate(EditBoxDelegate* pDelegate) { _delegate = pDelegate; }; + EditBoxDelegate* getDelegate() { return _delegate; }; + EditBox* getEditBox() { return _editBox; }; + protected: + EditBoxDelegate* _delegate; + EditBox* _editBox; + }; + + // This method must be implemented at each subclass of EditBoxImpl. + extern EditBoxImpl* __createSystemEditBox(EditBox* pEditBox); + + } +} + +#endif /* __UIEditBoxIMPL_H__ */ diff --git a/extensions/GUI/CCEditBox/CCEditBoxImplAndroid.cpp b/cocos/ui/UIEditBox/UIEditBoxImplAndroid.cpp similarity index 98% rename from extensions/GUI/CCEditBox/CCEditBoxImplAndroid.cpp rename to cocos/ui/UIEditBox/UIEditBoxImplAndroid.cpp index b8863a4fa7..338b8defd3 100644 --- a/extensions/GUI/CCEditBox/CCEditBoxImplAndroid.cpp +++ b/cocos/ui/UIEditBox/UIEditBoxImplAndroid.cpp @@ -23,16 +23,18 @@ THE SOFTWARE. ****************************************************************************/ -#include "CCEditBoxImplAndroid.h" +#include "UIEditBoxImplAndroid.h" #if (CC_TARGET_PLATFORM == CC_PLATFORM_ANDROID) -#include "CCEditBox.h" +#include "UIEditBox.h" #include "jni/Java_org_cocos2dx_lib_Cocos2dxBitmap.h" #include "jni/Java_org_cocos2dx_lib_Cocos2dxHelper.h" -NS_CC_EXT_BEGIN +NS_CC_BEGIN + +namespace ui { EditBoxImpl* __createSystemEditBox(EditBox* pEditBox) { @@ -309,7 +311,9 @@ void EditBoxImplAndroid::closeKeyboard() } -NS_CC_EXT_END +} + +NS_CC_END #endif /* #if (CC_TARGET_PLATFORM == CC_PLATFORM_ANDROID) */ diff --git a/extensions/GUI/CCEditBox/CCEditBoxImplAndroid.h b/cocos/ui/UIEditBox/UIEditBoxImplAndroid.h similarity index 93% rename from extensions/GUI/CCEditBox/CCEditBoxImplAndroid.h rename to cocos/ui/UIEditBox/UIEditBoxImplAndroid.h index 8f4d6a1e95..2b38934752 100644 --- a/extensions/GUI/CCEditBox/CCEditBoxImplAndroid.h +++ b/cocos/ui/UIEditBox/UIEditBoxImplAndroid.h @@ -23,17 +23,18 @@ THE SOFTWARE. ****************************************************************************/ -#ifndef __CCEDITBOXIMPLANDROID_H__ -#define __CCEDITBOXIMPLANDROID_H__ +#ifndef __UIEDITBOXIMPLANDROID_H__ +#define __UIEDITBOXIMPLANDROID_H__ #include "cocos2d.h" #if (CC_TARGET_PLATFORM == CC_PLATFORM_ANDROID) -#include "extensions/ExtensionMacros.h" -#include "CCEditBoxImpl.h" +#include "UIEditBoxImpl.h" -NS_CC_EXT_BEGIN +NS_CC_BEGIN + +namespace ui { class EditBox; @@ -78,7 +79,7 @@ public: * @js NA * @lua NA */ - virtual void onEnter(void); + virtual void onEnter(void); virtual void doAnimationWhenKeyboardMove(float duration, float distance); virtual void openKeyboard(); virtual void closeKeyboard(); @@ -101,9 +102,11 @@ private: }; -NS_CC_EXT_END +} + +NS_CC_END #endif /* #if (CC_TARGET_PLATFORM == CC_PLATFORM_ANDROID) */ -#endif /* __CCEDITBOXIMPLANDROID_H__ */ +#endif /* __UIEDITBOXIMPLANDROID_H__ */ diff --git a/extensions/GUI/CCEditBox/CCEditBoxImplIOS.h b/cocos/ui/UIEditBox/UIEditBoxImplIOS.h similarity index 91% rename from extensions/GUI/CCEditBox/CCEditBoxImplIOS.h rename to cocos/ui/UIEditBox/UIEditBoxImplIOS.h index 0e666ee6ed..b78ce96da6 100644 --- a/extensions/GUI/CCEditBox/CCEditBoxImplIOS.h +++ b/cocos/ui/UIEditBox/UIEditBoxImplIOS.h @@ -23,29 +23,29 @@ THE SOFTWARE. ****************************************************************************/ -#ifndef __CCEditBoxIMPLIOS_H__ -#define __CCEditBoxIMPLIOS_H__ +#ifndef __UIEditBoxIMPLIOS_H__ +#define __UIEditBoxIMPLIOS_H__ #include "cocos2d.h" #if (CC_TARGET_PLATFORM == CC_PLATFORM_IOS) #include "extensions/ExtensionMacros.h" -#include "CCEditBoxImpl.h" +#include "UIEditBoxImpl.h" #import #import -@interface CCCustomUITextField : UITextField +@interface UICustomUITextField : UITextField { } @end -@interface CCEditBoxImplIOS_objc : NSObject +@interface UIEditBoxImplIOS_objc : NSObject { - CCCustomUITextField* textField_; + UICustomUITextField* textField_; void* editBox_; BOOL editState_; } @@ -64,7 +64,9 @@ @end -NS_CC_EXT_BEGIN +NS_CC_BEGIN + +namespace ui { class EditBox; @@ -128,16 +130,18 @@ private: Size _contentSize; Vec2 _position; Vec2 _anchorPoint; - CCEditBoxImplIOS_objc* _systemControl; + UIEditBoxImplIOS_objc* _systemControl; int _maxTextLength; bool _inRetinaMode; }; -NS_CC_EXT_END +} + +NS_CC_END #endif /* #if (CC_TARGET_PLATFORM == CC_PLATFORM_IOS) */ -#endif /* __CCEditBoxIMPLIOS_H__ */ +#endif /* __UIEditBoxIMPLIOS_H__ */ diff --git a/extensions/GUI/CCEditBox/CCEditBoxImplIOS.mm b/cocos/ui/UIEditBox/UIEditBoxImplIOS.mm similarity index 95% rename from extensions/GUI/CCEditBox/CCEditBoxImplIOS.mm rename to cocos/ui/UIEditBox/UIEditBoxImplIOS.mm index 0c0be51a6d..d78dd0c765 100644 --- a/extensions/GUI/CCEditBox/CCEditBoxImplIOS.mm +++ b/cocos/ui/UIEditBox/UIEditBoxImplIOS.mm @@ -22,20 +22,20 @@ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. ****************************************************************************/ -#include "CCEditBoxImplIOS.h" +#include "UIEditBoxImplIOS.h" #if (CC_TARGET_PLATFORM == CC_PLATFORM_IOS) #define kLabelZOrder 9999 -#include "CCEditBox.h" +#include "UIEditBox.h" #import "CCEAGLView.h" -#define getEditBoxImplIOS() ((cocos2d::extension::EditBoxImplIOS*)editBox_) +#define getEditBoxImplIOS() ((cocos2d::ui::EditBoxImplIOS*)editBox_) static const int CC_EDIT_BOX_PADDING = 5; -@implementation CCCustomUITextField +@implementation UICustomUITextField - (CGRect)textRectForBounds:(CGRect)bounds { auto glview = cocos2d::Director::getInstance()->getOpenGLView(); @@ -50,7 +50,7 @@ static const int CC_EDIT_BOX_PADDING = 5; @end -@implementation CCEditBoxImplIOS_objc +@implementation UIEditBoxImplIOS_objc @synthesize textField = textField_; @synthesize editState = editState_; @@ -71,7 +71,7 @@ static const int CC_EDIT_BOX_PADDING = 5; if (self) { editState_ = NO; - self.textField = [[[CCCustomUITextField alloc] initWithFrame: frameRect] autorelease]; + self.textField = [[[UICustomUITextField alloc] initWithFrame: frameRect] autorelease]; [textField_ setTextColor:[UIColor whiteColor]]; //TODO: need to delete hard code here. @@ -159,14 +159,14 @@ static const int CC_EDIT_BOX_PADDING = 5; { [self performSelector:@selector(animationSelector) withObject:nil afterDelay:0.0f]; } - cocos2d::extension::EditBoxDelegate* pDelegate = getEditBoxImplIOS()->getDelegate(); + cocos2d::ui::EditBoxDelegate* pDelegate = getEditBoxImplIOS()->getDelegate(); if (pDelegate != NULL) { pDelegate->editBoxEditingDidBegin(getEditBoxImplIOS()->getEditBox()); } #if CC_ENABLE_SCRIPT_BINDING - cocos2d::extension::EditBox* pEditBox= getEditBoxImplIOS()->getEditBox(); + cocos2d::ui::EditBox* pEditBox= getEditBoxImplIOS()->getEditBox(); if (NULL != pEditBox && 0 != pEditBox->getScriptEditBoxHandler()) { cocos2d::CommonScriptData data(pEditBox->getScriptEditBoxHandler(), "began",pEditBox); @@ -183,7 +183,7 @@ static const int CC_EDIT_BOX_PADDING = 5; editState_ = NO; getEditBoxImplIOS()->refreshInactiveText(); - cocos2d::extension::EditBoxDelegate* pDelegate = getEditBoxImplIOS()->getDelegate(); + cocos2d::ui::EditBoxDelegate* pDelegate = getEditBoxImplIOS()->getDelegate(); if (pDelegate != NULL) { pDelegate->editBoxEditingDidEnd(getEditBoxImplIOS()->getEditBox()); @@ -191,7 +191,7 @@ static const int CC_EDIT_BOX_PADDING = 5; } #if CC_ENABLE_SCRIPT_BINDING - cocos2d::extension::EditBox* pEditBox= getEditBoxImplIOS()->getEditBox(); + cocos2d::ui::EditBox* pEditBox= getEditBoxImplIOS()->getEditBox(); if (NULL != pEditBox && 0 != pEditBox->getScriptEditBoxHandler()) { cocos2d::CommonScriptData data(pEditBox->getScriptEditBoxHandler(), "ended",pEditBox); @@ -240,14 +240,14 @@ static const int CC_EDIT_BOX_PADDING = 5; - (void) textChanged { // NSLog(@"text is %@", self.textField.text); - cocos2d::extension::EditBoxDelegate* pDelegate = getEditBoxImplIOS()->getDelegate(); + cocos2d::ui::EditBoxDelegate* pDelegate = getEditBoxImplIOS()->getDelegate(); if (pDelegate != NULL) { pDelegate->editBoxTextChanged(getEditBoxImplIOS()->getEditBox(), getEditBoxImplIOS()->getText()); } #if CC_ENABLE_SCRIPT_BINDING - cocos2d::extension::EditBox* pEditBox= getEditBoxImplIOS()->getEditBox(); + cocos2d::ui::EditBox* pEditBox= getEditBoxImplIOS()->getEditBox(); if (NULL != pEditBox && 0 != pEditBox->getScriptEditBoxHandler()) { cocos2d::CommonScriptData data(pEditBox->getScriptEditBoxHandler(), "changed",pEditBox); @@ -260,7 +260,9 @@ static const int CC_EDIT_BOX_PADDING = 5; @end -NS_CC_EXT_BEGIN +NS_CC_BEGIN + +namespace ui { EditBoxImpl* __createSystemEditBox(EditBox* pEditBox) { @@ -307,7 +309,7 @@ bool EditBoxImplIOS::initWithSize(const Size& size) rect.size.height /= 2.0f; } - _systemControl = [[CCEditBoxImplIOS_objc alloc] initWithFrame:rect editBox:this]; + _systemControl = [[UIEditBoxImplIOS_objc alloc] initWithFrame:rect editBox:this]; if (!_systemControl) break; initInactiveLabels(size); @@ -668,7 +670,9 @@ void EditBoxImplIOS::onEndEditing() } } -NS_CC_EXT_END +} + +NS_CC_END #endif /* #if (CC_TARGET_PLATFORM == CC_PLATFORM_IOS) */ diff --git a/extensions/GUI/CCEditBox/CCEditBoxImplMac.h b/cocos/ui/UIEditBox/UIEditBoxImplMac.h similarity index 93% rename from extensions/GUI/CCEditBox/CCEditBoxImplMac.h rename to cocos/ui/UIEditBox/UIEditBoxImplMac.h index 34085e8278..ffb53d29ef 100644 --- a/extensions/GUI/CCEditBox/CCEditBoxImplMac.h +++ b/cocos/ui/UIEditBox/UIEditBoxImplMac.h @@ -23,8 +23,8 @@ THE SOFTWARE. ****************************************************************************/ -#ifndef __CCEditBoxIMPLMAC_H__ -#define __CCEditBoxIMPLMAC_H__ +#ifndef __UIEditBoxIMPLMAC_H__ +#define __UIEditBoxIMPLMAC_H__ #include "cocos2d.h" @@ -33,11 +33,10 @@ #import #import -#include "extensions/ExtensionMacros.h" -#include "CCEditBoxImpl.h" +#include "UIEditBoxImpl.h" -@interface CCEditBoxImplMac : NSObject +@interface UIEditBoxImplMac : NSObject { NSTextField* textField_; NSSecureTextField* secureTextField_; @@ -62,8 +61,11 @@ @end -NS_CC_EXT_BEGIN +NS_CC_BEGIN + +namespace ui { + class EditBox; class EditBoxImplMac : public EditBoxImpl @@ -120,13 +122,15 @@ private: Vec2 _anchorPoint; int _maxTextLength; bool _inRetinaMode; - CCEditBoxImplMac* _sysEdit; + UIEditBoxImplMac* _sysEdit; }; -NS_CC_EXT_END +} + +NS_CC_END #endif // #if (CC_TARGET_PLATFORM == CC_PLATFORM_MAC) -#endif /* __CCEditBoxIMPLMAC_H__ */ +#endif /* __UIEditBoxIMPLMAC_H__ */ diff --git a/extensions/GUI/CCEditBox/CCEditBoxImplMac.mm b/cocos/ui/UIEditBox/UIEditBoxImplMac.mm similarity index 95% rename from extensions/GUI/CCEditBox/CCEditBoxImplMac.mm rename to cocos/ui/UIEditBox/UIEditBoxImplMac.mm index 3668a7f134..87bf88e615 100644 --- a/extensions/GUI/CCEditBox/CCEditBoxImplMac.mm +++ b/cocos/ui/UIEditBox/UIEditBoxImplMac.mm @@ -23,19 +23,19 @@ THE SOFTWARE. ****************************************************************************/ -#include "CCEditBoxImplMac.h" +#include "UIEditBoxImplMac.h" #include "base/CCDirector.h" #if (CC_TARGET_PLATFORM == CC_PLATFORM_MAC) -#include "CCEditBox.h" +#include "UIEditBox.h" -#define getEditBoxImplMac() ((cocos2d::extension::EditBoxImplMac*)editBox_) +#define getEditBoxImplMac() ((cocos2d::ui::EditBoxImplMac*)editBox_) -@implementation CCEditBoxImplMac +@implementation UIEditBoxImplMac @synthesize textField = textField_; @synthesize secureTextField = secureTextField_; @@ -163,14 +163,14 @@ - (void)controlTextDidBeginEditing:(NSNotification *)notification { editState_ = YES; - cocos2d::extension::EditBoxDelegate* pDelegate = getEditBoxImplMac()->getDelegate(); + cocos2d::ui::EditBoxDelegate* pDelegate = getEditBoxImplMac()->getDelegate(); if (pDelegate != NULL) { pDelegate->editBoxEditingDidBegin(getEditBoxImplMac()->getEditBox()); } #if CC_ENABLE_SCRIPT_BINDING - cocos2d::extension::EditBox* pEditBox= getEditBoxImplMac()->getEditBox(); + cocos2d::ui::EditBox* pEditBox= getEditBoxImplMac()->getEditBox(); if (NULL != pEditBox && 0 != pEditBox->getScriptEditBoxHandler()) { cocos2d::CommonScriptData data(pEditBox->getScriptEditBoxHandler(), "began",pEditBox); @@ -183,7 +183,7 @@ - (void)controlTextDidEndEditing:(NSNotification *)notification { editState_ = NO; - cocos2d::extension::EditBoxDelegate* pDelegate = getEditBoxImplMac()->getDelegate(); + cocos2d::ui::EditBoxDelegate* pDelegate = getEditBoxImplMac()->getDelegate(); if (pDelegate != NULL) { pDelegate->editBoxEditingDidEnd(getEditBoxImplMac()->getEditBox()); @@ -191,7 +191,7 @@ } #if CC_ENABLE_SCRIPT_BINDING - cocos2d::extension::EditBox* pEditBox= getEditBoxImplMac()->getEditBox(); + cocos2d::ui::EditBox* pEditBox= getEditBoxImplMac()->getEditBox(); if (NULL != pEditBox && 0 != pEditBox->getScriptEditBoxHandler()) { cocos2d::CommonScriptData data(pEditBox->getScriptEditBoxHandler(), "ended",pEditBox); @@ -233,14 +233,14 @@ */ - (void)controlTextDidChange:(NSNotification *)notification { - cocos2d::extension::EditBoxDelegate* pDelegate = getEditBoxImplMac()->getDelegate(); + cocos2d::ui::EditBoxDelegate* pDelegate = getEditBoxImplMac()->getDelegate(); if (pDelegate != NULL) { pDelegate->editBoxTextChanged(getEditBoxImplMac()->getEditBox(), getEditBoxImplMac()->getText()); } #if CC_ENABLE_SCRIPT_BINDING - cocos2d::extension::EditBox* pEditBox= getEditBoxImplMac()->getEditBox(); + cocos2d::ui::EditBox* pEditBox= getEditBoxImplMac()->getEditBox(); if (NULL != pEditBox && 0 != pEditBox->getScriptEditBoxHandler()) { cocos2d::CommonScriptData data(pEditBox->getScriptEditBoxHandler(), "changed",pEditBox); @@ -252,7 +252,9 @@ @end -NS_CC_EXT_BEGIN +NS_CC_BEGIN + +namespace ui { EditBoxImpl* __createSystemEditBox(EditBox* pEditBox) { @@ -292,7 +294,7 @@ bool EditBoxImplMac::initWithSize(const Size& size) rect.size.height /= 2.0f; } - _sysEdit = [[CCEditBoxImplMac alloc] initWithFrame:rect editBox:this]; + _sysEdit = [[UIEditBoxImplMac alloc] initWithFrame:rect editBox:this]; if (!_sysEdit) return false; @@ -514,7 +516,9 @@ void EditBoxImplMac::onEnter(void) adjustTextFieldPosition(); } -NS_CC_EXT_END +} + +NS_CC_END #endif // #if (CC_TARGET_PLATFORM == CC_PLATFORM_MAC) diff --git a/extensions/GUI/CCEditBox/CCEditBoxImplNone.cpp b/cocos/ui/UIEditBox/UIEditBoxImplNone.cpp similarity index 83% rename from extensions/GUI/CCEditBox/CCEditBoxImplNone.cpp rename to cocos/ui/UIEditBox/UIEditBoxImplNone.cpp index 5cac865d3d..7e3899672c 100644 --- a/extensions/GUI/CCEditBox/CCEditBoxImplNone.cpp +++ b/cocos/ui/UIEditBox/UIEditBoxImplNone.cpp @@ -1,14 +1,18 @@ -#include "CCEditBox.h" +#include "UIEditBox.h" #if (CC_TARGET_PLATFORM != CC_PLATFORM_ANDROID ) && (CC_TARGET_PLATFORM != CC_PLATFORM_IOS ) && (CC_TARGET_PLATFORM != CC_PLATFORM_WIN32) && (CC_TARGET_PLATFORM != CC_PLATFORM_MAC) && (CC_TARGET_PLATFORM != CC_PLATFORM_TIZEN) -NS_CC_EXT_BEGIN +NS_CC_BEGIN + +namespace ui { EditBoxImpl* __createSystemEditBox(EditBox* pEditBox) { return NULL; } -NS_CC_EXT_END +} + +NS_CC_END #endif /* #if (..) */ diff --git a/extensions/GUI/CCEditBox/CCEditBoxImplWin.cpp b/cocos/ui/UIEditBox/UIEditBoxImplWin.cpp similarity index 98% rename from extensions/GUI/CCEditBox/CCEditBoxImplWin.cpp rename to cocos/ui/UIEditBox/UIEditBoxImplWin.cpp index 0056d54faf..af5e9f8213 100644 --- a/extensions/GUI/CCEditBox/CCEditBoxImplWin.cpp +++ b/cocos/ui/UIEditBox/UIEditBoxImplWin.cpp @@ -22,14 +22,16 @@ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. ****************************************************************************/ -#include "CCEditBoxImplWin.h" +#include "UIEditBoxImplWin.h" #if (CC_TARGET_PLATFORM == CC_PLATFORM_WIN32) -#include "CCEditBox.h" +#include "UIEditBox.h" #include "proj.win32/Win32InputBox.h" -NS_CC_EXT_BEGIN +NS_CC_BEGIN + +namespace ui { EditBoxImpl* __createSystemEditBox(EditBox* pEditBox) { @@ -293,6 +295,8 @@ void EditBoxImplWin::onEnter(void) } -NS_CC_EXT_END +} + +NS_CC_END #endif /* (CC_TARGET_PLATFORM == CC_PLATFORM_WIN32) */ diff --git a/extensions/GUI/CCEditBox/CCEditBoxImplWin.h b/cocos/ui/UIEditBox/UIEditBoxImplWin.h similarity index 92% rename from extensions/GUI/CCEditBox/CCEditBoxImplWin.h rename to cocos/ui/UIEditBox/UIEditBoxImplWin.h index 4d04fb6cce..b4c9cf9f47 100644 --- a/extensions/GUI/CCEditBox/CCEditBoxImplWin.h +++ b/cocos/ui/UIEditBox/UIEditBoxImplWin.h @@ -23,22 +23,22 @@ THE SOFTWARE. ****************************************************************************/ -#ifndef __CCEditBoxIMPLWIN_H__ -#define __CCEditBoxIMPLWIN_H__ +#ifndef __UIEditBoxIMPLWIN_H__ +#define __UIEditBoxIMPLWIN_H__ #include "cocos2d.h" #if (CC_TARGET_PLATFORM == CC_PLATFORM_WIN32) -#include "extensions/ExtensionMacros.h" -#include "CCEditBoxImpl.h" -#include "extensions/ExtensionExport.h" +#include "UIEditBoxImpl.h" -NS_CC_EXT_BEGIN +NS_CC_BEGIN + +namespace ui { class EditBox; -class CC_EX_DLL EditBoxImplWin : public EditBoxImpl +class CC_GUI_DLL EditBoxImplWin : public EditBoxImpl { public: /** @@ -108,9 +108,11 @@ private: }; -NS_CC_EXT_END +} + +NS_CC_END #endif /* (CC_TARGET_PLATFORM == CC_PLATFORM_WIN32) */ -#endif /* __CCEditBoxIMPLWIN_H__ */ +#endif /* __UIEditBoxIMPLWIN_H__ */ diff --git a/extensions/GUI/CCEditBox/CCEditBoxImplWp8.cpp b/cocos/ui/UIEditBox/UIEditBoxImplWp8.cpp similarity index 80% rename from extensions/GUI/CCEditBox/CCEditBoxImplWp8.cpp rename to cocos/ui/UIEditBox/UIEditBoxImplWp8.cpp index 245149d164..b8a2f23050 100644 --- a/extensions/GUI/CCEditBox/CCEditBoxImplWp8.cpp +++ b/cocos/ui/UIEditBox/UIEditBoxImplWp8.cpp @@ -22,20 +22,22 @@ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. ****************************************************************************/ -#include "CCEditBoxImplWp8.h" -#include "CCEditBox.h" +#include "UIEditBoxImplWp8.h" +#include "UIEditBox.h" #include "CCGLViewImpl.h" #include "base/CCScriptSupport.h" #include "base/ccUTF8.h" -NS_CC_EXT_BEGIN +NS_CC_BEGIN + +namespace ui { EditBoxImpl* __createSystemEditBox(EditBox* pEditBox) { - return new CCEditBoxImplWp8(pEditBox); + return new UIEditBoxImplWp8(pEditBox); } -CCEditBoxImplWp8::CCEditBoxImplWp8( EditBox* pEditText ) +UIEditBoxImplWp8::UIEditBoxImplWp8( EditBox* pEditText ) : EditBoxImpl(pEditText) , m_pLabel(NULL) , m_pLabelPlaceHolder(NULL) @@ -49,12 +51,12 @@ CCEditBoxImplWp8::CCEditBoxImplWp8( EditBox* pEditText ) } -CCEditBoxImplWp8::~CCEditBoxImplWp8() +UIEditBoxImplWp8::~UIEditBoxImplWp8() { } -void CCEditBoxImplWp8::openKeyboard() +void UIEditBoxImplWp8::openKeyboard() { if (_delegate != NULL) { @@ -92,7 +94,7 @@ void CCEditBoxImplWp8::openKeyboard() GLViewImpl::sharedOpenGLView()->OpenXamlEditBox(stringToPlatformString(placeHolder), stringToPlatformString(getText()), m_nMaxLength, (int)m_eEditBoxInputMode, (int)m_eEditBoxInputFlag, receiveHandler); } -bool CCEditBoxImplWp8::initWithSize( const Size& size ) +bool UIEditBoxImplWp8::initWithSize( const Size& size ) { //! int fontSize = getFontSizeAccordingHeightJni(size.height-12); m_pLabel = Label::createWithSystemFont("", "", size.height-12); @@ -114,7 +116,7 @@ bool CCEditBoxImplWp8::initWithSize( const Size& size ) return true; } -void CCEditBoxImplWp8::setFont( const char* pFontName, int fontSize ) +void UIEditBoxImplWp8::setFont( const char* pFontName, int fontSize ) { if(m_pLabel != NULL) { m_pLabel->setSystemFontName(pFontName); @@ -127,13 +129,13 @@ void CCEditBoxImplWp8::setFont( const char* pFontName, int fontSize ) } } -void CCEditBoxImplWp8::setFontColor( const Color3B& color ) +void UIEditBoxImplWp8::setFontColor( const Color3B& color ) { m_colText = color; m_pLabel->setColor(color); } -void CCEditBoxImplWp8::setPlaceholderFont( const char* pFontName, int fontSize ) +void UIEditBoxImplWp8::setPlaceholderFont( const char* pFontName, int fontSize ) { if(m_pLabelPlaceHolder != NULL) { m_pLabelPlaceHolder->setSystemFontName(pFontName); @@ -141,43 +143,43 @@ void CCEditBoxImplWp8::setPlaceholderFont( const char* pFontName, int fontSize ) } } -void CCEditBoxImplWp8::setPlaceholderFontColor( const Color3B& color ) +void UIEditBoxImplWp8::setPlaceholderFontColor( const Color3B& color ) { m_colPlaceHolder = color; m_pLabelPlaceHolder->setColor(color); } -void CCEditBoxImplWp8::setInputMode( EditBox::InputMode inputMode ) +void UIEditBoxImplWp8::setInputMode( EditBox::InputMode inputMode ) { m_eEditBoxInputMode = inputMode; } -void CCEditBoxImplWp8::setInputFlag(EditBox::InputFlag inputFlag ) +void UIEditBoxImplWp8::setInputFlag(EditBox::InputFlag inputFlag ) { m_eEditBoxInputFlag = inputFlag; } -void CCEditBoxImplWp8::setMaxLength( int maxLength ) +void UIEditBoxImplWp8::setMaxLength( int maxLength ) { m_nMaxLength = maxLength; } -int CCEditBoxImplWp8::getMaxLength() +int UIEditBoxImplWp8::getMaxLength() { return m_nMaxLength; } -void CCEditBoxImplWp8::setReturnType( EditBox::KeyboardReturnType returnType ) +void UIEditBoxImplWp8::setReturnType( EditBox::KeyboardReturnType returnType ) { m_eKeyboardReturnType = returnType; } -bool CCEditBoxImplWp8::isEditing() +bool UIEditBoxImplWp8::isEditing() { return false; } -void CCEditBoxImplWp8::setText( const char* pText ) +void UIEditBoxImplWp8::setText( const char* pText ) { if (pText != NULL) { @@ -215,12 +217,12 @@ void CCEditBoxImplWp8::setText( const char* pText ) } } -const char* CCEditBoxImplWp8::getText( void ) +const char* UIEditBoxImplWp8::getText( void ) { return m_strText.c_str(); } -void CCEditBoxImplWp8::setPlaceHolder( const char* pText ) +void UIEditBoxImplWp8::setPlaceHolder( const char* pText ) { if (pText != NULL) { @@ -234,47 +236,47 @@ void CCEditBoxImplWp8::setPlaceHolder( const char* pText ) } } -void CCEditBoxImplWp8::setPosition( const Vec2& pos ) +void UIEditBoxImplWp8::setPosition( const Vec2& pos ) { } -void CCEditBoxImplWp8::setVisible( bool visible ) +void UIEditBoxImplWp8::setVisible( bool visible ) { } -void CCEditBoxImplWp8::setContentSize( const Size& size ) +void UIEditBoxImplWp8::setContentSize( const Size& size ) { } -void CCEditBoxImplWp8::setAnchorPoint( const Vec2& anchorPoint ) +void UIEditBoxImplWp8::setAnchorPoint( const Vec2& anchorPoint ) { } -void CCEditBoxImplWp8::visit( void ) +void UIEditBoxImplWp8::visit( void ) { } -void CCEditBoxImplWp8::doAnimationWhenKeyboardMove( float duration, float distance ) +void UIEditBoxImplWp8::doAnimationWhenKeyboardMove( float duration, float distance ) { } -void CCEditBoxImplWp8::closeKeyboard() +void UIEditBoxImplWp8::closeKeyboard() { } -void CCEditBoxImplWp8::onEnter( void ) +void UIEditBoxImplWp8::onEnter( void ) { } -Platform::String^ CCEditBoxImplWp8::stringToPlatformString( std::string strSrc ) +Platform::String^ UIEditBoxImplWp8::stringToPlatformString( std::string strSrc ) { // to wide char int nStrLen = MultiByteToWideChar(CP_UTF8, 0, strSrc.c_str(), -1, NULL, 0); @@ -286,7 +288,7 @@ Platform::String^ CCEditBoxImplWp8::stringToPlatformString( std::string strSrc ) return strDst; } -std::string CCEditBoxImplWp8::PlatformStringTostring( Platform::String^ strSrc ) +std::string UIEditBoxImplWp8::PlatformStringTostring( Platform::String^ strSrc ) { const wchar_t* pWStr = strSrc->Data(); int nStrLen = WideCharToMultiByte(CP_UTF8, 0, pWStr, -1, NULL, 0, NULL, NULL); @@ -300,4 +302,6 @@ std::string CCEditBoxImplWp8::PlatformStringTostring( Platform::String^ strSrc ) return strDst; } -NS_CC_EXT_END +} + +NS_CC_END diff --git a/cocos/ui/UIEditBox/UIEditBoxImplWp8.h b/cocos/ui/UIEditBox/UIEditBoxImplWp8.h new file mode 100644 index 0000000000..09d78167cd --- /dev/null +++ b/cocos/ui/UIEditBox/UIEditBoxImplWp8.h @@ -0,0 +1,88 @@ +/**************************************************************************** +Copyright (c) 2014 cocos2d-x.org + +http://www.cocos2d-x.org + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. +****************************************************************************/ +#ifndef __UIEditBoxIMPLWP8_H__ +#define __UIEditBoxIMPLWP8_H__ + +#include "UIEditBoxImpl.h" + +NS_CC_BEGIN + +namespace ui { + class EditBox; + + class CC_GUI_DLL UIEditBoxImplWp8 : public EditBoxImpl + { + public: + UIEditBoxImplWp8(EditBox* pEditText); + virtual ~UIEditBoxImplWp8(); + + virtual bool initWithSize(const Size& size); + virtual void setFont(const char* pFontName, int fontSize); + virtual void setFontColor(const Color3B& color); + virtual void setPlaceholderFont(const char* pFontName, int fontSize); + virtual void setPlaceholderFontColor(const Color3B& color); + virtual void setInputMode(EditBox::InputMode inputMode); + virtual void setInputFlag(EditBox::InputFlag inputFlag); + virtual void setMaxLength(int maxLength); + virtual int getMaxLength(); + virtual void setReturnType(EditBox::KeyboardReturnType returnType); + virtual bool isEditing(); + + virtual void setText(const char* pText); + virtual const char* getText(void); + virtual void setPlaceHolder(const char* pText); + virtual void setPosition(const Vec2& pos); + virtual void setVisible(bool visible); + virtual void setContentSize(const Size& size); + virtual void setAnchorPoint(const Vec2& anchorPoint); + virtual void visit(void); + virtual void doAnimationWhenKeyboardMove(float duration, float distance); + virtual void openKeyboard(); + virtual void closeKeyboard(); + virtual void onEnter(void); + private: + Platform::String^ stringToPlatformString(std::string strSrc); + std::string PlatformStringTostring(Platform::String^ strSrc); + private: + + Label* m_pLabel; + Label* m_pLabelPlaceHolder; + EditBox::InputMode m_eEditBoxInputMode; + EditBox::InputFlag m_eEditBoxInputFlag; + (EditBox::KeyboardReturnType m_eKeyboardReturnType; + + std::string m_strText; + std::string m_strPlaceHolder; + + Color3B m_colText; + Color3B m_colPlaceHolder; + + int m_nMaxLength; + Size m_EditSize; + }; +} + +NS_CC_END + +#endif diff --git a/cocos/ui/UIScale9Sprite.cpp b/cocos/ui/UIScale9Sprite.cpp index a7071c3729..13f6f2f92d 100644 --- a/cocos/ui/UIScale9Sprite.cpp +++ b/cocos/ui/UIScale9Sprite.cpp @@ -140,11 +140,28 @@ namespace ui { return true; } + bool Scale9Sprite::initWithBatchNode(cocos2d::SpriteBatchNode *batchnode, const cocos2d::Rect &rect, bool rotated, const cocos2d::Rect &capInsets) + { + Sprite *sprite = Sprite::createWithTexture(batchnode->getTexture()); + return init(sprite, rect, rotated, capInsets); + } + + bool Scale9Sprite::initWithBatchNode(cocos2d::SpriteBatchNode *batchnode, const cocos2d::Rect &rect, const cocos2d::Rect &capInsets) + { + return initWithBatchNode(batchnode, rect, false, capInsets); + } + #define TRANSLATE_X(x, y, xtranslate) \ x+=xtranslate; \ #define TRANSLATE_Y(x, y, ytranslate) \ -y+=ytranslate; \ +y+=ytranslate; \ + + bool Scale9Sprite::updateWithBatchNode(cocos2d::SpriteBatchNode *batchnode, const cocos2d::Rect &originalRect, bool rotated, const cocos2d::Rect &capInsets) + { + Sprite *sprite = Sprite::createWithTexture(batchnode->getTexture()); + return this->updateWithSprite(sprite, originalRect, rotated, capInsets); + } bool Scale9Sprite::updateWithSprite(Sprite* sprite, const Rect& originalRect, bool rotated, const Rect& capInsets) { diff --git a/cocos/ui/UIScale9Sprite.h b/cocos/ui/UIScale9Sprite.h index da54df5de0..6a0d8b7e4f 100644 --- a/cocos/ui/UIScale9Sprite.h +++ b/cocos/ui/UIScale9Sprite.h @@ -69,6 +69,7 @@ namespace ui { */ static Scale9Sprite* create(const std::string& file, const Rect& rect, const Rect& capInsets); + /** * Creates a 9-slice sprite with a texture file. The whole texture will be * broken down into a 3×3 grid of equal blocks. @@ -233,6 +234,9 @@ namespace ui { virtual bool init(); virtual bool init(Sprite* sprite, const Rect& rect, bool rotated, const Rect& capInsets); virtual bool init(Sprite* sprite, const Rect& rect, const Rect& capInsets); + CC_DEPRECATED_ATTRIBUTE virtual bool initWithBatchNode(SpriteBatchNode* batchnode, const Rect& rect, bool rotated, const Rect& capInsets); + CC_DEPRECATED_ATTRIBUTE virtual bool initWithBatchNode(SpriteBatchNode* batchnode, const Rect& rect, const Rect& capInsets); + /** * Creates and returns a new sprite object with the specified cap insets. * You use this method to add cap insets to a sprite or to change the existing @@ -244,6 +248,8 @@ namespace ui { Scale9Sprite* resizableSpriteWithCapInsets(const Rect& capInsets); virtual bool updateWithSprite(Sprite* sprite, const Rect& rect, bool rotated, const Rect& capInsets); + CC_DEPRECATED_ATTRIBUTE bool updateWithBatchNode(SpriteBatchNode* batchnode, const Rect& originalRect, bool rotated, const Rect& capInsets); + virtual void setSpriteFrame(SpriteFrame * spriteFrame); // overrides diff --git a/cocos/ui/proj.win32/Win32InputBox.cpp b/cocos/ui/proj.win32/Win32InputBox.cpp new file mode 100644 index 0000000000..da1cb12301 --- /dev/null +++ b/cocos/ui/proj.win32/Win32InputBox.cpp @@ -0,0 +1,383 @@ +#include "Win32InputBox.h" + +#if (CC_TARGET_PLATFORM == CC_PLATFORM_WIN32) + +#include + +#pragma warning (disable: 4312) + +typedef struct _MSDN_DLGTEMPLATEEX +{ + WORD dlgVer; + WORD signature; + DWORD helpID; + DWORD exStyle; + DWORD style; + WORD cDlgItems; + short x; + short y; + short cx; + short cy; + BYTE _rest[1]; // rest of structure +} MSDN_DLGTEMPLATEEX; + +static bool IsDlgTemplateExtended(DLGTEMPLATE *dlgTemplate) +{ + MSDN_DLGTEMPLATEEX *dgExTemplate = (MSDN_DLGTEMPLATEEX *) dlgTemplate; + + // MSDN excerpt: + //* dlgVer + // Specifies the version number of the extended dialog box template. This member must be 1. + //* signature + // Indicates whether a template is an extended dialog box template. + // If signature is 0xFFFF, this is an extended dialog box template. + // In this case, the dlgVer member specifies the template version number. + // If signature is any value other than 0xFFFF, this is a standard dialog box template that uses the DLGTEMPLATE and DLGITEMTEMPLATE structures. + + return (dgExTemplate->dlgVer == 1) && (dgExTemplate->signature == 0xFFFF); +} + +// Use alignment if supported by the compiler +#ifdef _MSC_VER + #if _MSC_VER > 1200 + __declspec(align(4)) + #endif +#endif + +// per the MSDN, the DLGTEMPLATE must be DWORD aligned +// this was generated by the DlgResToDlgTemplate tool +static unsigned char definputbox_dlg[] = +{ + 0x01,0x00,0xff,0xff,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xc8,0x00,0xc8,0x00,0x06, + 0x00,0x16,0x00,0x11,0x00,0xe7,0x00,0x6d,0x00,0x00,0x00,0x00,0x00,0x57,0x00,0x69, + 0x00,0x6e,0x00,0x33,0x00,0x32,0x00,0x49,0x00,0x6e,0x00,0x70,0x00,0x75,0x00,0x74, + 0x00,0x42,0x00,0x6f,0x00,0x78,0x00,0x00,0x00,0x08,0x00,0xbc,0x02,0x00,0x00,0x4d, + 0x00,0x53,0x00,0x20,0x00,0x53,0x00,0x68,0x00,0x65,0x00,0x6c,0x00,0x6c,0x00,0x20, + 0x00,0x44,0x00,0x6c,0x00,0x67,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x80,0x00,0x02,0x50,0x06,0x00,0x04,0x00,0x9d,0x00,0x21,0x00,0xe8, + 0x03,0x00,0x00,0xff,0xff,0x82,0x00,0x50,0x00,0x72,0x00,0x6f,0x00,0x6d,0x00,0x70, + 0x00,0x74,0x00,0x3a,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x80,0x00,0x81,0x50,0x06,0x00,0x25,0x00,0xd8,0x00,0x0e,0x00,0xe9, + 0x03,0x00,0x00,0xff,0xff,0x81,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x84,0x10,0xa1,0x50,0x06,0x00,0x37,0x00,0xd8,0x00,0x31,0x00,0xea, + 0x03,0x00,0x00,0xff,0xff,0x81,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x01,0x00,0x03,0x50,0xab,0x00,0x04,0x00,0x33,0x00,0x0e,0x00,0x01, + 0x00,0x00,0x00,0xff,0xff,0x80,0x00,0x4f,0x00,0x4b,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x03,0x50,0xab,0x00,0x15,0x00,0x33, + 0x00,0x0e,0x00,0x02,0x00,0x00,0x00,0xff,0xff,0x80,0x00,0x43,0x00,0x41,0x00,0x4e, + 0x00,0x43,0x00,0x45,0x00,0x4c,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x02,0x40,0x00,0x00,0x27,0x00,0x08,0x00,0x08,0x00,0xff, + 0xff,0xff,0xff,0xff,0xff,0x82,0x00,0x00,0x00,0x00,0x00 +}; + +static LPCTSTR definputbox_buttonnames[] = { _T("OK"), _T("CANCEL") }; +static const INT_PTR definputbox_buttonids[] = { IDOK, IDCANCEL }; + +static const INT + definputbox_id_prompt = 1000, + definputbox_id_edit1 = 1001, + definputbox_id_edit2 = 1002; + +WIN32INPUTBOX_PARAM::WIN32INPUTBOX_PARAM() +{ + bMultiline = false; + hwndOwner = 0; + DlgTemplateName = 0; + hInstance = (HINSTANCE) ::GetModuleHandle(0); + DlgTemplateData = definputbox_dlg; + + bCenter = true; + + dwStylesPlus = 0; + dwExStylesPlus = 0; + dwStylesMinus = 0xFFFFFFFF; + dwExStylesMinus = 0xFFFFFFFF; + + xPos = yPos = -1; + + szResult = 0; + nResultSize = 0; +} + +CWin32InputBox::CWin32InputBox(WIN32INPUTBOX_PARAM *param) +{ + _param = param; +} + +CWin32InputBox::~CWin32InputBox() +{ + +} + +void CWin32InputBox::SetParam(WIN32INPUTBOX_PARAM *param) +{ + _param = param; +} + +WIN32INPUTBOX_PARAM *CWin32InputBox::GetParam() +{ + return _param; +} + +INT_PTR CWin32InputBox::InputBoxEx(WIN32INPUTBOX_PARAM *param) +{ + // Check mandatory parameters + if (param->szResult == 0) + { + ::SetLastError(ERROR_INVALID_PARAMETER); + return 0; + } + + LPDLGTEMPLATE dlgTemplate; + + if (param->DlgTemplateName != 0) + { + HMODULE hModule = (HMODULE)param->hInstance; +#ifdef __MINGW32__ + HRSRC rcDlg = ::FindResource(hModule, (LPWSTR)(ULONG_PTR)(size_t)(param->DlgTemplateName), RT_DIALOG); +#else + HRSRC rcDlg = ::FindResource(hModule, MAKEINTRESOURCE(param->DlgTemplateName), RT_DIALOG); +#endif + if (rcDlg == nullptr) + return 0; + + HGLOBAL hglobalDlg = ::LoadResource(hModule, rcDlg); + if (hglobalDlg == nullptr) + return 0; + + dlgTemplate = (LPDLGTEMPLATE) hglobalDlg; + } + else if (param->DlgTemplateData != 0) + { + dlgTemplate = (LPDLGTEMPLATE) param->DlgTemplateData; + } + + MSDN_DLGTEMPLATEEX *dlgTemplateEx = + IsDlgTemplateExtended((LPDLGTEMPLATE) dlgTemplate) ? (MSDN_DLGTEMPLATEEX *) dlgTemplate : 0; + + if (dlgTemplateEx != 0) + { + dlgTemplateEx->exStyle |= param->dwExStylesPlus; + dlgTemplateEx->style |= param->dwStylesPlus; + dlgTemplateEx->exStyle &= param->dwExStylesMinus; + dlgTemplateEx->style &= param->dwStylesMinus; + + if (param->bCenter) + dlgTemplateEx->style |= DS_CENTER; + + if (param->xPos != -1) + dlgTemplateEx->x = param->xPos; + if (param->yPos != -1) + dlgTemplateEx->y = param->yPos; + } + else + { + dlgTemplate->dwExtendedStyle |= param->dwExStylesPlus; + dlgTemplate->style |= param->dwStylesPlus; + dlgTemplate->dwExtendedStyle &= param->dwExStylesMinus; + dlgTemplate->style &= param->dwStylesMinus; + + if (param->bCenter) + dlgTemplate->style |= DS_CENTER; + + if (param->xPos != -1) + dlgTemplate->x = param->xPos; + + if (param->yPos != -1) + dlgTemplate->y = param->yPos; + } + + CWin32InputBox inputbox(param); + + // Resize dialog and SHOW or HIDE multiline + INT_PTR r = ::DialogBoxIndirectParam(param->hInstance, dlgTemplate, param->hwndOwner, (DLGPROC)DlgProc, (LPARAM)&inputbox); + + return r; +} + +INT_PTR CWin32InputBox::InputBox( + LPCSTR szTitle, + LPCSTR szPrompt, + LPSTR szResult, + DWORD nResultSize, + bool bMultiLine, + HWND hwndParent) +{ + WIN32INPUTBOX_PARAM param; + + param.szTitle = szTitle; + param.szPrompt = szPrompt; + param.szResult = szResult; + param.nResultSize = nResultSize; + param.bMultiline = bMultiLine; + param.hwndOwner = hwndParent; + return InputBoxEx(¶m); +} + +void CWin32InputBox::InitDialog() +{ + // Set the button captions + for (size_t i=0;ihDlg, (int) definputbox_buttonids[i], definputbox_buttonnames[i]); + + // Set other controls + ::SetWindowTextA(_param->hDlg, Utf8ToAnsi(_param->szTitle).c_str()); + ::SetDlgItemTextA(_param->hDlg, definputbox_id_prompt, Utf8ToAnsi(_param->szPrompt).c_str()); + + HWND hwndEdit1 = ::GetDlgItem(_param->hDlg, definputbox_id_edit1); + HWND hwndEdit2 = ::GetDlgItem(_param->hDlg, definputbox_id_edit2); + + if (_param->bMultiline) + _hwndEditCtrl = hwndEdit2; + else + _hwndEditCtrl = hwndEdit1; + + ::SetWindowTextA(_hwndEditCtrl, Utf8ToAnsi(_param->szResult).c_str()); + + RECT rectDlg, rectEdit1, rectEdit2; + + ::GetWindowRect(_param->hDlg, &rectDlg); + ::GetWindowRect(hwndEdit1, &rectEdit1); + ::GetWindowRect(hwndEdit2, &rectEdit2); + + if (_param->bMultiline) + { + ::ShowWindow(hwndEdit1, SW_HIDE); + ::SetWindowPos( + hwndEdit2, + HWND_NOTOPMOST, + rectEdit1.left - rectDlg.left, + (rectEdit1.top - rectDlg.top) - (rectEdit1.bottom - rectEdit1.top), + 0, + 0, + SWP_NOSIZE | SWP_NOZORDER); + + ::SetWindowPos( + _param->hDlg, + HWND_NOTOPMOST, + 0, + 0, + rectDlg.right - rectDlg.left, + rectDlg.bottom - rectDlg.top - (rectEdit1.bottom - rectEdit1.top), + SWP_NOMOVE); + + } + else + { + ::SetWindowPos( + _param->hDlg, + HWND_NOTOPMOST, + 0, + 0, + rectDlg.right - rectDlg.left, + rectEdit1.bottom - rectDlg.top + 5, + SWP_NOMOVE); + + ::ShowWindow(hwndEdit2, SW_HIDE); + } +} + +// Message handler for about box. +LRESULT CALLBACK CWin32InputBox::DlgProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam) +{ + CWin32InputBox *_this = (CWin32InputBox *) ::GetWindowLongPtr(hDlg, GWLP_USERDATA); + WIN32INPUTBOX_PARAM *param = _this ? _this->GetParam() : 0; + + switch (message) + { + case WM_INITDIALOG: + { + SetWindowLongPtr(hDlg, GWLP_USERDATA, (LONG_PTR) lParam); + + _this = (CWin32InputBox *) lParam; + _this->_param->hDlg = hDlg; + _this->InitDialog(); + return TRUE; + } + + case WM_COMMAND: + { +#ifdef _MY_DEBUG + CHAR buf[1024]; + static int i=0; + sprintf(buf, "WM_COMMAND: %09d wParam=%08X lParam=%08X\n", i++, wParam, lParam); + OutputDebugString(buf); +#endif + INT_PTR buttonId = LOWORD(wParam); + for (size_t i=0; + i_hwndEditCtrl, + _this->_param->szResult, + _this->_param->nResultSize); + + std::string strUtf8 = AnsiToUtf8(_this->_param->szResult); + + memset(_this->_param->szResult, 0, _this->_param->nResultSize); + strncpy(_this->_param->szResult, strUtf8.c_str(), _this->_param->nResultSize-1); + + ::EndDialog(hDlg, buttonId); + return TRUE; + } + } + } + break; + } + return FALSE; +} + + +std::string CWin32InputBox::AnsiToUtf8(std::string strAnsi) +{ + std::string ret; + if (strAnsi.length() > 0) + { + int nWideStrLength = MultiByteToWideChar(CP_ACP, 0, strAnsi.c_str(), -1, nullptr, 0); + WCHAR* pwszBuf = (WCHAR*)malloc((nWideStrLength+1)*sizeof(WCHAR)); + memset(pwszBuf, 0, (nWideStrLength+1)*sizeof(WCHAR)); + MultiByteToWideChar(CP_ACP, 0, strAnsi.c_str(), -1, pwszBuf, (nWideStrLength+1)*sizeof(WCHAR)); + + int nUtf8Length = WideCharToMultiByte( CP_UTF8,0,pwszBuf,-1,nullptr,0,nullptr,FALSE ); + char* pszUtf8Buf = (char*)malloc((nUtf8Length+1)*sizeof(char)); + memset(pszUtf8Buf, 0, (nUtf8Length+1)*sizeof(char)); + + WideCharToMultiByte(CP_UTF8, 0, pwszBuf, -1, pszUtf8Buf, (nUtf8Length+1)*sizeof(char), nullptr, FALSE); + ret = pszUtf8Buf; + + free(pszUtf8Buf); + free(pwszBuf); + } + return ret; +} + +std::string CWin32InputBox::Utf8ToAnsi(std::string strUTF8) +{ + std::string ret; + if (strUTF8.length() > 0) + { + int nWideStrLength = MultiByteToWideChar(CP_UTF8, 0, strUTF8.c_str(), -1, nullptr, 0); + WCHAR* pwszBuf = (WCHAR*)malloc((nWideStrLength+1)*sizeof(WCHAR)); + memset(pwszBuf, 0, (nWideStrLength+1)*sizeof(WCHAR)); + MultiByteToWideChar(CP_UTF8, 0, strUTF8.c_str(), -1, pwszBuf, (nWideStrLength+1)*sizeof(WCHAR)); + + int nAnsiStrLength = WideCharToMultiByte( CP_ACP,0,pwszBuf,-1,nullptr,0,nullptr,FALSE ); + char* pszAnsiBuf = (char*)malloc((nAnsiStrLength+1)*sizeof(char)); + memset(pszAnsiBuf, 0, (nAnsiStrLength+1)*sizeof(char)); + + WideCharToMultiByte(CP_ACP, 0, pwszBuf, -1, pszAnsiBuf, (nAnsiStrLength+1)*sizeof(char), nullptr, FALSE); + ret = pszAnsiBuf; + + free(pszAnsiBuf); + free(pwszBuf); + } + + return ret; +} + + + +#endif /* #if (CC_TARGET_PLATFORM == CC_PLATFORM_WIN32) */ diff --git a/cocos/ui/proj.win32/Win32InputBox.h b/cocos/ui/proj.win32/Win32InputBox.h new file mode 100644 index 0000000000..1fd46a5593 --- /dev/null +++ b/cocos/ui/proj.win32/Win32InputBox.h @@ -0,0 +1,106 @@ +#ifndef __03022006__WIN32INPUTBOX__ +#define __03022006__WIN32INPUTBOX__ + +#include "cocos2d.h" + +#if (CC_TARGET_PLATFORM == CC_PLATFORM_WIN32) +/* + +This library is (c) Elias Bachaalany aka lallous +You may use this library under the following license agreement: + +The zlib/libpng License. +--------------------------- +This software is provided 'as-is', without any express or implied warranty. In no event will the authors be held liable for any damages arising from the use of this software. + +Permission is granted to anyone to use this software for any purpose, including commercial applications, +and to alter it and redistribute it freely, subject to the following restrictions: + +1. The origin of this software must not be misrepresented; + you must not claim that you wrote the original software. + If you use this software in a product, an acknowledgment in the product + documentation would be appreciated but is not required. +2. Altered source versions must be plainly marked as such, + and must not be misrepresented as being the original software. +3. This notice may not be removed or altered from any source distribution. + +*/ + +#include +#include + +class CWin32InputBox; + +// Structure used to orient the inputbox behavior +struct WIN32INPUTBOX_PARAM +{ + friend class CWin32InputBox; + + // + IN OPTIONAL bool bMultiline; + + // Pass this as none zero so to use this memory dlg template + IN OPTIONAL LPVOID DlgTemplateData; + + // Pass this as none ZERO so to load DLGTEMPLATE from resources + IN OPTIONAL LPCSTR DlgTemplateName; + + // passing both "DlgTemplateName" and "DlgTemplateData" ZERO will cause + // the dialog to use his default embedded resource + + // Center on monitor or owner window? + IN OPTIONAL bool bCenter; + + // Want to add more styles to the dialog? + IN OPTIONAL DWORD dwStylesPlus, dwStylesMinus; + IN OPTIONAL DWORD dwExStylesPlus, dwExStylesMinus; + + IN LPCSTR szTitle, szPrompt; + + // Return buffer + OUT LPSTR szResult; + IN DWORD nResultSize; + + // Owner window + HWND hwndOwner; + HINSTANCE hInstance; + + short xPos, yPos; + + WIN32INPUTBOX_PARAM(); +private: + HWND hDlg; +}; + +class CWin32InputBox +{ +private: + WIN32INPUTBOX_PARAM *_param; + static LRESULT CALLBACK DlgProc(HWND, UINT, WPARAM, LPARAM); + HWND _hwndEditCtrl; + + void InitDialog(); + void SetParam(WIN32INPUTBOX_PARAM *); + WIN32INPUTBOX_PARAM * GetParam(); + +public: + + CWin32InputBox(WIN32INPUTBOX_PARAM *); + ~CWin32InputBox(); + + static INT_PTR InputBoxEx(WIN32INPUTBOX_PARAM *); + static INT_PTR InputBox( + LPCSTR szTitle, + LPCSTR szPrompt, + LPSTR szResult, + DWORD nResultSize, + bool bMultiLine = false, + HWND hwndParent = 0); + + static std::string AnsiToUtf8(std::string strAnsi); + static std::string Utf8ToAnsi(std::string strUTF8); +}; + +#endif /* (CC_TARGET_PLATFORM == CC_PLATFORM_WIN32) */ + +#endif diff --git a/cocos/ui/proj.win32/libui.vcxproj b/cocos/ui/proj.win32/libui.vcxproj new file mode 100644 index 0000000000..92003d88cd --- /dev/null +++ b/cocos/ui/proj.win32/libui.vcxproj @@ -0,0 +1,171 @@ + + + + + Debug + Win32 + + + Release + Win32 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + {21b2c324-891f-48ea-ad1a-5ae13de12e28} + + + {98a51ba8-fc3a-415b-ac8f-8c7bd464e93e} + + + + {7E06E92C-537A-442B-9E4A-4761C84F8A1A} + libui + libui + + + + DynamicLibrary + true + v100 + v110 + v110_xp + v120 + v120_xp + Unicode + + + DynamicLibrary + false + v100 + v110 + v110_xp + v120 + v120_xp + true + Unicode + + + + + + + + + + + + + + + $(SolutionDir)$(Configuration).win32\ + $(Configuration).win32\ + + + $(SolutionDir)$(Configuration).win32\ + $(Configuration).win32\ + + + + Level3 + Disabled + + + $(EngineRoot);$(EngineRoot)cocos;$(EngineRoot)cocos\audio\include;$(EngineRoot)cocos\editor-support;$(EngineRoot)external;$(EngineRoot)extensions;%(AdditionalIncludeDirectories) + WIN32;_DEBUG;_WINDOWS;COCOS2DXWIN32_EXPORTS;GL_GLEXT_PROTOTYPES;COCOS2D_DEBUG=1;_CRT_SECURE_NO_WARNINGS;_SCL_SECURE_NO_WARNINGS;_USEGUIDLL;%(PreprocessorDefinitions) + true + 4267;4251;4244;%(DisableSpecificWarnings) + false + OldStyle + + + true + $(OutDir);%(AdditionalLibraryDirectories) + opengl32.lib;glew32.lib;%(AdditionalDependencies) + + + + + Level3 + MinSpace + true + true + + + WIN32;_WINDOWS;COCOS2DXWIN32_EXPORTS;GL_GLEXT_PROTOTYPES;_CRT_SECURE_NO_WARNINGS;_SCL_SECURE_NO_WARNINGS;_USEGUIDLL;%(PreprocessorDefinitions) + $(EngineRoot);$(EngineRoot)cocos;$(EngineRoot)cocos\audio\include;$(EngineRoot)cocos\editor-support;$(EngineRoot)external;$(EngineRoot)extensions;%(AdditionalIncludeDirectories) + None + false + + + true + true + true + $(OutDir);%(AdditionalLibraryDirectories) + opengl32.lib;glew32.lib;%(AdditionalDependencies) + + + + + + \ No newline at end of file diff --git a/cocos/ui/proj.win32/libui.vcxproj.filters b/cocos/ui/proj.win32/libui.vcxproj.filters new file mode 100644 index 0000000000..2933d8b07f --- /dev/null +++ b/cocos/ui/proj.win32/libui.vcxproj.filters @@ -0,0 +1,195 @@ + + + + + {e31ab7d3-b8b2-467f-9e08-fd5fe168b491} + + + {f9d13563-9e5e-4b35-b0e7-d41f587efa42} + + + {ed8a2ae0-5690-4d0d-829b-7c07164c0597} + + + {5f6e9e52-fbe7-4073-ac71-98632f9e6781} + + + {b59b178a-b7e0-4826-ba07-44c46cd29a10} + + + {08fb4468-821b-4e5c-9298-8b57a3152a5b} + + + + + UIWidgets\ScrollWidget + + + UIWidgets\ScrollWidget + + + UIWidgets\ScrollWidget + + + UIWidgets + + + UIWidgets + + + UIWidgets + + + UIWidgets + + + UIWidgets + + + UIWidgets + + + System + + + System + + + BaseClasses + + + Layouts + + + Layouts + + + UIWidgets + + + UIWidgets + + + UIWidgets + + + UIWidgets + + + Layouts + + + Layouts + + + Layouts + + + Layouts + + + System + + + System + + + BaseClasses + + + UIWidgets\UIEditBox + + + UIWidgets\UIEditBox + + + UIWidgets\UIEditBox + + + UIWidgets\UIEditBox + + + + + UIWidgets\ScrollWidget + + + UIWidgets\ScrollWidget + + + UIWidgets\ScrollWidget + + + UIWidgets + + + UIWidgets + + + UIWidgets + + + UIWidgets + + + UIWidgets + + + UIWidgets + + + System + + + System + + + BaseClasses + + + Layouts + + + Layouts + + + UIWidgets + + + UIWidgets + + + UIWidgets + + + UIWidgets + + + Layouts + + + Layouts + + + Layouts + + + Layouts + + + System + + + BaseClasses + + + UIWidgets\UIEditBox + + + UIWidgets\UIEditBox + + + UIWidgets\UIEditBox + + + \ No newline at end of file diff --git a/cocos/ui/proj.wp8/libGUI.vcxproj b/cocos/ui/proj.wp8/libGUI.vcxproj index 5e2e4e6453..47ec5d9d10 100644 --- a/cocos/ui/proj.wp8/libGUI.vcxproj +++ b/cocos/ui/proj.wp8/libGUI.vcxproj @@ -184,6 +184,9 @@ + + + @@ -210,6 +213,8 @@ + + diff --git a/cocos/ui/proj.wp8/libGUI.vcxproj.filters b/cocos/ui/proj.wp8/libGUI.vcxproj.filters index 7a7b4ae6b4..c0a7f8250b 100644 --- a/cocos/ui/proj.wp8/libGUI.vcxproj.filters +++ b/cocos/ui/proj.wp8/libGUI.vcxproj.filters @@ -87,6 +87,15 @@ BaseClasses + + UIWidgets + + + UIWidgets + + + UIWidgets +
@@ -161,5 +170,11 @@ BaseClasses + + UIWidgets + + + UIWidgets + \ No newline at end of file diff --git a/extensions/Android.mk b/extensions/Android.mk index 89877aa54d..2603f2f3d2 100644 --- a/extensions/Android.mk +++ b/extensions/Android.mk @@ -18,11 +18,6 @@ GUI/CCControlExtension/CCControlStepper.cpp \ GUI/CCControlExtension/CCControlSwitch.cpp \ GUI/CCControlExtension/CCControlUtils.cpp \ GUI/CCControlExtension/CCInvocation.cpp \ -GUI/CCControlExtension/CCScale9Sprite.cpp \ -GUI/CCEditBox/CCEditBox.cpp \ -GUI/CCEditBox/CCEditBoxImplAndroid.cpp \ -GUI/CCEditBox/CCEditBoxImplNone.cpp \ -GUI/CCEditBox/CCEditBoxImplWin.cpp \ GUI/CCScrollView/CCScrollView.cpp \ GUI/CCScrollView/CCTableView.cpp \ GUI/CCScrollView/CCTableViewCell.cpp \ @@ -33,6 +28,10 @@ LOCAL_STATIC_LIBRARIES := cocos2dx_internal_static LOCAL_STATIC_LIBRARIES += cocos_curl_static LOCAL_STATIC_LIBRARIES += box2d_static +GU/CCEditBox/CCEditBox.cpp \ +GUI/CCEditBox/CCEditBoxImplAndroid.cpp \ +GUI/CCEditBox/CCEditBoxImplNone.cpp \ +GUI/CCEditBox/CCEditBoxImplWin.cpp \ LOCAL_CXXFLAGS += -fexceptions LOCAL_C_INCLUDES := $(LOCAL_PATH)/.. \ diff --git a/extensions/CMakeLists.txt b/extensions/CMakeLists.txt deleted file mode 100644 index b3c609beb5..0000000000 --- a/extensions/CMakeLists.txt +++ /dev/null @@ -1,52 +0,0 @@ -set(EXTENSIONS_SRC - assets-manager/AssetsManager.cpp - GUI/CCControlExtension/CCControl.cpp - GUI/CCControlExtension/CCControlButton.cpp - GUI/CCControlExtension/CCControlColourPicker.cpp - GUI/CCControlExtension/CCControlHuePicker.cpp - GUI/CCControlExtension/CCControlPotentiometer.cpp - GUI/CCControlExtension/CCControlSaturationBrightnessPicker.cpp - GUI/CCControlExtension/CCControlSlider.cpp - GUI/CCControlExtension/CCControlStepper.cpp - GUI/CCControlExtension/CCControlSwitch.cpp - GUI/CCControlExtension/CCControlUtils.cpp - GUI/CCControlExtension/CCInvocation.cpp - GUI/CCControlExtension/CCScale9Sprite.cpp - GUI/CCEditBox/CCEditBox.cpp - GUI/CCEditBox/CCEditBoxImplAndroid.cpp - GUI/CCEditBox/CCEditBoxImplNone.cpp - GUI/CCEditBox/CCEditBoxImplWin.cpp - GUI/CCScrollView/CCScrollView.cpp - GUI/CCScrollView/CCTableView.cpp - GUI/CCScrollView/CCTableViewCell.cpp - physics-nodes/CCPhysicsDebugNode.cpp - physics-nodes/CCPhysicsSprite.cpp -) - -if(WIN32) - ADD_DEFINITIONS(-DUNICODE -D_UNICODE) - - set(PLATFORM_EXTENSIONS_SRC - proj.win32/Win32InputBox.cpp - ) -elseif(APPLE) - -else() - -endif() - -include_directories( - .. -) - -add_library(extensions STATIC - ${EXTENSIONS_SRC} - ${PLATFORM_EXTENSIONS_SRC} -) - -set_target_properties(extensions - PROPERTIES - ARCHIVE_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/lib" - LIBRARY_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/lib" -) - diff --git a/extensions/ExtensionDeprecated.cpp b/extensions/ExtensionDeprecated.cpp new file mode 100644 index 0000000000..d3e3e65e5d --- /dev/null +++ b/extensions/ExtensionDeprecated.cpp @@ -0,0 +1,25 @@ +/**************************************************************************** + Copyright (c) 2013-2014 Chukong Technologies Inc. + + http://www.cocos2d-x.org + + Permission is hereby granted, free of charge, to any person obtaining a copy + of this software and associated documentation files (the "Software"), to deal + in the Software without restriction, including without limitation the rights + to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + copies of the Software, and to permit persons to whom the Software is + furnished to do so, subject to the following conditions: + + The above copyright notice and this permission notice shall be included in + all copies or substantial portions of the Software. + + THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN + THE SOFTWARE. + ****************************************************************************/ + +#include "ExtensionDeprecated.h" diff --git a/extensions/ExtensionDeprecated.h b/extensions/ExtensionDeprecated.h new file mode 100644 index 0000000000..8abdf919b6 --- /dev/null +++ b/extensions/ExtensionDeprecated.h @@ -0,0 +1,39 @@ +/**************************************************************************** + Copyright (c) 2013-2014 Chukong Technologies Inc. + + http://www.cocos2d-x.org + + Permission is hereby granted, free of charge, to any person obtaining a copy + of this software and associated documentation files (the "Software"), to deal + in the Software without restriction, including without limitation the rights + to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + copies of the Software, and to permit persons to whom the Software is + furnished to do so, subject to the following conditions: + + The above copyright notice and this permission notice shall be included in + all copies or substantial portions of the Software. + + THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN + THE SOFTWARE. + ****************************************************************************/ + +#ifndef __cocos2d_libs__ExtensionDeprecated__ +#define __cocos2d_libs__ExtensionDeprecated__ + +#include "ui/UIEditBox/UIEditBox.h" +#include "ExtensionMacros.h" + +NS_CC_EXT_BEGIN + +CC_DEPRECATED_ATTRIBUTE typedef ui::EditBox EditBox; +CC_DEPRECATED_ATTRIBUTE typedef ui::EditBoxDelegate EditBoxDelegate; +CC_DEPRECATED_ATTRIBUTE typedef ui::Scale9Sprite Scale9Sprite; + +NS_CC_EXT_END + +#endif /* defined(__cocos2d_libs__ExtensionDeprecated__) */ diff --git a/extensions/GUI/CCControlExtension/CCControlButton.cpp b/extensions/GUI/CCControlExtension/CCControlButton.cpp index f7cc5b71b6..9a69de517e 100644 --- a/extensions/GUI/CCControlExtension/CCControlButton.cpp +++ b/extensions/GUI/CCControlExtension/CCControlButton.cpp @@ -26,7 +26,6 @@ */ #include "CCControlButton.h" -#include "CCScale9Sprite.h" #include "2d/CCLabel.h" #include "2d/CCAction.h" #include "2d/CCActionInterval.h" @@ -64,10 +63,10 @@ ControlButton::~ControlButton() bool ControlButton::init() { - return this->initWithLabelAndBackgroundSprite(Label::createWithSystemFont("", "Helvetica", 12), Scale9Sprite::create()); + return this->initWithLabelAndBackgroundSprite(Label::createWithSystemFont("", "Helvetica", 12), cocos2d::ui::Scale9Sprite::create()); } -bool ControlButton::initWithLabelAndBackgroundSprite(Node* node, Scale9Sprite* backgroundSprite) +bool ControlButton::initWithLabelAndBackgroundSprite(Node* node, ui::Scale9Sprite* backgroundSprite) { if (Control::init()) { @@ -121,7 +120,7 @@ bool ControlButton::initWithLabelAndBackgroundSprite(Node* node, Scale9Sprite* b } } -ControlButton* ControlButton::create(Node* label, Scale9Sprite* backgroundSprite) +ControlButton* ControlButton::create(Node* label, cocos2d::ui::Scale9Sprite* backgroundSprite) { ControlButton *pRet = new (std::nothrow) ControlButton(); pRet->initWithLabelAndBackgroundSprite(label, backgroundSprite); @@ -131,7 +130,7 @@ ControlButton* ControlButton::create(Node* label, Scale9Sprite* backgroundSprite bool ControlButton::initWithTitleAndFontNameAndFontSize(const std::string& title, const std::string& fontName, float fontSize) { - return initWithLabelAndBackgroundSprite(Label::createWithSystemFont(title, fontName, fontSize), Scale9Sprite::create()); + return initWithLabelAndBackgroundSprite(Label::createWithSystemFont(title, fontName, fontSize), cocos2d::ui::Scale9Sprite::create()); } ControlButton* ControlButton::create(const std::string& title, const std::string& fontName, float fontSize) @@ -142,13 +141,13 @@ ControlButton* ControlButton::create(const std::string& title, const std::string return pRet; } -bool ControlButton::initWithBackgroundSprite(Scale9Sprite* sprite) +bool ControlButton::initWithBackgroundSprite(cocos2d::ui::Scale9Sprite* sprite) { Label *label = Label::createWithSystemFont("", "Arial", 30);// return initWithLabelAndBackgroundSprite(label, sprite); } -ControlButton* ControlButton::create(Scale9Sprite* sprite) +ControlButton* ControlButton::create(cocos2d::ui::Scale9Sprite* sprite) { ControlButton *pRet = new (std::nothrow) ControlButton(); pRet->initWithBackgroundSprite(sprite); @@ -423,7 +422,7 @@ const std::string& ControlButton::getTitleBMFontForState(State state) } -Scale9Sprite* ControlButton::getBackgroundSpriteForState(State state) +ui::Scale9Sprite* ControlButton::getBackgroundSpriteForState(State state) { auto backgroundSprite = _backgroundSpriteDispatchTable.at((int)state); if (backgroundSprite) @@ -434,7 +433,7 @@ Scale9Sprite* ControlButton::getBackgroundSpriteForState(State state) } -void ControlButton::setBackgroundSpriteForState(Scale9Sprite* sprite, State state) +void ControlButton::setBackgroundSpriteForState(ui::Scale9Sprite* sprite, State state) { Size oldPreferredSize = _preferredSize; @@ -470,7 +469,7 @@ void ControlButton::setBackgroundSpriteForState(Scale9Sprite* sprite, State stat void ControlButton::setBackgroundSpriteFrameForState(SpriteFrame * spriteFrame, State state) { - Scale9Sprite * sprite = Scale9Sprite::createWithSpriteFrame(spriteFrame); + ui::Scale9Sprite * sprite = ui::Scale9Sprite::createWithSpriteFrame(spriteFrame); this->setBackgroundSpriteForState(sprite, state); } diff --git a/extensions/GUI/CCControlExtension/CCControlButton.h b/extensions/GUI/CCControlExtension/CCControlButton.h index f7484e2172..2ead117306 100644 --- a/extensions/GUI/CCControlExtension/CCControlButton.h +++ b/extensions/GUI/CCControlExtension/CCControlButton.h @@ -32,9 +32,8 @@ #include "CCControl.h" #include "CCInvocation.h" -#include "CCScale9Sprite.h" #include "base/CCMap.h" -#include "extensions/ExtensionExport.h" +#include "ui/UIScale9Sprite.h" NS_CC_EXT_BEGIN @@ -56,8 +55,8 @@ class CC_EX_DLL ControlButton : public Control { public: static ControlButton* create(); - static ControlButton* create(Scale9Sprite* sprite); - static ControlButton* create(Node* label, Scale9Sprite* backgroundSprite); + static ControlButton* create(cocos2d::ui::Scale9Sprite* sprite); + static ControlButton* create(Node* label, cocos2d::ui::Scale9Sprite* backgroundSprite); static ControlButton* create(const std::string& title, const std::string& fontName, float fontSize); virtual void needsLayout(void); @@ -149,7 +148,7 @@ public: * @param state The state that uses the background sprite. Possible values are * described in "CCControlState". */ - virtual Scale9Sprite* getBackgroundSpriteForState(State state); + virtual cocos2d::ui::Scale9Sprite* getBackgroundSpriteForState(State state); /** * Sets the background sprite to use for the specified button state. @@ -158,7 +157,7 @@ public: * @param state The state that uses the specified image. The values are described * in "CCControlState". */ - virtual void setBackgroundSpriteForState(Scale9Sprite* sprite, State state); + virtual void setBackgroundSpriteForState(cocos2d::ui::Scale9Sprite* sprite, State state); /** * Sets the background spriteFrame to use for the specified button state. @@ -203,8 +202,8 @@ CC_CONSTRUCTOR_ACCESS: virtual ~ControlButton(); virtual bool init() override; - virtual bool initWithLabelAndBackgroundSprite(Node* label, Scale9Sprite* backgroundSprite); - virtual bool initWithBackgroundSprite(Scale9Sprite* sprite); + virtual bool initWithLabelAndBackgroundSprite(Node* label, cocos2d::ui::Scale9Sprite* backgroundSprite); + virtual bool initWithBackgroundSprite(cocos2d::ui::Scale9Sprite* sprite); virtual bool initWithTitleAndFontNameAndFontSize(const std::string& title, const std::string& fontName, float fontSize); protected: @@ -222,7 +221,7 @@ protected: CC_SYNTHESIZE_RETAIN(Node*, _titleLabel, TitleLabel); /** The current background sprite. */ - CC_SYNTHESIZE_RETAIN(Scale9Sprite*, _backgroundSprite, BackgroundSprite); + CC_SYNTHESIZE_RETAIN(cocos2d::ui::Scale9Sprite*, _backgroundSprite, BackgroundSprite); /** The prefered size of the button, if label is larger it will be expanded. */ CC_PROPERTY_PASS_BY_REF(Size, _preferredSize, PreferredSize); @@ -238,7 +237,7 @@ protected: std::unordered_map _titleColorDispatchTable; Map _titleLabelDispatchTable; - Map _backgroundSpriteDispatchTable; + Map _backgroundSpriteDispatchTable; /* Define the button margin for Top/Bottom edge */ CC_SYNTHESIZE_READONLY(int, _marginV, VerticalMargin); diff --git a/extensions/GUI/CCControlExtension/CCControlExtensions.h b/extensions/GUI/CCControlExtension/CCControlExtensions.h index c4548bf535..2cbae97035 100644 --- a/extensions/GUI/CCControlExtension/CCControlExtensions.h +++ b/extensions/GUI/CCControlExtension/CCControlExtensions.h @@ -25,7 +25,6 @@ THE SOFTWARE. #ifndef __CCCONTROL_EXTENSIONS_H__ #define __CCCONTROL_EXTENSIONS_H__ -#include "CCScale9Sprite.h" #include "CCControl.h" #include "CCControlButton.h" #include "CCControlColourPicker.h" diff --git a/extensions/GUI/CCControlExtension/CCScale9Sprite.cpp b/extensions/GUI/CCControlExtension/CCScale9Sprite.cpp deleted file mode 100644 index 021de0489e..0000000000 --- a/extensions/GUI/CCControlExtension/CCScale9Sprite.cpp +++ /dev/null @@ -1,816 +0,0 @@ -/**************************************************************************** -Copyright (c) 2012 cocos2d-x.org - -http://www.cocos2d-x.org - -Created by Jung Sang-Taik on 12. 3. 16.. -Copyright (c) 2012 Neofect. All rights reserved. - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. -****************************************************************************/ - -#include "CCScale9Sprite.h" -#include "base/CCPlatformMacros.h" -#include "2d/CCSprite.h" -#include "2d/CCSpriteFrameCache.h" - -NS_CC_EXT_BEGIN - -Scale9Sprite::Scale9Sprite() -: _spritesGenerated(false) -, _spriteFrameRotated(false) -, _positionsAreDirty(false) -, _scale9Image(nullptr) -, _topLeft(nullptr) -, _top(nullptr) -, _topRight(nullptr) -, _left(nullptr) -, _centre(nullptr) -, _right(nullptr) -, _bottomLeft(nullptr) -, _bottom(nullptr) -, _bottomRight(nullptr) -, _opacityModifyRGB(false) -, _insetLeft(0) -, _insetTop(0) -, _insetRight(0) -, _insetBottom(0) -{ - -} - -Scale9Sprite::~Scale9Sprite() -{ - CC_SAFE_RELEASE(_topLeft); - CC_SAFE_RELEASE(_top); - CC_SAFE_RELEASE(_topRight); - CC_SAFE_RELEASE(_left); - CC_SAFE_RELEASE(_centre); - CC_SAFE_RELEASE(_right); - CC_SAFE_RELEASE(_bottomLeft); - CC_SAFE_RELEASE(_bottom); - CC_SAFE_RELEASE(_bottomRight); - CC_SAFE_RELEASE(_scale9Image); -} - -bool Scale9Sprite::init() -{ - return this->initWithBatchNode(nullptr, Rect::ZERO, Rect::ZERO); -} - -bool Scale9Sprite::initWithBatchNode(SpriteBatchNode* batchnode, const Rect& rect, const Rect& capInsets) -{ - return this->initWithBatchNode(batchnode, rect, false, capInsets); -} - -bool Scale9Sprite::initWithBatchNode(SpriteBatchNode* batchnode, const Rect& rect, bool rotated, const Rect& capInsets) -{ - if(batchnode) - { - this->updateWithBatchNode(batchnode, rect, rotated, capInsets); - } - this->setCascadeColorEnabled(true); - this->setCascadeOpacityEnabled(true); - this->setAnchorPoint(Vec2(0.5f, 0.5f)); - this->_positionsAreDirty = true; - - return true; -} - -#define TRANSLATE_X(x, y, xtranslate) \ - x+=xtranslate; \ - -#define TRANSLATE_Y(x, y, ytranslate) \ - y+=ytranslate; \ - -bool Scale9Sprite::updateWithBatchNode(SpriteBatchNode* batchnode, const Rect& originalRect, bool rotated, const Rect& capInsets) -{ - GLubyte opacity = getOpacity(); - Color3B color = getColor(); - Rect rect(originalRect); - - // Release old sprites - this->removeAllChildrenWithCleanup(true); - - CC_SAFE_RELEASE(this->_centre); - CC_SAFE_RELEASE(this->_top); - CC_SAFE_RELEASE(this->_topLeft); - CC_SAFE_RELEASE(this->_topRight); - CC_SAFE_RELEASE(this->_left); - CC_SAFE_RELEASE(this->_right); - CC_SAFE_RELEASE(this->_bottomLeft); - CC_SAFE_RELEASE(this->_bottom); - CC_SAFE_RELEASE(this->_bottomRight); - - - if(this->_scale9Image != batchnode) - { - CC_SAFE_RELEASE(this->_scale9Image); - _scale9Image = batchnode; - CC_SAFE_RETAIN(_scale9Image); - } - - if (!_scale9Image) - { - return false; - } - - _capInsets = capInsets; - _spriteFrameRotated = rotated; - - // If there is no given rect - if ( rect.equals(Rect::ZERO) ) - { - // Get the texture size as original - Size textureSize = _scale9Image->getTextureAtlas()->getTexture()->getContentSize(); - - rect = Rect(0, 0, textureSize.width, textureSize.height); - } - - // Set the given rect's size as original size - _spriteRect = rect; - _originalSize = rect.size; - _preferredSize = _originalSize; - _capInsetsInternal = capInsets; - - float w = rect.size.width; - float h = rect.size.height; - - // If there is no specified center region - if ( _capInsetsInternal.equals(Rect::ZERO) ) - { - // log("... cap insets not specified : using default cap insets ..."); - _capInsetsInternal = Rect(w/3, h/3, w/3, h/3); - } - - float left_w = _capInsetsInternal.origin.x; - float center_w = _capInsetsInternal.size.width; - float right_w = rect.size.width - (left_w + center_w); - - float top_h = _capInsetsInternal.origin.y; - float center_h = _capInsetsInternal.size.height; - float bottom_h = rect.size.height - (top_h + center_h); - - // calculate rects - - // ... top row - float x = 0.0; - float y = 0.0; - - // top left - Rect lefttopbounds = Rect(x, y, left_w, top_h); - - // top center - TRANSLATE_X(x, y, left_w); - Rect centertopbounds = Rect(x, y, center_w, top_h); - - // top right - TRANSLATE_X(x, y, center_w); - Rect righttopbounds = Rect(x, y, right_w, top_h); - - // ... center row - x = 0.0; - y = 0.0; - TRANSLATE_Y(x, y, top_h); - - // center left - Rect leftcenterbounds = Rect(x, y, left_w, center_h); - - // center center - TRANSLATE_X(x, y, left_w); - Rect centerbounds = Rect(x, y, center_w, center_h); - - // center right - TRANSLATE_X(x, y, center_w); - Rect rightcenterbounds = Rect(x, y, right_w, center_h); - - // ... bottom row - x = 0.0; - y = 0.0; - TRANSLATE_Y(x, y, top_h); - TRANSLATE_Y(x, y, center_h); - - // bottom left - Rect leftbottombounds = Rect(x, y, left_w, bottom_h); - - // bottom center - TRANSLATE_X(x, y, left_w); - Rect centerbottombounds = Rect(x, y, center_w, bottom_h); - - // bottom right - TRANSLATE_X(x, y, center_w); - Rect rightbottombounds = Rect(x, y, right_w, bottom_h); - - if (!rotated) { - // log("!rotated"); - - AffineTransform t = AffineTransform::IDENTITY; - t = AffineTransformTranslate(t, rect.origin.x, rect.origin.y); - - centerbounds = RectApplyAffineTransform(centerbounds, t); - rightbottombounds = RectApplyAffineTransform(rightbottombounds, t); - leftbottombounds = RectApplyAffineTransform(leftbottombounds, t); - righttopbounds = RectApplyAffineTransform(righttopbounds, t); - lefttopbounds = RectApplyAffineTransform(lefttopbounds, t); - rightcenterbounds = RectApplyAffineTransform(rightcenterbounds, t); - leftcenterbounds = RectApplyAffineTransform(leftcenterbounds, t); - centerbottombounds = RectApplyAffineTransform(centerbottombounds, t); - centertopbounds = RectApplyAffineTransform(centertopbounds, t); - - // Centre - _centre = Sprite::createWithTexture(_scale9Image->getTexture(), centerbounds); - _centre->retain(); - this->addChild(_centre); - - - // Top - _top = Sprite::createWithTexture(_scale9Image->getTexture(), centertopbounds); - _top->retain(); - this->addChild(_top); - - // Bottom - _bottom = Sprite::createWithTexture(_scale9Image->getTexture(), centerbottombounds); - _bottom->retain(); - this->addChild(_bottom); - - // Left - _left = Sprite::createWithTexture(_scale9Image->getTexture(), leftcenterbounds); - _left->retain(); - this->addChild(_left); - - // Right - _right = Sprite::createWithTexture(_scale9Image->getTexture(), rightcenterbounds); - _right->retain(); - this->addChild(_right); - - // Top left - _topLeft = Sprite::createWithTexture(_scale9Image->getTexture(), lefttopbounds); - _topLeft->retain(); - this->addChild(_topLeft); - - // Top right - _topRight = Sprite::createWithTexture(_scale9Image->getTexture(), righttopbounds); - _topRight->retain(); - this->addChild(_topRight); - - // Bottom left - _bottomLeft = Sprite::createWithTexture(_scale9Image->getTexture(), leftbottombounds); - _bottomLeft->retain(); - this->addChild(_bottomLeft); - - // Bottom right - _bottomRight = Sprite::createWithTexture(_scale9Image->getTexture(), rightbottombounds); - _bottomRight->retain(); - this->addChild(_bottomRight); - } else { - // set up transformation of coordinates - // to handle the case where the sprite is stored rotated - // in the spritesheet - // log("rotated"); - - AffineTransform t = AffineTransform::IDENTITY; - - Rect rotatedcenterbounds = centerbounds; - Rect rotatedrightbottombounds = rightbottombounds; - Rect rotatedleftbottombounds = leftbottombounds; - Rect rotatedrighttopbounds = righttopbounds; - Rect rotatedlefttopbounds = lefttopbounds; - Rect rotatedrightcenterbounds = rightcenterbounds; - Rect rotatedleftcenterbounds = leftcenterbounds; - Rect rotatedcenterbottombounds = centerbottombounds; - Rect rotatedcentertopbounds = centertopbounds; - - t = AffineTransformTranslate(t, rect.size.height+rect.origin.x, rect.origin.y); - t = AffineTransformRotate(t, 1.57079633f); - - centerbounds = RectApplyAffineTransform(centerbounds, t); - rightbottombounds = RectApplyAffineTransform(rightbottombounds, t); - leftbottombounds = RectApplyAffineTransform(leftbottombounds, t); - righttopbounds = RectApplyAffineTransform(righttopbounds, t); - lefttopbounds = RectApplyAffineTransform(lefttopbounds, t); - rightcenterbounds = RectApplyAffineTransform(rightcenterbounds, t); - leftcenterbounds = RectApplyAffineTransform(leftcenterbounds, t); - centerbottombounds = RectApplyAffineTransform(centerbottombounds, t); - centertopbounds = RectApplyAffineTransform(centertopbounds, t); - - rotatedcenterbounds.origin = centerbounds.origin; - rotatedrightbottombounds.origin = rightbottombounds.origin; - rotatedleftbottombounds.origin = leftbottombounds.origin; - rotatedrighttopbounds.origin = righttopbounds.origin; - rotatedlefttopbounds.origin = lefttopbounds.origin; - rotatedrightcenterbounds.origin = rightcenterbounds.origin; - rotatedleftcenterbounds.origin = leftcenterbounds.origin; - rotatedcenterbottombounds.origin = centerbottombounds.origin; - rotatedcentertopbounds.origin = centertopbounds.origin; - - // Centre - _centre = Sprite::createWithTexture(_scale9Image->getTexture(), rotatedcenterbounds, true); - _centre->retain(); - this->addChild(_centre, 0); - - // Top - _top = Sprite::createWithTexture(_scale9Image->getTexture(), rotatedcentertopbounds, true); - _top->retain(); - this->addChild(_top); - - // Bottom - _bottom = Sprite::createWithTexture(_scale9Image->getTexture(), rotatedcenterbottombounds, true); - _bottom->retain(); - this->addChild(_bottom); - - // Left - _left = Sprite::createWithTexture(_scale9Image->getTexture(), rotatedleftcenterbounds, true); - _left->retain(); - this->addChild(_left); - - // Right - _right = Sprite::createWithTexture(_scale9Image->getTexture(), rotatedrightcenterbounds, true); - _right->retain(); - this->addChild(_right); - - // Top left - _topLeft = Sprite::createWithTexture(_scale9Image->getTexture(), rotatedlefttopbounds, true); - _topLeft->retain(); - this->addChild(_topLeft); - - // Top right - _topRight = Sprite::createWithTexture(_scale9Image->getTexture(), rotatedrighttopbounds, true); - _topRight->retain(); - this->addChild(_topRight); - - // Bottom left - _bottomLeft = Sprite::createWithTexture(_scale9Image->getTexture(), rotatedleftbottombounds, true); - _bottomLeft->retain(); - this->addChild(_bottomLeft); - - // Bottom right - _bottomRight = Sprite::createWithTexture(_scale9Image->getTexture(), rotatedrightbottombounds, true); - _bottomRight->retain(); - this->addChild(_bottomRight); - } - - this->setContentSize(rect.size); -// this->addChild(_scale9Image); - - if (_spritesGenerated) - { - // Restore color and opacity - this->setOpacity(opacity); - this->setColor(color); - } - _spritesGenerated = true; - - return true; -} - -void Scale9Sprite::setContentSize(const Size &size) -{ - Node::setContentSize(size); - this->_positionsAreDirty = true; -} - -void Scale9Sprite::updatePositions() -{ - // Check that instances are non-nullptr - if(!((_topLeft) && - (_topRight) && - (_bottomRight) && - (_bottomLeft) && - (_centre))) { - // if any of the above sprites are nullptr, return - return; - } - - Size size = this->_contentSize; - - float sizableWidth = size.width - _topLeft->getContentSize().width - _topRight->getContentSize().width; - float sizableHeight = size.height - _topLeft->getContentSize().height - _bottomRight->getContentSize().height; - - float horizontalScale = sizableWidth/_centre->getContentSize().width; - float verticalScale = sizableHeight/_centre->getContentSize().height; - - _centre->setScaleX(horizontalScale); - _centre->setScaleY(verticalScale); - - float rescaledWidth = _centre->getContentSize().width * horizontalScale; - float rescaledHeight = _centre->getContentSize().height * verticalScale; - - float leftWidth = _bottomLeft->getContentSize().width; - float bottomHeight = _bottomLeft->getContentSize().height; - - _bottomLeft->setAnchorPoint(Vec2(0,0)); - _bottomRight->setAnchorPoint(Vec2(0,0)); - _topLeft->setAnchorPoint(Vec2(0,0)); - _topRight->setAnchorPoint(Vec2(0,0)); - _left->setAnchorPoint(Vec2(0,0)); - _right->setAnchorPoint(Vec2(0,0)); - _top->setAnchorPoint(Vec2(0,0)); - _bottom->setAnchorPoint(Vec2(0,0)); - _centre->setAnchorPoint(Vec2(0,0)); - - // Position corners - _bottomLeft->setPosition(0,0); - _bottomRight->setPosition(leftWidth+rescaledWidth,0); - _topLeft->setPosition(0, bottomHeight+rescaledHeight); - _topRight->setPosition(leftWidth+rescaledWidth, bottomHeight+rescaledHeight); - - // Scale and position borders - _left->setPosition(0, bottomHeight); - _left->setScaleY(verticalScale); - _right->setPosition(leftWidth+rescaledWidth,bottomHeight); - _right->setScaleY(verticalScale); - _bottom->setPosition(leftWidth,0); - _bottom->setScaleX(horizontalScale); - _top->setPosition(leftWidth,bottomHeight+rescaledHeight); - _top->setScaleX(horizontalScale); - - // Position centre - _centre->setPosition(leftWidth, bottomHeight); -} - -bool Scale9Sprite::initWithFile(const std::string& file, const Rect& rect, const Rect& capInsets) -{ - SpriteBatchNode *batchnode = SpriteBatchNode::create(file, 9); - bool pReturn = this->initWithBatchNode(batchnode, rect, capInsets); - return pReturn; -} - -Scale9Sprite* Scale9Sprite::create(const std::string& file, const Rect& rect, const Rect& capInsets) -{ - Scale9Sprite* pReturn = new (std::nothrow) Scale9Sprite(); - if ( pReturn && pReturn->initWithFile(file, rect, capInsets) ) - { - pReturn->autorelease(); - return pReturn; - } - CC_SAFE_DELETE(pReturn); - return nullptr; -} - -bool Scale9Sprite::initWithFile(const std::string& file, const Rect& rect) -{ - bool pReturn = this->initWithFile(file, rect, Rect::ZERO); - return pReturn; -} - -Scale9Sprite* Scale9Sprite::create(const std::string& file, const Rect& rect) -{ - Scale9Sprite* pReturn = new (std::nothrow) Scale9Sprite(); - if ( pReturn && pReturn->initWithFile(file, rect) ) - { - pReturn->autorelease(); - return pReturn; - } - CC_SAFE_DELETE(pReturn); - return nullptr; -} - - -bool Scale9Sprite::initWithFile(const Rect& capInsets, const std::string& file) -{ - bool pReturn = this->initWithFile(file, Rect::ZERO, capInsets); - return pReturn; -} - -Scale9Sprite* Scale9Sprite::create(const Rect& capInsets, const std::string& file) -{ - Scale9Sprite* pReturn = new (std::nothrow) Scale9Sprite(); - if ( pReturn && pReturn->initWithFile(capInsets, file) ) - { - pReturn->autorelease(); - return pReturn; - } - CC_SAFE_DELETE(pReturn); - return nullptr; -} - -bool Scale9Sprite::initWithFile(const std::string& file) -{ - bool pReturn = this->initWithFile(file, Rect::ZERO); - return pReturn; - -} - -Scale9Sprite* Scale9Sprite::create(const std::string& file) -{ - Scale9Sprite* pReturn = new (std::nothrow) Scale9Sprite(); - if ( pReturn && pReturn->initWithFile(file) ) - { - pReturn->autorelease(); - return pReturn; - } - CC_SAFE_DELETE(pReturn); - return nullptr; -} - -bool Scale9Sprite::initWithSpriteFrame(SpriteFrame* spriteFrame, const Rect& capInsets) -{ - Texture2D* texture = spriteFrame->getTexture(); - CCASSERT(texture != nullptr, "CCTexture must be not nil"); - - SpriteBatchNode *batchnode = SpriteBatchNode::createWithTexture(texture, 9); - CCASSERT(batchnode != nullptr, "CCSpriteBatchNode must be not nil"); - - bool pReturn = this->initWithBatchNode(batchnode, spriteFrame->getRect(), spriteFrame->isRotated(), capInsets); - return pReturn; -} - -Scale9Sprite* Scale9Sprite::createWithSpriteFrame(SpriteFrame* spriteFrame, const Rect& capInsets) -{ - Scale9Sprite* pReturn = new (std::nothrow) Scale9Sprite(); - if ( pReturn && pReturn->initWithSpriteFrame(spriteFrame, capInsets) ) - { - pReturn->autorelease(); - return pReturn; - } - CC_SAFE_DELETE(pReturn); - return nullptr; -} -bool Scale9Sprite::initWithSpriteFrame(SpriteFrame* spriteFrame) -{ - CCASSERT(spriteFrame != nullptr, "Invalid spriteFrame for sprite"); - bool pReturn = this->initWithSpriteFrame(spriteFrame, Rect::ZERO); - return pReturn; -} - -Scale9Sprite* Scale9Sprite::createWithSpriteFrame(SpriteFrame* spriteFrame) -{ - Scale9Sprite* pReturn = new (std::nothrow) Scale9Sprite(); - if ( pReturn && pReturn->initWithSpriteFrame(spriteFrame) ) - { - pReturn->autorelease(); - return pReturn; - } - CC_SAFE_DELETE(pReturn); - return nullptr; -} - -bool Scale9Sprite::initWithSpriteFrameName(const std::string& spriteFrameName, const Rect& capInsets) -{ - CCASSERT((SpriteFrameCache::getInstance()) != nullptr, "SpriteFrameCache::getInstance() must be non-nullptr"); - - SpriteFrame *frame = SpriteFrameCache::getInstance()->getSpriteFrameByName(spriteFrameName); - CCASSERT(frame != nullptr, "CCSpriteFrame must be non-nullptr"); - - if (nullptr == frame) return false; - - bool pReturn = this->initWithSpriteFrame(frame, capInsets); - return pReturn; -} - -Scale9Sprite* Scale9Sprite::createWithSpriteFrameName(const std::string& spriteFrameName, const Rect& capInsets) -{ - Scale9Sprite* pReturn = new (std::nothrow) Scale9Sprite(); - if ( pReturn && pReturn->initWithSpriteFrameName(spriteFrameName, capInsets) ) - { - pReturn->autorelease(); - return pReturn; - } - CC_SAFE_DELETE(pReturn); - return nullptr; -} - -bool Scale9Sprite::initWithSpriteFrameName(const std::string& spriteFrameName) -{ - bool pReturn = this->initWithSpriteFrameName(spriteFrameName, Rect::ZERO); - return pReturn; -} - -Scale9Sprite* Scale9Sprite::createWithSpriteFrameName(const std::string& spriteFrameName) -{ - Scale9Sprite* pReturn = new (std::nothrow) Scale9Sprite(); - if ( pReturn && pReturn->initWithSpriteFrameName(spriteFrameName) ) - { - pReturn->autorelease(); - return pReturn; - } - CC_SAFE_DELETE(pReturn); - - log("Could not allocate Scale9Sprite()"); - return nullptr; - -} - -Scale9Sprite* Scale9Sprite::resizableSpriteWithCapInsets(const Rect& capInsets) -{ - Scale9Sprite* pReturn = new (std::nothrow) Scale9Sprite(); - if ( pReturn && pReturn->initWithBatchNode(_scale9Image, _spriteRect, capInsets) ) - { - pReturn->autorelease(); - return pReturn; - } - CC_SAFE_DELETE(pReturn); - return nullptr; -} - -Scale9Sprite* Scale9Sprite::create() -{ - Scale9Sprite *pReturn = new (std::nothrow) Scale9Sprite(); - if (pReturn && pReturn->init()) - { - pReturn->autorelease(); - return pReturn; - } - CC_SAFE_DELETE(pReturn); - return nullptr; -} - -/** sets the opacity. - @warning If the the texture has premultiplied alpha then, the R, G and B channels will be modifed. - Values goes from 0 to 255, where 255 means fully opaque. - */ - -void Scale9Sprite::setPreferredSize(Size preferedSize) -{ - this->setContentSize(preferedSize); - this->_preferredSize = preferedSize; -} - -Size Scale9Sprite::getPreferredSize() -{ - return this->_preferredSize; -} - -void Scale9Sprite::setCapInsets(Rect capInsets) -{ - Size contentSize = this->_contentSize; - this->updateWithBatchNode(this->_scale9Image, this->_spriteRect, _spriteFrameRotated, capInsets); - this->setContentSize(contentSize); -} - -Rect Scale9Sprite::getCapInsets() -{ - return _capInsets; -} - -void Scale9Sprite::updateCapInset() -{ - Rect insets; - if (this->_insetLeft == 0 && this->_insetTop == 0 && this->_insetRight == 0 && this->_insetBottom == 0) - { - insets = Rect::ZERO; - } - else - { - insets = Rect(_insetLeft, - _insetTop, - _spriteRect.size.width-_insetLeft-_insetRight, - _spriteRect.size.height-_insetTop-_insetBottom); - } - this->setCapInsets(insets); -} - -void Scale9Sprite::setOpacityModifyRGB(bool var) -{ - if (!_scale9Image) - { - return; - } - _opacityModifyRGB = var; - - for(auto child : _scale9Image->getChildren()){ - child->setOpacityModifyRGB(_opacityModifyRGB); - } -} - -bool Scale9Sprite::isOpacityModifyRGB() const -{ - return _opacityModifyRGB; -} - -void Scale9Sprite::setSpriteFrame(SpriteFrame * spriteFrame) -{ - SpriteBatchNode * batchnode = SpriteBatchNode::createWithTexture(spriteFrame->getTexture(), 9); - this->updateWithBatchNode(batchnode, spriteFrame->getRect(), spriteFrame->isRotated(), Rect::ZERO); - - // Reset insets - this->_insetLeft = 0; - this->_insetTop = 0; - this->_insetRight = 0; - this->_insetBottom = 0; -} - -float Scale9Sprite::getInsetLeft() -{ - return this->_insetLeft; -} - -float Scale9Sprite::getInsetTop() -{ - return this->_insetTop; -} - -float Scale9Sprite::getInsetRight() -{ - return this->_insetRight; -} - -float Scale9Sprite::getInsetBottom() -{ - return this->_insetBottom; -} - -void Scale9Sprite::setInsetLeft(float insetLeft) -{ - this->_insetLeft = insetLeft; - this->updateCapInset(); -} - -void Scale9Sprite::setInsetTop(float insetTop) -{ - this->_insetTop = insetTop; - this->updateCapInset(); -} - -void Scale9Sprite::setInsetRight(float insetRight) -{ - this->_insetRight = insetRight; - this->updateCapInset(); -} - -void Scale9Sprite::setInsetBottom(float insetBottom) -{ - this->_insetBottom = insetBottom; - this->updateCapInset(); -} - -void Scale9Sprite::visit(Renderer *renderer, const Mat4 &parentTransform, uint32_t parentFlags) -{ - if(this->_positionsAreDirty) - { - this->updatePositions(); - this->_positionsAreDirty = false; - } - Node::visit(renderer, parentTransform, parentFlags); -} - -void Scale9Sprite::setColor(const Color3B& color) -{ - if (!_scale9Image) - { - return; - } - - Node::setColor(color); - - for(auto child : _scale9Image->getChildren()){ - child->setColor(color); - } -} - -void Scale9Sprite::setOpacity(GLubyte opacity) -{ - if (!_scale9Image) - { - return; - } - Node::setOpacity(opacity); - - for(auto child : _scale9Image->getChildren()){ - child->setOpacity(opacity); - } -} - -void Scale9Sprite::updateDisplayedColor(const cocos2d::Color3B &parentColor) -{ - if (!_scale9Image) - { - return; - } - Node::updateDisplayedColor(parentColor); - - for(auto child : _scale9Image->getChildren()){ - child->updateDisplayedColor(parentColor); - } -} - -void Scale9Sprite::updateDisplayedOpacity(GLubyte parentOpacity) -{ - if (!_scale9Image) - { - return; - } - Node::updateDisplayedOpacity(parentOpacity); - - for(auto child : _scale9Image->getChildren()){ - child->updateDisplayedOpacity(parentOpacity); - } -} - -NS_CC_EXT_END diff --git a/extensions/GUI/CCControlExtension/CCScale9Sprite.h b/extensions/GUI/CCControlExtension/CCScale9Sprite.h deleted file mode 100644 index fc1dea95ba..0000000000 --- a/extensions/GUI/CCControlExtension/CCScale9Sprite.h +++ /dev/null @@ -1,323 +0,0 @@ -/**************************************************************************** -Copyright (c) 2012 cocos2d-x.org - -http://www.cocos2d-x.org - -Created by Jung Sang-Taik on 12. 3. 16.. -Copyright (c) 2012 Neofect. All rights reserved. - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. -****************************************************************************/ - -#ifndef __CCScale9Sprite_H__ -#define __CCScale9Sprite_H__ - -#include "2d/CCNode.h" -#include "2d/CCSpriteFrame.h" -#include "2d/CCSpriteBatchNode.h" -#include "extensions/ExtensionExport.h" -#include "../../ExtensionMacros.h" - -NS_CC_EXT_BEGIN - -/** - * @addtogroup GUI - * @{ - * @addtogroup control_extension - * @{ - */ - -/** - * A 9-slice sprite for cocos2d. - * - * 9-slice scaling allows you to specify how scaling is applied - * to specific areas of a sprite. With 9-slice scaling (3x3 grid), - * you can ensure that the sprite does not become distorted when - * scaled. - * - * @see http://yannickloriot.com/library/ios/cccontrolextension/Classes/CCScale9Sprite.html - */ -class CC_EX_DLL Scale9Sprite : public Node -{ -public: - /** - * @js ctor - */ - Scale9Sprite(); - /** - * @js NA - * @lua NA - */ - virtual ~Scale9Sprite(); - -public: - static Scale9Sprite* create(); - - /** - * Creates a 9-slice sprite with a texture file, a delimitation zone and - * with the specified cap insets. - * - * @see initWithFile(const char *file, const Rect& rect, const Rect& capInsets) - */ - static Scale9Sprite* create(const std::string& file, const Rect& rect, const Rect& capInsets); - - /** - * Creates a 9-slice sprite with a texture file. The whole texture will be - * broken down into a 3×3 grid of equal blocks. - * - * @see initWithFile(const Rect& capInsets, const char *file) - */ - static Scale9Sprite* create(const Rect& capInsets, const std::string& file); - - /** - * Creates a 9-slice sprite with a texture file and a delimitation zone. The - * texture will be broken down into a 3×3 grid of equal blocks. - * - * @see initWithFile(const char *file, const Rect& rect) - */ - static Scale9Sprite* create(const std::string& file, const Rect& rect); - - /** - * Creates a 9-slice sprite with a texture file. The whole texture will be - * broken down into a 3×3 grid of equal blocks. - * - * @see initWithFile(const char *file) - */ - static Scale9Sprite* create(const std::string& file); - - /** - * Creates a 9-slice sprite with an sprite frame. - * Once the sprite is created, you can then call its "setContentSize:" method - * to resize the sprite will all it's 9-slice goodness intract. - * It respects the anchorPoint too. - * - * @see initWithSpriteFrame(SpriteFrame *spriteFrame) - */ - static Scale9Sprite* createWithSpriteFrame(SpriteFrame* spriteFrame); - - /** - * Creates a 9-slice sprite with an sprite frame and the centre of its zone. - * Once the sprite is created, you can then call its "setContentSize:" method - * to resize the sprite will all it's 9-slice goodness intract. - * It respects the anchorPoint too. - * - * @see initWithSpriteFrame(SpriteFrame *spriteFrame, const Rect& capInsets) - */ - static Scale9Sprite* createWithSpriteFrame(SpriteFrame* spriteFrame, const Rect& capInsets); - - /** - * Creates a 9-slice sprite with an sprite frame name. - * Once the sprite is created, you can then call its "setContentSize:" method - * to resize the sprite will all it's 9-slice goodness intract. - * It respects the anchorPoint too. - * - * @see initWithSpriteFrameName(const char *spriteFrameName) - */ - static Scale9Sprite* createWithSpriteFrameName(const std::string& spriteFrameName); - - /** - * Creates a 9-slice sprite with an sprite frame name and the centre of its - * zone. - * Once the sprite is created, you can then call its "setContentSize:" method - * to resize the sprite will all it's 9-slice goodness intract. - * It respects the anchorPoint too. - * - * @see initWithSpriteFrameName(const char *spriteFrameName, const Rect& capInsets) - */ - static Scale9Sprite* createWithSpriteFrameName(const std::string& spriteFrameName, const Rect& capInsets); - - /** - * Initializes a 9-slice sprite with a texture file, a delimitation zone and - * with the specified cap insets. - * Once the sprite is created, you can then call its "setContentSize:" method - * to resize the sprite will all it's 9-slice goodness intract. - * It respects the anchorPoint too. - * - * @param file The name of the texture file. - * @param rect The rectangle that describes the sub-part of the texture that - * is the whole image. If the shape is the whole texture, set this to the - * texture's full rect. - * @param capInsets The values to use for the cap insets. - */ - virtual bool initWithFile(const std::string& file, const Rect& rect, const Rect& capInsets); - - /** - * Initializes a 9-slice sprite with a texture file and a delimitation zone. The - * texture will be broken down into a 3×3 grid of equal blocks. - * Once the sprite is created, you can then call its "setContentSize:" method - * to resize the sprite will all it's 9-slice goodness intract. - * It respects the anchorPoint too. - * - * @param file The name of the texture file. - * @param rect The rectangle that describes the sub-part of the texture that - * is the whole image. If the shape is the whole texture, set this to the - * texture's full rect. - */ - virtual bool initWithFile(const std::string& file, const Rect& rect); - - /** - * Initializes a 9-slice sprite with a texture file and with the specified cap - * insets. - * Once the sprite is created, you can then call its "setContentSize:" method - * to resize the sprite will all it's 9-slice goodness intract. - * It respects the anchorPoint too. - * - * @param file The name of the texture file. - * @param capInsets The values to use for the cap insets. - */ - virtual bool initWithFile(const Rect& capInsets, const std::string& file); - - /** - * Initializes a 9-slice sprite with a texture file. The whole texture will be - * broken down into a 3×3 grid of equal blocks. - * Once the sprite is created, you can then call its "setContentSize:" method - * to resize the sprite will all it's 9-slice goodness intract. - * It respects the anchorPoint too. - * - * @param file The name of the texture file. - */ - virtual bool initWithFile(const std::string& file); - - /** - * Initializes a 9-slice sprite with an sprite frame and with the specified - * cap insets. - * Once the sprite is created, you can then call its "setContentSize:" method - * to resize the sprite will all it's 9-slice goodness intract. - * It respects the anchorPoint too. - * - * @param spriteFrame The sprite frame object. - * @param capInsets The values to use for the cap insets. - */ - virtual bool initWithSpriteFrame(SpriteFrame* spriteFrame, const Rect& capInsets); - - /** - * Initializes a 9-slice sprite with an sprite frame. - * Once the sprite is created, you can then call its "setContentSize:" method - * to resize the sprite will all it's 9-slice goodness intract. - * It respects the anchorPoint too. - * - * @param spriteFrame The sprite frame object. - */ - virtual bool initWithSpriteFrame(SpriteFrame* spriteFrame); - - /** - * Initializes a 9-slice sprite with an sprite frame name and with the specified - * cap insets. - * Once the sprite is created, you can then call its "setContentSize:" method - * to resize the sprite will all it's 9-slice goodness intract. - * It respects the anchorPoint too. - * - * @param spriteFrameName The sprite frame name. - * @param capInsets The values to use for the cap insets. - */ - virtual bool initWithSpriteFrameName(const std::string& spriteFrameName, const Rect& capInsets); - - /** - * Initializes a 9-slice sprite with an sprite frame name. - * Once the sprite is created, you can then call its "setContentSize:" method - * to resize the sprite will all it's 9-slice goodness intract. - * It respects the anchorPoint too. - * - * @param spriteFrameName The sprite frame name. - */ - virtual bool initWithSpriteFrameName(const std::string& spriteFrameName); - - virtual bool init(); - virtual bool initWithBatchNode(SpriteBatchNode* batchnode, const Rect& rect, bool rotated, const Rect& capInsets); - virtual bool initWithBatchNode(SpriteBatchNode* batchnode, const Rect& rect, const Rect& capInsets); - - /** - * Creates and returns a new sprite object with the specified cap insets. - * You use this method to add cap insets to a sprite or to change the existing - * cap insets of a sprite. In both cases, you get back a new image and the - * original sprite remains untouched. - * - * @param capInsets The values to use for the cap insets. - */ - Scale9Sprite* resizableSpriteWithCapInsets(const Rect& capInsets); - - virtual bool updateWithBatchNode(SpriteBatchNode* batchnode, const Rect& rect, bool rotated, const Rect& capInsets); - virtual void setSpriteFrame(SpriteFrame * spriteFrame); - - // overrides - virtual void setContentSize(const Size & size) override; - /** - * @js NA - * @lua NA - */ - virtual void visit(Renderer *renderer, const Mat4 &parentTransform, uint32_t parentFlags) override; - virtual void setOpacityModifyRGB(bool bValue) override; - virtual bool isOpacityModifyRGB(void) const override; - virtual void setOpacity(GLubyte opacity) override; - virtual void setColor(const Color3B& color) override; - virtual void updateDisplayedOpacity(GLubyte parentOpacity) override; - virtual void updateDisplayedColor(const Color3B& parentColor) override; - -protected: - void updateCapInset(); - void updatePositions(); - - bool _spritesGenerated; - Rect _spriteRect; - bool _spriteFrameRotated; - Rect _capInsetsInternal; - bool _positionsAreDirty; - - SpriteBatchNode* _scale9Image; - Sprite* _topLeft; - Sprite* _top; - Sprite* _topRight; - Sprite* _left; - Sprite* _centre; - Sprite* _right; - Sprite* _bottomLeft; - Sprite* _bottom; - Sprite* _bottomRight; - - bool _opacityModifyRGB; - - /** Original sprite's size. */ - CC_SYNTHESIZE_READONLY(Size, _originalSize, OriginalSize); - /** Prefered sprite's size. By default the prefered size is the original size. */ - - //if the preferredSize component is given as -1, it is ignored - CC_PROPERTY(Size, _preferredSize, PreferredSize); - /** - * The end-cap insets. - * On a non-resizeable sprite, this property is set to CGRect::ZERO; the sprite - * does not use end caps and the entire sprite is subject to stretching. - */ - CC_PROPERTY(Rect, _capInsets, CapInsets); - /** Sets the left side inset */ - CC_PROPERTY(float, _insetLeft, InsetLeft); - /** Sets the top side inset */ - CC_PROPERTY(float, _insetTop, InsetTop); - /** Sets the right side inset */ - CC_PROPERTY(float, _insetRight, InsetRight); - /** Sets the bottom side inset */ - CC_PROPERTY(float, _insetBottom, InsetBottom); -}; - -// end of GUI group -/// @} -/// @} - -NS_CC_EXT_END - -#endif // __CCScale9Sprite_H__ diff --git a/extensions/GUI/CCEditBox/CCEditBox.h b/extensions/GUI/CCEditBox/CCEditBox.h deleted file mode 100644 index 9203cbfaac..0000000000 --- a/extensions/GUI/CCEditBox/CCEditBox.h +++ /dev/null @@ -1,452 +0,0 @@ -/**************************************************************************** - Copyright (c) 2010-2012 cocos2d-x.org - Copyright (c) 2012 James Chen - - http://www.cocos2d-x.org - - Permission is hereby granted, free of charge, to any person obtaining a copy - of this software and associated documentation files (the "Software"), to deal - in the Software without restriction, including without limitation the rights - to use, copy, modify, merge, publish, distribute, sublicense, and/or sell - copies of the Software, and to permit persons to whom the Software is - furnished to do so, subject to the following conditions: - - The above copyright notice and this permission notice shall be included in - all copies or substantial portions of the Software. - - THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN - THE SOFTWARE. - ****************************************************************************/ - -#ifndef __CCEDITTEXT_H__ -#define __CCEDITTEXT_H__ - -#include "base/CCIMEDelegate.h" -#include "extensions/ExtensionMacros.h" -#include "../CCControlExtension/CCControlExtensions.h" -#include "extensions/ExtensionExport.h" - -NS_CC_EXT_BEGIN - -class EditBox; -class EditBoxImpl; - - -class CC_EX_DLL EditBoxDelegate -{ -public: - /** - * @js NA - * @lua NA - */ - virtual ~EditBoxDelegate() {}; - - /** - * This method is called when an edit box gains focus after keyboard is shown. - * @param editBox The edit box object that generated the event. - * @js NA - * @lua NA - */ - virtual void editBoxEditingDidBegin(EditBox* editBox) {}; - - - /** - * This method is called when an edit box loses focus after keyboard is hidden. - * @param editBox The edit box object that generated the event. - * @js NA - * @lua NA - */ - virtual void editBoxEditingDidEnd(EditBox* editBox) {}; - - /** - * This method is called when the edit box text was changed. - * @param editBox The edit box object that generated the event. - * @param text The new text. - * @js NA - * @lua NA - */ - virtual void editBoxTextChanged(EditBox* editBox, const std::string& text) {}; - - /** - * This method is called when the return button was pressed or the outside area of keyboard was touched. - * @param editBox The edit box object that generated the event. - * @js NA - * @lua NA - */ - virtual void editBoxReturn(EditBox* editBox) = 0; - -}; - -/** - * \brief Class for edit box. - * - * You can use this widget to gather small amounts of text from the user. - * - */ - -class CC_EX_DLL EditBox -: public ControlButton -, public IMEDelegate -{ -public: - enum class KeyboardReturnType - { - DEFAULT, - DONE, - SEND, - SEARCH, - GO - }; - - /** - * \brief The EditBox::InputMode defines the type of text that the user is allowed - * to enter. - */ - enum class InputMode - { - /** - * The user is allowed to enter any text, including line breaks. - */ - ANY, - - /** - * The user is allowed to enter an e-mail address. - */ - EMAIL_ADDRESS, - - /** - * The user is allowed to enter an integer value. - */ - NUMERIC, - - /** - * The user is allowed to enter a phone number. - */ - PHONE_NUMBER, - - /** - * The user is allowed to enter a URL. - */ - URL, - - /** - * The user is allowed to enter a real number value. - * This extends kEditBoxInputModeNumeric by allowing a decimal point. - */ - DECIMAL, - - /** - * The user is allowed to enter any text, except for line breaks. - */ - SINGLE_LINE, - }; - - /** - * \brief The EditBox::InputFlag defines how the input text is displayed/formatted. - */ - enum class InputFlag - { - /** - * Indicates that the text entered is confidential data that should be - * obscured whenever possible. This implies EDIT_BOX_INPUT_FLAG_SENSITIVE. - */ - PASSWORD, - - /** - * Indicates that the text entered is sensitive data that the - * implementation must never store into a dictionary or table for use - * in predictive, auto-completing, or other accelerated input schemes. - * A credit card number is an example of sensitive data. - */ - SENSITIVE, - - /** - * This flag is a hint to the implementation that during text editing, - * the initial letter of each word should be capitalized. - */ - INITIAL_CAPS_WORD, - - /** - * This flag is a hint to the implementation that during text editing, - * the initial letter of each sentence should be capitalized. - */ - INITIAL_CAPS_SENTENCE, - - /** - * Capitalize all characters automatically. - */ - INTIAL_CAPS_ALL_CHARACTERS, - }; - - /** - * create a edit box with size. - * @return An autorelease pointer of EditBox, you don't need to release it only if you retain it again. - */ - static EditBox* create(const Size& size, Scale9Sprite* pNormal9SpriteBg, Scale9Sprite* pPressed9SpriteBg = NULL, Scale9Sprite* pDisabled9SpriteBg = NULL); - - /** - * Constructor. - * @js ctor - */ - EditBox(void); - - /** - * Destructor. - * @js NA - * @lua NA - */ - virtual ~EditBox(void); - - /** - * Init edit box with specified size. This method should be invoked right after constructor. - * @param size The size of edit box. - */ - bool initWithSizeAndBackgroundSprite(const Size& size, Scale9Sprite* pNormal9SpriteBg); - - /** - * Gets/Sets the delegate for edit box. - * @lua NA - */ - void setDelegate(EditBoxDelegate* pDelegate); - /** - * @js NA - * @lua NA - */ - EditBoxDelegate* getDelegate(); - -#if CC_ENABLE_SCRIPT_BINDING - /** - * Registers a script function that will be called for EditBox events. - * - * This handler will be removed automatically after onExit() called. - * @code - * -- lua sample - * local function editboxEventHandler(eventType) - * if eventType == "began" then - * -- triggered when an edit box gains focus after keyboard is shown - * elseif eventType == "ended" then - * -- triggered when an edit box loses focus after keyboard is hidden. - * elseif eventType == "changed" then - * -- triggered when the edit box text was changed. - * elseif eventType == "return" then - * -- triggered when the return button was pressed or the outside area of keyboard was touched. - * end - * end - * - * local editbox = EditBox:create(Size(...), Scale9Sprite:create(...)) - * editbox = registerScriptEditBoxHandler(editboxEventHandler) - * @endcode - * - * @param handler A number that indicates a lua function. - * @js NA - * @lua NA - */ - void registerScriptEditBoxHandler(int handler); - - /** - * Unregisters a script function that will be called for EditBox events. - * @js NA - * @lua NA - */ - void unregisterScriptEditBoxHandler(void); - /** - * get a script Handler - * @js NA - * @lua NA - */ - int getScriptEditBoxHandler(void){ return _scriptEditBoxHandler ;} - -#endif // #if CC_ENABLE_SCRIPT_BINDING - - /** - * Set the text entered in the edit box. - * @param pText The given text. - */ - void setText(const char* pText); - - /** - * Get the text entered in the edit box. - * @return The text entered in the edit box. - */ - const char* getText(void); - - /** - * Set the font. - * @param pFontName The font name. - * @param fontSize The font size. - */ - void setFont(const char* pFontName, int fontSize); - - /** - * Set the font name. - * @param pFontName The font name. - */ - void setFontName(const char* pFontName); - - /** - * Set the font size. - * @param fontSize The font size. - */ - void setFontSize(int fontSize); - - /** - * Set the font color of the widget's text. - */ - void setFontColor(const Color3B& color); - - /** - * Set the placeholder's font. - * @param pFontName The font name. - * @param fontSize The font size. - */ - void setPlaceholderFont(const char* pFontName, int fontSize); - - /** - * Set the placeholder's font name. - * @param pFontName The font name. - */ - void setPlaceholderFontName(const char* pFontName); - - /** - * Set the placeholder's font size. - * @param fontSize The font size. - */ - void setPlaceholderFontSize(int fontSize); - - /** - * Set the font color of the placeholder text when the edit box is empty. - * Not supported on IOS. - */ - void setPlaceholderFontColor(const Color3B& color); - - /** - * Set a text in the edit box that acts as a placeholder when an - * edit box is empty. - * @param pText The given text. - */ - void setPlaceHolder(const char* pText); - - /** - * Get a text in the edit box that acts as a placeholder when an - * edit box is empty. - */ - const char* getPlaceHolder(void); - - /** - * Set the input mode of the edit box. - * @param inputMode One of the EditBox::InputMode constants. - */ - void setInputMode(InputMode inputMode); - - /** - * Sets the maximum input length of the edit box. - * Setting this value enables multiline input mode by default. - * Available on Android, iOS and Windows Phone. - * - * @param maxLength The maximum length. - */ - void setMaxLength(int maxLength); - - /** - * Gets the maximum input length of the edit box. - * - * @return Maximum input length. - */ - int getMaxLength(); - - /** - * Set the input flags that are to be applied to the edit box. - * @param inputFlag One of the EditBox::InputFlag constants. - */ - void setInputFlag(InputFlag inputFlag); - - /** - * Set the return type that are to be applied to the edit box. - * @param returnType One of the EditBox::KeyboardReturnType constants. - */ - void setReturnType(EditBox::KeyboardReturnType returnType); - - /* override functions */ - virtual void setPosition(const Vec2& pos) override; - virtual void setVisible(bool visible) override; - virtual void setContentSize(const Size& size) override; - virtual void setAnchorPoint(const Vec2& anchorPoint) override; - /** - * @js NA - * @lua NA - */ - virtual void visit(Renderer *renderer, const Mat4 &parentTransform, uint32_t parentFlags) override; - /** - * @js NA - * @lua NA - */ - virtual void onEnter(void) override; - /** - * @js NA - * @lua NA - */ - virtual void onExit(void) override; - /** - * @js NA - * @lua NA - */ - virtual void keyboardWillShow(IMEKeyboardNotificationInfo& info) override; - /** - * @js NA - * @lua NA - */ - virtual void keyboardDidShow(IMEKeyboardNotificationInfo& info) override; - /** - * @js NA - * @lua NA - */ - virtual void keyboardWillHide(IMEKeyboardNotificationInfo& info) override; - /** - * @js NA - * @lua NA - */ - virtual void keyboardDidHide(IMEKeyboardNotificationInfo& info) override; - - /* callback funtions - * @js NA - * @lua NA - */ - void touchDownAction(Ref *sender, Control::EventType controlEvent); - -protected: - void updatePosition(float dt); - EditBoxImpl* _editBoxImpl; - EditBoxDelegate* _delegate; - - InputMode _editBoxInputMode; - InputFlag _editBoxInputFlag; - EditBox::KeyboardReturnType _keyboardReturnType; - - std::string _text; - std::string _placeHolder; - - std::string _fontName; - std::string _placeholderFontName; - - int _fontSize; - int _placeholderFontSize; - - Color3B _colText; - Color3B _colPlaceHolder; - - int _maxLength; - float _adjustHeight; -#if CC_ENABLE_SCRIPT_BINDING - int _scriptEditBoxHandler; -#endif -}; - -NS_CC_EXT_END - -#endif /* __CCEDITTEXT_H__ */ - diff --git a/extensions/GUI/CCEditBox/CCEditBoxImpl.h b/extensions/GUI/CCEditBox/CCEditBoxImpl.h deleted file mode 100644 index 79d3d8f3fa..0000000000 --- a/extensions/GUI/CCEditBox/CCEditBoxImpl.h +++ /dev/null @@ -1,104 +0,0 @@ -/**************************************************************************** - Copyright (c) 2010-2012 cocos2d-x.org - Copyright (c) 2012 James Chen - - http://www.cocos2d-x.org - - Permission is hereby granted, free of charge, to any person obtaining a copy - of this software and associated documentation files (the "Software"), to deal - in the Software without restriction, including without limitation the rights - to use, copy, modify, merge, publish, distribute, sublicense, and/or sell - copies of the Software, and to permit persons to whom the Software is - furnished to do so, subject to the following conditions: - - The above copyright notice and this permission notice shall be included in - all copies or substantial portions of the Software. - - THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN - THE SOFTWARE. - ****************************************************************************/ - -#ifndef __CCEditBoxIMPL_H__ -#define __CCEditBoxIMPL_H__ - -#include "extensions/ExtensionMacros.h" -#include "CCEditBox.h" -#include "extensions/ExtensionExport.h" - -NS_CC_EXT_BEGIN - - -class CC_EX_DLL EditBoxImpl -{ -public: - /** - * @js NA - */ - EditBoxImpl(EditBox* pEditBox) : _delegate(nullptr),_editBox(pEditBox) {} - /** - * @js NA - * @lua NA - */ - virtual ~EditBoxImpl() {} - - virtual bool initWithSize(const Size& size) = 0; - virtual void setFont(const char* pFontName, int fontSize) = 0; - virtual void setFontColor(const Color3B& color) = 0; - virtual void setPlaceholderFont(const char* pFontName, int fontSize) = 0; - virtual void setPlaceholderFontColor(const Color3B& color) = 0; - virtual void setInputMode(EditBox::InputMode inputMode) = 0; - virtual void setInputFlag(EditBox::InputFlag inputFlag) = 0; - virtual void setMaxLength(int maxLength) = 0; - virtual int getMaxLength() = 0; - virtual void setReturnType(EditBox::KeyboardReturnType returnType) = 0; - virtual bool isEditing() = 0; - - virtual void setText(const char* pText) = 0; - virtual const char* getText(void) = 0; - virtual void setPlaceHolder(const char* pText) = 0; - virtual void doAnimationWhenKeyboardMove(float duration, float distance) = 0; - - virtual void openKeyboard() = 0; - virtual void closeKeyboard() = 0; - - virtual void setPosition(const Vec2& pos) = 0; - virtual void setVisible(bool visible) = 0; - virtual void setContentSize(const Size& size) = 0; - virtual void setAnchorPoint(const Vec2& anchorPoint) = 0; - - /** - * check the editbox's position, update it when needed - */ - virtual void updatePosition(float dt){}; - /** - * @js NA - * @lua NA - */ - virtual void visit(void) = 0; - /** - * @js NA - * @lua NA - */ - virtual void onEnter(void) = 0; - - - void setDelegate(EditBoxDelegate* pDelegate) { _delegate = pDelegate; }; - EditBoxDelegate* getDelegate() { return _delegate; }; - EditBox* getEditBox() { return _editBox; }; -protected: - EditBoxDelegate* _delegate; - EditBox* _editBox; -}; - -// This method must be implemented at each subclass of EditBoxImpl. -extern EditBoxImpl* __createSystemEditBox(EditBox* pEditBox); - - -NS_CC_EXT_END - -#endif /* __CCEditBoxIMPL_H__ */ diff --git a/extensions/GUI/CCEditBox/CCEditBoxImplWp8.h b/extensions/GUI/CCEditBox/CCEditBoxImplWp8.h deleted file mode 100644 index 4513ec6dfd..0000000000 --- a/extensions/GUI/CCEditBox/CCEditBoxImplWp8.h +++ /dev/null @@ -1,87 +0,0 @@ -/**************************************************************************** -Copyright (c) 2014 cocos2d-x.org - -http://www.cocos2d-x.org - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. -****************************************************************************/ -#ifndef __CCEditBoxIMPLWP8_H__ -#define __CCEditBoxIMPLWP8_H__ - -#include "ExtensionMacros.h" -#include "CCEditBoxImpl.h" - -NS_CC_EXT_BEGIN - -class CCEditBox; - -class CCEditBoxImplWp8 : public EditBoxImpl -{ -public: - CCEditBoxImplWp8(EditBox* pEditText); - virtual ~CCEditBoxImplWp8(); - - virtual bool initWithSize(const Size& size); - virtual void setFont(const char* pFontName, int fontSize); - virtual void setFontColor(const Color3B& color); - virtual void setPlaceholderFont(const char* pFontName, int fontSize); - virtual void setPlaceholderFontColor(const Color3B& color); - virtual void setInputMode(EditBox::InputMode inputMode); - virtual void setInputFlag(EditBox::InputFlag inputFlag); - virtual void setMaxLength(int maxLength); - virtual int getMaxLength(); - virtual void setReturnType(EditBox::KeyboardReturnType returnType); - virtual bool isEditing(); - - virtual void setText(const char* pText); - virtual const char* getText(void); - virtual void setPlaceHolder(const char* pText); - virtual void setPosition(const Vec2& pos); - virtual void setVisible(bool visible); - virtual void setContentSize(const Size& size); - virtual void setAnchorPoint(const Vec2& anchorPoint); - virtual void visit(void); - virtual void doAnimationWhenKeyboardMove(float duration, float distance); - virtual void openKeyboard(); - virtual void closeKeyboard(); - virtual void onEnter(void); -private: - Platform::String^ stringToPlatformString(std::string strSrc); - std::string PlatformStringTostring(Platform::String^ strSrc); -private: - - Label* m_pLabel; - Label* m_pLabelPlaceHolder; - EditBox::InputMode m_eEditBoxInputMode; - EditBox::InputFlag m_eEditBoxInputFlag; - (EditBox::KeyboardReturnType m_eKeyboardReturnType; - - std::string m_strText; - std::string m_strPlaceHolder; - - Color3B m_colText; - Color3B m_colPlaceHolder; - - int m_nMaxLength; - Size m_EditSize; -}; - -NS_CC_EXT_END - -#endif diff --git a/extensions/cocos-ext.h b/extensions/cocos-ext.h index a204f40e43..6f742b7046 100644 --- a/extensions/cocos-ext.h +++ b/extensions/cocos-ext.h @@ -7,12 +7,12 @@ #include "GUI/CCControlExtension/CCControlExtensions.h" #include "GUI/CCScrollView/CCScrollView.h" #include "GUI/CCScrollView/CCTableView.h" -#include "GUI/CCEditBox/CCEditBox.h" // Physics integration #include "physics-nodes/CCPhysicsDebugNode.h" #include "physics-nodes/CCPhysicsSprite.h" #include "assets-manager/AssetsManager.h" +#include "ExtensionDeprecated.h" #endif /* __COCOS2D_EXT_H__ */ diff --git a/templates/cocos2dx_files.json b/templates/cocos2dx_files.json index 25d6d414cb..ff4f386aa0 100644 --- a/templates/cocos2dx_files.json +++ b/templates/cocos2dx_files.json @@ -764,7 +764,6 @@ "cocos/platform/android/java/src/org/cocos2dx/lib/Cocos2dxAccelerometer.java", "cocos/platform/android/java/src/org/cocos2dx/lib/Cocos2dxActivity.java", "cocos/platform/android/java/src/org/cocos2dx/lib/Cocos2dxBitmap.java", - "cocos/platform/android/java/src/org/cocos2dx/lib/Cocos2dxETCLoader.java", "cocos/platform/android/java/src/org/cocos2dx/lib/Cocos2dxEditBoxDialog.java", "cocos/platform/android/java/src/org/cocos2dx/lib/Cocos2dxEditText.java", "cocos/platform/android/java/src/org/cocos2dx/lib/Cocos2dxGLSurfaceView.java", @@ -997,6 +996,20 @@ "cocos/ui/UICheckBox.h", "cocos/ui/UIDeprecated.cpp", "cocos/ui/UIDeprecated.h", + "cocos/ui/UIEditBox/UIEditBox.cpp", + "cocos/ui/UIEditBox/UIEditBox.h", + "cocos/ui/UIEditBox/UIEditBoxImpl.h", + "cocos/ui/UIEditBox/UIEditBoxImplAndroid.cpp", + "cocos/ui/UIEditBox/UIEditBoxImplAndroid.h", + "cocos/ui/UIEditBox/UIEditBoxImplIOS.h", + "cocos/ui/UIEditBox/UIEditBoxImplIOS.mm", + "cocos/ui/UIEditBox/UIEditBoxImplMac.h", + "cocos/ui/UIEditBox/UIEditBoxImplMac.mm", + "cocos/ui/UIEditBox/UIEditBoxImplNone.cpp", + "cocos/ui/UIEditBox/UIEditBoxImplWin.cpp", + "cocos/ui/UIEditBox/UIEditBoxImplWin.h", + "cocos/ui/UIEditBox/UIEditBoxImplWp8.cpp", + "cocos/ui/UIEditBox/UIEditBoxImplWp8.h", "cocos/ui/UIHBox.cpp", "cocos/ui/UIHBox.h", "cocos/ui/UIHelper.cpp", @@ -1048,6 +1061,10 @@ "cocos/ui/UIWebViewImpl_iOS.mm", "cocos/ui/UIWidget.cpp", "cocos/ui/UIWidget.h", + "cocos/ui/proj.win32/Win32InputBox.cpp", + "cocos/ui/proj.win32/Win32InputBox.h", + "cocos/ui/proj.win32/libui.vcxproj", + "cocos/ui/proj.win32/libui.vcxproj.filters", "cocos/ui/proj.wp8/libGUI.vcxproj", "cocos/ui/proj.wp8/libGUI.vcxproj.filters", "docs/CODING_STYLE.md", @@ -1058,7 +1075,8 @@ "docs/doxygen.config", "download-deps.py", "extensions/Android.mk", - "extensions/CMakeLists.txt", + "extensions/ExtensionDeprecated.cpp", + "extensions/ExtensionDeprecated.h", "extensions/ExtensionExport.h", "extensions/ExtensionMacros.h", "extensions/GUI/CCControlExtension/CCControl.cpp", @@ -1084,22 +1102,6 @@ "extensions/GUI/CCControlExtension/CCControlUtils.h", "extensions/GUI/CCControlExtension/CCInvocation.cpp", "extensions/GUI/CCControlExtension/CCInvocation.h", - "extensions/GUI/CCControlExtension/CCScale9Sprite.cpp", - "extensions/GUI/CCControlExtension/CCScale9Sprite.h", - "extensions/GUI/CCEditBox/CCEditBox.cpp", - "extensions/GUI/CCEditBox/CCEditBox.h", - "extensions/GUI/CCEditBox/CCEditBoxImpl.h", - "extensions/GUI/CCEditBox/CCEditBoxImplAndroid.cpp", - "extensions/GUI/CCEditBox/CCEditBoxImplAndroid.h", - "extensions/GUI/CCEditBox/CCEditBoxImplIOS.h", - "extensions/GUI/CCEditBox/CCEditBoxImplIOS.mm", - "extensions/GUI/CCEditBox/CCEditBoxImplMac.h", - "extensions/GUI/CCEditBox/CCEditBoxImplMac.mm", - "extensions/GUI/CCEditBox/CCEditBoxImplNone.cpp", - "extensions/GUI/CCEditBox/CCEditBoxImplWin.cpp", - "extensions/GUI/CCEditBox/CCEditBoxImplWin.h", - "extensions/GUI/CCEditBox/CCEditBoxImplWp8.cpp", - "extensions/GUI/CCEditBox/CCEditBoxImplWp8.h", "extensions/GUI/CCScrollView/CCScrollView.cpp", "extensions/GUI/CCScrollView/CCScrollView.h", "extensions/GUI/CCScrollView/CCTableView.cpp", @@ -3694,7 +3696,6 @@ "cocos/scripting/lua-bindings/auto/api/EaseSineIn.lua", "cocos/scripting/lua-bindings/auto/api/EaseSineInOut.lua", "cocos/scripting/lua-bindings/auto/api/EaseSineOut.lua", - "cocos/scripting/lua-bindings/auto/api/EditBox.lua", "cocos/scripting/lua-bindings/auto/api/Event.lua", "cocos/scripting/lua-bindings/auto/api/EventAcceleration.lua", "cocos/scripting/lua-bindings/auto/api/EventController.lua", diff --git a/templates/cpp-template-default/proj.android/README.md b/templates/cpp-template-default/proj.android/README.md deleted file mode 100644 index ff6c44369c..0000000000 --- a/templates/cpp-template-default/proj.android/README.md +++ /dev/null @@ -1,36 +0,0 @@ -## Prerequisites: - -* Android NDK -* Android SDK **OR** Eclipse ADT Bundle -* Android AVD target installed - -## Building project - -There are two ways of building Android projects. - -1. Eclipse -2. Command Line - -### Import Project in Eclipse - -####Step 1: C/C++ Environment Variable `NDK_ROOT` - -* Eclipse->Preferences->C/C++->Build->**Environment**. -* Click **Add** button and add a new variable `NDK_ROOT` pointing to the root NDK directory. - ![Example](https://lh3.googleusercontent.com/-AVcY8IAT0_g/UUOYltoRobI/AAAAAAAAsdM/22D2J9u3sig/s400/cocos2d-x-eclipse-ndk.png) -* Only for Windows: Add new variables **CYGWIN** with value `nodosfilewarning` and **SHELLOPTS** with value `igncr` - -####Step 2: Adding and running from Eclipse - -![Example](https://lh3.googleusercontent.com/-SLBOu6e3QbE/UUOcOXYaGqI/AAAAAAAAsdo/tYBY2SylOSM/s288/cocos2d-x-eclipse-project-from-code.png) ![Import](https://lh5.googleusercontent.com/-XzC9Pn65USc/UUOcOTAwizI/AAAAAAAAsdk/4b6YM-oim9Y/s400/cocos2d-x-eclipse-import-project.png) - -1. File->New->Project->Android Project From Existing Code -2. **Browse** to your project directory and Add the project -3. Click **Run as Android Application** to run on connected device or emulator. - -That's all !!! - -### Running project from Command Line - - $ cd NEW_PROJECTS_DIR/MyGame - $ cocos run -p android -j 4 diff --git a/templates/lua-template-runtime/frameworks/runtime-src/Classes/AppDelegate.cpp b/templates/lua-template-runtime/frameworks/runtime-src/Classes/AppDelegate.cpp index 2bbc729319..8bd26e143a 100644 --- a/templates/lua-template-runtime/frameworks/runtime-src/Classes/AppDelegate.cpp +++ b/templates/lua-template-runtime/frameworks/runtime-src/Classes/AppDelegate.cpp @@ -65,12 +65,7 @@ bool AppDelegate::applicationDidFinishLaunching() auto engine = LuaEngine::getInstance(); ScriptEngineManager::getInstance()->setScriptEngine(engine); lua_State* L = engine->getLuaStack()->getLuaState(); - lua_getglobal(L, "_G"); - if (lua_istable(L,-1))//stack:...,_G, - { - lua_module_register(L); - } - lua_pop(L, 1);//statck:... + lua_module_register(L); LuaStack* stack = engine->getLuaStack(); stack->setXXTEAKeyAndSign("2dxLua", strlen("2dxLua"), "XXTEA", strlen("XXTEA")); diff --git a/tests/cpp-empty-test/proj.android/README.md b/tests/cpp-empty-test/proj.android/README.md deleted file mode 100644 index 312835611a..0000000000 --- a/tests/cpp-empty-test/proj.android/README.md +++ /dev/null @@ -1,87 +0,0 @@ -## Prerequisites: - -* Android NDK -* Android SDK **OR** Eclipse ADT Bundle -* Android AVD target installed - -## Building project - -There are two ways of building Android projects. - -1. Eclipse -2. Command Line - -### Import Project in Eclipse - -#### Features: - -1. Complete workflow from Eclipse, including: - * Build C++. - * Clean C++. - * Build and Run whole project. - * Logcat view. - * Debug Java code. - * Javascript editor. - * Project management. -2. True C++ editing, including: - * Code completion. - * Jump to definition. - * Refactoring tools etc. - * Quick open C++ files. - - -#### Setup Eclipse Environment (only once) - - -**NOTE:** This step needs to be done only once to setup the Eclipse environment for cocos2d-x projects. Skip this section if you've done this before. - -1. Download Eclipse ADT bundle from [Google ADT homepage](http://developer.android.com/sdk/index.html) - - **OR** - - Install Eclipse with Java. Add ADT and CDT plugins. - -2. Only for Windows - 1. Install [Cygwin](http://www.cygwin.com/) with make (select make package from the list during the install). - 2. Add `Cygwin\bin` directory to system PATH variable. - 3. Add this line `none /cygdrive cygdrive binary,noacl,posix=0,user 0 0` to `Cygwin\etc\fstab` file. - -3. Set up Variables: - 1. Path Variable `COCOS2DX`: - * Eclipse->Preferences->General->Workspace->**Linked Resources** - * Click **New** button to add a Path Variable `COCOS2DX` pointing to the root cocos2d-x directory. - ![Example](https://lh5.googleusercontent.com/-oPpk9kg3e5w/UUOYlq8n7aI/AAAAAAAAsdQ/zLA4eghBH9U/s400/cocos2d-x-eclipse-vars.png) - - 2. C/C++ Environment Variable `NDK_ROOT`: - * Eclipse->Preferences->C/C++->Build->**Environment**. - * Click **Add** button and add a new variable `NDK_ROOT` pointing to the root NDK directory. - ![Example](https://lh3.googleusercontent.com/-AVcY8IAT0_g/UUOYltoRobI/AAAAAAAAsdM/22D2J9u3sig/s400/cocos2d-x-eclipse-ndk.png) - * Only for Windows: Add new variables **CYGWIN** with value `nodosfilewarning` and **SHELLOPTS** with value `igncr` - -4. Import libcocos2dx library project: - 1. File->New->Project->Android Project From Existing Code. - 2. Click **Browse** button and open `cocos2d-x/cocos2dx/platform/android/java` directory. - 3. Click **Finish** to add project. - -#### Adding and running from Eclipse - -![Example](https://lh3.googleusercontent.com/-SLBOu6e3QbE/UUOcOXYaGqI/AAAAAAAAsdo/tYBY2SylOSM/s288/cocos2d-x-eclipse-project-from-code.png) ![Import](https://lh5.googleusercontent.com/-XzC9Pn65USc/UUOcOTAwizI/AAAAAAAAsdk/4b6YM-oim9Y/s400/cocos2d-x-eclipse-import-project.png) - -1. File->New->Project->Android Project From Existing Code -2. **Browse** to your project directory. eg: `cocos2d-x/cocos2dx/samples/Cpp/TestCpp/proj.android/` -3. Add the project -4. Click **Run** or **Debug** to compile C++ followed by Java and to run on connected device or emulator. - - -### Running project from Command Line - - $ cd cocos2d-x/samples/Cpp/TestCpp/proj.android/ - $ export NDK_ROOT=/path/to/ndk - $ ./build_native.sh - $ ant debug install - -If the last command results in sdk.dir missing error then do: - - $ android list target - $ android update project -p . -t (id from step 6) - $ android update project -p cocos2d-x/cocos2dx/platform/android/java/ -t (id from step 6) diff --git a/tests/cpp-empty-test/proj.win32/cpp-empty-test.vcxproj b/tests/cpp-empty-test/proj.win32/cpp-empty-test.vcxproj index 38b48664c1..4bc89fa9de 100644 --- a/tests/cpp-empty-test/proj.win32/cpp-empty-test.vcxproj +++ b/tests/cpp-empty-test/proj.win32/cpp-empty-test.vcxproj @@ -24,7 +24,7 @@ v110 v110_xp v120 - v120_xp + v110_xp Application @@ -33,7 +33,7 @@ v110 v110_xp v120 - v120_xp + v110_xp diff --git a/tests/cpp-tests/Android.mk b/tests/cpp-tests/Android.mk index 71ff77954d..dba250329b 100644 --- a/tests/cpp-tests/Android.mk +++ b/tests/cpp-tests/Android.mk @@ -70,6 +70,7 @@ Classes/UITest/CocoStudioGUITest/GUIEditorTest.cpp \ Classes/UITest/CocoStudioGUITest/CustomGUIScene.cpp \ Classes/UITest/CocoStudioGUITest/UIScene.cpp \ Classes/UITest/CocoStudioGUITest/UIScale9SpriteTest.cpp \ +Classes/UITest/CocoStudioGUITest/UIEditBoxTest.cpp \ Classes/UITest/CocoStudioGUITest/UISceneManager.cpp \ Classes/UITest/CocoStudioGUITest/UIButtonTest/UIButtonTest.cpp \ Classes/UITest/CocoStudioGUITest/UIFocusTest/UIFocusTest.cpp \ @@ -123,12 +124,10 @@ Classes/ExtensionsTest/ControlExtensionTest/CCControlPotentiometerTest/CCControl Classes/ExtensionsTest/ControlExtensionTest/CCControlSliderTest/CCControlSliderTest.cpp \ Classes/ExtensionsTest/ControlExtensionTest/CCControlStepperTest/CCControlStepperTest.cpp \ Classes/ExtensionsTest/ControlExtensionTest/CCControlSwitchTest/CCControlSwitchTest.cpp \ -Classes/ExtensionsTest/EditBoxTest/EditBoxTest.cpp \ Classes/ExtensionsTest/NetworkTest/HttpClientTest.cpp \ Classes/ExtensionsTest/NetworkTest/SocketIOTest.cpp \ Classes/ExtensionsTest/NetworkTest/WebSocketTest.cpp \ Classes/ExtensionsTest/NotificationCenterTest/NotificationCenterTest.cpp \ -Classes/ExtensionsTest/Scale9SpriteTest/Scale9SpriteTest.cpp \ Classes/ExtensionsTest/TableViewTest/CustomTableViewCell.cpp \ Classes/ExtensionsTest/TableViewTest/TableViewTestScene.cpp \ Classes/FileUtilsTest/FileUtilsTest.cpp \ diff --git a/tests/cpp-tests/CMakeLists.txt b/tests/cpp-tests/CMakeLists.txt index d86b9d7bc4..815cfb7e43 100644 --- a/tests/cpp-tests/CMakeLists.txt +++ b/tests/cpp-tests/CMakeLists.txt @@ -2,7 +2,6 @@ set(APP_NAME cpp-tests) if(WIN32) set(PLATFORM_SRC - Classes/ExtensionsTest/EditBoxTest/EditBoxTest.cpp Classes/ExtensionsTest/NetworkTest/WebSocketTest.cpp Classes/ExtensionsTest/NetworkTest/SocketIOTest.cpp proj.win32/main.cpp @@ -124,7 +123,6 @@ set(SAMPLE_SRC Classes/UITest/CocoStudioGUITest/CustomWidget/CustomReader.cpp Classes/UITest/CocoStudioGUITest/CustomTest/CustomImageTest/CustomImageTest.cpp Classes/UITest/CocoStudioGUITest/CustomTest/CustomParticleWidgetTest/CustomParticleWidgetTest.cpp - Classes/ExtensionsTest/Scale9SpriteTest/Scale9SpriteTest.cpp Classes/NewRendererTest/NewRendererTest.cpp Classes/NewEventDispatcherTest/NewEventDispatcherTest.cpp Classes/FontTest/FontTest.cpp diff --git a/tests/cpp-tests/Classes/ExtensionsTest/ControlExtensionTest/CCControlButtonTest/CCControlButtonTest.cpp b/tests/cpp-tests/Classes/ExtensionsTest/ControlExtensionTest/CCControlButtonTest/CCControlButtonTest.cpp index 2fef6f9aa3..6981d7c7aa 100644 --- a/tests/cpp-tests/Classes/ExtensionsTest/ControlExtensionTest/CCControlButtonTest/CCControlButtonTest.cpp +++ b/tests/cpp-tests/Classes/ExtensionsTest/ControlExtensionTest/CCControlButtonTest/CCControlButtonTest.cpp @@ -91,8 +91,8 @@ bool ControlButtonTest_HelloVariableSize::init() ControlButton *ControlButtonTest_HelloVariableSize::standardButtonWithTitle(const char * title) { /** Creates and return a button with a default background and title color. */ - auto backgroundButton = Scale9Sprite::create("extensions/button.png"); - auto backgroundHighlightedButton = Scale9Sprite::create("extensions/buttonHighlighted.png"); + auto backgroundButton = cocos2d::extension::Scale9Sprite::create("extensions/button.png"); + auto backgroundHighlightedButton = cocos2d::extension::Scale9Sprite::create("extensions/buttonHighlighted.png"); auto titleButton = Label::createWithTTF(title, "fonts/Marker Felt.ttf", 30); @@ -258,7 +258,7 @@ bool ControlButtonTest_Styling::init() layer->setPosition(screenSize.width / 2.0f, screenSize.height / 2.0f); // Add the black background - auto backgroundButton = Scale9Sprite::create("extensions/buttonBackground.png"); + auto backgroundButton = cocos2d::extension::Scale9Sprite::create("extensions/buttonBackground.png"); backgroundButton->setContentSize(Size(max_w + 14, max_h + 14)); backgroundButton->setPosition(screenSize.width / 2.0f, screenSize.height / 2.0f); addChild(backgroundButton); diff --git a/tests/cpp-tests/Classes/ExtensionsTest/EditBoxTest/EditBoxTest.cpp b/tests/cpp-tests/Classes/ExtensionsTest/EditBoxTest/EditBoxTest.cpp deleted file mode 100644 index ccb0ef030a..0000000000 --- a/tests/cpp-tests/Classes/ExtensionsTest/EditBoxTest/EditBoxTest.cpp +++ /dev/null @@ -1,134 +0,0 @@ -// -// EditBoxTest.cpp -// TestCpp -// -// Created by James on 8/14/12. -// -// - -#include "EditBoxTest.h" -#include "../ExtensionsTest.h" - -USING_NS_CC; -USING_NS_CC_EXT; - - -EditBoxTest::EditBoxTest() -{ - auto glview = Director::getInstance()->getOpenGLView(); - auto visibleOrigin = glview->getVisibleOrigin(); - auto visibleSize = glview->getVisibleSize(); - - auto pBg = Sprite::create("Images/HelloWorld.png"); - pBg->setPosition(visibleOrigin.x+visibleSize.width/2, visibleOrigin.y+visibleSize.height/2); - addChild(pBg); - - _TTFShowEditReturn = Label::createWithSystemFont("No edit control return!", "", 30); - _TTFShowEditReturn->setPosition(visibleOrigin.x+visibleSize.width/2, visibleOrigin.y + visibleSize.height - 50); - addChild(_TTFShowEditReturn); - - // Back Menu - auto itemBack = MenuItemFont::create("Back", CC_CALLBACK_1(EditBoxTest::toExtensionsMainLayer, this)); - itemBack->setPosition(visibleOrigin.x+visibleSize.width - 50, visibleOrigin.y+25); - auto menuBack = Menu::create(itemBack, nullptr); - menuBack->setPosition(Vec2::ZERO); - addChild(menuBack); - - auto editBoxSize = Size(visibleSize.width - 100, 60); - - // top - _editName = EditBox::create(editBoxSize, Scale9Sprite::create("extensions/green_edit.png")); - _editName->setPosition(Vec2(visibleOrigin.x+visibleSize.width/2, visibleOrigin.y+visibleSize.height*3/4)); - _editName->setFontName("Paint Boy"); - _editName->setFontSize(25); - _editName->setFontColor(Color3B::RED); - _editName->setPlaceHolder("Name:"); - _editName->setPlaceholderFontColor(Color3B::WHITE); - _editName->setMaxLength(8); - _editName->setReturnType(EditBox::KeyboardReturnType::DONE); - _editName->setDelegate(this); - addChild(_editName); - - // middle - _editPassword = EditBox::create(editBoxSize, Scale9Sprite::create("extensions/orange_edit.png")); - _editPassword->setPosition(Vec2(visibleOrigin.x+visibleSize.width/2, visibleOrigin.y+visibleSize.height/2)); -#if (CC_TARGET_PLATFORM == CC_PLATFORM_IOS) - _editPassword->setFont("American Typewriter", 30); -#else - _editPassword->setFont("American Typewriter", 80); - _editPassword->setPlaceholderFont("American Typewriter", 80); -#endif - _editPassword->setFontColor(Color3B::GREEN); - _editPassword->setPlaceHolder("Password:"); - _editPassword->setMaxLength(6); - _editPassword->setInputFlag(EditBox::InputFlag::PASSWORD); - _editPassword->setInputMode(EditBox::InputMode::SINGLE_LINE); - _editPassword->setDelegate(this); - addChild(_editPassword); - - // bottom - _editEmail = EditBox::create(Size(editBoxSize.width, editBoxSize.height), Scale9Sprite::create("extensions/yellow_edit.png")); - _editEmail->setPosition(Vec2(visibleOrigin.x+visibleSize.width/2, visibleOrigin.y+visibleSize.height/4)); - _editEmail->setAnchorPoint(Vec2(0.5, 1.0f)); - _editEmail->setPlaceHolder("Email:"); - _editEmail->setInputMode(EditBox::InputMode::EMAIL_ADDRESS); - _editEmail->setDelegate(this); - addChild(_editEmail); - - this->setPosition(10, 20); -} - -EditBoxTest::~EditBoxTest() -{ - -} - -void EditBoxTest::toExtensionsMainLayer(cocos2d::Ref *sender) -{ - auto scene = new (std::nothrow) ExtensionsTestScene(); - scene->runThisTest(); - scene->release(); -} - -void EditBoxTest::editBoxEditingDidBegin(cocos2d::extension::EditBox* editBox) -{ - log("editBox %p DidBegin !", editBox); -} - -void EditBoxTest::editBoxEditingDidEnd(cocos2d::extension::EditBox* editBox) -{ - log("editBox %p DidEnd !", editBox); -} - -void EditBoxTest::editBoxTextChanged(cocos2d::extension::EditBox* editBox, const std::string& text) -{ - log("editBox %p TextChanged, text: %s ", editBox, text.c_str()); -} - -void EditBoxTest::editBoxReturn(EditBox* editBox) -{ - log("editBox %p was returned !",editBox); - - if (_editName == editBox) - { - _TTFShowEditReturn->setString("Name EditBox return !"); - } - else if (_editPassword == editBox) - { - _TTFShowEditReturn->setString("Password EditBox return !"); - } - else if (_editEmail == editBox) - { - _TTFShowEditReturn->setString("Email EditBox return !"); - } -} - -void runEditBoxTest() -{ - auto scene = Scene::create(); - EditBoxTest *layer = new (std::nothrow) EditBoxTest(); - scene->addChild(layer); - - Director::getInstance()->replaceScene(scene); - layer->release(); -} diff --git a/tests/cpp-tests/Classes/ExtensionsTest/EditBoxTest/EditBoxTest.h b/tests/cpp-tests/Classes/ExtensionsTest/EditBoxTest/EditBoxTest.h deleted file mode 100644 index 3cef026dbd..0000000000 --- a/tests/cpp-tests/Classes/ExtensionsTest/EditBoxTest/EditBoxTest.h +++ /dev/null @@ -1,35 +0,0 @@ -// -// EditBoxTest.h -// TestCpp -// -// Created by James on 8/14/12. -// -// - -#ifndef __TestCpp__CCEditBoxTest__ -#define __TestCpp__CCEditBoxTest__ - -#include "cocos2d.h" -#include "extensions/cocos-ext.h" - -class EditBoxTest : public cocos2d::Layer, public cocos2d::extension::EditBoxDelegate -{ -public: - EditBoxTest(); - virtual ~EditBoxTest(); - void toExtensionsMainLayer(cocos2d::Ref *sender); - - virtual void editBoxEditingDidBegin(cocos2d::extension::EditBox* editBox); - virtual void editBoxEditingDidEnd(cocos2d::extension::EditBox* editBox); - virtual void editBoxTextChanged(cocos2d::extension::EditBox* editBox, const std::string& text); - virtual void editBoxReturn(cocos2d::extension::EditBox* editBox); -private: - cocos2d::Label* _TTFShowEditReturn; - cocos2d::extension::EditBox* _editName; - cocos2d::extension::EditBox* _editPassword; - cocos2d::extension::EditBox* _editEmail; -}; - -void runEditBoxTest(); - -#endif /* defined(__TestCpp__CCEditBoxTest__) */ diff --git a/tests/cpp-tests/Classes/ExtensionsTest/ExtensionsTest.cpp b/tests/cpp-tests/Classes/ExtensionsTest/ExtensionsTest.cpp index 3a09e2da85..10d31a2900 100644 --- a/tests/cpp-tests/Classes/ExtensionsTest/ExtensionsTest.cpp +++ b/tests/cpp-tests/Classes/ExtensionsTest/ExtensionsTest.cpp @@ -18,11 +18,6 @@ #include "NetworkTest/SocketIOTest.h" #endif -#if (CC_TARGET_PLATFORM == CC_PLATFORM_IOS) || (CC_TARGET_PLATFORM == CC_PLATFORM_ANDROID) || (CC_TARGET_PLATFORM == CC_PLATFORM_MAC) || (CC_TARGET_PLATFORM == CC_PLATFORM_WIN32) || (CC_TARGET_PLATFORM == CC_PLATFORM_TIZEN) || (CC_TARGET_PLATFORM == CC_PLATFORM_WP8) -#include "EditBoxTest/EditBoxTest.h" -#endif - -#include "Scale9SpriteTest/Scale9SpriteTest.h" enum { @@ -36,15 +31,6 @@ static struct { } g_extensionsTests[] = { { "NotificationCenterTest", [](Ref* sender) { runNotificationCenterTest(); } }, - { "Scale9SpriteTest", [](Ref* sender) { - auto scene = new (std::nothrow) S9SpriteTestScene(); - if (scene) - { - scene->runThisTest(); - scene->release(); - } - } - }, { "CCControlButtonTest", [](Ref *sender){ ControlSceneManager* pManager = ControlSceneManager::sharedControlSceneManager(); auto scene = pManager->currentControlScene(); @@ -68,10 +54,7 @@ static struct { { "SocketIOTest", [](Ref *sender){ runSocketIOTest();} }, #endif -#if (CC_TARGET_PLATFORM == CC_PLATFORM_IOS) || (CC_TARGET_PLATFORM == CC_PLATFORM_ANDROID) || (CC_TARGET_PLATFORM == CC_PLATFORM_MAC) || (CC_TARGET_PLATFORM == CC_PLATFORM_WIN32) || (CC_TARGET_PLATFORM == CC_PLATFORM_TIZEN) || (CC_TARGET_PLATFORM == CC_PLATFORM_WP8) - { "EditBoxTest", [](Ref *sender){ runEditBoxTest();} - }, -#endif + { "TableViewTest", [](Ref *sender){ runTableViewTest();} }, { "CocoStudioArmatureTest", [](Ref *sender) { ArmatureTestScene *scene = new (std::nothrow) ArmatureTestScene(); diff --git a/tests/cpp-tests/Classes/ExtensionsTest/Scale9SpriteTest/Scale9SpriteTest.cpp b/tests/cpp-tests/Classes/ExtensionsTest/Scale9SpriteTest/Scale9SpriteTest.cpp deleted file mode 100644 index c8cc71acbf..0000000000 --- a/tests/cpp-tests/Classes/ExtensionsTest/Scale9SpriteTest/Scale9SpriteTest.cpp +++ /dev/null @@ -1,784 +0,0 @@ -/**************************************************************************** - Copyright (c) 2010-2012 cocos2d-x.org - Copyright (c) 2008-2010 Ricardo Quesada - Copyright (c) 2011 Zynga Inc. - Copyright (c) 2013 Surith Thekkiam - - http://www.cocos2d-x.org - - Permission is hereby granted, free of charge, to any person obtaining a copy - of this software and associated documentation files (the "Software"), to deal - in the Software without restriction, including without limitation the rights - to use, copy, modify, merge, publish, distribute, sublicense, and/or sell - copies of the Software, and to permit persons to whom the Software is - furnished to do so, subject to the following conditions: - - The above copyright notice and this permission notice shall be included in - all copies or substantial portions of the Software. - - THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN - THE SOFTWARE. - ****************************************************************************/ - -#include "Scale9SpriteTest.h" -#include "testResource.h" -#include "cocos2d.h" -#include "extensions/cocos-ext.h" - -USING_NS_CC_EXT; - -static std::function createFunctions[] = { - CL(S9BatchNodeBasic), - CL(S9FrameNameSpriteSheet), - CL(S9FrameNameSpriteSheetRotated), - CL(S9BatchNodeScaledNoInsets), - CL(S9FrameNameSpriteSheetScaledNoInsets), - CL(S9FrameNameSpriteSheetRotatedScaledNoInsets), - CL(S9BatchNodeScaleWithCapInsets), - CL(S9FrameNameSpriteSheetInsets), - CL(S9FrameNameSpriteSheetInsetsScaled), - CL(S9FrameNameSpriteSheetRotatedInsets), - CL(S9_TexturePacker), - CL(S9FrameNameSpriteSheetRotatedInsetsScaled), - CL(S9FrameNameSpriteSheetRotatedSetCapInsetLater), - CL(S9CascadeOpacityAndColor), - CL(S9ZOrder), - CL(S9Flip) -}; - -static int sceneIdx=-1; -#define MAX_LAYER (sizeof(createFunctions) / sizeof(createFunctions[0])) - -static Layer* nextAction() -{ - sceneIdx++; - sceneIdx = sceneIdx % MAX_LAYER; - - auto layer = (createFunctions[sceneIdx])(); - return layer; -} - -static Layer* backAction() -{ - sceneIdx--; - int total = MAX_LAYER; - if( sceneIdx < 0 ) - sceneIdx += total; - - auto layer = (createFunctions[sceneIdx])(); - return layer; -} - -static Layer* restartAction() -{ - auto layer = (createFunctions[sceneIdx])(); - return layer; -} - -void S9SpriteTestScene::runThisTest() -{ - sceneIdx = -1; - addChild(nextAction()); - - Director::getInstance()->replaceScene(this); -} - -//------------------------------------------------------------------ -// -// S9SpriteTestDemo -// -//------------------------------------------------------------------ - -void S9SpriteTestDemo::onEnter() -{ - BaseTest::onEnter(); - SpriteFrameCache::getInstance()->addSpriteFramesWithFile(s_s9s_blocks9_plist); - CCLOG("sprite frames added to sprite frame cache..."); -} - -void S9SpriteTestDemo::restartCallback(Ref* sender) -{ - auto s = new (std::nothrow) S9SpriteTestScene(); - s->addChild( restartAction() ); - Director::getInstance()->replaceScene(s); - s->release(); -} - -void S9SpriteTestDemo::nextCallback(Ref* sender) -{ - auto s = new (std::nothrow) S9SpriteTestScene(); - s->addChild( nextAction() ); - Director::getInstance()->replaceScene(s); - s->release(); -} - -void S9SpriteTestDemo::backCallback(Ref* sender) -{ - auto s = new (std::nothrow) S9SpriteTestScene(); - s->addChild( backAction() ); - Director::getInstance()->replaceScene(s); - s->release(); -} - - -// S9BatchNodeBasic - -void S9BatchNodeBasic::onEnter() -{ - S9SpriteTestDemo::onEnter(); - auto winSize = Director::getInstance()->getWinSize(); - float x = winSize.width / 2; - float y = 0 + (winSize.height / 2); - - log("S9BatchNodeBasic ..."); - - auto batchNode = SpriteBatchNode::create("Images/blocks9.png"); - log("batchNode created with : Images/blocks9.png"); - - auto blocks = Scale9Sprite::create(); - log("... created"); - - blocks->updateWithBatchNode(batchNode, Rect(0, 0, 96, 96), false, Rect(0, 0, 96, 96)); - log("... updateWithBatchNode"); - - blocks->setPosition(Vec2(x, y)); - log("... setPosition"); - - this->addChild(blocks); - log("this->addChild"); - - log("... S9BatchNodeBasic done."); -} - -std::string S9BatchNodeBasic::title() const -{ - return "Scale9Sprite created empty and updated from SpriteBatchNode"; -} - -std::string S9BatchNodeBasic::subtitle() const -{ - return "updateWithBatchNode(); capInsets=full size"; -} - - -// S9FrameNameSpriteSheet - -void S9FrameNameSpriteSheet::onEnter() -{ - S9SpriteTestDemo::onEnter(); - auto winSize = Director::getInstance()->getWinSize(); - float x = winSize.width / 2; - float y = 0 + (winSize.height / 2); - - log("S9FrameNameSpriteSheet ..."); - - auto blocks = Scale9Sprite::createWithSpriteFrameName("blocks9.png"); - log("... created"); - - blocks->setPosition(Vec2(x, y)); - log("... setPosition"); - - this->addChild(blocks); - log("this->addChild"); - - log("... S9FrameNameSpriteSheet done."); -} - -std::string S9FrameNameSpriteSheet::title() const -{ - return "Scale9Sprite from sprite sheet"; -} - -std::string S9FrameNameSpriteSheet::subtitle() const -{ - return "createWithSpriteFrameName(); default cap insets"; -} - -// -//// S9FrameNameSpriteSheetRotated -// -void S9FrameNameSpriteSheetRotated::onEnter() -{ - S9SpriteTestDemo::onEnter(); - auto winSize = Director::getInstance()->getWinSize(); - float x = winSize.width / 2; - float y = 0 + (winSize.height / 2); - - log("S9FrameNameSpriteSheetRotated ..."); - - auto blocks = Scale9Sprite::createWithSpriteFrameName("blocks9r.png"); - log("... created"); - - blocks->setPosition(Vec2(x, y)); - log("... setPosition"); - - this->addChild(blocks); - log("this->addChild"); - - log("... S9FrameNameSpriteSheetRotated done."); -} - -std::string S9FrameNameSpriteSheetRotated::title() const -{ - return "Scale9Sprite from sprite sheet (stored rotated)"; -} - -std::string S9FrameNameSpriteSheetRotated::subtitle() const -{ - return "createWithSpriteFrameName(); default cap insets"; -} - -// -//// S9BatchNodeScaledNoInsets -// - -void S9BatchNodeScaledNoInsets::onEnter() -{ - S9SpriteTestDemo::onEnter(); - auto winSize = Director::getInstance()->getWinSize(); - float x = winSize.width / 2; - float y = 0 + (winSize.height / 2); - - log("S9BatchNodeScaledNoInsets ..."); - - // scaled without insets - auto batchNode_scaled = SpriteBatchNode::create("Images/blocks9.png"); - log("batchNode_scaled created with : Images/blocks9.png"); - - auto blocks_scaled = Scale9Sprite::create(); - log("... created"); - blocks_scaled->updateWithBatchNode(batchNode_scaled, Rect(0, 0, 96, 96), false, Rect(0, 0, 96, 96)); - log("... updateWithBatchNode"); - - blocks_scaled->setPosition(Vec2(x, y)); - log("... setPosition"); - - blocks_scaled->setContentSize(Size(96 * 4, 96*2)); - log("... setContentSize"); - - this->addChild(blocks_scaled); - log("this->addChild"); - - log("... S9BtchNodeScaledNoInsets done."); -} - -std::string S9BatchNodeScaledNoInsets::title() const -{ - return "Scale9Sprite created empty and updated from SpriteBatchNode"; -} - -std::string S9BatchNodeScaledNoInsets::subtitle() const -{ - return "updateWithBatchNode(); capInsets=full size; rendered 4 X width, 2 X height"; -} - -// -//// S9FrameNameSpriteSheetScaledNoInsets -// - -void S9FrameNameSpriteSheetScaledNoInsets::onEnter() -{ - S9SpriteTestDemo::onEnter(); - auto winSize = Director::getInstance()->getWinSize(); - float x = winSize.width / 2; - float y = 0 + (winSize.height / 2); - - log("S9FrameNameSpriteSheetScaledNoInsets ..."); - - auto blocks_scaled = Scale9Sprite::createWithSpriteFrameName("blocks9.png"); - log("... created"); - - blocks_scaled->setPosition(Vec2(x, y)); - log("... setPosition"); - - blocks_scaled->setContentSize(Size(96 * 4, 96*2)); - log("... setContentSize"); - - this->addChild(blocks_scaled); - log("this->addChild"); - - log("... S9FrameNameSpriteSheetScaledNoInsets done."); -} - -std::string S9FrameNameSpriteSheetScaledNoInsets::title() const -{ - return "Scale9Sprite from sprite sheet"; -} - -std::string S9FrameNameSpriteSheetScaledNoInsets::subtitle() const -{ - return "createWithSpriteFrameName(); default cap insets; rendered 4 X width, 2 X height"; -} - - -// -//// S9FrameNameSpriteSheetRotatedScaledNoInsets -// - -void S9FrameNameSpriteSheetRotatedScaledNoInsets::onEnter() -{ - S9SpriteTestDemo::onEnter(); - auto winSize = Director::getInstance()->getWinSize(); - float x = winSize.width / 2; - float y = 0 + (winSize.height / 2); - - log("S9FrameNameSpriteSheetRotatedScaledNoInsets ..."); - - auto blocks_scaled = Scale9Sprite::createWithSpriteFrameName("blocks9r.png"); - log("... created"); - - blocks_scaled->setPosition(Vec2(x, y)); - log("... setPosition"); - - blocks_scaled->setContentSize(Size(96 * 4, 96*2)); - log("... setContentSize"); - - this->addChild(blocks_scaled); - log("this->addChild"); - - log("... S9FrameNameSpriteSheetRotatedScaledNoInsets done."); -} - -std::string S9FrameNameSpriteSheetRotatedScaledNoInsets::title() const -{ - return "Scale9Sprite from sprite sheet (stored rotated)"; -} - -std::string S9FrameNameSpriteSheetRotatedScaledNoInsets::subtitle() const -{ - return "createWithSpriteFrameName(); default cap insets; rendered 4 X width, 2 X height"; -} - -// -// -//// S9BatchNodeScaleWithCapInsets -// - -void S9BatchNodeScaleWithCapInsets::onEnter() -{ - S9SpriteTestDemo::onEnter(); - auto winSize = Director::getInstance()->getWinSize(); - float x = winSize.width / 2; - float y = 0 + (winSize.height / 2); - - log("S9BatchNodeScaleWithCapInsets ..."); - - auto batchNode_scaled_with_insets = SpriteBatchNode::create("Images/blocks9.png"); - log("batchNode_scaled_with_insets created with : Images/blocks9.png"); - - auto blocks_scaled_with_insets = Scale9Sprite::create(); - log("... created"); - - blocks_scaled_with_insets->updateWithBatchNode(batchNode_scaled_with_insets, Rect(0, 0, 96, 96), false, Rect(32, 32, 32, 32)); - log("... updateWithBatchNode"); - - blocks_scaled_with_insets->setContentSize(Size(96 * 4.5, 96 * 2.5)); - log("... setContentSize"); - - blocks_scaled_with_insets->setPosition(Vec2(x, y)); - log("... setPosition"); - - this->addChild(blocks_scaled_with_insets); - log("this->addChild"); - - log("... S9BatchNodeScaleWithCapInsets done."); -} - -std::string S9BatchNodeScaleWithCapInsets::title() const -{ - return "Scale9Sprite created empty and updated from SpriteBatchNode"; -} - -std::string S9BatchNodeScaleWithCapInsets::subtitle() const -{ - return "updateWithBatchNode(); capInsets=(32, 32, 32, 32)"; -} - -// -//// S9FrameNameSpriteSheetInsets -// - -void S9FrameNameSpriteSheetInsets::onEnter() -{ - S9SpriteTestDemo::onEnter(); - auto winSize = Director::getInstance()->getWinSize(); - float x = winSize.width / 2; - float y = 0 + (winSize.height / 2); - - log("S9FrameNameSpriteSheetInsets ..."); - - auto blocks_with_insets = Scale9Sprite::createWithSpriteFrameName("blocks9.png", Rect(32, 32, 32, 32)); - log("... created"); - - blocks_with_insets->setPosition(Vec2(x, y)); - log("... setPosition"); - - this->addChild(blocks_with_insets); - log("this->addChild"); - - log("... S9FrameNameSpriteSheetInsets done."); -} - -std::string S9FrameNameSpriteSheetInsets::title() const -{ - return "Scale9Sprite scaled with insets sprite sheet"; -} - -std::string S9FrameNameSpriteSheetInsets::subtitle() const -{ - return "createWithSpriteFrameName(); cap insets=(32, 32, 32, 32)"; -} - -// -//// S9FrameNameSpriteSheetInsetsScaled -// -void S9FrameNameSpriteSheetInsetsScaled::onEnter() -{ - S9SpriteTestDemo::onEnter(); - auto winSize = Director::getInstance()->getWinSize(); - float x = winSize.width / 2; - float y = 0 + (winSize.height / 2); - - log("S9FrameNameSpriteSheetInsetsScaled ..."); - - auto blocks_scaled_with_insets = Scale9Sprite::createWithSpriteFrameName("blocks9.png", Rect(32, 32, 32, 32)); - log("... created"); - - blocks_scaled_with_insets->setContentSize(Size(96 * 4.5, 96 * 2.5)); - log("... setContentSize"); - - blocks_scaled_with_insets->setPosition(Vec2(x, y)); - log("... setPosition"); - - this->addChild(blocks_scaled_with_insets); - log("this->addChild"); - - log("... S9FrameNameSpriteSheetInsetsScaled done."); -} - -std::string S9FrameNameSpriteSheetInsetsScaled::title() const -{ - return "Scale9Sprite scaled with insets sprite sheet"; -} - -std::string S9FrameNameSpriteSheetInsetsScaled::subtitle() const -{ - return "createWithSpriteFrameName(); default cap insets; rendered scaled 4.5 X width, 2.5 X height"; -} - -//// S9FrameNameSpriteSheetRotatedInsets -// - -void S9FrameNameSpriteSheetRotatedInsets::onEnter() -{ - S9SpriteTestDemo::onEnter(); - auto winSize = Director::getInstance()->getWinSize(); - float x = winSize.width / 2; - float y = 0 + (winSize.height / 2); - - log("S9FrameNameSpriteSheetRotatedInsets ..."); - - auto blocks_with_insets = Scale9Sprite::createWithSpriteFrameName("blocks9r.png", Rect(32, 32, 32, 32)); - log("... created"); - - blocks_with_insets->setPosition(Vec2(x, y)); - log("... setPosition"); - - this->addChild(blocks_with_insets); - log("this->addChild"); - - log("... S9FrameNameSpriteSheetRotatedInsets done."); -} - -std::string S9FrameNameSpriteSheetRotatedInsets::title() const -{ - return "Scale9Sprite scaled with insets sprite sheet (stored rotated)"; -} - -std::string S9FrameNameSpriteSheetRotatedInsets::subtitle() const -{ - return "createWithSpriteFrameName(); cap insets=(32, 32, 32, 32)"; -} - -// -//// S9_TexturePacker -// - -void S9_TexturePacker::onEnter() -{ - S9SpriteTestDemo::onEnter(); - auto winSize = Director::getInstance()->getWinSize(); - SpriteFrameCache::getInstance()->addSpriteFramesWithFile(s_s9s_ui_plist); - - float x = winSize.width / 4; - float y = 0 + (winSize.height / 2); - - log("S9_TexturePacker ..."); - - auto s = Scale9Sprite::createWithSpriteFrameName("button_normal.png"); - log("... created"); - - s->setPosition(Vec2(x, y)); - log("... setPosition"); - - s->setContentSize(Size(14 * 16, 10 * 16)); - log("... setContentSize"); - - this->addChild(s); - log("this->addChild"); - - x = winSize.width * 3/4; - - auto s2 = Scale9Sprite::createWithSpriteFrameName("button_actived.png"); - log("... created"); - - s2->setPosition(Vec2(x, y)); - log("... setPosition"); - - s2->setContentSize(Size(14 * 16, 10 * 16)); - log("... setContentSize"); - - this->addChild(s2); - log("this->addChild"); - - log("... S9_TexturePacker done."); -} - -std::string S9_TexturePacker::title() const -{ - return "Scale9Sprite from a spritesheet created with TexturePacker"; -} - -std::string S9_TexturePacker::subtitle() const -{ - return "createWithSpriteFrameName('button_normal.png');createWithSpriteFrameName('button_actived.png');"; -} - -// -//// S9FrameNameSpriteSheetRotatedInsetsScaled -// - -void S9FrameNameSpriteSheetRotatedInsetsScaled::onEnter() -{ - S9SpriteTestDemo::onEnter(); - auto winSize = Director::getInstance()->getWinSize(); - float x = winSize.width / 2; - float y = 0 + (winSize.height / 2); - - log("S9FrameNameSpriteSheetRotatedInsetsScaled ..."); - - auto blocks_scaled_with_insets = Scale9Sprite::createWithSpriteFrameName("blocks9.png", Rect(32, 32, 32, 32)); - log("... created"); - - blocks_scaled_with_insets->setContentSize(Size(96 * 4.5, 96 * 2.5)); - log("... setContentSize"); - - blocks_scaled_with_insets->setPosition(Vec2(x, y)); - log("... setPosition"); - - this->addChild(blocks_scaled_with_insets); - log("this->addChild"); - - log("... S9FrameNameSpriteSheetRotatedInsetsScaled done."); -} - -std::string S9FrameNameSpriteSheetRotatedInsetsScaled::title() const -{ - return "Scale9Sprite scaled with insets sprite sheet (stored rotated)"; -} - -std::string S9FrameNameSpriteSheetRotatedInsetsScaled::subtitle() const -{ - return "createWithSpriteFrameName(); default cap insets; rendered scaled 4.5 X width, 2.5 X height"; -} - -// -//// Scale9FrameNameSpriteSheetRotatedSetCapInsetLater -// - -void S9FrameNameSpriteSheetRotatedSetCapInsetLater::onEnter() -{ - S9SpriteTestDemo::onEnter(); - auto winSize = Director::getInstance()->getWinSize(); - float x = winSize.width / 2; - float y = 0 + (winSize.height / 2); - - log("Scale9FrameNameSpriteSheetRotatedSetCapInsetLater ..."); - - auto blocks_scaled_with_insets = Scale9Sprite::createWithSpriteFrameName("blocks9r.png"); - log("... created"); - - blocks_scaled_with_insets->setInsetLeft(32); - blocks_scaled_with_insets->setInsetRight(32); - - blocks_scaled_with_insets->setPreferredSize(Size(32*5.5f, 32*4)); - blocks_scaled_with_insets->setPosition(Vec2(x, y)); - log("... setPosition"); - - this->addChild(blocks_scaled_with_insets); - log("this->addChild"); - - log("... Scale9FrameNameSpriteSheetRotatedSetCapInsetLater done."); -} - -std::string S9FrameNameSpriteSheetRotatedSetCapInsetLater::title() const -{ - return "Scale9Sprite from sprite sheet (stored rotated), with setting CapInset later"; -} - -std::string S9FrameNameSpriteSheetRotatedSetCapInsetLater::subtitle() const -{ - return "createWithSpriteFrameName(); setInsetLeft(32); setInsetRight(32);"; -} - -// -//// S9CascadeOpacityAndColor -// - -void S9CascadeOpacityAndColor::onEnter() -{ - S9SpriteTestDemo::onEnter(); - auto winSize = Director::getInstance()->getWinSize(); - float x = winSize.width / 2; - float y = 0 + (winSize.height / 2); - auto rgba = Layer::create(); - rgba->setCascadeColorEnabled(true); - rgba->setCascadeOpacityEnabled(true); - this->addChild(rgba); - - log("S9CascadeOpacityAndColor ..."); - - auto blocks_scaled_with_insets = Scale9Sprite::createWithSpriteFrameName("blocks9r.png"); - log("... created"); - - blocks_scaled_with_insets->setPosition(Vec2(x, y)); - log("... setPosition"); - - rgba->addChild(blocks_scaled_with_insets); - auto actions = Sequence::create(FadeIn::create(1), - TintTo::create(1, 0, 255, 0), - TintTo::create(1, 255, 255, 255), - FadeOut::create(1), - nullptr); - auto repeat = RepeatForever::create(actions); - rgba->runAction(repeat); - log("this->addChild"); - - log("... S9CascadeOpacityAndColor done."); -} - -std::string S9CascadeOpacityAndColor::title() const -{ - return "Scale9Sprite and a Layer parent with setCascadeOpacityEnable(true) and setCascadeColorEnable(true)"; -} - -std::string S9CascadeOpacityAndColor::subtitle() const -{ - return "when parent change color/opacity, Scale9Sprite should also change"; -} - -// -//// S9ZOrder -// - -void S9ZOrder::onEnter() -{ - S9SpriteTestDemo::onEnter(); - auto winSize = Director::getInstance()->getWinSize(); - float x = winSize.width / 2; - float y = 0 + (winSize.height / 2); - - auto blocks_scaled_with_insets = Scale9Sprite::createWithSpriteFrameName("blocks9r.png"); - - blocks_scaled_with_insets->setPosition(Vec2(x, y)); - this->addChild(blocks_scaled_with_insets); - - Sprite *normalSprite = Sprite::createWithSpriteFrameName("blocks9r.png"); - normalSprite->setColor(Color3B::RED); - blocks_scaled_with_insets->addChild(normalSprite); - - auto topLabel = Label::createWithSystemFont("I Must be On the Top", "Arial", 15); - topLabel->setPosition(Vec2(20,20)); - blocks_scaled_with_insets->addChild(topLabel); - - auto bottomLabel = Label::createWithSystemFont("I Must be On the Bottom", "Arial", 15); - bottomLabel->setPosition(Vec2(80,80)); - bottomLabel->setColor(Color3B::BLUE); - blocks_scaled_with_insets->addChild(bottomLabel,-1); - -} - -std::string S9ZOrder::title() const -{ - return "Scale9Sprite ZOrder issue"; -} - -std::string S9ZOrder::subtitle() const -{ - return "When adding nodes to Scale9Sprite, it should be added on top itself"; -} - -// -//// S9Flip -// - -void S9Flip::onEnter() -{ - S9SpriteTestDemo::onEnter(); - auto winSize = Director::getInstance()->getWinSize(); - float x = winSize.width / 2; - float y = 0 + (winSize.height / 2); - - - auto normalSprite = Scale9Sprite::createWithSpriteFrameName("blocks9r.png"); - - normalSprite->setPosition(Vec2(x, y )); - this->addChild(normalSprite); - - - auto normalLabel = Label::createWithSystemFont("Normal Sprite","Airal",10); - normalLabel->setPosition(normalSprite->getPosition() + Vec2(0, normalSprite->getContentSize().height/2 + 10)); - this->addChild(normalLabel); - - - - auto flipXSprite = Scale9Sprite::createWithSpriteFrameName("blocks9r.png"); - - flipXSprite->setPosition(Vec2(x - 120, y )); - this->addChild(flipXSprite); - - flipXSprite->setScaleX(-1); - - auto flipXLabel = Label::createWithSystemFont("Sprite FlipX","Airal",10); - flipXLabel->setPosition(flipXSprite->getPosition() + Vec2(0, flipXSprite->getContentSize().height/2 + 10)); - this->addChild(flipXLabel); - - - auto flipYSprite = Scale9Sprite::createWithSpriteFrameName("blocks9r.png"); - - flipYSprite->setPosition(Vec2(x + 120, y)); - this->addChild(flipYSprite); - - flipYSprite->setScaleY(-1); - - auto flipYLabel = Label::createWithSystemFont("Sprite FlipY","Airal",10); - flipYLabel->setPosition(flipYSprite->getPosition() + Vec2(0, flipYSprite->getContentSize().height/2 + 10)); - this->addChild(flipYLabel); - - -} - -std::string S9Flip::title() const -{ - return "Scale9Sprite Flip issue"; -} - -std::string S9Flip::subtitle() const -{ - return "When Flipped, the scale9Sprite should behavior like a normal node"; -} diff --git a/tests/cpp-tests/Classes/ExtensionsTest/Scale9SpriteTest/Scale9SpriteTest.h b/tests/cpp-tests/Classes/ExtensionsTest/Scale9SpriteTest/Scale9SpriteTest.h deleted file mode 100644 index a5448fb86e..0000000000 --- a/tests/cpp-tests/Classes/ExtensionsTest/Scale9SpriteTest/Scale9SpriteTest.h +++ /dev/null @@ -1,255 +0,0 @@ -/**************************************************************************** - Copyright (c) 2010-2012 cocos2d-x.org - Copyright (c) 2008-2010 Ricardo Quesada - Copyright (c) 2011 Zynga Inc. - Copyright (c) 2013 Surith Thekkiam - - http://www.cocos2d-x.org - - Permission is hereby granted, free of charge, to any person obtaining a copy - of this software and associated documentation files (the "Software"), to deal - in the Software without restriction, including without limitation the rights - to use, copy, modify, merge, publish, distribute, sublicense, and/or sell - copies of the Software, and to permit persons to whom the Software is - furnished to do so, subject to the following conditions: - - The above copyright notice and this permission notice shall be included in - all copies or substantial portions of the Software. - - THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN - THE SOFTWARE. - ****************************************************************************/ - -#include "testBasic.h" -#include "BaseTest.h" - - -class S9SpriteTestScene : public TestScene -{ -public: - virtual void runThisTest(); -}; - -class S9SpriteTestDemo : public BaseTest -{ -public: - virtual void onEnter() override; - - virtual void restartCallback(Ref* sender); - virtual void nextCallback(Ref* sender); - virtual void backCallback(Ref* sender); -}; - -// S9BatchNodeBasic - -class S9BatchNodeBasic : public S9SpriteTestDemo -{ -public: - CREATE_FUNC(S9BatchNodeBasic); - - virtual void onEnter() override; - - virtual std::string title() const override; - virtual std::string subtitle() const override; -}; - -// S9FrameNameSpriteSheet - -class S9FrameNameSpriteSheet : public S9SpriteTestDemo -{ -public: - CREATE_FUNC(S9FrameNameSpriteSheet); - - virtual void onEnter() override; - - virtual std::string title() const override; - virtual std::string subtitle() const override; -}; - -// S9FrameNameSpriteSheetRotated - -class S9FrameNameSpriteSheetRotated : public S9SpriteTestDemo -{ -public: - CREATE_FUNC(S9FrameNameSpriteSheetRotated); - - virtual void onEnter() override; - - virtual std::string title() const override; - virtual std::string subtitle() const override; -}; - -// S9BatchNodeScaledNoInsets - -class S9BatchNodeScaledNoInsets : public S9SpriteTestDemo -{ -public: - CREATE_FUNC(S9BatchNodeScaledNoInsets); - - virtual void onEnter() override; - - virtual std::string title() const override; - virtual std::string subtitle() const override; -}; - -// S9FrameNameSpriteSheetScaledNoInsets - -class S9FrameNameSpriteSheetScaledNoInsets : public S9SpriteTestDemo -{ -public: - CREATE_FUNC(S9FrameNameSpriteSheetScaledNoInsets); - - virtual void onEnter() override; - - virtual std::string title() const override; - virtual std::string subtitle() const override; -}; - -// S9FrameNameSpriteSheetRotatedScaledNoInsets - -class S9FrameNameSpriteSheetRotatedScaledNoInsets : public S9SpriteTestDemo -{ -public: - CREATE_FUNC(S9FrameNameSpriteSheetRotatedScaledNoInsets); - - virtual void onEnter() override; - - virtual std::string title() const override; - virtual std::string subtitle() const override; -}; - - -// S9BatchNodeScaleWithCapInsets - -class S9BatchNodeScaleWithCapInsets : public S9SpriteTestDemo -{ -public: - CREATE_FUNC(S9BatchNodeScaleWithCapInsets); - - virtual void onEnter() override; - - virtual std::string title() const override; - virtual std::string subtitle() const override; -}; - -// S9FrameNameSpriteSheetInsets - -class S9FrameNameSpriteSheetInsets : public S9SpriteTestDemo -{ -public: - CREATE_FUNC(S9FrameNameSpriteSheetInsets); - - virtual void onEnter() override; - - virtual std::string title() const override; - virtual std::string subtitle() const override; -}; - -// S9FrameNameSpriteSheetInsetsScaled - -class S9FrameNameSpriteSheetInsetsScaled : public S9SpriteTestDemo -{ -public: - CREATE_FUNC(S9FrameNameSpriteSheetInsetsScaled); - - virtual void onEnter() override; - - virtual std::string title() const override; - virtual std::string subtitle() const override; -}; - -// S9FrameNameSpriteSheetRotatedInsets - -class S9FrameNameSpriteSheetRotatedInsets : public S9SpriteTestDemo -{ -public: - CREATE_FUNC(S9FrameNameSpriteSheetRotatedInsets); - - virtual void onEnter() override; - - virtual std::string title() const override; - virtual std::string subtitle() const override; -}; - -// S9_TexturePacker - -class S9_TexturePacker : public S9SpriteTestDemo -{ -public: - CREATE_FUNC(S9_TexturePacker); - - virtual void onEnter() override; - - virtual std::string title() const override; - virtual std::string subtitle() const override; -}; - -// S9FrameNameSpriteSheetRotatedInsetsScaled - -class S9FrameNameSpriteSheetRotatedInsetsScaled : public S9SpriteTestDemo -{ -public: - CREATE_FUNC(S9FrameNameSpriteSheetRotatedInsetsScaled); - - virtual void onEnter() override; - - virtual std::string title() const override; - virtual std::string subtitle() const override; -}; - -// S9FrameNameSpriteSheetRotatedInsetsScaled - -class S9FrameNameSpriteSheetRotatedSetCapInsetLater : public S9SpriteTestDemo -{ -public: - CREATE_FUNC(S9FrameNameSpriteSheetRotatedSetCapInsetLater); - - virtual void onEnter() override; - - virtual std::string title() const override; - virtual std::string subtitle() const override; -}; - -// S9CascadeOpacityAndColor - -class S9CascadeOpacityAndColor : public S9SpriteTestDemo -{ -public: - CREATE_FUNC(S9CascadeOpacityAndColor); - - virtual void onEnter() override; - - virtual std::string title() const override; - virtual std::string subtitle() const override; -}; - -// Scale9Sprite ZOrder - -class S9ZOrder : public S9SpriteTestDemo -{ -public: - CREATE_FUNC(S9ZOrder); - - virtual void onEnter() override; - - virtual std::string title() const override; - virtual std::string subtitle() const override; -}; - -// Scale9Sprite Flip - -class S9Flip : public S9SpriteTestDemo -{ -public: - CREATE_FUNC(S9Flip); - - virtual void onEnter() override; - - virtual std::string title() const override; - virtual std::string subtitle() const override; -}; diff --git a/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/CocosGUIScene.cpp b/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/CocosGUIScene.cpp index 6905ba7701..de96938730 100644 --- a/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/CocosGUIScene.cpp +++ b/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/CocosGUIScene.cpp @@ -44,6 +44,18 @@ g_guisTests[] = } }, #endif + { + "EditBox Test", + [](Ref* sender) + { + UISceneManager* sceneManager = UISceneManager::sharedUISceneManager(); + sceneManager->setCurrentUISceneId(kUIEditBoxTest); + sceneManager->setMinUISceneId(kUIEditBoxTest); + sceneManager->setMaxUISceneId(kUIEditBoxTest); + Scene* scene = sceneManager->currentUIScene(); + Director::getInstance()->replaceScene(scene); + } + }, { "focus test", [](Ref* sender) diff --git a/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/UIEditBoxTest.cpp b/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/UIEditBoxTest.cpp new file mode 100644 index 0000000000..121f6a1fb0 --- /dev/null +++ b/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/UIEditBoxTest.cpp @@ -0,0 +1,137 @@ +/**************************************************************************** + Copyright (c) 2013-2014 Chukong Technologies Inc. + + http://www.cocos2d-x.org + + Permission is hereby granted, free of charge, to any person obtaining a copy + of this software and associated documentation files (the "Software"), to deal + in the Software without restriction, including without limitation the rights + to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + copies of the Software, and to permit persons to whom the Software is + furnished to do so, subject to the following conditions: + + The above copyright notice and this permission notice shall be included in + all copies or substantial portions of the Software. + + THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN + THE SOFTWARE. + ****************************************************************************/ + +#include "UIEditBoxTest.h" +#include "testResource.h" + +// UIEditBoxTest +UIEditBoxTest::UIEditBoxTest() +{ + +} + +UIEditBoxTest::~UIEditBoxTest() +{ +} + +bool UIEditBoxTest::init() +{ + if (UIScene::init()) + { + auto glview = Director::getInstance()->getOpenGLView(); + auto visibleOrigin = glview->getVisibleOrigin(); + auto visibleSize = glview->getVisibleSize(); + + auto pBg = Sprite::create("Images/HelloWorld.png"); + pBg->setPosition(Vec2(visibleOrigin.x+visibleSize.width/2, visibleOrigin.y+visibleSize.height/2)); + addChild(pBg); + + _TTFShowEditReturn = Label::createWithSystemFont("No edit control return!", "Arial", 30); + _TTFShowEditReturn->setPosition(Vec2(visibleOrigin.x+visibleSize.width/2, visibleOrigin.y + visibleSize.height - 50)); + addChild(_TTFShowEditReturn); + + + auto editBoxSize = Size(visibleSize.width - 100, 60); + + // top + std::string pNormalSprite = "extensions/green_edit.png"; + _editName = ui::EditBox::create(editBoxSize, ui::Scale9Sprite::create(pNormalSprite)); + _editName->setPosition(Vec2(visibleOrigin.x+visibleSize.width/2, visibleOrigin.y+visibleSize.height*3/4)); + _editName->setFontName("Paint Boy"); + _editName->setFontSize(25); + _editName->setFontColor(Color3B::RED); + _editName->setPlaceHolder("Name:"); + _editName->setPlaceholderFontColor(Color3B::WHITE); + _editName->setMaxLength(8); + _editName->setReturnType(ui::EditBox::KeyboardReturnType::DONE); + _editName->setDelegate(this); + addChild(_editName); + + // middle + _editPassword = ui::EditBox::create(editBoxSize, "extensions/orange_edit.png"); + _editPassword->setPosition(Vec2(visibleOrigin.x+visibleSize.width/2, visibleOrigin.y+visibleSize.height/2)); +#if (CC_TARGET_PLATFORM == CC_PLATFORM_IOS) + _editPassword->setFont("American Typewriter", 30); +#else + _editPassword->setFont("American Typewriter", 80); + _editPassword->setPlaceholderFont("American Typewriter", 80); +#endif + _editPassword->setFontColor(Color3B::GREEN); + _editPassword->setPlaceHolder("Password:"); + _editPassword->setMaxLength(6); + _editPassword->setInputFlag(ui::EditBox::InputFlag::PASSWORD); + _editPassword->setInputMode(ui::EditBox::InputMode::SINGLE_LINE); + _editPassword->setDelegate(this); + addChild(_editPassword); + + // bottom + _editEmail = ui::EditBox::create(Size(editBoxSize.width, editBoxSize.height), "extensions/yellow_edit.png"); + _editEmail->setPosition(Vec2(visibleOrigin.x+visibleSize.width/2, visibleOrigin.y+visibleSize.height/4)); + _editEmail->setAnchorPoint(Vec2(0.5, 1.0f)); + _editEmail->setPlaceHolder("Email:"); + _editEmail->setInputMode(ui::EditBox::InputMode::EMAIL_ADDRESS); + _editEmail->setDelegate(this); + addChild(_editEmail); + + this->setPosition(Vec2(10, 20)); + + + + return true; + } + return false; +} + +void UIEditBoxTest::editBoxEditingDidBegin(cocos2d::ui::EditBox* editBox) +{ + log("editBox %p DidBegin !", editBox); +} + +void UIEditBoxTest::editBoxEditingDidEnd(cocos2d::ui::EditBox* editBox) +{ + log("editBox %p DidEnd !", editBox); +} + +void UIEditBoxTest::editBoxTextChanged(cocos2d::ui::EditBox* editBox, const std::string& text) +{ + log("editBox %p TextChanged, text: %s ", editBox, text.c_str()); +} + +void UIEditBoxTest::editBoxReturn(ui::EditBox* editBox) +{ + log("editBox %p was returned !",editBox); + + if (_editName == editBox) + { + _TTFShowEditReturn->setString("Name EditBox return !"); + } + else if (_editPassword == editBox) + { + _TTFShowEditReturn->setString("Password EditBox return !"); + } + else if (_editEmail == editBox) + { + _TTFShowEditReturn->setString("Email EditBox return !"); + } +} diff --git a/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/UIEditBoxTest.h b/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/UIEditBoxTest.h new file mode 100644 index 0000000000..3d93dd7717 --- /dev/null +++ b/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/UIEditBoxTest.h @@ -0,0 +1,52 @@ +/**************************************************************************** + Copyright (c) 2013-2014 Chukong Technologies Inc. + + http://www.cocos2d-x.org + + Permission is hereby granted, free of charge, to any person obtaining a copy + of this software and associated documentation files (the "Software"), to deal + in the Software without restriction, including without limitation the rights + to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + copies of the Software, and to permit persons to whom the Software is + furnished to do so, subject to the following conditions: + + The above copyright notice and this permission notice shall be included in + all copies or substantial portions of the Software. + + THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN + THE SOFTWARE. + ****************************************************************************/ + +#ifndef __cocos2d_tests__UIEditBoxTest__ +#define __cocos2d_tests__UIEditBoxTest__ + +#include "UIScene.h" + +class UIEditBoxTest : public UIScene, public cocos2d::ui::EditBoxDelegate +{ +public: + UIEditBoxTest(); + ~UIEditBoxTest(); + bool init(); + + virtual void editBoxEditingDidBegin(cocos2d::ui::EditBox* editBox); + virtual void editBoxEditingDidEnd(cocos2d::ui::EditBox* editBox); + virtual void editBoxTextChanged(cocos2d::ui::EditBox* editBox, const std::string& text); + virtual void editBoxReturn(cocos2d::ui::EditBox* editBox); + + +protected: + cocos2d::Label* _TTFShowEditReturn; + cocos2d::ui::EditBox* _editName; + cocos2d::ui::EditBox* _editPassword; + cocos2d::ui::EditBox* _editEmail; + + UI_SCENE_CREATE_FUNC(UIEditBoxTest) +}; + +#endif /* defined(__cocos2d_tests__UIEditBoxTest__) */ diff --git a/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/UIScene.h b/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/UIScene.h index 3279022d33..dcdca668bb 100644 --- a/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/UIScene.h +++ b/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/UIScene.h @@ -31,7 +31,7 @@ USING_NS_CC; USING_NS_CC_EXT; -using namespace ui; +using namespace cocos2d::ui; #define UI_SCENE_CREATE_FUNC(UIScene) \ public: \ diff --git a/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/UISceneManager.cpp b/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/UISceneManager.cpp index 535b85c4ad..ab9a713c83 100644 --- a/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/UISceneManager.cpp +++ b/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/UISceneManager.cpp @@ -23,6 +23,9 @@ #include "UIWebViewTest/UIWebViewTest.h" #endif #include "UIScale9SpriteTest.h" +#if (CC_TARGET_PLATFORM == CC_PLATFORM_IOS) || (CC_TARGET_PLATFORM == CC_PLATFORM_ANDROID) || (CC_TARGET_PLATFORM == CC_PLATFORM_MAC) || (CC_TARGET_PLATFORM == CC_PLATFORM_WIN32) || (CC_TARGET_PLATFORM == CC_PLATFORM_TIZEN) || (CC_TARGET_PLATFORM == CC_PLATFORM_WP8) +#include "UIEditBoxTest.h" +#endif USING_NS_CC; @@ -36,6 +39,9 @@ static const char* s_testArray[] = "UIButtonTest_RemoveSelf", "UIButtonTestSwitchScale9", "UIButtonTestZoomScale", +#if (CC_TARGET_PLATFORM == CC_PLATFORM_IOS) || (CC_TARGET_PLATFORM == CC_PLATFORM_ANDROID) || (CC_TARGET_PLATFORM == CC_PLATFORM_MAC) || (CC_TARGET_PLATFORM == CC_PLATFORM_WIN32) || (CC_TARGET_PLATFORM == CC_PLATFORM_TIZEN) || (CC_TARGET_PLATFORM == CC_PLATFORM_WP8) + "UIEditBoxTest", +#endif "UICheckBoxTest", "UISliderTest", "UISliderTest_Scale9", @@ -373,6 +379,11 @@ Scene *UISceneManager::currentUIScene() return UIS9Flip::sceneWithTitle(s_testArray[_currentUISceneId]); case kUIS9ChangeAnchorPoint: return UIS9ChangeAnchorPoint::sceneWithTitle(s_testArray[_currentUISceneId]); +#if (CC_TARGET_PLATFORM == CC_PLATFORM_IOS) || (CC_TARGET_PLATFORM == CC_PLATFORM_ANDROID) || (CC_TARGET_PLATFORM == CC_PLATFORM_MAC) || (CC_TARGET_PLATFORM == CC_PLATFORM_WIN32) || (CC_TARGET_PLATFORM == CC_PLATFORM_TIZEN) || (CC_TARGET_PLATFORM == CC_PLATFORM_WP8) + case kUIEditBoxTest: + return UIEditBoxTest::sceneWithTitle(s_testArray[_currentUISceneId]); +#endif + } return nullptr; } diff --git a/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/UISceneManager.h b/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/UISceneManager.h index 6bf7c2c2c9..fe0ed8e067 100644 --- a/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/UISceneManager.h +++ b/tests/cpp-tests/Classes/UITest/CocoStudioGUITest/UISceneManager.h @@ -38,6 +38,7 @@ enum kUIButtonTest_RemoveSelf, kUIButtonTestSwitchScale9, kUIButtonTestZoomScale, + kUIEditBoxTest, kUICheckBoxTest, kUISliderTest, kUISliderTest_Scale9, diff --git a/tests/cpp-tests/proj.android/README.md b/tests/cpp-tests/proj.android/README.md deleted file mode 100644 index a4670ebabc..0000000000 --- a/tests/cpp-tests/proj.android/README.md +++ /dev/null @@ -1,87 +0,0 @@ -## Prerequisites: - -* Android NDK -* Android SDK **OR** Eclipse ADT Bundle -* Android AVD target installed - -## Building project - -There are two ways of building Android projects. - -1. Eclipse -2. Command Line - -### Import Project in Eclipse - -#### Features: - -1. Complete workflow from Eclipse, including: - * Build C++. - * Clean C++. - * Build and Run whole project. - * Logcat view. - * Debug Java code. - * Javascript editor. - * Project management. -2. True C++ editing, including: - * Code completion. - * Jump to definition. - * Refactoring tools etc. - * Quick open C++ files. - - -#### Setup Eclipse Environment (only once) - - -**NOTE:** This step needs to be done only once to setup the Eclipse environment for cocos2d-x projects. Skip this section if you've done this before. - -1. Download Eclipse ADT bundle from [Google ADT homepage](http://developer.android.com/sdk/index.html) - - **OR** - - Install Eclipse with Java. Add ADT and CDT plugins. - -2. Only for Windows - 1. Install [Cygwin](http://www.cygwin.com/) with make (select make package from the list during the install). - 2. Add `Cygwin\bin` directory to system PATH variable. - 3. Add this line `none /cygdrive cygdrive binary,noacl,posix=0,user 0 0` to `Cygwin\etc\fstab` file. - -3. Set up Variables: - 1. Path Variable `COCOS2DX`: - * Eclipse->Preferences->General->Workspace->**Linked Resources** - * Click **New** button to add a Path Variable `COCOS2DX` pointing to the root cocos2d-x directory. - ![Example](https://lh5.googleusercontent.com/-oPpk9kg3e5w/UUOYlq8n7aI/AAAAAAAAsdQ/zLA4eghBH9U/s400/cocos2d-x-eclipse-vars.png) - - 2. C/C++ Environment Variable `NDK_ROOT`: - * Eclipse->Preferences->C/C++->Build->**Environment**. - * Click **Add** button and add a new variable `NDK_ROOT` pointing to the root NDK directory. - ![Example](https://lh3.googleusercontent.com/-AVcY8IAT0_g/UUOYltoRobI/AAAAAAAAsdM/22D2J9u3sig/s400/cocos2d-x-eclipse-ndk.png) - * Only for Windows: Add new variables **CYGWIN** with value `nodosfilewarning` and **SHELLOPTS** with value `igncr` - -4. Import libcocos2dx library project: - 1. File->New->Project->Android Project From Existing Code. - 2. Click **Browse** button and open `cocos2d-x/cocos2dx/platform/android/java` directory. - 3. Click **Finish** to add project. - -#### Adding and running from Eclipse - -![Example](https://lh3.googleusercontent.com/-SLBOu6e3QbE/UUOcOXYaGqI/AAAAAAAAsdo/tYBY2SylOSM/s288/cocos2d-x-eclipse-project-from-code.png) ![Import](https://lh5.googleusercontent.com/-XzC9Pn65USc/UUOcOTAwizI/AAAAAAAAsdk/4b6YM-oim9Y/s400/cocos2d-x-eclipse-import-project.png) - -1. File->New->Project->Android Project From Existing Code -2. **Browse** to your project directory. eg: `cocos2d-x/cocos2dx/samples/Cpp/CppTests/proj.android/` -3. Add the project -4. Click **Run** or **Debug** to compile C++ followed by Java and to run on connected device or emulator. - - -### Running project from Command Line - - $ cd cocos2d-x/samples/Cpp/CppTests/proj.android/ - $ export NDK_ROOT=/path/to/ndk - $ ./build_native.sh - $ ant debug install - -If the last command results in sdk.dir missing error then do: - - $ android list target - $ android update project -p . -t (id from step 6) - $ android update project -p cocos2d-x/cocos2dx/platform/android/java/ -t (id from step 6) diff --git a/tests/cpp-tests/proj.win32/cpp-tests.vcxproj b/tests/cpp-tests/proj.win32/cpp-tests.vcxproj index 6cce146e18..7f132bd32d 100644 --- a/tests/cpp-tests/proj.win32/cpp-tests.vcxproj +++ b/tests/cpp-tests/proj.win32/cpp-tests.vcxproj @@ -24,7 +24,7 @@ v110 v110_xp v120 - v120_xp + v110_xp Application @@ -33,7 +33,7 @@ v110 v110_xp v120 - v120_xp + v110_xp @@ -109,8 +109,6 @@ WIN32;NDEBUG;_WINDOWS;_USE_MATH_DEFINES;GL_GLEXT_PROTOTYPES;CC_ENABLE_CHIPMUNK_INTEGRATION=1;_CRT_SECURE_NO_WARNINGS;_SCL_SECURE_NO_WARNINGS;%(PreprocessorDefinitions) MultiThreadedDLL true - - Level3 OldStyle 4267;4251;4244;%(DisableSpecificWarnings) @@ -161,11 +159,9 @@ - - @@ -204,6 +200,7 @@ + @@ -349,11 +346,9 @@ - - @@ -392,6 +387,7 @@ + diff --git a/tests/cpp-tests/proj.win32/cpp-tests.vcxproj.filters b/tests/cpp-tests/proj.win32/cpp-tests.vcxproj.filters index e815660d53..f0e771d566 100644 --- a/tests/cpp-tests/proj.win32/cpp-tests.vcxproj.filters +++ b/tests/cpp-tests/proj.win32/cpp-tests.vcxproj.filters @@ -202,9 +202,6 @@ {a4c2111f-cf9f-492c-884d-3de24715adce} - - {18a69e7e-8ca7-475a-bfbb-7296baab16ce} - {0ef55f53-411a-4661-b5d5-13930da52e68} @@ -220,9 +217,6 @@ {81ec2355-7efd-49e0-b6cb-b1bba23fbbc8} - - {3d73aa04-d66e-43d3-921f-b867a753c113} - {a6e7d28e-46a3-46c4-9735-b39e96f776f0} @@ -594,9 +588,6 @@ Classes\FileUtilsTest - - Classes\ExtensionsTest\EditBoxTest - Classes\ExtensionsTest\CocosBuilderTest\TimelineCallbackTest @@ -618,9 +609,6 @@ Classes - - Classes\ExtensionsTest\Scale9SpriteTest - Classes\ExtensionsTest\NetworkTest @@ -867,6 +855,9 @@ Classes\Sprite3DTest + + Classes\UITest\CocostudioGUISceneTest + @@ -1307,9 +1298,6 @@ Classes\FileUtilsTest - - Classes\ExtensionsTest\EditBoxTest - Classes\ExtensionsTest\CocosBuilderTest\TimelineCallbackTest @@ -1334,9 +1322,6 @@ Classes - - Classes\ExtensionsTest\Scale9SpriteTest - Classes\ExtensionsTest\NetworkTest @@ -1601,5 +1586,8 @@ Classes\Sprite3DTest + + Classes\UITest\CocostudioGUISceneTest + \ No newline at end of file diff --git a/tests/cpp-tests/proj.wp8-xaml/cpp-testsComponent/cpp-testsComponent.vcxproj b/tests/cpp-tests/proj.wp8-xaml/cpp-testsComponent/cpp-testsComponent.vcxproj index 16806e1f8c..60ea821193 100644 --- a/tests/cpp-tests/proj.wp8-xaml/cpp-testsComponent/cpp-testsComponent.vcxproj +++ b/tests/cpp-tests/proj.wp8-xaml/cpp-testsComponent/cpp-testsComponent.vcxproj @@ -250,6 +250,7 @@ + @@ -453,6 +454,7 @@ + diff --git a/tests/game-controller-test/proj.android/README.md b/tests/game-controller-test/proj.android/README.md deleted file mode 100644 index 312835611a..0000000000 --- a/tests/game-controller-test/proj.android/README.md +++ /dev/null @@ -1,87 +0,0 @@ -## Prerequisites: - -* Android NDK -* Android SDK **OR** Eclipse ADT Bundle -* Android AVD target installed - -## Building project - -There are two ways of building Android projects. - -1. Eclipse -2. Command Line - -### Import Project in Eclipse - -#### Features: - -1. Complete workflow from Eclipse, including: - * Build C++. - * Clean C++. - * Build and Run whole project. - * Logcat view. - * Debug Java code. - * Javascript editor. - * Project management. -2. True C++ editing, including: - * Code completion. - * Jump to definition. - * Refactoring tools etc. - * Quick open C++ files. - - -#### Setup Eclipse Environment (only once) - - -**NOTE:** This step needs to be done only once to setup the Eclipse environment for cocos2d-x projects. Skip this section if you've done this before. - -1. Download Eclipse ADT bundle from [Google ADT homepage](http://developer.android.com/sdk/index.html) - - **OR** - - Install Eclipse with Java. Add ADT and CDT plugins. - -2. Only for Windows - 1. Install [Cygwin](http://www.cygwin.com/) with make (select make package from the list during the install). - 2. Add `Cygwin\bin` directory to system PATH variable. - 3. Add this line `none /cygdrive cygdrive binary,noacl,posix=0,user 0 0` to `Cygwin\etc\fstab` file. - -3. Set up Variables: - 1. Path Variable `COCOS2DX`: - * Eclipse->Preferences->General->Workspace->**Linked Resources** - * Click **New** button to add a Path Variable `COCOS2DX` pointing to the root cocos2d-x directory. - ![Example](https://lh5.googleusercontent.com/-oPpk9kg3e5w/UUOYlq8n7aI/AAAAAAAAsdQ/zLA4eghBH9U/s400/cocos2d-x-eclipse-vars.png) - - 2. C/C++ Environment Variable `NDK_ROOT`: - * Eclipse->Preferences->C/C++->Build->**Environment**. - * Click **Add** button and add a new variable `NDK_ROOT` pointing to the root NDK directory. - ![Example](https://lh3.googleusercontent.com/-AVcY8IAT0_g/UUOYltoRobI/AAAAAAAAsdM/22D2J9u3sig/s400/cocos2d-x-eclipse-ndk.png) - * Only for Windows: Add new variables **CYGWIN** with value `nodosfilewarning` and **SHELLOPTS** with value `igncr` - -4. Import libcocos2dx library project: - 1. File->New->Project->Android Project From Existing Code. - 2. Click **Browse** button and open `cocos2d-x/cocos2dx/platform/android/java` directory. - 3. Click **Finish** to add project. - -#### Adding and running from Eclipse - -![Example](https://lh3.googleusercontent.com/-SLBOu6e3QbE/UUOcOXYaGqI/AAAAAAAAsdo/tYBY2SylOSM/s288/cocos2d-x-eclipse-project-from-code.png) ![Import](https://lh5.googleusercontent.com/-XzC9Pn65USc/UUOcOTAwizI/AAAAAAAAsdk/4b6YM-oim9Y/s400/cocos2d-x-eclipse-import-project.png) - -1. File->New->Project->Android Project From Existing Code -2. **Browse** to your project directory. eg: `cocos2d-x/cocos2dx/samples/Cpp/TestCpp/proj.android/` -3. Add the project -4. Click **Run** or **Debug** to compile C++ followed by Java and to run on connected device or emulator. - - -### Running project from Command Line - - $ cd cocos2d-x/samples/Cpp/TestCpp/proj.android/ - $ export NDK_ROOT=/path/to/ndk - $ ./build_native.sh - $ ant debug install - -If the last command results in sdk.dir missing error then do: - - $ android list target - $ android update project -p . -t (id from step 6) - $ android update project -p cocos2d-x/cocos2dx/platform/android/java/ -t (id from step 6) diff --git a/tests/lua-empty-test/project/proj.win32/lua-empty-test.vcxproj b/tests/lua-empty-test/project/proj.win32/lua-empty-test.vcxproj index a504628f28..7d24ad16dc 100644 --- a/tests/lua-empty-test/project/proj.win32/lua-empty-test.vcxproj +++ b/tests/lua-empty-test/project/proj.win32/lua-empty-test.vcxproj @@ -22,7 +22,7 @@ v110 v110_xp v120 - v120_xp + v110_xp Application @@ -31,7 +31,7 @@ v110 v110_xp v120 - v120_xp + v110_xp diff --git a/tests/lua-tests/project/proj.win32/lua-tests.win32.vcxproj b/tests/lua-tests/project/proj.win32/lua-tests.win32.vcxproj index 51add38ae6..f4592847dd 100644 --- a/tests/lua-tests/project/proj.win32/lua-tests.win32.vcxproj +++ b/tests/lua-tests/project/proj.win32/lua-tests.win32.vcxproj @@ -23,7 +23,7 @@ v110 v110_xp v120 - v120_xp + v110_xp Application @@ -33,7 +33,7 @@ v110 v110_xp v120 - v120_xp + v110_xp diff --git a/tools/cocos2d-console b/tools/cocos2d-console index fb44ec8cf7..305f090f26 160000 --- a/tools/cocos2d-console +++ b/tools/cocos2d-console @@ -1 +1 @@ -Subproject commit fb44ec8cf77f6f51503987c3a1a0964580b5d88f +Subproject commit 305f090f260a0b8766c3fd09a3d4d2072910bfd9 diff --git a/tools/tolua/cocos2dx_extension.ini b/tools/tolua/cocos2dx_extension.ini index 03e0829edb..3b474c792f 100644 --- a/tools/tolua/cocos2dx_extension.ini +++ b/tools/tolua/cocos2dx_extension.ini @@ -27,7 +27,7 @@ headers = %(cocosdir)s/extensions/cocos-ext.h # what classes to produce code for. You can use regular expressions here. When testing the regular # expression, it will be enclosed in "^$", like this: "^Menu*$". -classes = AssetsManager.* Scale9Sprite Control.* ControlButton.* EditBox$ ScrollView$ TableView$ TableViewCell$ +classes = AssetsManager.* Control.* ControlButton.* ScrollView$ TableView$ TableViewCell$ # what should we skip? in the format ClassName::[function function] # ClassName is a regular expression, but will be used like this: "^ClassName$" functions are also @@ -39,7 +39,6 @@ classes = AssetsManager.* Scale9Sprite Control.* ControlButton.* EditBox$ Scroll skip = .*Delegate::[*], .*Loader.*::[*], *::[^visit$ copyWith.* onEnter.* onExit.* ^description$ getObjectType (g|s)etDelegate .*HSV], - EditBox::[(g|s)etDelegate ^keyboard.* touchDownAction getScriptEditBoxHandler registerScriptEditBoxHandler unregisterScriptEditBoxHandler], AssetsManager::[(g|s)etDelegate], AssetsManagerDelegateProtocol::[*], Control::[removeHandleOfControlEvent addHandleOfControlEvent],