lua_CheckBox.cpp 151 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537253825392540254125422543254425452546254725482549255025512552255325542555255625572558255925602561256225632564256525662567256825692570257125722573257425752576257725782579258025812582258325842585258625872588258925902591259225932594259525962597259825992600260126022603260426052606260726082609261026112612261326142615261626172618261926202621262226232624262526262627262826292630263126322633263426352636263726382639264026412642264326442645264626472648264926502651265226532654265526562657265826592660266126622663266426652666266726682669267026712672267326742675267626772678267926802681268226832684268526862687268826892690269126922693269426952696269726982699270027012702270327042705270627072708270927102711271227132714271527162717271827192720272127222723272427252726272727282729273027312732273327342735273627372738273927402741274227432744274527462747274827492750275127522753275427552756275727582759276027612762276327642765276627672768276927702771277227732774277527762777277827792780278127822783278427852786278727882789279027912792279327942795279627972798279928002801280228032804280528062807280828092810281128122813281428152816281728182819282028212822282328242825282628272828282928302831283228332834283528362837283828392840284128422843284428452846284728482849285028512852285328542855285628572858285928602861286228632864286528662867286828692870287128722873287428752876287728782879288028812882288328842885288628872888288928902891289228932894289528962897289828992900290129022903290429052906290729082909291029112912291329142915291629172918291929202921292229232924292529262927292829292930293129322933293429352936293729382939294029412942294329442945294629472948294929502951295229532954295529562957295829592960296129622963296429652966296729682969297029712972297329742975297629772978297929802981298229832984298529862987298829892990299129922993299429952996299729982999300030013002300330043005300630073008300930103011301230133014301530163017301830193020302130223023302430253026302730283029303030313032303330343035303630373038303930403041304230433044304530463047304830493050305130523053305430553056305730583059306030613062306330643065306630673068306930703071307230733074307530763077307830793080308130823083308430853086308730883089309030913092309330943095309630973098309931003101310231033104310531063107310831093110311131123113311431153116311731183119312031213122312331243125312631273128312931303131313231333134313531363137313831393140314131423143314431453146314731483149315031513152315331543155315631573158315931603161316231633164316531663167316831693170317131723173317431753176317731783179318031813182318331843185318631873188318931903191319231933194319531963197319831993200320132023203320432053206320732083209321032113212321332143215321632173218321932203221322232233224322532263227322832293230323132323233323432353236323732383239324032413242324332443245324632473248324932503251325232533254325532563257325832593260326132623263326432653266326732683269327032713272327332743275327632773278327932803281328232833284328532863287328832893290329132923293329432953296329732983299330033013302330333043305330633073308330933103311331233133314331533163317331833193320332133223323332433253326332733283329333033313332333333343335333633373338333933403341334233433344334533463347334833493350335133523353335433553356335733583359336033613362336333643365336633673368336933703371337233733374337533763377337833793380338133823383338433853386338733883389339033913392339333943395339633973398339934003401340234033404340534063407340834093410341134123413341434153416341734183419342034213422342334243425342634273428342934303431343234333434343534363437343834393440344134423443344434453446344734483449345034513452345334543455345634573458345934603461346234633464346534663467346834693470347134723473347434753476347734783479348034813482348334843485348634873488348934903491349234933494349534963497349834993500350135023503350435053506350735083509351035113512351335143515351635173518351935203521352235233524352535263527352835293530353135323533353435353536353735383539354035413542354335443545354635473548354935503551355235533554355535563557355835593560356135623563356435653566356735683569357035713572357335743575357635773578357935803581358235833584358535863587358835893590359135923593359435953596359735983599360036013602360336043605360636073608360936103611361236133614361536163617361836193620362136223623362436253626362736283629363036313632363336343635363636373638363936403641364236433644364536463647364836493650365136523653365436553656365736583659366036613662366336643665366636673668366936703671367236733674367536763677367836793680368136823683368436853686368736883689369036913692369336943695369636973698369937003701370237033704370537063707370837093710371137123713371437153716371737183719372037213722372337243725372637273728372937303731373237333734373537363737373837393740374137423743374437453746374737483749375037513752375337543755375637573758375937603761376237633764376537663767376837693770377137723773377437753776377737783779378037813782378337843785378637873788378937903791379237933794379537963797379837993800380138023803380438053806380738083809381038113812381338143815381638173818381938203821382238233824382538263827382838293830383138323833383438353836383738383839384038413842384338443845384638473848384938503851385238533854385538563857385838593860386138623863386438653866386738683869387038713872387338743875387638773878387938803881388238833884388538863887388838893890389138923893389438953896389738983899390039013902390339043905390639073908390939103911391239133914391539163917391839193920392139223923392439253926392739283929393039313932393339343935393639373938393939403941394239433944394539463947394839493950395139523953395439553956395739583959396039613962396339643965396639673968396939703971397239733974397539763977397839793980398139823983398439853986398739883989399039913992399339943995399639973998399940004001400240034004400540064007400840094010401140124013401440154016401740184019402040214022402340244025402640274028402940304031403240334034403540364037403840394040404140424043404440454046404740484049405040514052405340544055405640574058405940604061406240634064406540664067406840694070407140724073407440754076407740784079408040814082408340844085408640874088408940904091409240934094409540964097409840994100410141024103410441054106410741084109411041114112411341144115411641174118411941204121412241234124412541264127412841294130413141324133413441354136413741384139414041414142414341444145414641474148414941504151415241534154415541564157415841594160416141624163416441654166416741684169417041714172417341744175417641774178417941804181418241834184418541864187418841894190419141924193419441954196419741984199420042014202420342044205420642074208420942104211421242134214421542164217421842194220422142224223422442254226422742284229423042314232423342344235423642374238423942404241424242434244424542464247424842494250425142524253425442554256425742584259426042614262426342644265426642674268426942704271427242734274427542764277427842794280428142824283428442854286428742884289429042914292429342944295429642974298429943004301430243034304430543064307430843094310431143124313431443154316431743184319432043214322432343244325432643274328432943304331433243334334433543364337433843394340434143424343434443454346434743484349435043514352435343544355435643574358435943604361436243634364436543664367436843694370437143724373437443754376437743784379438043814382438343844385438643874388438943904391439243934394439543964397439843994400440144024403440444054406440744084409441044114412441344144415441644174418441944204421442244234424442544264427442844294430443144324433443444354436443744384439444044414442444344444445444644474448444944504451445244534454445544564457445844594460446144624463446444654466446744684469447044714472447344744475447644774478447944804481448244834484448544864487448844894490449144924493449444954496449744984499450045014502450345044505450645074508450945104511451245134514451545164517451845194520452145224523452445254526452745284529453045314532453345344535453645374538453945404541454245434544454545464547454845494550455145524553455445554556455745584559456045614562456345644565456645674568456945704571457245734574457545764577457845794580458145824583458445854586458745884589459045914592459345944595459645974598459946004601460246034604460546064607460846094610
  1. #include "Base.h"
  2. #include "ScriptController.h"
  3. #include "lua_CheckBox.h"
  4. #include "Animation.h"
  5. #include "AnimationTarget.h"
  6. #include "Base.h"
  7. #include "Button.h"
  8. #include "CheckBox.h"
  9. #include "Control.h"
  10. #include "Game.h"
  11. #include "Label.h"
  12. #include "Node.h"
  13. #include "Ref.h"
  14. #include "ScriptController.h"
  15. #include "ScriptTarget.h"
  16. #include "lua_ControlAlignment.h"
  17. #include "lua_ControlListenerEventType.h"
  18. #include "lua_ControlState.h"
  19. #include "lua_CurveInterpolationType.h"
  20. #include "lua_FontJustify.h"
  21. namespace gameplay
  22. {
  23. void luaRegister_CheckBox()
  24. {
  25. const luaL_Reg lua_members[] =
  26. {
  27. {"addListener", lua_CheckBox_addListener},
  28. {"addRef", lua_CheckBox_addRef},
  29. {"addScriptCallback", lua_CheckBox_addScriptCallback},
  30. {"createAnimation", lua_CheckBox_createAnimation},
  31. {"createAnimationFromBy", lua_CheckBox_createAnimationFromBy},
  32. {"createAnimationFromTo", lua_CheckBox_createAnimationFromTo},
  33. {"destroyAnimation", lua_CheckBox_destroyAnimation},
  34. {"disable", lua_CheckBox_disable},
  35. {"enable", lua_CheckBox_enable},
  36. {"getAlignment", lua_CheckBox_getAlignment},
  37. {"getAnimation", lua_CheckBox_getAnimation},
  38. {"getAnimationPropertyComponentCount", lua_CheckBox_getAnimationPropertyComponentCount},
  39. {"getAnimationPropertyValue", lua_CheckBox_getAnimationPropertyValue},
  40. {"getAutoHeight", lua_CheckBox_getAutoHeight},
  41. {"getAutoWidth", lua_CheckBox_getAutoWidth},
  42. {"getBorder", lua_CheckBox_getBorder},
  43. {"getBounds", lua_CheckBox_getBounds},
  44. {"getClip", lua_CheckBox_getClip},
  45. {"getClipBounds", lua_CheckBox_getClipBounds},
  46. {"getConsumeInputEvents", lua_CheckBox_getConsumeInputEvents},
  47. {"getCursorColor", lua_CheckBox_getCursorColor},
  48. {"getCursorRegion", lua_CheckBox_getCursorRegion},
  49. {"getCursorUVs", lua_CheckBox_getCursorUVs},
  50. {"getFocusIndex", lua_CheckBox_getFocusIndex},
  51. {"getFont", lua_CheckBox_getFont},
  52. {"getFontSize", lua_CheckBox_getFontSize},
  53. {"getHeight", lua_CheckBox_getHeight},
  54. {"getId", lua_CheckBox_getId},
  55. {"getImageColor", lua_CheckBox_getImageColor},
  56. {"getImageRegion", lua_CheckBox_getImageRegion},
  57. {"getImageSize", lua_CheckBox_getImageSize},
  58. {"getImageUVs", lua_CheckBox_getImageUVs},
  59. {"getMargin", lua_CheckBox_getMargin},
  60. {"getOpacity", lua_CheckBox_getOpacity},
  61. {"getPadding", lua_CheckBox_getPadding},
  62. {"getRefCount", lua_CheckBox_getRefCount},
  63. {"getSkinColor", lua_CheckBox_getSkinColor},
  64. {"getSkinRegion", lua_CheckBox_getSkinRegion},
  65. {"getState", lua_CheckBox_getState},
  66. {"getStyle", lua_CheckBox_getStyle},
  67. {"getText", lua_CheckBox_getText},
  68. {"getTextAlignment", lua_CheckBox_getTextAlignment},
  69. {"getTextColor", lua_CheckBox_getTextColor},
  70. {"getTextRightToLeft", lua_CheckBox_getTextRightToLeft},
  71. {"getType", lua_CheckBox_getType},
  72. {"getWidth", lua_CheckBox_getWidth},
  73. {"getX", lua_CheckBox_getX},
  74. {"getY", lua_CheckBox_getY},
  75. {"getZIndex", lua_CheckBox_getZIndex},
  76. {"isChecked", lua_CheckBox_isChecked},
  77. {"isContainer", lua_CheckBox_isContainer},
  78. {"isEnabled", lua_CheckBox_isEnabled},
  79. {"release", lua_CheckBox_release},
  80. {"removeScriptCallback", lua_CheckBox_removeScriptCallback},
  81. {"setAlignment", lua_CheckBox_setAlignment},
  82. {"setAnimationPropertyValue", lua_CheckBox_setAnimationPropertyValue},
  83. {"setAutoHeight", lua_CheckBox_setAutoHeight},
  84. {"setAutoWidth", lua_CheckBox_setAutoWidth},
  85. {"setBorder", lua_CheckBox_setBorder},
  86. {"setBounds", lua_CheckBox_setBounds},
  87. {"setChecked", lua_CheckBox_setChecked},
  88. {"setConsumeInputEvents", lua_CheckBox_setConsumeInputEvents},
  89. {"setCursorColor", lua_CheckBox_setCursorColor},
  90. {"setCursorRegion", lua_CheckBox_setCursorRegion},
  91. {"setFocusIndex", lua_CheckBox_setFocusIndex},
  92. {"setFont", lua_CheckBox_setFont},
  93. {"setFontSize", lua_CheckBox_setFontSize},
  94. {"setImageColor", lua_CheckBox_setImageColor},
  95. {"setImageRegion", lua_CheckBox_setImageRegion},
  96. {"setImageSize", lua_CheckBox_setImageSize},
  97. {"setMargin", lua_CheckBox_setMargin},
  98. {"setOpacity", lua_CheckBox_setOpacity},
  99. {"setPadding", lua_CheckBox_setPadding},
  100. {"setPosition", lua_CheckBox_setPosition},
  101. {"setSize", lua_CheckBox_setSize},
  102. {"setSkinColor", lua_CheckBox_setSkinColor},
  103. {"setSkinRegion", lua_CheckBox_setSkinRegion},
  104. {"setState", lua_CheckBox_setState},
  105. {"setStyle", lua_CheckBox_setStyle},
  106. {"setText", lua_CheckBox_setText},
  107. {"setTextAlignment", lua_CheckBox_setTextAlignment},
  108. {"setTextColor", lua_CheckBox_setTextColor},
  109. {"setTextRightToLeft", lua_CheckBox_setTextRightToLeft},
  110. {"setZIndex", lua_CheckBox_setZIndex},
  111. {NULL, NULL}
  112. };
  113. const luaL_Reg lua_statics[] =
  114. {
  115. {"ANIMATE_OPACITY", lua_CheckBox_static_ANIMATE_OPACITY},
  116. {"ANIMATE_POSITION", lua_CheckBox_static_ANIMATE_POSITION},
  117. {"ANIMATE_POSITION_X", lua_CheckBox_static_ANIMATE_POSITION_X},
  118. {"ANIMATE_POSITION_Y", lua_CheckBox_static_ANIMATE_POSITION_Y},
  119. {"ANIMATE_SIZE", lua_CheckBox_static_ANIMATE_SIZE},
  120. {"ANIMATE_SIZE_HEIGHT", lua_CheckBox_static_ANIMATE_SIZE_HEIGHT},
  121. {"ANIMATE_SIZE_WIDTH", lua_CheckBox_static_ANIMATE_SIZE_WIDTH},
  122. {"create", lua_CheckBox_static_create},
  123. {NULL, NULL}
  124. };
  125. std::vector<std::string> scopePath;
  126. ScriptUtil::registerClass("CheckBox", lua_members, NULL, lua_CheckBox__gc, lua_statics, scopePath);
  127. }
  128. static CheckBox* getInstance(lua_State* state)
  129. {
  130. void* userdata = luaL_checkudata(state, 1, "CheckBox");
  131. luaL_argcheck(state, userdata != NULL, 1, "'CheckBox' expected.");
  132. return (CheckBox*)((ScriptUtil::LuaObject*)userdata)->instance;
  133. }
  134. int lua_CheckBox__gc(lua_State* state)
  135. {
  136. // Get the number of parameters.
  137. int paramCount = lua_gettop(state);
  138. // Attempt to match the parameters to a valid binding.
  139. switch (paramCount)
  140. {
  141. case 1:
  142. {
  143. if ((lua_type(state, 1) == LUA_TUSERDATA))
  144. {
  145. void* userdata = luaL_checkudata(state, 1, "CheckBox");
  146. luaL_argcheck(state, userdata != NULL, 1, "'CheckBox' expected.");
  147. ScriptUtil::LuaObject* object = (ScriptUtil::LuaObject*)userdata;
  148. if (object->owns)
  149. {
  150. CheckBox* instance = (CheckBox*)object->instance;
  151. SAFE_RELEASE(instance);
  152. }
  153. return 0;
  154. }
  155. else
  156. {
  157. lua_pushstring(state, "lua_CheckBox__gc - Failed to match the given parameters to a valid function signature.");
  158. lua_error(state);
  159. }
  160. break;
  161. }
  162. default:
  163. {
  164. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  165. lua_error(state);
  166. break;
  167. }
  168. }
  169. return 0;
  170. }
  171. int lua_CheckBox_addListener(lua_State* state)
  172. {
  173. // Get the number of parameters.
  174. int paramCount = lua_gettop(state);
  175. // Attempt to match the parameters to a valid binding.
  176. switch (paramCount)
  177. {
  178. case 3:
  179. {
  180. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  181. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TTABLE || lua_type(state, 2) == LUA_TNIL) &&
  182. lua_type(state, 3) == LUA_TNUMBER)
  183. {
  184. // Get parameter 1 off the stack.
  185. ScriptUtil::LuaArray<Control::Listener> param1 = ScriptUtil::getObjectPointer<Control::Listener>(2, "ControlListener", false);
  186. // Get parameter 2 off the stack.
  187. int param2 = (int)luaL_checkint(state, 3);
  188. CheckBox* instance = getInstance(state);
  189. instance->addListener(param1, param2);
  190. return 0;
  191. }
  192. else
  193. {
  194. lua_pushstring(state, "lua_CheckBox_addListener - Failed to match the given parameters to a valid function signature.");
  195. lua_error(state);
  196. }
  197. break;
  198. }
  199. default:
  200. {
  201. lua_pushstring(state, "Invalid number of parameters (expected 3).");
  202. lua_error(state);
  203. break;
  204. }
  205. }
  206. return 0;
  207. }
  208. int lua_CheckBox_addRef(lua_State* state)
  209. {
  210. // Get the number of parameters.
  211. int paramCount = lua_gettop(state);
  212. // Attempt to match the parameters to a valid binding.
  213. switch (paramCount)
  214. {
  215. case 1:
  216. {
  217. if ((lua_type(state, 1) == LUA_TUSERDATA))
  218. {
  219. CheckBox* instance = getInstance(state);
  220. instance->addRef();
  221. return 0;
  222. }
  223. else
  224. {
  225. lua_pushstring(state, "lua_CheckBox_addRef - Failed to match the given parameters to a valid function signature.");
  226. lua_error(state);
  227. }
  228. break;
  229. }
  230. default:
  231. {
  232. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  233. lua_error(state);
  234. break;
  235. }
  236. }
  237. return 0;
  238. }
  239. int lua_CheckBox_addScriptCallback(lua_State* state)
  240. {
  241. // Get the number of parameters.
  242. int paramCount = lua_gettop(state);
  243. // Attempt to match the parameters to a valid binding.
  244. switch (paramCount)
  245. {
  246. case 3:
  247. {
  248. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  249. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL) &&
  250. (lua_type(state, 3) == LUA_TSTRING || lua_type(state, 3) == LUA_TNIL))
  251. {
  252. // Get parameter 1 off the stack.
  253. std::string param1 = ScriptUtil::getString(2, true);
  254. // Get parameter 2 off the stack.
  255. std::string param2 = ScriptUtil::getString(3, true);
  256. CheckBox* instance = getInstance(state);
  257. instance->addScriptCallback(param1, param2);
  258. return 0;
  259. }
  260. else
  261. {
  262. lua_pushstring(state, "lua_CheckBox_addScriptCallback - Failed to match the given parameters to a valid function signature.");
  263. lua_error(state);
  264. }
  265. break;
  266. }
  267. default:
  268. {
  269. lua_pushstring(state, "Invalid number of parameters (expected 3).");
  270. lua_error(state);
  271. break;
  272. }
  273. }
  274. return 0;
  275. }
  276. int lua_CheckBox_createAnimation(lua_State* state)
  277. {
  278. // Get the number of parameters.
  279. int paramCount = lua_gettop(state);
  280. // Attempt to match the parameters to a valid binding.
  281. switch (paramCount)
  282. {
  283. case 3:
  284. {
  285. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  286. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL) &&
  287. (lua_type(state, 3) == LUA_TSTRING || lua_type(state, 3) == LUA_TNIL))
  288. {
  289. // Get parameter 1 off the stack.
  290. ScriptUtil::LuaArray<const char> param1 = ScriptUtil::getString(2, false);
  291. // Get parameter 2 off the stack.
  292. ScriptUtil::LuaArray<const char> param2 = ScriptUtil::getString(3, false);
  293. CheckBox* instance = getInstance(state);
  294. void* returnPtr = (void*)instance->createAnimation(param1, param2);
  295. if (returnPtr)
  296. {
  297. ScriptUtil::LuaObject* object = (ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(ScriptUtil::LuaObject));
  298. object->instance = returnPtr;
  299. object->owns = false;
  300. luaL_getmetatable(state, "Animation");
  301. lua_setmetatable(state, -2);
  302. }
  303. else
  304. {
  305. lua_pushnil(state);
  306. }
  307. return 1;
  308. }
  309. else if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  310. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL) &&
  311. (lua_type(state, 3) == LUA_TUSERDATA || lua_type(state, 3) == LUA_TTABLE || lua_type(state, 3) == LUA_TNIL))
  312. {
  313. // Get parameter 1 off the stack.
  314. ScriptUtil::LuaArray<const char> param1 = ScriptUtil::getString(2, false);
  315. // Get parameter 2 off the stack.
  316. ScriptUtil::LuaArray<Properties> param2 = ScriptUtil::getObjectPointer<Properties>(3, "Properties", false);
  317. CheckBox* instance = getInstance(state);
  318. void* returnPtr = (void*)instance->createAnimation(param1, param2);
  319. if (returnPtr)
  320. {
  321. ScriptUtil::LuaObject* object = (ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(ScriptUtil::LuaObject));
  322. object->instance = returnPtr;
  323. object->owns = false;
  324. luaL_getmetatable(state, "Animation");
  325. lua_setmetatable(state, -2);
  326. }
  327. else
  328. {
  329. lua_pushnil(state);
  330. }
  331. return 1;
  332. }
  333. else
  334. {
  335. lua_pushstring(state, "lua_CheckBox_createAnimation - Failed to match the given parameters to a valid function signature.");
  336. lua_error(state);
  337. }
  338. break;
  339. }
  340. case 7:
  341. {
  342. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  343. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL) &&
  344. lua_type(state, 3) == LUA_TNUMBER &&
  345. lua_type(state, 4) == LUA_TNUMBER &&
  346. (lua_type(state, 5) == LUA_TTABLE || lua_type(state, 5) == LUA_TLIGHTUSERDATA) &&
  347. (lua_type(state, 6) == LUA_TTABLE || lua_type(state, 6) == LUA_TLIGHTUSERDATA) &&
  348. (lua_type(state, 7) == LUA_TSTRING || lua_type(state, 7) == LUA_TNIL))
  349. {
  350. // Get parameter 1 off the stack.
  351. ScriptUtil::LuaArray<const char> param1 = ScriptUtil::getString(2, false);
  352. // Get parameter 2 off the stack.
  353. int param2 = (int)luaL_checkint(state, 3);
  354. // Get parameter 3 off the stack.
  355. unsigned int param3 = (unsigned int)luaL_checkunsigned(state, 4);
  356. // Get parameter 4 off the stack.
  357. ScriptUtil::LuaArray<unsigned long> param4 = ScriptUtil::getUnsignedLongPointer(5);
  358. // Get parameter 5 off the stack.
  359. ScriptUtil::LuaArray<float> param5 = ScriptUtil::getFloatPointer(6);
  360. // Get parameter 6 off the stack.
  361. Curve::InterpolationType param6 = (Curve::InterpolationType)lua_enumFromString_CurveInterpolationType(luaL_checkstring(state, 7));
  362. CheckBox* instance = getInstance(state);
  363. void* returnPtr = (void*)instance->createAnimation(param1, param2, param3, param4, param5, param6);
  364. if (returnPtr)
  365. {
  366. ScriptUtil::LuaObject* object = (ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(ScriptUtil::LuaObject));
  367. object->instance = returnPtr;
  368. object->owns = false;
  369. luaL_getmetatable(state, "Animation");
  370. lua_setmetatable(state, -2);
  371. }
  372. else
  373. {
  374. lua_pushnil(state);
  375. }
  376. return 1;
  377. }
  378. else
  379. {
  380. lua_pushstring(state, "lua_CheckBox_createAnimation - Failed to match the given parameters to a valid function signature.");
  381. lua_error(state);
  382. }
  383. break;
  384. }
  385. case 9:
  386. {
  387. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  388. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL) &&
  389. lua_type(state, 3) == LUA_TNUMBER &&
  390. lua_type(state, 4) == LUA_TNUMBER &&
  391. (lua_type(state, 5) == LUA_TTABLE || lua_type(state, 5) == LUA_TLIGHTUSERDATA) &&
  392. (lua_type(state, 6) == LUA_TTABLE || lua_type(state, 6) == LUA_TLIGHTUSERDATA) &&
  393. (lua_type(state, 7) == LUA_TTABLE || lua_type(state, 7) == LUA_TLIGHTUSERDATA) &&
  394. (lua_type(state, 8) == LUA_TTABLE || lua_type(state, 8) == LUA_TLIGHTUSERDATA) &&
  395. (lua_type(state, 9) == LUA_TSTRING || lua_type(state, 9) == LUA_TNIL))
  396. {
  397. // Get parameter 1 off the stack.
  398. ScriptUtil::LuaArray<const char> param1 = ScriptUtil::getString(2, false);
  399. // Get parameter 2 off the stack.
  400. int param2 = (int)luaL_checkint(state, 3);
  401. // Get parameter 3 off the stack.
  402. unsigned int param3 = (unsigned int)luaL_checkunsigned(state, 4);
  403. // Get parameter 4 off the stack.
  404. ScriptUtil::LuaArray<unsigned long> param4 = ScriptUtil::getUnsignedLongPointer(5);
  405. // Get parameter 5 off the stack.
  406. ScriptUtil::LuaArray<float> param5 = ScriptUtil::getFloatPointer(6);
  407. // Get parameter 6 off the stack.
  408. ScriptUtil::LuaArray<float> param6 = ScriptUtil::getFloatPointer(7);
  409. // Get parameter 7 off the stack.
  410. ScriptUtil::LuaArray<float> param7 = ScriptUtil::getFloatPointer(8);
  411. // Get parameter 8 off the stack.
  412. Curve::InterpolationType param8 = (Curve::InterpolationType)lua_enumFromString_CurveInterpolationType(luaL_checkstring(state, 9));
  413. CheckBox* instance = getInstance(state);
  414. void* returnPtr = (void*)instance->createAnimation(param1, param2, param3, param4, param5, param6, param7, param8);
  415. if (returnPtr)
  416. {
  417. ScriptUtil::LuaObject* object = (ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(ScriptUtil::LuaObject));
  418. object->instance = returnPtr;
  419. object->owns = false;
  420. luaL_getmetatable(state, "Animation");
  421. lua_setmetatable(state, -2);
  422. }
  423. else
  424. {
  425. lua_pushnil(state);
  426. }
  427. return 1;
  428. }
  429. else
  430. {
  431. lua_pushstring(state, "lua_CheckBox_createAnimation - Failed to match the given parameters to a valid function signature.");
  432. lua_error(state);
  433. }
  434. break;
  435. }
  436. default:
  437. {
  438. lua_pushstring(state, "Invalid number of parameters (expected 3, 7 or 9).");
  439. lua_error(state);
  440. break;
  441. }
  442. }
  443. return 0;
  444. }
  445. int lua_CheckBox_createAnimationFromBy(lua_State* state)
  446. {
  447. // Get the number of parameters.
  448. int paramCount = lua_gettop(state);
  449. // Attempt to match the parameters to a valid binding.
  450. switch (paramCount)
  451. {
  452. case 7:
  453. {
  454. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  455. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL) &&
  456. lua_type(state, 3) == LUA_TNUMBER &&
  457. (lua_type(state, 4) == LUA_TTABLE || lua_type(state, 4) == LUA_TLIGHTUSERDATA) &&
  458. (lua_type(state, 5) == LUA_TTABLE || lua_type(state, 5) == LUA_TLIGHTUSERDATA) &&
  459. (lua_type(state, 6) == LUA_TSTRING || lua_type(state, 6) == LUA_TNIL) &&
  460. lua_type(state, 7) == LUA_TNUMBER)
  461. {
  462. // Get parameter 1 off the stack.
  463. ScriptUtil::LuaArray<const char> param1 = ScriptUtil::getString(2, false);
  464. // Get parameter 2 off the stack.
  465. int param2 = (int)luaL_checkint(state, 3);
  466. // Get parameter 3 off the stack.
  467. ScriptUtil::LuaArray<float> param3 = ScriptUtil::getFloatPointer(4);
  468. // Get parameter 4 off the stack.
  469. ScriptUtil::LuaArray<float> param4 = ScriptUtil::getFloatPointer(5);
  470. // Get parameter 5 off the stack.
  471. Curve::InterpolationType param5 = (Curve::InterpolationType)lua_enumFromString_CurveInterpolationType(luaL_checkstring(state, 6));
  472. // Get parameter 6 off the stack.
  473. unsigned long param6 = (unsigned long)luaL_checkunsigned(state, 7);
  474. CheckBox* instance = getInstance(state);
  475. void* returnPtr = (void*)instance->createAnimationFromBy(param1, param2, param3, param4, param5, param6);
  476. if (returnPtr)
  477. {
  478. ScriptUtil::LuaObject* object = (ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(ScriptUtil::LuaObject));
  479. object->instance = returnPtr;
  480. object->owns = false;
  481. luaL_getmetatable(state, "Animation");
  482. lua_setmetatable(state, -2);
  483. }
  484. else
  485. {
  486. lua_pushnil(state);
  487. }
  488. return 1;
  489. }
  490. else
  491. {
  492. lua_pushstring(state, "lua_CheckBox_createAnimationFromBy - Failed to match the given parameters to a valid function signature.");
  493. lua_error(state);
  494. }
  495. break;
  496. }
  497. default:
  498. {
  499. lua_pushstring(state, "Invalid number of parameters (expected 7).");
  500. lua_error(state);
  501. break;
  502. }
  503. }
  504. return 0;
  505. }
  506. int lua_CheckBox_createAnimationFromTo(lua_State* state)
  507. {
  508. // Get the number of parameters.
  509. int paramCount = lua_gettop(state);
  510. // Attempt to match the parameters to a valid binding.
  511. switch (paramCount)
  512. {
  513. case 7:
  514. {
  515. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  516. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL) &&
  517. lua_type(state, 3) == LUA_TNUMBER &&
  518. (lua_type(state, 4) == LUA_TTABLE || lua_type(state, 4) == LUA_TLIGHTUSERDATA) &&
  519. (lua_type(state, 5) == LUA_TTABLE || lua_type(state, 5) == LUA_TLIGHTUSERDATA) &&
  520. (lua_type(state, 6) == LUA_TSTRING || lua_type(state, 6) == LUA_TNIL) &&
  521. lua_type(state, 7) == LUA_TNUMBER)
  522. {
  523. // Get parameter 1 off the stack.
  524. ScriptUtil::LuaArray<const char> param1 = ScriptUtil::getString(2, false);
  525. // Get parameter 2 off the stack.
  526. int param2 = (int)luaL_checkint(state, 3);
  527. // Get parameter 3 off the stack.
  528. ScriptUtil::LuaArray<float> param3 = ScriptUtil::getFloatPointer(4);
  529. // Get parameter 4 off the stack.
  530. ScriptUtil::LuaArray<float> param4 = ScriptUtil::getFloatPointer(5);
  531. // Get parameter 5 off the stack.
  532. Curve::InterpolationType param5 = (Curve::InterpolationType)lua_enumFromString_CurveInterpolationType(luaL_checkstring(state, 6));
  533. // Get parameter 6 off the stack.
  534. unsigned long param6 = (unsigned long)luaL_checkunsigned(state, 7);
  535. CheckBox* instance = getInstance(state);
  536. void* returnPtr = (void*)instance->createAnimationFromTo(param1, param2, param3, param4, param5, param6);
  537. if (returnPtr)
  538. {
  539. ScriptUtil::LuaObject* object = (ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(ScriptUtil::LuaObject));
  540. object->instance = returnPtr;
  541. object->owns = false;
  542. luaL_getmetatable(state, "Animation");
  543. lua_setmetatable(state, -2);
  544. }
  545. else
  546. {
  547. lua_pushnil(state);
  548. }
  549. return 1;
  550. }
  551. else
  552. {
  553. lua_pushstring(state, "lua_CheckBox_createAnimationFromTo - Failed to match the given parameters to a valid function signature.");
  554. lua_error(state);
  555. }
  556. break;
  557. }
  558. default:
  559. {
  560. lua_pushstring(state, "Invalid number of parameters (expected 7).");
  561. lua_error(state);
  562. break;
  563. }
  564. }
  565. return 0;
  566. }
  567. int lua_CheckBox_destroyAnimation(lua_State* state)
  568. {
  569. // Get the number of parameters.
  570. int paramCount = lua_gettop(state);
  571. // Attempt to match the parameters to a valid binding.
  572. switch (paramCount)
  573. {
  574. case 1:
  575. {
  576. if ((lua_type(state, 1) == LUA_TUSERDATA))
  577. {
  578. CheckBox* instance = getInstance(state);
  579. instance->destroyAnimation();
  580. return 0;
  581. }
  582. else
  583. {
  584. lua_pushstring(state, "lua_CheckBox_destroyAnimation - Failed to match the given parameters to a valid function signature.");
  585. lua_error(state);
  586. }
  587. break;
  588. }
  589. case 2:
  590. {
  591. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  592. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL))
  593. {
  594. // Get parameter 1 off the stack.
  595. ScriptUtil::LuaArray<const char> param1 = ScriptUtil::getString(2, false);
  596. CheckBox* instance = getInstance(state);
  597. instance->destroyAnimation(param1);
  598. return 0;
  599. }
  600. else
  601. {
  602. lua_pushstring(state, "lua_CheckBox_destroyAnimation - Failed to match the given parameters to a valid function signature.");
  603. lua_error(state);
  604. }
  605. break;
  606. }
  607. default:
  608. {
  609. lua_pushstring(state, "Invalid number of parameters (expected 1 or 2).");
  610. lua_error(state);
  611. break;
  612. }
  613. }
  614. return 0;
  615. }
  616. int lua_CheckBox_disable(lua_State* state)
  617. {
  618. // Get the number of parameters.
  619. int paramCount = lua_gettop(state);
  620. // Attempt to match the parameters to a valid binding.
  621. switch (paramCount)
  622. {
  623. case 1:
  624. {
  625. if ((lua_type(state, 1) == LUA_TUSERDATA))
  626. {
  627. CheckBox* instance = getInstance(state);
  628. instance->disable();
  629. return 0;
  630. }
  631. else
  632. {
  633. lua_pushstring(state, "lua_CheckBox_disable - Failed to match the given parameters to a valid function signature.");
  634. lua_error(state);
  635. }
  636. break;
  637. }
  638. default:
  639. {
  640. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  641. lua_error(state);
  642. break;
  643. }
  644. }
  645. return 0;
  646. }
  647. int lua_CheckBox_enable(lua_State* state)
  648. {
  649. // Get the number of parameters.
  650. int paramCount = lua_gettop(state);
  651. // Attempt to match the parameters to a valid binding.
  652. switch (paramCount)
  653. {
  654. case 1:
  655. {
  656. if ((lua_type(state, 1) == LUA_TUSERDATA))
  657. {
  658. CheckBox* instance = getInstance(state);
  659. instance->enable();
  660. return 0;
  661. }
  662. else
  663. {
  664. lua_pushstring(state, "lua_CheckBox_enable - Failed to match the given parameters to a valid function signature.");
  665. lua_error(state);
  666. }
  667. break;
  668. }
  669. default:
  670. {
  671. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  672. lua_error(state);
  673. break;
  674. }
  675. }
  676. return 0;
  677. }
  678. int lua_CheckBox_getAlignment(lua_State* state)
  679. {
  680. // Get the number of parameters.
  681. int paramCount = lua_gettop(state);
  682. // Attempt to match the parameters to a valid binding.
  683. switch (paramCount)
  684. {
  685. case 1:
  686. {
  687. if ((lua_type(state, 1) == LUA_TUSERDATA))
  688. {
  689. CheckBox* instance = getInstance(state);
  690. Control::Alignment result = instance->getAlignment();
  691. // Push the return value onto the stack.
  692. lua_pushstring(state, lua_stringFromEnum_ControlAlignment(result));
  693. return 1;
  694. }
  695. else
  696. {
  697. lua_pushstring(state, "lua_CheckBox_getAlignment - Failed to match the given parameters to a valid function signature.");
  698. lua_error(state);
  699. }
  700. break;
  701. }
  702. default:
  703. {
  704. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  705. lua_error(state);
  706. break;
  707. }
  708. }
  709. return 0;
  710. }
  711. int lua_CheckBox_getAnimation(lua_State* state)
  712. {
  713. // Get the number of parameters.
  714. int paramCount = lua_gettop(state);
  715. // Attempt to match the parameters to a valid binding.
  716. switch (paramCount)
  717. {
  718. case 1:
  719. {
  720. if ((lua_type(state, 1) == LUA_TUSERDATA))
  721. {
  722. CheckBox* instance = getInstance(state);
  723. void* returnPtr = (void*)instance->getAnimation();
  724. if (returnPtr)
  725. {
  726. ScriptUtil::LuaObject* object = (ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(ScriptUtil::LuaObject));
  727. object->instance = returnPtr;
  728. object->owns = false;
  729. luaL_getmetatable(state, "Animation");
  730. lua_setmetatable(state, -2);
  731. }
  732. else
  733. {
  734. lua_pushnil(state);
  735. }
  736. return 1;
  737. }
  738. else
  739. {
  740. lua_pushstring(state, "lua_CheckBox_getAnimation - Failed to match the given parameters to a valid function signature.");
  741. lua_error(state);
  742. }
  743. break;
  744. }
  745. case 2:
  746. {
  747. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  748. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL))
  749. {
  750. // Get parameter 1 off the stack.
  751. ScriptUtil::LuaArray<const char> param1 = ScriptUtil::getString(2, false);
  752. CheckBox* instance = getInstance(state);
  753. void* returnPtr = (void*)instance->getAnimation(param1);
  754. if (returnPtr)
  755. {
  756. ScriptUtil::LuaObject* object = (ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(ScriptUtil::LuaObject));
  757. object->instance = returnPtr;
  758. object->owns = false;
  759. luaL_getmetatable(state, "Animation");
  760. lua_setmetatable(state, -2);
  761. }
  762. else
  763. {
  764. lua_pushnil(state);
  765. }
  766. return 1;
  767. }
  768. else
  769. {
  770. lua_pushstring(state, "lua_CheckBox_getAnimation - Failed to match the given parameters to a valid function signature.");
  771. lua_error(state);
  772. }
  773. break;
  774. }
  775. default:
  776. {
  777. lua_pushstring(state, "Invalid number of parameters (expected 1 or 2).");
  778. lua_error(state);
  779. break;
  780. }
  781. }
  782. return 0;
  783. }
  784. int lua_CheckBox_getAnimationPropertyComponentCount(lua_State* state)
  785. {
  786. // Get the number of parameters.
  787. int paramCount = lua_gettop(state);
  788. // Attempt to match the parameters to a valid binding.
  789. switch (paramCount)
  790. {
  791. case 2:
  792. {
  793. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  794. lua_type(state, 2) == LUA_TNUMBER)
  795. {
  796. // Get parameter 1 off the stack.
  797. int param1 = (int)luaL_checkint(state, 2);
  798. CheckBox* instance = getInstance(state);
  799. unsigned int result = instance->getAnimationPropertyComponentCount(param1);
  800. // Push the return value onto the stack.
  801. lua_pushunsigned(state, result);
  802. return 1;
  803. }
  804. else
  805. {
  806. lua_pushstring(state, "lua_CheckBox_getAnimationPropertyComponentCount - Failed to match the given parameters to a valid function signature.");
  807. lua_error(state);
  808. }
  809. break;
  810. }
  811. default:
  812. {
  813. lua_pushstring(state, "Invalid number of parameters (expected 2).");
  814. lua_error(state);
  815. break;
  816. }
  817. }
  818. return 0;
  819. }
  820. int lua_CheckBox_getAnimationPropertyValue(lua_State* state)
  821. {
  822. // Get the number of parameters.
  823. int paramCount = lua_gettop(state);
  824. // Attempt to match the parameters to a valid binding.
  825. switch (paramCount)
  826. {
  827. case 3:
  828. {
  829. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  830. lua_type(state, 2) == LUA_TNUMBER &&
  831. (lua_type(state, 3) == LUA_TUSERDATA || lua_type(state, 3) == LUA_TTABLE || lua_type(state, 3) == LUA_TNIL))
  832. {
  833. // Get parameter 1 off the stack.
  834. int param1 = (int)luaL_checkint(state, 2);
  835. // Get parameter 2 off the stack.
  836. ScriptUtil::LuaArray<AnimationValue> param2 = ScriptUtil::getObjectPointer<AnimationValue>(3, "AnimationValue", false);
  837. CheckBox* instance = getInstance(state);
  838. instance->getAnimationPropertyValue(param1, param2);
  839. return 0;
  840. }
  841. else
  842. {
  843. lua_pushstring(state, "lua_CheckBox_getAnimationPropertyValue - Failed to match the given parameters to a valid function signature.");
  844. lua_error(state);
  845. }
  846. break;
  847. }
  848. default:
  849. {
  850. lua_pushstring(state, "Invalid number of parameters (expected 3).");
  851. lua_error(state);
  852. break;
  853. }
  854. }
  855. return 0;
  856. }
  857. int lua_CheckBox_getAutoHeight(lua_State* state)
  858. {
  859. // Get the number of parameters.
  860. int paramCount = lua_gettop(state);
  861. // Attempt to match the parameters to a valid binding.
  862. switch (paramCount)
  863. {
  864. case 1:
  865. {
  866. if ((lua_type(state, 1) == LUA_TUSERDATA))
  867. {
  868. CheckBox* instance = getInstance(state);
  869. bool result = instance->getAutoHeight();
  870. // Push the return value onto the stack.
  871. lua_pushboolean(state, result);
  872. return 1;
  873. }
  874. else
  875. {
  876. lua_pushstring(state, "lua_CheckBox_getAutoHeight - Failed to match the given parameters to a valid function signature.");
  877. lua_error(state);
  878. }
  879. break;
  880. }
  881. default:
  882. {
  883. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  884. lua_error(state);
  885. break;
  886. }
  887. }
  888. return 0;
  889. }
  890. int lua_CheckBox_getAutoWidth(lua_State* state)
  891. {
  892. // Get the number of parameters.
  893. int paramCount = lua_gettop(state);
  894. // Attempt to match the parameters to a valid binding.
  895. switch (paramCount)
  896. {
  897. case 1:
  898. {
  899. if ((lua_type(state, 1) == LUA_TUSERDATA))
  900. {
  901. CheckBox* instance = getInstance(state);
  902. bool result = instance->getAutoWidth();
  903. // Push the return value onto the stack.
  904. lua_pushboolean(state, result);
  905. return 1;
  906. }
  907. else
  908. {
  909. lua_pushstring(state, "lua_CheckBox_getAutoWidth - Failed to match the given parameters to a valid function signature.");
  910. lua_error(state);
  911. }
  912. break;
  913. }
  914. default:
  915. {
  916. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  917. lua_error(state);
  918. break;
  919. }
  920. }
  921. return 0;
  922. }
  923. int lua_CheckBox_getBorder(lua_State* state)
  924. {
  925. // Get the number of parameters.
  926. int paramCount = lua_gettop(state);
  927. // Attempt to match the parameters to a valid binding.
  928. switch (paramCount)
  929. {
  930. case 1:
  931. {
  932. if ((lua_type(state, 1) == LUA_TUSERDATA))
  933. {
  934. CheckBox* instance = getInstance(state);
  935. void* returnPtr = (void*)&(instance->getBorder());
  936. if (returnPtr)
  937. {
  938. ScriptUtil::LuaObject* object = (ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(ScriptUtil::LuaObject));
  939. object->instance = returnPtr;
  940. object->owns = false;
  941. luaL_getmetatable(state, "ThemeSideRegions");
  942. lua_setmetatable(state, -2);
  943. }
  944. else
  945. {
  946. lua_pushnil(state);
  947. }
  948. return 1;
  949. }
  950. else
  951. {
  952. lua_pushstring(state, "lua_CheckBox_getBorder - Failed to match the given parameters to a valid function signature.");
  953. lua_error(state);
  954. }
  955. break;
  956. }
  957. case 2:
  958. {
  959. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  960. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL))
  961. {
  962. // Get parameter 1 off the stack.
  963. Control::State param1 = (Control::State)lua_enumFromString_ControlState(luaL_checkstring(state, 2));
  964. CheckBox* instance = getInstance(state);
  965. void* returnPtr = (void*)&(instance->getBorder(param1));
  966. if (returnPtr)
  967. {
  968. ScriptUtil::LuaObject* object = (ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(ScriptUtil::LuaObject));
  969. object->instance = returnPtr;
  970. object->owns = false;
  971. luaL_getmetatable(state, "ThemeSideRegions");
  972. lua_setmetatable(state, -2);
  973. }
  974. else
  975. {
  976. lua_pushnil(state);
  977. }
  978. return 1;
  979. }
  980. else
  981. {
  982. lua_pushstring(state, "lua_CheckBox_getBorder - Failed to match the given parameters to a valid function signature.");
  983. lua_error(state);
  984. }
  985. break;
  986. }
  987. default:
  988. {
  989. lua_pushstring(state, "Invalid number of parameters (expected 1 or 2).");
  990. lua_error(state);
  991. break;
  992. }
  993. }
  994. return 0;
  995. }
  996. int lua_CheckBox_getBounds(lua_State* state)
  997. {
  998. // Get the number of parameters.
  999. int paramCount = lua_gettop(state);
  1000. // Attempt to match the parameters to a valid binding.
  1001. switch (paramCount)
  1002. {
  1003. case 1:
  1004. {
  1005. if ((lua_type(state, 1) == LUA_TUSERDATA))
  1006. {
  1007. CheckBox* instance = getInstance(state);
  1008. void* returnPtr = (void*)&(instance->getBounds());
  1009. if (returnPtr)
  1010. {
  1011. ScriptUtil::LuaObject* object = (ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(ScriptUtil::LuaObject));
  1012. object->instance = returnPtr;
  1013. object->owns = false;
  1014. luaL_getmetatable(state, "Rectangle");
  1015. lua_setmetatable(state, -2);
  1016. }
  1017. else
  1018. {
  1019. lua_pushnil(state);
  1020. }
  1021. return 1;
  1022. }
  1023. else
  1024. {
  1025. lua_pushstring(state, "lua_CheckBox_getBounds - Failed to match the given parameters to a valid function signature.");
  1026. lua_error(state);
  1027. }
  1028. break;
  1029. }
  1030. default:
  1031. {
  1032. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  1033. lua_error(state);
  1034. break;
  1035. }
  1036. }
  1037. return 0;
  1038. }
  1039. int lua_CheckBox_getClip(lua_State* state)
  1040. {
  1041. // Get the number of parameters.
  1042. int paramCount = lua_gettop(state);
  1043. // Attempt to match the parameters to a valid binding.
  1044. switch (paramCount)
  1045. {
  1046. case 1:
  1047. {
  1048. if ((lua_type(state, 1) == LUA_TUSERDATA))
  1049. {
  1050. CheckBox* instance = getInstance(state);
  1051. void* returnPtr = (void*)&(instance->getClip());
  1052. if (returnPtr)
  1053. {
  1054. ScriptUtil::LuaObject* object = (ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(ScriptUtil::LuaObject));
  1055. object->instance = returnPtr;
  1056. object->owns = false;
  1057. luaL_getmetatable(state, "Rectangle");
  1058. lua_setmetatable(state, -2);
  1059. }
  1060. else
  1061. {
  1062. lua_pushnil(state);
  1063. }
  1064. return 1;
  1065. }
  1066. else
  1067. {
  1068. lua_pushstring(state, "lua_CheckBox_getClip - Failed to match the given parameters to a valid function signature.");
  1069. lua_error(state);
  1070. }
  1071. break;
  1072. }
  1073. default:
  1074. {
  1075. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  1076. lua_error(state);
  1077. break;
  1078. }
  1079. }
  1080. return 0;
  1081. }
  1082. int lua_CheckBox_getClipBounds(lua_State* state)
  1083. {
  1084. // Get the number of parameters.
  1085. int paramCount = lua_gettop(state);
  1086. // Attempt to match the parameters to a valid binding.
  1087. switch (paramCount)
  1088. {
  1089. case 1:
  1090. {
  1091. if ((lua_type(state, 1) == LUA_TUSERDATA))
  1092. {
  1093. CheckBox* instance = getInstance(state);
  1094. void* returnPtr = (void*)&(instance->getClipBounds());
  1095. if (returnPtr)
  1096. {
  1097. ScriptUtil::LuaObject* object = (ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(ScriptUtil::LuaObject));
  1098. object->instance = returnPtr;
  1099. object->owns = false;
  1100. luaL_getmetatable(state, "Rectangle");
  1101. lua_setmetatable(state, -2);
  1102. }
  1103. else
  1104. {
  1105. lua_pushnil(state);
  1106. }
  1107. return 1;
  1108. }
  1109. else
  1110. {
  1111. lua_pushstring(state, "lua_CheckBox_getClipBounds - Failed to match the given parameters to a valid function signature.");
  1112. lua_error(state);
  1113. }
  1114. break;
  1115. }
  1116. default:
  1117. {
  1118. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  1119. lua_error(state);
  1120. break;
  1121. }
  1122. }
  1123. return 0;
  1124. }
  1125. int lua_CheckBox_getConsumeInputEvents(lua_State* state)
  1126. {
  1127. // Get the number of parameters.
  1128. int paramCount = lua_gettop(state);
  1129. // Attempt to match the parameters to a valid binding.
  1130. switch (paramCount)
  1131. {
  1132. case 1:
  1133. {
  1134. if ((lua_type(state, 1) == LUA_TUSERDATA))
  1135. {
  1136. CheckBox* instance = getInstance(state);
  1137. bool result = instance->getConsumeInputEvents();
  1138. // Push the return value onto the stack.
  1139. lua_pushboolean(state, result);
  1140. return 1;
  1141. }
  1142. else
  1143. {
  1144. lua_pushstring(state, "lua_CheckBox_getConsumeInputEvents - Failed to match the given parameters to a valid function signature.");
  1145. lua_error(state);
  1146. }
  1147. break;
  1148. }
  1149. default:
  1150. {
  1151. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  1152. lua_error(state);
  1153. break;
  1154. }
  1155. }
  1156. return 0;
  1157. }
  1158. int lua_CheckBox_getCursorColor(lua_State* state)
  1159. {
  1160. // Get the number of parameters.
  1161. int paramCount = lua_gettop(state);
  1162. // Attempt to match the parameters to a valid binding.
  1163. switch (paramCount)
  1164. {
  1165. case 2:
  1166. {
  1167. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  1168. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL))
  1169. {
  1170. // Get parameter 1 off the stack.
  1171. Control::State param1 = (Control::State)lua_enumFromString_ControlState(luaL_checkstring(state, 2));
  1172. CheckBox* instance = getInstance(state);
  1173. void* returnPtr = (void*)&(instance->getCursorColor(param1));
  1174. if (returnPtr)
  1175. {
  1176. ScriptUtil::LuaObject* object = (ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(ScriptUtil::LuaObject));
  1177. object->instance = returnPtr;
  1178. object->owns = false;
  1179. luaL_getmetatable(state, "Vector4");
  1180. lua_setmetatable(state, -2);
  1181. }
  1182. else
  1183. {
  1184. lua_pushnil(state);
  1185. }
  1186. return 1;
  1187. }
  1188. else
  1189. {
  1190. lua_pushstring(state, "lua_CheckBox_getCursorColor - Failed to match the given parameters to a valid function signature.");
  1191. lua_error(state);
  1192. }
  1193. break;
  1194. }
  1195. default:
  1196. {
  1197. lua_pushstring(state, "Invalid number of parameters (expected 2).");
  1198. lua_error(state);
  1199. break;
  1200. }
  1201. }
  1202. return 0;
  1203. }
  1204. int lua_CheckBox_getCursorRegion(lua_State* state)
  1205. {
  1206. // Get the number of parameters.
  1207. int paramCount = lua_gettop(state);
  1208. // Attempt to match the parameters to a valid binding.
  1209. switch (paramCount)
  1210. {
  1211. case 2:
  1212. {
  1213. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  1214. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL))
  1215. {
  1216. // Get parameter 1 off the stack.
  1217. Control::State param1 = (Control::State)lua_enumFromString_ControlState(luaL_checkstring(state, 2));
  1218. CheckBox* instance = getInstance(state);
  1219. void* returnPtr = (void*)&(instance->getCursorRegion(param1));
  1220. if (returnPtr)
  1221. {
  1222. ScriptUtil::LuaObject* object = (ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(ScriptUtil::LuaObject));
  1223. object->instance = returnPtr;
  1224. object->owns = false;
  1225. luaL_getmetatable(state, "Rectangle");
  1226. lua_setmetatable(state, -2);
  1227. }
  1228. else
  1229. {
  1230. lua_pushnil(state);
  1231. }
  1232. return 1;
  1233. }
  1234. else
  1235. {
  1236. lua_pushstring(state, "lua_CheckBox_getCursorRegion - Failed to match the given parameters to a valid function signature.");
  1237. lua_error(state);
  1238. }
  1239. break;
  1240. }
  1241. default:
  1242. {
  1243. lua_pushstring(state, "Invalid number of parameters (expected 2).");
  1244. lua_error(state);
  1245. break;
  1246. }
  1247. }
  1248. return 0;
  1249. }
  1250. int lua_CheckBox_getCursorUVs(lua_State* state)
  1251. {
  1252. // Get the number of parameters.
  1253. int paramCount = lua_gettop(state);
  1254. // Attempt to match the parameters to a valid binding.
  1255. switch (paramCount)
  1256. {
  1257. case 2:
  1258. {
  1259. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  1260. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL))
  1261. {
  1262. // Get parameter 1 off the stack.
  1263. Control::State param1 = (Control::State)lua_enumFromString_ControlState(luaL_checkstring(state, 2));
  1264. CheckBox* instance = getInstance(state);
  1265. void* returnPtr = (void*)&(instance->getCursorUVs(param1));
  1266. if (returnPtr)
  1267. {
  1268. ScriptUtil::LuaObject* object = (ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(ScriptUtil::LuaObject));
  1269. object->instance = returnPtr;
  1270. object->owns = false;
  1271. luaL_getmetatable(state, "ThemeUVs");
  1272. lua_setmetatable(state, -2);
  1273. }
  1274. else
  1275. {
  1276. lua_pushnil(state);
  1277. }
  1278. return 1;
  1279. }
  1280. else
  1281. {
  1282. lua_pushstring(state, "lua_CheckBox_getCursorUVs - Failed to match the given parameters to a valid function signature.");
  1283. lua_error(state);
  1284. }
  1285. break;
  1286. }
  1287. default:
  1288. {
  1289. lua_pushstring(state, "Invalid number of parameters (expected 2).");
  1290. lua_error(state);
  1291. break;
  1292. }
  1293. }
  1294. return 0;
  1295. }
  1296. int lua_CheckBox_getFocusIndex(lua_State* state)
  1297. {
  1298. // Get the number of parameters.
  1299. int paramCount = lua_gettop(state);
  1300. // Attempt to match the parameters to a valid binding.
  1301. switch (paramCount)
  1302. {
  1303. case 1:
  1304. {
  1305. if ((lua_type(state, 1) == LUA_TUSERDATA))
  1306. {
  1307. CheckBox* instance = getInstance(state);
  1308. int result = instance->getFocusIndex();
  1309. // Push the return value onto the stack.
  1310. lua_pushinteger(state, result);
  1311. return 1;
  1312. }
  1313. else
  1314. {
  1315. lua_pushstring(state, "lua_CheckBox_getFocusIndex - Failed to match the given parameters to a valid function signature.");
  1316. lua_error(state);
  1317. }
  1318. break;
  1319. }
  1320. default:
  1321. {
  1322. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  1323. lua_error(state);
  1324. break;
  1325. }
  1326. }
  1327. return 0;
  1328. }
  1329. int lua_CheckBox_getFont(lua_State* state)
  1330. {
  1331. // Get the number of parameters.
  1332. int paramCount = lua_gettop(state);
  1333. // Attempt to match the parameters to a valid binding.
  1334. switch (paramCount)
  1335. {
  1336. case 1:
  1337. {
  1338. if ((lua_type(state, 1) == LUA_TUSERDATA))
  1339. {
  1340. CheckBox* instance = getInstance(state);
  1341. void* returnPtr = (void*)instance->getFont();
  1342. if (returnPtr)
  1343. {
  1344. ScriptUtil::LuaObject* object = (ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(ScriptUtil::LuaObject));
  1345. object->instance = returnPtr;
  1346. object->owns = false;
  1347. luaL_getmetatable(state, "Font");
  1348. lua_setmetatable(state, -2);
  1349. }
  1350. else
  1351. {
  1352. lua_pushnil(state);
  1353. }
  1354. return 1;
  1355. }
  1356. else
  1357. {
  1358. lua_pushstring(state, "lua_CheckBox_getFont - Failed to match the given parameters to a valid function signature.");
  1359. lua_error(state);
  1360. }
  1361. break;
  1362. }
  1363. case 2:
  1364. {
  1365. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  1366. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL))
  1367. {
  1368. // Get parameter 1 off the stack.
  1369. Control::State param1 = (Control::State)lua_enumFromString_ControlState(luaL_checkstring(state, 2));
  1370. CheckBox* instance = getInstance(state);
  1371. void* returnPtr = (void*)instance->getFont(param1);
  1372. if (returnPtr)
  1373. {
  1374. ScriptUtil::LuaObject* object = (ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(ScriptUtil::LuaObject));
  1375. object->instance = returnPtr;
  1376. object->owns = false;
  1377. luaL_getmetatable(state, "Font");
  1378. lua_setmetatable(state, -2);
  1379. }
  1380. else
  1381. {
  1382. lua_pushnil(state);
  1383. }
  1384. return 1;
  1385. }
  1386. else
  1387. {
  1388. lua_pushstring(state, "lua_CheckBox_getFont - Failed to match the given parameters to a valid function signature.");
  1389. lua_error(state);
  1390. }
  1391. break;
  1392. }
  1393. default:
  1394. {
  1395. lua_pushstring(state, "Invalid number of parameters (expected 1 or 2).");
  1396. lua_error(state);
  1397. break;
  1398. }
  1399. }
  1400. return 0;
  1401. }
  1402. int lua_CheckBox_getFontSize(lua_State* state)
  1403. {
  1404. // Get the number of parameters.
  1405. int paramCount = lua_gettop(state);
  1406. // Attempt to match the parameters to a valid binding.
  1407. switch (paramCount)
  1408. {
  1409. case 1:
  1410. {
  1411. if ((lua_type(state, 1) == LUA_TUSERDATA))
  1412. {
  1413. CheckBox* instance = getInstance(state);
  1414. unsigned int result = instance->getFontSize();
  1415. // Push the return value onto the stack.
  1416. lua_pushunsigned(state, result);
  1417. return 1;
  1418. }
  1419. else
  1420. {
  1421. lua_pushstring(state, "lua_CheckBox_getFontSize - Failed to match the given parameters to a valid function signature.");
  1422. lua_error(state);
  1423. }
  1424. break;
  1425. }
  1426. case 2:
  1427. {
  1428. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  1429. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL))
  1430. {
  1431. // Get parameter 1 off the stack.
  1432. Control::State param1 = (Control::State)lua_enumFromString_ControlState(luaL_checkstring(state, 2));
  1433. CheckBox* instance = getInstance(state);
  1434. unsigned int result = instance->getFontSize(param1);
  1435. // Push the return value onto the stack.
  1436. lua_pushunsigned(state, result);
  1437. return 1;
  1438. }
  1439. else
  1440. {
  1441. lua_pushstring(state, "lua_CheckBox_getFontSize - Failed to match the given parameters to a valid function signature.");
  1442. lua_error(state);
  1443. }
  1444. break;
  1445. }
  1446. default:
  1447. {
  1448. lua_pushstring(state, "Invalid number of parameters (expected 1 or 2).");
  1449. lua_error(state);
  1450. break;
  1451. }
  1452. }
  1453. return 0;
  1454. }
  1455. int lua_CheckBox_getHeight(lua_State* state)
  1456. {
  1457. // Get the number of parameters.
  1458. int paramCount = lua_gettop(state);
  1459. // Attempt to match the parameters to a valid binding.
  1460. switch (paramCount)
  1461. {
  1462. case 1:
  1463. {
  1464. if ((lua_type(state, 1) == LUA_TUSERDATA))
  1465. {
  1466. CheckBox* instance = getInstance(state);
  1467. float result = instance->getHeight();
  1468. // Push the return value onto the stack.
  1469. lua_pushnumber(state, result);
  1470. return 1;
  1471. }
  1472. else
  1473. {
  1474. lua_pushstring(state, "lua_CheckBox_getHeight - Failed to match the given parameters to a valid function signature.");
  1475. lua_error(state);
  1476. }
  1477. break;
  1478. }
  1479. default:
  1480. {
  1481. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  1482. lua_error(state);
  1483. break;
  1484. }
  1485. }
  1486. return 0;
  1487. }
  1488. int lua_CheckBox_getId(lua_State* state)
  1489. {
  1490. // Get the number of parameters.
  1491. int paramCount = lua_gettop(state);
  1492. // Attempt to match the parameters to a valid binding.
  1493. switch (paramCount)
  1494. {
  1495. case 1:
  1496. {
  1497. if ((lua_type(state, 1) == LUA_TUSERDATA))
  1498. {
  1499. CheckBox* instance = getInstance(state);
  1500. const char* result = instance->getId();
  1501. // Push the return value onto the stack.
  1502. lua_pushstring(state, result);
  1503. return 1;
  1504. }
  1505. else
  1506. {
  1507. lua_pushstring(state, "lua_CheckBox_getId - Failed to match the given parameters to a valid function signature.");
  1508. lua_error(state);
  1509. }
  1510. break;
  1511. }
  1512. default:
  1513. {
  1514. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  1515. lua_error(state);
  1516. break;
  1517. }
  1518. }
  1519. return 0;
  1520. }
  1521. int lua_CheckBox_getImageColor(lua_State* state)
  1522. {
  1523. // Get the number of parameters.
  1524. int paramCount = lua_gettop(state);
  1525. // Attempt to match the parameters to a valid binding.
  1526. switch (paramCount)
  1527. {
  1528. case 3:
  1529. {
  1530. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  1531. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL) &&
  1532. (lua_type(state, 3) == LUA_TSTRING || lua_type(state, 3) == LUA_TNIL))
  1533. {
  1534. // Get parameter 1 off the stack.
  1535. ScriptUtil::LuaArray<const char> param1 = ScriptUtil::getString(2, false);
  1536. // Get parameter 2 off the stack.
  1537. Control::State param2 = (Control::State)lua_enumFromString_ControlState(luaL_checkstring(state, 3));
  1538. CheckBox* instance = getInstance(state);
  1539. void* returnPtr = (void*)&(instance->getImageColor(param1, param2));
  1540. if (returnPtr)
  1541. {
  1542. ScriptUtil::LuaObject* object = (ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(ScriptUtil::LuaObject));
  1543. object->instance = returnPtr;
  1544. object->owns = false;
  1545. luaL_getmetatable(state, "Vector4");
  1546. lua_setmetatable(state, -2);
  1547. }
  1548. else
  1549. {
  1550. lua_pushnil(state);
  1551. }
  1552. return 1;
  1553. }
  1554. else
  1555. {
  1556. lua_pushstring(state, "lua_CheckBox_getImageColor - Failed to match the given parameters to a valid function signature.");
  1557. lua_error(state);
  1558. }
  1559. break;
  1560. }
  1561. default:
  1562. {
  1563. lua_pushstring(state, "Invalid number of parameters (expected 3).");
  1564. lua_error(state);
  1565. break;
  1566. }
  1567. }
  1568. return 0;
  1569. }
  1570. int lua_CheckBox_getImageRegion(lua_State* state)
  1571. {
  1572. // Get the number of parameters.
  1573. int paramCount = lua_gettop(state);
  1574. // Attempt to match the parameters to a valid binding.
  1575. switch (paramCount)
  1576. {
  1577. case 3:
  1578. {
  1579. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  1580. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL) &&
  1581. (lua_type(state, 3) == LUA_TSTRING || lua_type(state, 3) == LUA_TNIL))
  1582. {
  1583. // Get parameter 1 off the stack.
  1584. ScriptUtil::LuaArray<const char> param1 = ScriptUtil::getString(2, false);
  1585. // Get parameter 2 off the stack.
  1586. Control::State param2 = (Control::State)lua_enumFromString_ControlState(luaL_checkstring(state, 3));
  1587. CheckBox* instance = getInstance(state);
  1588. void* returnPtr = (void*)&(instance->getImageRegion(param1, param2));
  1589. if (returnPtr)
  1590. {
  1591. ScriptUtil::LuaObject* object = (ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(ScriptUtil::LuaObject));
  1592. object->instance = returnPtr;
  1593. object->owns = false;
  1594. luaL_getmetatable(state, "Rectangle");
  1595. lua_setmetatable(state, -2);
  1596. }
  1597. else
  1598. {
  1599. lua_pushnil(state);
  1600. }
  1601. return 1;
  1602. }
  1603. else
  1604. {
  1605. lua_pushstring(state, "lua_CheckBox_getImageRegion - Failed to match the given parameters to a valid function signature.");
  1606. lua_error(state);
  1607. }
  1608. break;
  1609. }
  1610. default:
  1611. {
  1612. lua_pushstring(state, "Invalid number of parameters (expected 3).");
  1613. lua_error(state);
  1614. break;
  1615. }
  1616. }
  1617. return 0;
  1618. }
  1619. int lua_CheckBox_getImageSize(lua_State* state)
  1620. {
  1621. // Get the number of parameters.
  1622. int paramCount = lua_gettop(state);
  1623. // Attempt to match the parameters to a valid binding.
  1624. switch (paramCount)
  1625. {
  1626. case 1:
  1627. {
  1628. if ((lua_type(state, 1) == LUA_TUSERDATA))
  1629. {
  1630. CheckBox* instance = getInstance(state);
  1631. void* returnPtr = (void*)&(instance->getImageSize());
  1632. if (returnPtr)
  1633. {
  1634. ScriptUtil::LuaObject* object = (ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(ScriptUtil::LuaObject));
  1635. object->instance = returnPtr;
  1636. object->owns = false;
  1637. luaL_getmetatable(state, "Vector2");
  1638. lua_setmetatable(state, -2);
  1639. }
  1640. else
  1641. {
  1642. lua_pushnil(state);
  1643. }
  1644. return 1;
  1645. }
  1646. else
  1647. {
  1648. lua_pushstring(state, "lua_CheckBox_getImageSize - Failed to match the given parameters to a valid function signature.");
  1649. lua_error(state);
  1650. }
  1651. break;
  1652. }
  1653. default:
  1654. {
  1655. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  1656. lua_error(state);
  1657. break;
  1658. }
  1659. }
  1660. return 0;
  1661. }
  1662. int lua_CheckBox_getImageUVs(lua_State* state)
  1663. {
  1664. // Get the number of parameters.
  1665. int paramCount = lua_gettop(state);
  1666. // Attempt to match the parameters to a valid binding.
  1667. switch (paramCount)
  1668. {
  1669. case 3:
  1670. {
  1671. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  1672. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL) &&
  1673. (lua_type(state, 3) == LUA_TSTRING || lua_type(state, 3) == LUA_TNIL))
  1674. {
  1675. // Get parameter 1 off the stack.
  1676. ScriptUtil::LuaArray<const char> param1 = ScriptUtil::getString(2, false);
  1677. // Get parameter 2 off the stack.
  1678. Control::State param2 = (Control::State)lua_enumFromString_ControlState(luaL_checkstring(state, 3));
  1679. CheckBox* instance = getInstance(state);
  1680. void* returnPtr = (void*)&(instance->getImageUVs(param1, param2));
  1681. if (returnPtr)
  1682. {
  1683. ScriptUtil::LuaObject* object = (ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(ScriptUtil::LuaObject));
  1684. object->instance = returnPtr;
  1685. object->owns = false;
  1686. luaL_getmetatable(state, "ThemeUVs");
  1687. lua_setmetatable(state, -2);
  1688. }
  1689. else
  1690. {
  1691. lua_pushnil(state);
  1692. }
  1693. return 1;
  1694. }
  1695. else
  1696. {
  1697. lua_pushstring(state, "lua_CheckBox_getImageUVs - Failed to match the given parameters to a valid function signature.");
  1698. lua_error(state);
  1699. }
  1700. break;
  1701. }
  1702. default:
  1703. {
  1704. lua_pushstring(state, "Invalid number of parameters (expected 3).");
  1705. lua_error(state);
  1706. break;
  1707. }
  1708. }
  1709. return 0;
  1710. }
  1711. int lua_CheckBox_getMargin(lua_State* state)
  1712. {
  1713. // Get the number of parameters.
  1714. int paramCount = lua_gettop(state);
  1715. // Attempt to match the parameters to a valid binding.
  1716. switch (paramCount)
  1717. {
  1718. case 1:
  1719. {
  1720. if ((lua_type(state, 1) == LUA_TUSERDATA))
  1721. {
  1722. CheckBox* instance = getInstance(state);
  1723. void* returnPtr = (void*)&(instance->getMargin());
  1724. if (returnPtr)
  1725. {
  1726. ScriptUtil::LuaObject* object = (ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(ScriptUtil::LuaObject));
  1727. object->instance = returnPtr;
  1728. object->owns = false;
  1729. luaL_getmetatable(state, "ThemeSideRegions");
  1730. lua_setmetatable(state, -2);
  1731. }
  1732. else
  1733. {
  1734. lua_pushnil(state);
  1735. }
  1736. return 1;
  1737. }
  1738. else
  1739. {
  1740. lua_pushstring(state, "lua_CheckBox_getMargin - Failed to match the given parameters to a valid function signature.");
  1741. lua_error(state);
  1742. }
  1743. break;
  1744. }
  1745. default:
  1746. {
  1747. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  1748. lua_error(state);
  1749. break;
  1750. }
  1751. }
  1752. return 0;
  1753. }
  1754. int lua_CheckBox_getOpacity(lua_State* state)
  1755. {
  1756. // Get the number of parameters.
  1757. int paramCount = lua_gettop(state);
  1758. // Attempt to match the parameters to a valid binding.
  1759. switch (paramCount)
  1760. {
  1761. case 1:
  1762. {
  1763. if ((lua_type(state, 1) == LUA_TUSERDATA))
  1764. {
  1765. CheckBox* instance = getInstance(state);
  1766. float result = instance->getOpacity();
  1767. // Push the return value onto the stack.
  1768. lua_pushnumber(state, result);
  1769. return 1;
  1770. }
  1771. else
  1772. {
  1773. lua_pushstring(state, "lua_CheckBox_getOpacity - Failed to match the given parameters to a valid function signature.");
  1774. lua_error(state);
  1775. }
  1776. break;
  1777. }
  1778. case 2:
  1779. {
  1780. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  1781. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL))
  1782. {
  1783. // Get parameter 1 off the stack.
  1784. Control::State param1 = (Control::State)lua_enumFromString_ControlState(luaL_checkstring(state, 2));
  1785. CheckBox* instance = getInstance(state);
  1786. float result = instance->getOpacity(param1);
  1787. // Push the return value onto the stack.
  1788. lua_pushnumber(state, result);
  1789. return 1;
  1790. }
  1791. else
  1792. {
  1793. lua_pushstring(state, "lua_CheckBox_getOpacity - Failed to match the given parameters to a valid function signature.");
  1794. lua_error(state);
  1795. }
  1796. break;
  1797. }
  1798. default:
  1799. {
  1800. lua_pushstring(state, "Invalid number of parameters (expected 1 or 2).");
  1801. lua_error(state);
  1802. break;
  1803. }
  1804. }
  1805. return 0;
  1806. }
  1807. int lua_CheckBox_getPadding(lua_State* state)
  1808. {
  1809. // Get the number of parameters.
  1810. int paramCount = lua_gettop(state);
  1811. // Attempt to match the parameters to a valid binding.
  1812. switch (paramCount)
  1813. {
  1814. case 1:
  1815. {
  1816. if ((lua_type(state, 1) == LUA_TUSERDATA))
  1817. {
  1818. CheckBox* instance = getInstance(state);
  1819. void* returnPtr = (void*)&(instance->getPadding());
  1820. if (returnPtr)
  1821. {
  1822. ScriptUtil::LuaObject* object = (ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(ScriptUtil::LuaObject));
  1823. object->instance = returnPtr;
  1824. object->owns = false;
  1825. luaL_getmetatable(state, "ThemeSideRegions");
  1826. lua_setmetatable(state, -2);
  1827. }
  1828. else
  1829. {
  1830. lua_pushnil(state);
  1831. }
  1832. return 1;
  1833. }
  1834. else
  1835. {
  1836. lua_pushstring(state, "lua_CheckBox_getPadding - Failed to match the given parameters to a valid function signature.");
  1837. lua_error(state);
  1838. }
  1839. break;
  1840. }
  1841. default:
  1842. {
  1843. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  1844. lua_error(state);
  1845. break;
  1846. }
  1847. }
  1848. return 0;
  1849. }
  1850. int lua_CheckBox_getRefCount(lua_State* state)
  1851. {
  1852. // Get the number of parameters.
  1853. int paramCount = lua_gettop(state);
  1854. // Attempt to match the parameters to a valid binding.
  1855. switch (paramCount)
  1856. {
  1857. case 1:
  1858. {
  1859. if ((lua_type(state, 1) == LUA_TUSERDATA))
  1860. {
  1861. CheckBox* instance = getInstance(state);
  1862. unsigned int result = instance->getRefCount();
  1863. // Push the return value onto the stack.
  1864. lua_pushunsigned(state, result);
  1865. return 1;
  1866. }
  1867. else
  1868. {
  1869. lua_pushstring(state, "lua_CheckBox_getRefCount - Failed to match the given parameters to a valid function signature.");
  1870. lua_error(state);
  1871. }
  1872. break;
  1873. }
  1874. default:
  1875. {
  1876. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  1877. lua_error(state);
  1878. break;
  1879. }
  1880. }
  1881. return 0;
  1882. }
  1883. int lua_CheckBox_getSkinColor(lua_State* state)
  1884. {
  1885. // Get the number of parameters.
  1886. int paramCount = lua_gettop(state);
  1887. // Attempt to match the parameters to a valid binding.
  1888. switch (paramCount)
  1889. {
  1890. case 1:
  1891. {
  1892. if ((lua_type(state, 1) == LUA_TUSERDATA))
  1893. {
  1894. CheckBox* instance = getInstance(state);
  1895. void* returnPtr = (void*)&(instance->getSkinColor());
  1896. if (returnPtr)
  1897. {
  1898. ScriptUtil::LuaObject* object = (ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(ScriptUtil::LuaObject));
  1899. object->instance = returnPtr;
  1900. object->owns = false;
  1901. luaL_getmetatable(state, "Vector4");
  1902. lua_setmetatable(state, -2);
  1903. }
  1904. else
  1905. {
  1906. lua_pushnil(state);
  1907. }
  1908. return 1;
  1909. }
  1910. else
  1911. {
  1912. lua_pushstring(state, "lua_CheckBox_getSkinColor - Failed to match the given parameters to a valid function signature.");
  1913. lua_error(state);
  1914. }
  1915. break;
  1916. }
  1917. case 2:
  1918. {
  1919. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  1920. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL))
  1921. {
  1922. // Get parameter 1 off the stack.
  1923. Control::State param1 = (Control::State)lua_enumFromString_ControlState(luaL_checkstring(state, 2));
  1924. CheckBox* instance = getInstance(state);
  1925. void* returnPtr = (void*)&(instance->getSkinColor(param1));
  1926. if (returnPtr)
  1927. {
  1928. ScriptUtil::LuaObject* object = (ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(ScriptUtil::LuaObject));
  1929. object->instance = returnPtr;
  1930. object->owns = false;
  1931. luaL_getmetatable(state, "Vector4");
  1932. lua_setmetatable(state, -2);
  1933. }
  1934. else
  1935. {
  1936. lua_pushnil(state);
  1937. }
  1938. return 1;
  1939. }
  1940. else
  1941. {
  1942. lua_pushstring(state, "lua_CheckBox_getSkinColor - Failed to match the given parameters to a valid function signature.");
  1943. lua_error(state);
  1944. }
  1945. break;
  1946. }
  1947. default:
  1948. {
  1949. lua_pushstring(state, "Invalid number of parameters (expected 1 or 2).");
  1950. lua_error(state);
  1951. break;
  1952. }
  1953. }
  1954. return 0;
  1955. }
  1956. int lua_CheckBox_getSkinRegion(lua_State* state)
  1957. {
  1958. // Get the number of parameters.
  1959. int paramCount = lua_gettop(state);
  1960. // Attempt to match the parameters to a valid binding.
  1961. switch (paramCount)
  1962. {
  1963. case 1:
  1964. {
  1965. if ((lua_type(state, 1) == LUA_TUSERDATA))
  1966. {
  1967. CheckBox* instance = getInstance(state);
  1968. void* returnPtr = (void*)&(instance->getSkinRegion());
  1969. if (returnPtr)
  1970. {
  1971. ScriptUtil::LuaObject* object = (ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(ScriptUtil::LuaObject));
  1972. object->instance = returnPtr;
  1973. object->owns = false;
  1974. luaL_getmetatable(state, "Rectangle");
  1975. lua_setmetatable(state, -2);
  1976. }
  1977. else
  1978. {
  1979. lua_pushnil(state);
  1980. }
  1981. return 1;
  1982. }
  1983. else
  1984. {
  1985. lua_pushstring(state, "lua_CheckBox_getSkinRegion - Failed to match the given parameters to a valid function signature.");
  1986. lua_error(state);
  1987. }
  1988. break;
  1989. }
  1990. case 2:
  1991. {
  1992. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  1993. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL))
  1994. {
  1995. // Get parameter 1 off the stack.
  1996. Control::State param1 = (Control::State)lua_enumFromString_ControlState(luaL_checkstring(state, 2));
  1997. CheckBox* instance = getInstance(state);
  1998. void* returnPtr = (void*)&(instance->getSkinRegion(param1));
  1999. if (returnPtr)
  2000. {
  2001. ScriptUtil::LuaObject* object = (ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(ScriptUtil::LuaObject));
  2002. object->instance = returnPtr;
  2003. object->owns = false;
  2004. luaL_getmetatable(state, "Rectangle");
  2005. lua_setmetatable(state, -2);
  2006. }
  2007. else
  2008. {
  2009. lua_pushnil(state);
  2010. }
  2011. return 1;
  2012. }
  2013. else
  2014. {
  2015. lua_pushstring(state, "lua_CheckBox_getSkinRegion - Failed to match the given parameters to a valid function signature.");
  2016. lua_error(state);
  2017. }
  2018. break;
  2019. }
  2020. default:
  2021. {
  2022. lua_pushstring(state, "Invalid number of parameters (expected 1 or 2).");
  2023. lua_error(state);
  2024. break;
  2025. }
  2026. }
  2027. return 0;
  2028. }
  2029. int lua_CheckBox_getState(lua_State* state)
  2030. {
  2031. // Get the number of parameters.
  2032. int paramCount = lua_gettop(state);
  2033. // Attempt to match the parameters to a valid binding.
  2034. switch (paramCount)
  2035. {
  2036. case 1:
  2037. {
  2038. if ((lua_type(state, 1) == LUA_TUSERDATA))
  2039. {
  2040. CheckBox* instance = getInstance(state);
  2041. Control::State result = instance->getState();
  2042. // Push the return value onto the stack.
  2043. lua_pushstring(state, lua_stringFromEnum_ControlState(result));
  2044. return 1;
  2045. }
  2046. else
  2047. {
  2048. lua_pushstring(state, "lua_CheckBox_getState - Failed to match the given parameters to a valid function signature.");
  2049. lua_error(state);
  2050. }
  2051. break;
  2052. }
  2053. default:
  2054. {
  2055. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  2056. lua_error(state);
  2057. break;
  2058. }
  2059. }
  2060. return 0;
  2061. }
  2062. int lua_CheckBox_getStyle(lua_State* state)
  2063. {
  2064. // Get the number of parameters.
  2065. int paramCount = lua_gettop(state);
  2066. // Attempt to match the parameters to a valid binding.
  2067. switch (paramCount)
  2068. {
  2069. case 1:
  2070. {
  2071. if ((lua_type(state, 1) == LUA_TUSERDATA))
  2072. {
  2073. CheckBox* instance = getInstance(state);
  2074. void* returnPtr = (void*)instance->getStyle();
  2075. if (returnPtr)
  2076. {
  2077. ScriptUtil::LuaObject* object = (ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(ScriptUtil::LuaObject));
  2078. object->instance = returnPtr;
  2079. object->owns = false;
  2080. luaL_getmetatable(state, "ThemeStyle");
  2081. lua_setmetatable(state, -2);
  2082. }
  2083. else
  2084. {
  2085. lua_pushnil(state);
  2086. }
  2087. return 1;
  2088. }
  2089. else
  2090. {
  2091. lua_pushstring(state, "lua_CheckBox_getStyle - Failed to match the given parameters to a valid function signature.");
  2092. lua_error(state);
  2093. }
  2094. break;
  2095. }
  2096. default:
  2097. {
  2098. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  2099. lua_error(state);
  2100. break;
  2101. }
  2102. }
  2103. return 0;
  2104. }
  2105. int lua_CheckBox_getText(lua_State* state)
  2106. {
  2107. // Get the number of parameters.
  2108. int paramCount = lua_gettop(state);
  2109. // Attempt to match the parameters to a valid binding.
  2110. switch (paramCount)
  2111. {
  2112. case 1:
  2113. {
  2114. if ((lua_type(state, 1) == LUA_TUSERDATA))
  2115. {
  2116. CheckBox* instance = getInstance(state);
  2117. const char* result = instance->getText();
  2118. // Push the return value onto the stack.
  2119. lua_pushstring(state, result);
  2120. return 1;
  2121. }
  2122. else
  2123. {
  2124. lua_pushstring(state, "lua_CheckBox_getText - Failed to match the given parameters to a valid function signature.");
  2125. lua_error(state);
  2126. }
  2127. break;
  2128. }
  2129. default:
  2130. {
  2131. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  2132. lua_error(state);
  2133. break;
  2134. }
  2135. }
  2136. return 0;
  2137. }
  2138. int lua_CheckBox_getTextAlignment(lua_State* state)
  2139. {
  2140. // Get the number of parameters.
  2141. int paramCount = lua_gettop(state);
  2142. // Attempt to match the parameters to a valid binding.
  2143. switch (paramCount)
  2144. {
  2145. case 1:
  2146. {
  2147. if ((lua_type(state, 1) == LUA_TUSERDATA))
  2148. {
  2149. CheckBox* instance = getInstance(state);
  2150. Font::Justify result = instance->getTextAlignment();
  2151. // Push the return value onto the stack.
  2152. lua_pushstring(state, lua_stringFromEnum_FontJustify(result));
  2153. return 1;
  2154. }
  2155. else
  2156. {
  2157. lua_pushstring(state, "lua_CheckBox_getTextAlignment - Failed to match the given parameters to a valid function signature.");
  2158. lua_error(state);
  2159. }
  2160. break;
  2161. }
  2162. case 2:
  2163. {
  2164. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  2165. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL))
  2166. {
  2167. // Get parameter 1 off the stack.
  2168. Control::State param1 = (Control::State)lua_enumFromString_ControlState(luaL_checkstring(state, 2));
  2169. CheckBox* instance = getInstance(state);
  2170. Font::Justify result = instance->getTextAlignment(param1);
  2171. // Push the return value onto the stack.
  2172. lua_pushstring(state, lua_stringFromEnum_FontJustify(result));
  2173. return 1;
  2174. }
  2175. else
  2176. {
  2177. lua_pushstring(state, "lua_CheckBox_getTextAlignment - Failed to match the given parameters to a valid function signature.");
  2178. lua_error(state);
  2179. }
  2180. break;
  2181. }
  2182. default:
  2183. {
  2184. lua_pushstring(state, "Invalid number of parameters (expected 1 or 2).");
  2185. lua_error(state);
  2186. break;
  2187. }
  2188. }
  2189. return 0;
  2190. }
  2191. int lua_CheckBox_getTextColor(lua_State* state)
  2192. {
  2193. // Get the number of parameters.
  2194. int paramCount = lua_gettop(state);
  2195. // Attempt to match the parameters to a valid binding.
  2196. switch (paramCount)
  2197. {
  2198. case 1:
  2199. {
  2200. if ((lua_type(state, 1) == LUA_TUSERDATA))
  2201. {
  2202. CheckBox* instance = getInstance(state);
  2203. void* returnPtr = (void*)&(instance->getTextColor());
  2204. if (returnPtr)
  2205. {
  2206. ScriptUtil::LuaObject* object = (ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(ScriptUtil::LuaObject));
  2207. object->instance = returnPtr;
  2208. object->owns = false;
  2209. luaL_getmetatable(state, "Vector4");
  2210. lua_setmetatable(state, -2);
  2211. }
  2212. else
  2213. {
  2214. lua_pushnil(state);
  2215. }
  2216. return 1;
  2217. }
  2218. else
  2219. {
  2220. lua_pushstring(state, "lua_CheckBox_getTextColor - Failed to match the given parameters to a valid function signature.");
  2221. lua_error(state);
  2222. }
  2223. break;
  2224. }
  2225. case 2:
  2226. {
  2227. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  2228. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL))
  2229. {
  2230. // Get parameter 1 off the stack.
  2231. Control::State param1 = (Control::State)lua_enumFromString_ControlState(luaL_checkstring(state, 2));
  2232. CheckBox* instance = getInstance(state);
  2233. void* returnPtr = (void*)&(instance->getTextColor(param1));
  2234. if (returnPtr)
  2235. {
  2236. ScriptUtil::LuaObject* object = (ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(ScriptUtil::LuaObject));
  2237. object->instance = returnPtr;
  2238. object->owns = false;
  2239. luaL_getmetatable(state, "Vector4");
  2240. lua_setmetatable(state, -2);
  2241. }
  2242. else
  2243. {
  2244. lua_pushnil(state);
  2245. }
  2246. return 1;
  2247. }
  2248. else
  2249. {
  2250. lua_pushstring(state, "lua_CheckBox_getTextColor - Failed to match the given parameters to a valid function signature.");
  2251. lua_error(state);
  2252. }
  2253. break;
  2254. }
  2255. default:
  2256. {
  2257. lua_pushstring(state, "Invalid number of parameters (expected 1 or 2).");
  2258. lua_error(state);
  2259. break;
  2260. }
  2261. }
  2262. return 0;
  2263. }
  2264. int lua_CheckBox_getTextRightToLeft(lua_State* state)
  2265. {
  2266. // Get the number of parameters.
  2267. int paramCount = lua_gettop(state);
  2268. // Attempt to match the parameters to a valid binding.
  2269. switch (paramCount)
  2270. {
  2271. case 1:
  2272. {
  2273. if ((lua_type(state, 1) == LUA_TUSERDATA))
  2274. {
  2275. CheckBox* instance = getInstance(state);
  2276. bool result = instance->getTextRightToLeft();
  2277. // Push the return value onto the stack.
  2278. lua_pushboolean(state, result);
  2279. return 1;
  2280. }
  2281. else
  2282. {
  2283. lua_pushstring(state, "lua_CheckBox_getTextRightToLeft - Failed to match the given parameters to a valid function signature.");
  2284. lua_error(state);
  2285. }
  2286. break;
  2287. }
  2288. case 2:
  2289. {
  2290. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  2291. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL))
  2292. {
  2293. // Get parameter 1 off the stack.
  2294. Control::State param1 = (Control::State)lua_enumFromString_ControlState(luaL_checkstring(state, 2));
  2295. CheckBox* instance = getInstance(state);
  2296. bool result = instance->getTextRightToLeft(param1);
  2297. // Push the return value onto the stack.
  2298. lua_pushboolean(state, result);
  2299. return 1;
  2300. }
  2301. else
  2302. {
  2303. lua_pushstring(state, "lua_CheckBox_getTextRightToLeft - Failed to match the given parameters to a valid function signature.");
  2304. lua_error(state);
  2305. }
  2306. break;
  2307. }
  2308. default:
  2309. {
  2310. lua_pushstring(state, "Invalid number of parameters (expected 1 or 2).");
  2311. lua_error(state);
  2312. break;
  2313. }
  2314. }
  2315. return 0;
  2316. }
  2317. int lua_CheckBox_getType(lua_State* state)
  2318. {
  2319. // Get the number of parameters.
  2320. int paramCount = lua_gettop(state);
  2321. // Attempt to match the parameters to a valid binding.
  2322. switch (paramCount)
  2323. {
  2324. case 1:
  2325. {
  2326. if ((lua_type(state, 1) == LUA_TUSERDATA))
  2327. {
  2328. CheckBox* instance = getInstance(state);
  2329. const char* result = instance->getType();
  2330. // Push the return value onto the stack.
  2331. lua_pushstring(state, result);
  2332. return 1;
  2333. }
  2334. else
  2335. {
  2336. lua_pushstring(state, "lua_CheckBox_getType - Failed to match the given parameters to a valid function signature.");
  2337. lua_error(state);
  2338. }
  2339. break;
  2340. }
  2341. default:
  2342. {
  2343. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  2344. lua_error(state);
  2345. break;
  2346. }
  2347. }
  2348. return 0;
  2349. }
  2350. int lua_CheckBox_getWidth(lua_State* state)
  2351. {
  2352. // Get the number of parameters.
  2353. int paramCount = lua_gettop(state);
  2354. // Attempt to match the parameters to a valid binding.
  2355. switch (paramCount)
  2356. {
  2357. case 1:
  2358. {
  2359. if ((lua_type(state, 1) == LUA_TUSERDATA))
  2360. {
  2361. CheckBox* instance = getInstance(state);
  2362. float result = instance->getWidth();
  2363. // Push the return value onto the stack.
  2364. lua_pushnumber(state, result);
  2365. return 1;
  2366. }
  2367. else
  2368. {
  2369. lua_pushstring(state, "lua_CheckBox_getWidth - Failed to match the given parameters to a valid function signature.");
  2370. lua_error(state);
  2371. }
  2372. break;
  2373. }
  2374. default:
  2375. {
  2376. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  2377. lua_error(state);
  2378. break;
  2379. }
  2380. }
  2381. return 0;
  2382. }
  2383. int lua_CheckBox_getX(lua_State* state)
  2384. {
  2385. // Get the number of parameters.
  2386. int paramCount = lua_gettop(state);
  2387. // Attempt to match the parameters to a valid binding.
  2388. switch (paramCount)
  2389. {
  2390. case 1:
  2391. {
  2392. if ((lua_type(state, 1) == LUA_TUSERDATA))
  2393. {
  2394. CheckBox* instance = getInstance(state);
  2395. float result = instance->getX();
  2396. // Push the return value onto the stack.
  2397. lua_pushnumber(state, result);
  2398. return 1;
  2399. }
  2400. else
  2401. {
  2402. lua_pushstring(state, "lua_CheckBox_getX - Failed to match the given parameters to a valid function signature.");
  2403. lua_error(state);
  2404. }
  2405. break;
  2406. }
  2407. default:
  2408. {
  2409. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  2410. lua_error(state);
  2411. break;
  2412. }
  2413. }
  2414. return 0;
  2415. }
  2416. int lua_CheckBox_getY(lua_State* state)
  2417. {
  2418. // Get the number of parameters.
  2419. int paramCount = lua_gettop(state);
  2420. // Attempt to match the parameters to a valid binding.
  2421. switch (paramCount)
  2422. {
  2423. case 1:
  2424. {
  2425. if ((lua_type(state, 1) == LUA_TUSERDATA))
  2426. {
  2427. CheckBox* instance = getInstance(state);
  2428. float result = instance->getY();
  2429. // Push the return value onto the stack.
  2430. lua_pushnumber(state, result);
  2431. return 1;
  2432. }
  2433. else
  2434. {
  2435. lua_pushstring(state, "lua_CheckBox_getY - Failed to match the given parameters to a valid function signature.");
  2436. lua_error(state);
  2437. }
  2438. break;
  2439. }
  2440. default:
  2441. {
  2442. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  2443. lua_error(state);
  2444. break;
  2445. }
  2446. }
  2447. return 0;
  2448. }
  2449. int lua_CheckBox_getZIndex(lua_State* state)
  2450. {
  2451. // Get the number of parameters.
  2452. int paramCount = lua_gettop(state);
  2453. // Attempt to match the parameters to a valid binding.
  2454. switch (paramCount)
  2455. {
  2456. case 1:
  2457. {
  2458. if ((lua_type(state, 1) == LUA_TUSERDATA))
  2459. {
  2460. CheckBox* instance = getInstance(state);
  2461. int result = instance->getZIndex();
  2462. // Push the return value onto the stack.
  2463. lua_pushinteger(state, result);
  2464. return 1;
  2465. }
  2466. else
  2467. {
  2468. lua_pushstring(state, "lua_CheckBox_getZIndex - Failed to match the given parameters to a valid function signature.");
  2469. lua_error(state);
  2470. }
  2471. break;
  2472. }
  2473. default:
  2474. {
  2475. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  2476. lua_error(state);
  2477. break;
  2478. }
  2479. }
  2480. return 0;
  2481. }
  2482. int lua_CheckBox_isChecked(lua_State* state)
  2483. {
  2484. // Get the number of parameters.
  2485. int paramCount = lua_gettop(state);
  2486. // Attempt to match the parameters to a valid binding.
  2487. switch (paramCount)
  2488. {
  2489. case 1:
  2490. {
  2491. if ((lua_type(state, 1) == LUA_TUSERDATA))
  2492. {
  2493. CheckBox* instance = getInstance(state);
  2494. bool result = instance->isChecked();
  2495. // Push the return value onto the stack.
  2496. lua_pushboolean(state, result);
  2497. return 1;
  2498. }
  2499. else
  2500. {
  2501. lua_pushstring(state, "lua_CheckBox_isChecked - Failed to match the given parameters to a valid function signature.");
  2502. lua_error(state);
  2503. }
  2504. break;
  2505. }
  2506. default:
  2507. {
  2508. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  2509. lua_error(state);
  2510. break;
  2511. }
  2512. }
  2513. return 0;
  2514. }
  2515. int lua_CheckBox_isContainer(lua_State* state)
  2516. {
  2517. // Get the number of parameters.
  2518. int paramCount = lua_gettop(state);
  2519. // Attempt to match the parameters to a valid binding.
  2520. switch (paramCount)
  2521. {
  2522. case 1:
  2523. {
  2524. if ((lua_type(state, 1) == LUA_TUSERDATA))
  2525. {
  2526. CheckBox* instance = getInstance(state);
  2527. bool result = instance->isContainer();
  2528. // Push the return value onto the stack.
  2529. lua_pushboolean(state, result);
  2530. return 1;
  2531. }
  2532. else
  2533. {
  2534. lua_pushstring(state, "lua_CheckBox_isContainer - Failed to match the given parameters to a valid function signature.");
  2535. lua_error(state);
  2536. }
  2537. break;
  2538. }
  2539. default:
  2540. {
  2541. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  2542. lua_error(state);
  2543. break;
  2544. }
  2545. }
  2546. return 0;
  2547. }
  2548. int lua_CheckBox_isEnabled(lua_State* state)
  2549. {
  2550. // Get the number of parameters.
  2551. int paramCount = lua_gettop(state);
  2552. // Attempt to match the parameters to a valid binding.
  2553. switch (paramCount)
  2554. {
  2555. case 1:
  2556. {
  2557. if ((lua_type(state, 1) == LUA_TUSERDATA))
  2558. {
  2559. CheckBox* instance = getInstance(state);
  2560. bool result = instance->isEnabled();
  2561. // Push the return value onto the stack.
  2562. lua_pushboolean(state, result);
  2563. return 1;
  2564. }
  2565. else
  2566. {
  2567. lua_pushstring(state, "lua_CheckBox_isEnabled - Failed to match the given parameters to a valid function signature.");
  2568. lua_error(state);
  2569. }
  2570. break;
  2571. }
  2572. default:
  2573. {
  2574. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  2575. lua_error(state);
  2576. break;
  2577. }
  2578. }
  2579. return 0;
  2580. }
  2581. int lua_CheckBox_release(lua_State* state)
  2582. {
  2583. // Get the number of parameters.
  2584. int paramCount = lua_gettop(state);
  2585. // Attempt to match the parameters to a valid binding.
  2586. switch (paramCount)
  2587. {
  2588. case 1:
  2589. {
  2590. if ((lua_type(state, 1) == LUA_TUSERDATA))
  2591. {
  2592. CheckBox* instance = getInstance(state);
  2593. instance->release();
  2594. return 0;
  2595. }
  2596. else
  2597. {
  2598. lua_pushstring(state, "lua_CheckBox_release - Failed to match the given parameters to a valid function signature.");
  2599. lua_error(state);
  2600. }
  2601. break;
  2602. }
  2603. default:
  2604. {
  2605. lua_pushstring(state, "Invalid number of parameters (expected 1).");
  2606. lua_error(state);
  2607. break;
  2608. }
  2609. }
  2610. return 0;
  2611. }
  2612. int lua_CheckBox_removeScriptCallback(lua_State* state)
  2613. {
  2614. // Get the number of parameters.
  2615. int paramCount = lua_gettop(state);
  2616. // Attempt to match the parameters to a valid binding.
  2617. switch (paramCount)
  2618. {
  2619. case 3:
  2620. {
  2621. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  2622. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL) &&
  2623. (lua_type(state, 3) == LUA_TSTRING || lua_type(state, 3) == LUA_TNIL))
  2624. {
  2625. // Get parameter 1 off the stack.
  2626. std::string param1 = ScriptUtil::getString(2, true);
  2627. // Get parameter 2 off the stack.
  2628. std::string param2 = ScriptUtil::getString(3, true);
  2629. CheckBox* instance = getInstance(state);
  2630. instance->removeScriptCallback(param1, param2);
  2631. return 0;
  2632. }
  2633. else
  2634. {
  2635. lua_pushstring(state, "lua_CheckBox_removeScriptCallback - Failed to match the given parameters to a valid function signature.");
  2636. lua_error(state);
  2637. }
  2638. break;
  2639. }
  2640. default:
  2641. {
  2642. lua_pushstring(state, "Invalid number of parameters (expected 3).");
  2643. lua_error(state);
  2644. break;
  2645. }
  2646. }
  2647. return 0;
  2648. }
  2649. int lua_CheckBox_setAlignment(lua_State* state)
  2650. {
  2651. // Get the number of parameters.
  2652. int paramCount = lua_gettop(state);
  2653. // Attempt to match the parameters to a valid binding.
  2654. switch (paramCount)
  2655. {
  2656. case 2:
  2657. {
  2658. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  2659. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL))
  2660. {
  2661. // Get parameter 1 off the stack.
  2662. Control::Alignment param1 = (Control::Alignment)lua_enumFromString_ControlAlignment(luaL_checkstring(state, 2));
  2663. CheckBox* instance = getInstance(state);
  2664. instance->setAlignment(param1);
  2665. return 0;
  2666. }
  2667. else
  2668. {
  2669. lua_pushstring(state, "lua_CheckBox_setAlignment - Failed to match the given parameters to a valid function signature.");
  2670. lua_error(state);
  2671. }
  2672. break;
  2673. }
  2674. default:
  2675. {
  2676. lua_pushstring(state, "Invalid number of parameters (expected 2).");
  2677. lua_error(state);
  2678. break;
  2679. }
  2680. }
  2681. return 0;
  2682. }
  2683. int lua_CheckBox_setAnimationPropertyValue(lua_State* state)
  2684. {
  2685. // Get the number of parameters.
  2686. int paramCount = lua_gettop(state);
  2687. // Attempt to match the parameters to a valid binding.
  2688. switch (paramCount)
  2689. {
  2690. case 3:
  2691. {
  2692. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  2693. lua_type(state, 2) == LUA_TNUMBER &&
  2694. (lua_type(state, 3) == LUA_TUSERDATA || lua_type(state, 3) == LUA_TTABLE || lua_type(state, 3) == LUA_TNIL))
  2695. {
  2696. // Get parameter 1 off the stack.
  2697. int param1 = (int)luaL_checkint(state, 2);
  2698. // Get parameter 2 off the stack.
  2699. ScriptUtil::LuaArray<AnimationValue> param2 = ScriptUtil::getObjectPointer<AnimationValue>(3, "AnimationValue", false);
  2700. CheckBox* instance = getInstance(state);
  2701. instance->setAnimationPropertyValue(param1, param2);
  2702. return 0;
  2703. }
  2704. else
  2705. {
  2706. lua_pushstring(state, "lua_CheckBox_setAnimationPropertyValue - Failed to match the given parameters to a valid function signature.");
  2707. lua_error(state);
  2708. }
  2709. break;
  2710. }
  2711. case 4:
  2712. {
  2713. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  2714. lua_type(state, 2) == LUA_TNUMBER &&
  2715. (lua_type(state, 3) == LUA_TUSERDATA || lua_type(state, 3) == LUA_TTABLE || lua_type(state, 3) == LUA_TNIL) &&
  2716. lua_type(state, 4) == LUA_TNUMBER)
  2717. {
  2718. // Get parameter 1 off the stack.
  2719. int param1 = (int)luaL_checkint(state, 2);
  2720. // Get parameter 2 off the stack.
  2721. ScriptUtil::LuaArray<AnimationValue> param2 = ScriptUtil::getObjectPointer<AnimationValue>(3, "AnimationValue", false);
  2722. // Get parameter 3 off the stack.
  2723. float param3 = (float)luaL_checknumber(state, 4);
  2724. CheckBox* instance = getInstance(state);
  2725. instance->setAnimationPropertyValue(param1, param2, param3);
  2726. return 0;
  2727. }
  2728. else
  2729. {
  2730. lua_pushstring(state, "lua_CheckBox_setAnimationPropertyValue - Failed to match the given parameters to a valid function signature.");
  2731. lua_error(state);
  2732. }
  2733. break;
  2734. }
  2735. default:
  2736. {
  2737. lua_pushstring(state, "Invalid number of parameters (expected 3 or 4).");
  2738. lua_error(state);
  2739. break;
  2740. }
  2741. }
  2742. return 0;
  2743. }
  2744. int lua_CheckBox_setAutoHeight(lua_State* state)
  2745. {
  2746. // Get the number of parameters.
  2747. int paramCount = lua_gettop(state);
  2748. // Attempt to match the parameters to a valid binding.
  2749. switch (paramCount)
  2750. {
  2751. case 2:
  2752. {
  2753. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  2754. lua_type(state, 2) == LUA_TBOOLEAN)
  2755. {
  2756. // Get parameter 1 off the stack.
  2757. bool param1 = ScriptUtil::luaCheckBool(state, 2);
  2758. CheckBox* instance = getInstance(state);
  2759. instance->setAutoHeight(param1);
  2760. return 0;
  2761. }
  2762. else
  2763. {
  2764. lua_pushstring(state, "lua_CheckBox_setAutoHeight - Failed to match the given parameters to a valid function signature.");
  2765. lua_error(state);
  2766. }
  2767. break;
  2768. }
  2769. default:
  2770. {
  2771. lua_pushstring(state, "Invalid number of parameters (expected 2).");
  2772. lua_error(state);
  2773. break;
  2774. }
  2775. }
  2776. return 0;
  2777. }
  2778. int lua_CheckBox_setAutoWidth(lua_State* state)
  2779. {
  2780. // Get the number of parameters.
  2781. int paramCount = lua_gettop(state);
  2782. // Attempt to match the parameters to a valid binding.
  2783. switch (paramCount)
  2784. {
  2785. case 2:
  2786. {
  2787. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  2788. lua_type(state, 2) == LUA_TBOOLEAN)
  2789. {
  2790. // Get parameter 1 off the stack.
  2791. bool param1 = ScriptUtil::luaCheckBool(state, 2);
  2792. CheckBox* instance = getInstance(state);
  2793. instance->setAutoWidth(param1);
  2794. return 0;
  2795. }
  2796. else
  2797. {
  2798. lua_pushstring(state, "lua_CheckBox_setAutoWidth - Failed to match the given parameters to a valid function signature.");
  2799. lua_error(state);
  2800. }
  2801. break;
  2802. }
  2803. default:
  2804. {
  2805. lua_pushstring(state, "Invalid number of parameters (expected 2).");
  2806. lua_error(state);
  2807. break;
  2808. }
  2809. }
  2810. return 0;
  2811. }
  2812. int lua_CheckBox_setBorder(lua_State* state)
  2813. {
  2814. // Get the number of parameters.
  2815. int paramCount = lua_gettop(state);
  2816. // Attempt to match the parameters to a valid binding.
  2817. switch (paramCount)
  2818. {
  2819. case 5:
  2820. {
  2821. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  2822. lua_type(state, 2) == LUA_TNUMBER &&
  2823. lua_type(state, 3) == LUA_TNUMBER &&
  2824. lua_type(state, 4) == LUA_TNUMBER &&
  2825. lua_type(state, 5) == LUA_TNUMBER)
  2826. {
  2827. // Get parameter 1 off the stack.
  2828. float param1 = (float)luaL_checknumber(state, 2);
  2829. // Get parameter 2 off the stack.
  2830. float param2 = (float)luaL_checknumber(state, 3);
  2831. // Get parameter 3 off the stack.
  2832. float param3 = (float)luaL_checknumber(state, 4);
  2833. // Get parameter 4 off the stack.
  2834. float param4 = (float)luaL_checknumber(state, 5);
  2835. CheckBox* instance = getInstance(state);
  2836. instance->setBorder(param1, param2, param3, param4);
  2837. return 0;
  2838. }
  2839. else
  2840. {
  2841. lua_pushstring(state, "lua_CheckBox_setBorder - Failed to match the given parameters to a valid function signature.");
  2842. lua_error(state);
  2843. }
  2844. break;
  2845. }
  2846. case 6:
  2847. {
  2848. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  2849. lua_type(state, 2) == LUA_TNUMBER &&
  2850. lua_type(state, 3) == LUA_TNUMBER &&
  2851. lua_type(state, 4) == LUA_TNUMBER &&
  2852. lua_type(state, 5) == LUA_TNUMBER &&
  2853. lua_type(state, 6) == LUA_TNUMBER)
  2854. {
  2855. // Get parameter 1 off the stack.
  2856. float param1 = (float)luaL_checknumber(state, 2);
  2857. // Get parameter 2 off the stack.
  2858. float param2 = (float)luaL_checknumber(state, 3);
  2859. // Get parameter 3 off the stack.
  2860. float param3 = (float)luaL_checknumber(state, 4);
  2861. // Get parameter 4 off the stack.
  2862. float param4 = (float)luaL_checknumber(state, 5);
  2863. // Get parameter 5 off the stack.
  2864. unsigned char param5 = (unsigned char)luaL_checkunsigned(state, 6);
  2865. CheckBox* instance = getInstance(state);
  2866. instance->setBorder(param1, param2, param3, param4, param5);
  2867. return 0;
  2868. }
  2869. else
  2870. {
  2871. lua_pushstring(state, "lua_CheckBox_setBorder - Failed to match the given parameters to a valid function signature.");
  2872. lua_error(state);
  2873. }
  2874. break;
  2875. }
  2876. default:
  2877. {
  2878. lua_pushstring(state, "Invalid number of parameters (expected 5 or 6).");
  2879. lua_error(state);
  2880. break;
  2881. }
  2882. }
  2883. return 0;
  2884. }
  2885. int lua_CheckBox_setBounds(lua_State* state)
  2886. {
  2887. // Get the number of parameters.
  2888. int paramCount = lua_gettop(state);
  2889. // Attempt to match the parameters to a valid binding.
  2890. switch (paramCount)
  2891. {
  2892. case 2:
  2893. {
  2894. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  2895. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TNIL))
  2896. {
  2897. // Get parameter 1 off the stack.
  2898. ScriptUtil::LuaArray<Rectangle> param1 = ScriptUtil::getObjectPointer<Rectangle>(2, "Rectangle", true);
  2899. CheckBox* instance = getInstance(state);
  2900. instance->setBounds(*param1);
  2901. return 0;
  2902. }
  2903. else
  2904. {
  2905. lua_pushstring(state, "lua_CheckBox_setBounds - Failed to match the given parameters to a valid function signature.");
  2906. lua_error(state);
  2907. }
  2908. break;
  2909. }
  2910. default:
  2911. {
  2912. lua_pushstring(state, "Invalid number of parameters (expected 2).");
  2913. lua_error(state);
  2914. break;
  2915. }
  2916. }
  2917. return 0;
  2918. }
  2919. int lua_CheckBox_setChecked(lua_State* state)
  2920. {
  2921. // Get the number of parameters.
  2922. int paramCount = lua_gettop(state);
  2923. // Attempt to match the parameters to a valid binding.
  2924. switch (paramCount)
  2925. {
  2926. case 2:
  2927. {
  2928. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  2929. lua_type(state, 2) == LUA_TBOOLEAN)
  2930. {
  2931. // Get parameter 1 off the stack.
  2932. bool param1 = ScriptUtil::luaCheckBool(state, 2);
  2933. CheckBox* instance = getInstance(state);
  2934. instance->setChecked(param1);
  2935. return 0;
  2936. }
  2937. else
  2938. {
  2939. lua_pushstring(state, "lua_CheckBox_setChecked - Failed to match the given parameters to a valid function signature.");
  2940. lua_error(state);
  2941. }
  2942. break;
  2943. }
  2944. default:
  2945. {
  2946. lua_pushstring(state, "Invalid number of parameters (expected 2).");
  2947. lua_error(state);
  2948. break;
  2949. }
  2950. }
  2951. return 0;
  2952. }
  2953. int lua_CheckBox_setConsumeInputEvents(lua_State* state)
  2954. {
  2955. // Get the number of parameters.
  2956. int paramCount = lua_gettop(state);
  2957. // Attempt to match the parameters to a valid binding.
  2958. switch (paramCount)
  2959. {
  2960. case 2:
  2961. {
  2962. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  2963. lua_type(state, 2) == LUA_TBOOLEAN)
  2964. {
  2965. // Get parameter 1 off the stack.
  2966. bool param1 = ScriptUtil::luaCheckBool(state, 2);
  2967. CheckBox* instance = getInstance(state);
  2968. instance->setConsumeInputEvents(param1);
  2969. return 0;
  2970. }
  2971. else
  2972. {
  2973. lua_pushstring(state, "lua_CheckBox_setConsumeInputEvents - Failed to match the given parameters to a valid function signature.");
  2974. lua_error(state);
  2975. }
  2976. break;
  2977. }
  2978. default:
  2979. {
  2980. lua_pushstring(state, "Invalid number of parameters (expected 2).");
  2981. lua_error(state);
  2982. break;
  2983. }
  2984. }
  2985. return 0;
  2986. }
  2987. int lua_CheckBox_setCursorColor(lua_State* state)
  2988. {
  2989. // Get the number of parameters.
  2990. int paramCount = lua_gettop(state);
  2991. // Attempt to match the parameters to a valid binding.
  2992. switch (paramCount)
  2993. {
  2994. case 3:
  2995. {
  2996. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  2997. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TNIL) &&
  2998. lua_type(state, 3) == LUA_TNUMBER)
  2999. {
  3000. // Get parameter 1 off the stack.
  3001. ScriptUtil::LuaArray<Vector4> param1 = ScriptUtil::getObjectPointer<Vector4>(2, "Vector4", true);
  3002. // Get parameter 2 off the stack.
  3003. unsigned char param2 = (unsigned char)luaL_checkunsigned(state, 3);
  3004. CheckBox* instance = getInstance(state);
  3005. instance->setCursorColor(*param1, param2);
  3006. return 0;
  3007. }
  3008. else
  3009. {
  3010. lua_pushstring(state, "lua_CheckBox_setCursorColor - Failed to match the given parameters to a valid function signature.");
  3011. lua_error(state);
  3012. }
  3013. break;
  3014. }
  3015. default:
  3016. {
  3017. lua_pushstring(state, "Invalid number of parameters (expected 3).");
  3018. lua_error(state);
  3019. break;
  3020. }
  3021. }
  3022. return 0;
  3023. }
  3024. int lua_CheckBox_setCursorRegion(lua_State* state)
  3025. {
  3026. // Get the number of parameters.
  3027. int paramCount = lua_gettop(state);
  3028. // Attempt to match the parameters to a valid binding.
  3029. switch (paramCount)
  3030. {
  3031. case 3:
  3032. {
  3033. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  3034. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TNIL) &&
  3035. lua_type(state, 3) == LUA_TNUMBER)
  3036. {
  3037. // Get parameter 1 off the stack.
  3038. ScriptUtil::LuaArray<Rectangle> param1 = ScriptUtil::getObjectPointer<Rectangle>(2, "Rectangle", true);
  3039. // Get parameter 2 off the stack.
  3040. unsigned char param2 = (unsigned char)luaL_checkunsigned(state, 3);
  3041. CheckBox* instance = getInstance(state);
  3042. instance->setCursorRegion(*param1, param2);
  3043. return 0;
  3044. }
  3045. else
  3046. {
  3047. lua_pushstring(state, "lua_CheckBox_setCursorRegion - Failed to match the given parameters to a valid function signature.");
  3048. lua_error(state);
  3049. }
  3050. break;
  3051. }
  3052. default:
  3053. {
  3054. lua_pushstring(state, "Invalid number of parameters (expected 3).");
  3055. lua_error(state);
  3056. break;
  3057. }
  3058. }
  3059. return 0;
  3060. }
  3061. int lua_CheckBox_setFocusIndex(lua_State* state)
  3062. {
  3063. // Get the number of parameters.
  3064. int paramCount = lua_gettop(state);
  3065. // Attempt to match the parameters to a valid binding.
  3066. switch (paramCount)
  3067. {
  3068. case 2:
  3069. {
  3070. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  3071. lua_type(state, 2) == LUA_TNUMBER)
  3072. {
  3073. // Get parameter 1 off the stack.
  3074. int param1 = (int)luaL_checkint(state, 2);
  3075. CheckBox* instance = getInstance(state);
  3076. instance->setFocusIndex(param1);
  3077. return 0;
  3078. }
  3079. else
  3080. {
  3081. lua_pushstring(state, "lua_CheckBox_setFocusIndex - Failed to match the given parameters to a valid function signature.");
  3082. lua_error(state);
  3083. }
  3084. break;
  3085. }
  3086. default:
  3087. {
  3088. lua_pushstring(state, "Invalid number of parameters (expected 2).");
  3089. lua_error(state);
  3090. break;
  3091. }
  3092. }
  3093. return 0;
  3094. }
  3095. int lua_CheckBox_setFont(lua_State* state)
  3096. {
  3097. // Get the number of parameters.
  3098. int paramCount = lua_gettop(state);
  3099. // Attempt to match the parameters to a valid binding.
  3100. switch (paramCount)
  3101. {
  3102. case 2:
  3103. {
  3104. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  3105. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TTABLE || lua_type(state, 2) == LUA_TNIL))
  3106. {
  3107. // Get parameter 1 off the stack.
  3108. ScriptUtil::LuaArray<Font> param1 = ScriptUtil::getObjectPointer<Font>(2, "Font", false);
  3109. CheckBox* instance = getInstance(state);
  3110. instance->setFont(param1);
  3111. return 0;
  3112. }
  3113. else
  3114. {
  3115. lua_pushstring(state, "lua_CheckBox_setFont - Failed to match the given parameters to a valid function signature.");
  3116. lua_error(state);
  3117. }
  3118. break;
  3119. }
  3120. case 3:
  3121. {
  3122. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  3123. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TTABLE || lua_type(state, 2) == LUA_TNIL) &&
  3124. lua_type(state, 3) == LUA_TNUMBER)
  3125. {
  3126. // Get parameter 1 off the stack.
  3127. ScriptUtil::LuaArray<Font> param1 = ScriptUtil::getObjectPointer<Font>(2, "Font", false);
  3128. // Get parameter 2 off the stack.
  3129. unsigned char param2 = (unsigned char)luaL_checkunsigned(state, 3);
  3130. CheckBox* instance = getInstance(state);
  3131. instance->setFont(param1, param2);
  3132. return 0;
  3133. }
  3134. else
  3135. {
  3136. lua_pushstring(state, "lua_CheckBox_setFont - Failed to match the given parameters to a valid function signature.");
  3137. lua_error(state);
  3138. }
  3139. break;
  3140. }
  3141. default:
  3142. {
  3143. lua_pushstring(state, "Invalid number of parameters (expected 2 or 3).");
  3144. lua_error(state);
  3145. break;
  3146. }
  3147. }
  3148. return 0;
  3149. }
  3150. int lua_CheckBox_setFontSize(lua_State* state)
  3151. {
  3152. // Get the number of parameters.
  3153. int paramCount = lua_gettop(state);
  3154. // Attempt to match the parameters to a valid binding.
  3155. switch (paramCount)
  3156. {
  3157. case 2:
  3158. {
  3159. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  3160. lua_type(state, 2) == LUA_TNUMBER)
  3161. {
  3162. // Get parameter 1 off the stack.
  3163. unsigned int param1 = (unsigned int)luaL_checkunsigned(state, 2);
  3164. CheckBox* instance = getInstance(state);
  3165. instance->setFontSize(param1);
  3166. return 0;
  3167. }
  3168. else
  3169. {
  3170. lua_pushstring(state, "lua_CheckBox_setFontSize - Failed to match the given parameters to a valid function signature.");
  3171. lua_error(state);
  3172. }
  3173. break;
  3174. }
  3175. case 3:
  3176. {
  3177. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  3178. lua_type(state, 2) == LUA_TNUMBER &&
  3179. lua_type(state, 3) == LUA_TNUMBER)
  3180. {
  3181. // Get parameter 1 off the stack.
  3182. unsigned int param1 = (unsigned int)luaL_checkunsigned(state, 2);
  3183. // Get parameter 2 off the stack.
  3184. unsigned char param2 = (unsigned char)luaL_checkunsigned(state, 3);
  3185. CheckBox* instance = getInstance(state);
  3186. instance->setFontSize(param1, param2);
  3187. return 0;
  3188. }
  3189. else
  3190. {
  3191. lua_pushstring(state, "lua_CheckBox_setFontSize - Failed to match the given parameters to a valid function signature.");
  3192. lua_error(state);
  3193. }
  3194. break;
  3195. }
  3196. default:
  3197. {
  3198. lua_pushstring(state, "Invalid number of parameters (expected 2 or 3).");
  3199. lua_error(state);
  3200. break;
  3201. }
  3202. }
  3203. return 0;
  3204. }
  3205. int lua_CheckBox_setImageColor(lua_State* state)
  3206. {
  3207. // Get the number of parameters.
  3208. int paramCount = lua_gettop(state);
  3209. // Attempt to match the parameters to a valid binding.
  3210. switch (paramCount)
  3211. {
  3212. case 3:
  3213. {
  3214. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  3215. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL) &&
  3216. (lua_type(state, 3) == LUA_TUSERDATA || lua_type(state, 3) == LUA_TNIL))
  3217. {
  3218. // Get parameter 1 off the stack.
  3219. ScriptUtil::LuaArray<const char> param1 = ScriptUtil::getString(2, false);
  3220. // Get parameter 2 off the stack.
  3221. ScriptUtil::LuaArray<Vector4> param2 = ScriptUtil::getObjectPointer<Vector4>(3, "Vector4", true);
  3222. CheckBox* instance = getInstance(state);
  3223. instance->setImageColor(param1, *param2);
  3224. return 0;
  3225. }
  3226. else
  3227. {
  3228. lua_pushstring(state, "lua_CheckBox_setImageColor - Failed to match the given parameters to a valid function signature.");
  3229. lua_error(state);
  3230. }
  3231. break;
  3232. }
  3233. case 4:
  3234. {
  3235. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  3236. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL) &&
  3237. (lua_type(state, 3) == LUA_TUSERDATA || lua_type(state, 3) == LUA_TNIL) &&
  3238. lua_type(state, 4) == LUA_TNUMBER)
  3239. {
  3240. // Get parameter 1 off the stack.
  3241. ScriptUtil::LuaArray<const char> param1 = ScriptUtil::getString(2, false);
  3242. // Get parameter 2 off the stack.
  3243. ScriptUtil::LuaArray<Vector4> param2 = ScriptUtil::getObjectPointer<Vector4>(3, "Vector4", true);
  3244. // Get parameter 3 off the stack.
  3245. unsigned char param3 = (unsigned char)luaL_checkunsigned(state, 4);
  3246. CheckBox* instance = getInstance(state);
  3247. instance->setImageColor(param1, *param2, param3);
  3248. return 0;
  3249. }
  3250. else
  3251. {
  3252. lua_pushstring(state, "lua_CheckBox_setImageColor - Failed to match the given parameters to a valid function signature.");
  3253. lua_error(state);
  3254. }
  3255. break;
  3256. }
  3257. default:
  3258. {
  3259. lua_pushstring(state, "Invalid number of parameters (expected 3 or 4).");
  3260. lua_error(state);
  3261. break;
  3262. }
  3263. }
  3264. return 0;
  3265. }
  3266. int lua_CheckBox_setImageRegion(lua_State* state)
  3267. {
  3268. // Get the number of parameters.
  3269. int paramCount = lua_gettop(state);
  3270. // Attempt to match the parameters to a valid binding.
  3271. switch (paramCount)
  3272. {
  3273. case 3:
  3274. {
  3275. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  3276. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL) &&
  3277. (lua_type(state, 3) == LUA_TUSERDATA || lua_type(state, 3) == LUA_TNIL))
  3278. {
  3279. // Get parameter 1 off the stack.
  3280. ScriptUtil::LuaArray<const char> param1 = ScriptUtil::getString(2, false);
  3281. // Get parameter 2 off the stack.
  3282. ScriptUtil::LuaArray<Rectangle> param2 = ScriptUtil::getObjectPointer<Rectangle>(3, "Rectangle", true);
  3283. CheckBox* instance = getInstance(state);
  3284. instance->setImageRegion(param1, *param2);
  3285. return 0;
  3286. }
  3287. else
  3288. {
  3289. lua_pushstring(state, "lua_CheckBox_setImageRegion - Failed to match the given parameters to a valid function signature.");
  3290. lua_error(state);
  3291. }
  3292. break;
  3293. }
  3294. case 4:
  3295. {
  3296. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  3297. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL) &&
  3298. (lua_type(state, 3) == LUA_TUSERDATA || lua_type(state, 3) == LUA_TNIL) &&
  3299. lua_type(state, 4) == LUA_TNUMBER)
  3300. {
  3301. // Get parameter 1 off the stack.
  3302. ScriptUtil::LuaArray<const char> param1 = ScriptUtil::getString(2, false);
  3303. // Get parameter 2 off the stack.
  3304. ScriptUtil::LuaArray<Rectangle> param2 = ScriptUtil::getObjectPointer<Rectangle>(3, "Rectangle", true);
  3305. // Get parameter 3 off the stack.
  3306. unsigned char param3 = (unsigned char)luaL_checkunsigned(state, 4);
  3307. CheckBox* instance = getInstance(state);
  3308. instance->setImageRegion(param1, *param2, param3);
  3309. return 0;
  3310. }
  3311. else
  3312. {
  3313. lua_pushstring(state, "lua_CheckBox_setImageRegion - Failed to match the given parameters to a valid function signature.");
  3314. lua_error(state);
  3315. }
  3316. break;
  3317. }
  3318. default:
  3319. {
  3320. lua_pushstring(state, "Invalid number of parameters (expected 3 or 4).");
  3321. lua_error(state);
  3322. break;
  3323. }
  3324. }
  3325. return 0;
  3326. }
  3327. int lua_CheckBox_setImageSize(lua_State* state)
  3328. {
  3329. // Get the number of parameters.
  3330. int paramCount = lua_gettop(state);
  3331. // Attempt to match the parameters to a valid binding.
  3332. switch (paramCount)
  3333. {
  3334. case 3:
  3335. {
  3336. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  3337. lua_type(state, 2) == LUA_TNUMBER &&
  3338. lua_type(state, 3) == LUA_TNUMBER)
  3339. {
  3340. // Get parameter 1 off the stack.
  3341. float param1 = (float)luaL_checknumber(state, 2);
  3342. // Get parameter 2 off the stack.
  3343. float param2 = (float)luaL_checknumber(state, 3);
  3344. CheckBox* instance = getInstance(state);
  3345. instance->setImageSize(param1, param2);
  3346. return 0;
  3347. }
  3348. else
  3349. {
  3350. lua_pushstring(state, "lua_CheckBox_setImageSize - Failed to match the given parameters to a valid function signature.");
  3351. lua_error(state);
  3352. }
  3353. break;
  3354. }
  3355. default:
  3356. {
  3357. lua_pushstring(state, "Invalid number of parameters (expected 3).");
  3358. lua_error(state);
  3359. break;
  3360. }
  3361. }
  3362. return 0;
  3363. }
  3364. int lua_CheckBox_setMargin(lua_State* state)
  3365. {
  3366. // Get the number of parameters.
  3367. int paramCount = lua_gettop(state);
  3368. // Attempt to match the parameters to a valid binding.
  3369. switch (paramCount)
  3370. {
  3371. case 5:
  3372. {
  3373. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  3374. lua_type(state, 2) == LUA_TNUMBER &&
  3375. lua_type(state, 3) == LUA_TNUMBER &&
  3376. lua_type(state, 4) == LUA_TNUMBER &&
  3377. lua_type(state, 5) == LUA_TNUMBER)
  3378. {
  3379. // Get parameter 1 off the stack.
  3380. float param1 = (float)luaL_checknumber(state, 2);
  3381. // Get parameter 2 off the stack.
  3382. float param2 = (float)luaL_checknumber(state, 3);
  3383. // Get parameter 3 off the stack.
  3384. float param3 = (float)luaL_checknumber(state, 4);
  3385. // Get parameter 4 off the stack.
  3386. float param4 = (float)luaL_checknumber(state, 5);
  3387. CheckBox* instance = getInstance(state);
  3388. instance->setMargin(param1, param2, param3, param4);
  3389. return 0;
  3390. }
  3391. else
  3392. {
  3393. lua_pushstring(state, "lua_CheckBox_setMargin - Failed to match the given parameters to a valid function signature.");
  3394. lua_error(state);
  3395. }
  3396. break;
  3397. }
  3398. default:
  3399. {
  3400. lua_pushstring(state, "Invalid number of parameters (expected 5).");
  3401. lua_error(state);
  3402. break;
  3403. }
  3404. }
  3405. return 0;
  3406. }
  3407. int lua_CheckBox_setOpacity(lua_State* state)
  3408. {
  3409. // Get the number of parameters.
  3410. int paramCount = lua_gettop(state);
  3411. // Attempt to match the parameters to a valid binding.
  3412. switch (paramCount)
  3413. {
  3414. case 2:
  3415. {
  3416. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  3417. lua_type(state, 2) == LUA_TNUMBER)
  3418. {
  3419. // Get parameter 1 off the stack.
  3420. float param1 = (float)luaL_checknumber(state, 2);
  3421. CheckBox* instance = getInstance(state);
  3422. instance->setOpacity(param1);
  3423. return 0;
  3424. }
  3425. else
  3426. {
  3427. lua_pushstring(state, "lua_CheckBox_setOpacity - Failed to match the given parameters to a valid function signature.");
  3428. lua_error(state);
  3429. }
  3430. break;
  3431. }
  3432. case 3:
  3433. {
  3434. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  3435. lua_type(state, 2) == LUA_TNUMBER &&
  3436. lua_type(state, 3) == LUA_TNUMBER)
  3437. {
  3438. // Get parameter 1 off the stack.
  3439. float param1 = (float)luaL_checknumber(state, 2);
  3440. // Get parameter 2 off the stack.
  3441. unsigned char param2 = (unsigned char)luaL_checkunsigned(state, 3);
  3442. CheckBox* instance = getInstance(state);
  3443. instance->setOpacity(param1, param2);
  3444. return 0;
  3445. }
  3446. else
  3447. {
  3448. lua_pushstring(state, "lua_CheckBox_setOpacity - Failed to match the given parameters to a valid function signature.");
  3449. lua_error(state);
  3450. }
  3451. break;
  3452. }
  3453. default:
  3454. {
  3455. lua_pushstring(state, "Invalid number of parameters (expected 2 or 3).");
  3456. lua_error(state);
  3457. break;
  3458. }
  3459. }
  3460. return 0;
  3461. }
  3462. int lua_CheckBox_setPadding(lua_State* state)
  3463. {
  3464. // Get the number of parameters.
  3465. int paramCount = lua_gettop(state);
  3466. // Attempt to match the parameters to a valid binding.
  3467. switch (paramCount)
  3468. {
  3469. case 5:
  3470. {
  3471. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  3472. lua_type(state, 2) == LUA_TNUMBER &&
  3473. lua_type(state, 3) == LUA_TNUMBER &&
  3474. lua_type(state, 4) == LUA_TNUMBER &&
  3475. lua_type(state, 5) == LUA_TNUMBER)
  3476. {
  3477. // Get parameter 1 off the stack.
  3478. float param1 = (float)luaL_checknumber(state, 2);
  3479. // Get parameter 2 off the stack.
  3480. float param2 = (float)luaL_checknumber(state, 3);
  3481. // Get parameter 3 off the stack.
  3482. float param3 = (float)luaL_checknumber(state, 4);
  3483. // Get parameter 4 off the stack.
  3484. float param4 = (float)luaL_checknumber(state, 5);
  3485. CheckBox* instance = getInstance(state);
  3486. instance->setPadding(param1, param2, param3, param4);
  3487. return 0;
  3488. }
  3489. else
  3490. {
  3491. lua_pushstring(state, "lua_CheckBox_setPadding - Failed to match the given parameters to a valid function signature.");
  3492. lua_error(state);
  3493. }
  3494. break;
  3495. }
  3496. default:
  3497. {
  3498. lua_pushstring(state, "Invalid number of parameters (expected 5).");
  3499. lua_error(state);
  3500. break;
  3501. }
  3502. }
  3503. return 0;
  3504. }
  3505. int lua_CheckBox_setPosition(lua_State* state)
  3506. {
  3507. // Get the number of parameters.
  3508. int paramCount = lua_gettop(state);
  3509. // Attempt to match the parameters to a valid binding.
  3510. switch (paramCount)
  3511. {
  3512. case 3:
  3513. {
  3514. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  3515. lua_type(state, 2) == LUA_TNUMBER &&
  3516. lua_type(state, 3) == LUA_TNUMBER)
  3517. {
  3518. // Get parameter 1 off the stack.
  3519. float param1 = (float)luaL_checknumber(state, 2);
  3520. // Get parameter 2 off the stack.
  3521. float param2 = (float)luaL_checknumber(state, 3);
  3522. CheckBox* instance = getInstance(state);
  3523. instance->setPosition(param1, param2);
  3524. return 0;
  3525. }
  3526. else
  3527. {
  3528. lua_pushstring(state, "lua_CheckBox_setPosition - Failed to match the given parameters to a valid function signature.");
  3529. lua_error(state);
  3530. }
  3531. break;
  3532. }
  3533. default:
  3534. {
  3535. lua_pushstring(state, "Invalid number of parameters (expected 3).");
  3536. lua_error(state);
  3537. break;
  3538. }
  3539. }
  3540. return 0;
  3541. }
  3542. int lua_CheckBox_setSize(lua_State* state)
  3543. {
  3544. // Get the number of parameters.
  3545. int paramCount = lua_gettop(state);
  3546. // Attempt to match the parameters to a valid binding.
  3547. switch (paramCount)
  3548. {
  3549. case 3:
  3550. {
  3551. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  3552. lua_type(state, 2) == LUA_TNUMBER &&
  3553. lua_type(state, 3) == LUA_TNUMBER)
  3554. {
  3555. // Get parameter 1 off the stack.
  3556. float param1 = (float)luaL_checknumber(state, 2);
  3557. // Get parameter 2 off the stack.
  3558. float param2 = (float)luaL_checknumber(state, 3);
  3559. CheckBox* instance = getInstance(state);
  3560. instance->setSize(param1, param2);
  3561. return 0;
  3562. }
  3563. else
  3564. {
  3565. lua_pushstring(state, "lua_CheckBox_setSize - Failed to match the given parameters to a valid function signature.");
  3566. lua_error(state);
  3567. }
  3568. break;
  3569. }
  3570. default:
  3571. {
  3572. lua_pushstring(state, "Invalid number of parameters (expected 3).");
  3573. lua_error(state);
  3574. break;
  3575. }
  3576. }
  3577. return 0;
  3578. }
  3579. int lua_CheckBox_setSkinColor(lua_State* state)
  3580. {
  3581. // Get the number of parameters.
  3582. int paramCount = lua_gettop(state);
  3583. // Attempt to match the parameters to a valid binding.
  3584. switch (paramCount)
  3585. {
  3586. case 2:
  3587. {
  3588. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  3589. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TNIL))
  3590. {
  3591. // Get parameter 1 off the stack.
  3592. ScriptUtil::LuaArray<Vector4> param1 = ScriptUtil::getObjectPointer<Vector4>(2, "Vector4", true);
  3593. CheckBox* instance = getInstance(state);
  3594. instance->setSkinColor(*param1);
  3595. return 0;
  3596. }
  3597. else
  3598. {
  3599. lua_pushstring(state, "lua_CheckBox_setSkinColor - Failed to match the given parameters to a valid function signature.");
  3600. lua_error(state);
  3601. }
  3602. break;
  3603. }
  3604. case 3:
  3605. {
  3606. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  3607. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TNIL) &&
  3608. lua_type(state, 3) == LUA_TNUMBER)
  3609. {
  3610. // Get parameter 1 off the stack.
  3611. ScriptUtil::LuaArray<Vector4> param1 = ScriptUtil::getObjectPointer<Vector4>(2, "Vector4", true);
  3612. // Get parameter 2 off the stack.
  3613. unsigned char param2 = (unsigned char)luaL_checkunsigned(state, 3);
  3614. CheckBox* instance = getInstance(state);
  3615. instance->setSkinColor(*param1, param2);
  3616. return 0;
  3617. }
  3618. else
  3619. {
  3620. lua_pushstring(state, "lua_CheckBox_setSkinColor - Failed to match the given parameters to a valid function signature.");
  3621. lua_error(state);
  3622. }
  3623. break;
  3624. }
  3625. default:
  3626. {
  3627. lua_pushstring(state, "Invalid number of parameters (expected 2 or 3).");
  3628. lua_error(state);
  3629. break;
  3630. }
  3631. }
  3632. return 0;
  3633. }
  3634. int lua_CheckBox_setSkinRegion(lua_State* state)
  3635. {
  3636. // Get the number of parameters.
  3637. int paramCount = lua_gettop(state);
  3638. // Attempt to match the parameters to a valid binding.
  3639. switch (paramCount)
  3640. {
  3641. case 2:
  3642. {
  3643. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  3644. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TNIL))
  3645. {
  3646. // Get parameter 1 off the stack.
  3647. ScriptUtil::LuaArray<Rectangle> param1 = ScriptUtil::getObjectPointer<Rectangle>(2, "Rectangle", true);
  3648. CheckBox* instance = getInstance(state);
  3649. instance->setSkinRegion(*param1);
  3650. return 0;
  3651. }
  3652. else
  3653. {
  3654. lua_pushstring(state, "lua_CheckBox_setSkinRegion - Failed to match the given parameters to a valid function signature.");
  3655. lua_error(state);
  3656. }
  3657. break;
  3658. }
  3659. case 3:
  3660. {
  3661. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  3662. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TNIL) &&
  3663. lua_type(state, 3) == LUA_TNUMBER)
  3664. {
  3665. // Get parameter 1 off the stack.
  3666. ScriptUtil::LuaArray<Rectangle> param1 = ScriptUtil::getObjectPointer<Rectangle>(2, "Rectangle", true);
  3667. // Get parameter 2 off the stack.
  3668. unsigned char param2 = (unsigned char)luaL_checkunsigned(state, 3);
  3669. CheckBox* instance = getInstance(state);
  3670. instance->setSkinRegion(*param1, param2);
  3671. return 0;
  3672. }
  3673. else
  3674. {
  3675. lua_pushstring(state, "lua_CheckBox_setSkinRegion - Failed to match the given parameters to a valid function signature.");
  3676. lua_error(state);
  3677. }
  3678. break;
  3679. }
  3680. default:
  3681. {
  3682. lua_pushstring(state, "Invalid number of parameters (expected 2 or 3).");
  3683. lua_error(state);
  3684. break;
  3685. }
  3686. }
  3687. return 0;
  3688. }
  3689. int lua_CheckBox_setState(lua_State* state)
  3690. {
  3691. // Get the number of parameters.
  3692. int paramCount = lua_gettop(state);
  3693. // Attempt to match the parameters to a valid binding.
  3694. switch (paramCount)
  3695. {
  3696. case 2:
  3697. {
  3698. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  3699. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL))
  3700. {
  3701. // Get parameter 1 off the stack.
  3702. Control::State param1 = (Control::State)lua_enumFromString_ControlState(luaL_checkstring(state, 2));
  3703. CheckBox* instance = getInstance(state);
  3704. instance->setState(param1);
  3705. return 0;
  3706. }
  3707. else
  3708. {
  3709. lua_pushstring(state, "lua_CheckBox_setState - Failed to match the given parameters to a valid function signature.");
  3710. lua_error(state);
  3711. }
  3712. break;
  3713. }
  3714. default:
  3715. {
  3716. lua_pushstring(state, "Invalid number of parameters (expected 2).");
  3717. lua_error(state);
  3718. break;
  3719. }
  3720. }
  3721. return 0;
  3722. }
  3723. int lua_CheckBox_setStyle(lua_State* state)
  3724. {
  3725. // Get the number of parameters.
  3726. int paramCount = lua_gettop(state);
  3727. // Attempt to match the parameters to a valid binding.
  3728. switch (paramCount)
  3729. {
  3730. case 2:
  3731. {
  3732. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  3733. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TTABLE || lua_type(state, 2) == LUA_TNIL))
  3734. {
  3735. // Get parameter 1 off the stack.
  3736. ScriptUtil::LuaArray<Theme::Style> param1 = ScriptUtil::getObjectPointer<Theme::Style>(2, "ThemeStyle", false);
  3737. CheckBox* instance = getInstance(state);
  3738. instance->setStyle(param1);
  3739. return 0;
  3740. }
  3741. else
  3742. {
  3743. lua_pushstring(state, "lua_CheckBox_setStyle - Failed to match the given parameters to a valid function signature.");
  3744. lua_error(state);
  3745. }
  3746. break;
  3747. }
  3748. default:
  3749. {
  3750. lua_pushstring(state, "Invalid number of parameters (expected 2).");
  3751. lua_error(state);
  3752. break;
  3753. }
  3754. }
  3755. return 0;
  3756. }
  3757. int lua_CheckBox_setText(lua_State* state)
  3758. {
  3759. // Get the number of parameters.
  3760. int paramCount = lua_gettop(state);
  3761. // Attempt to match the parameters to a valid binding.
  3762. switch (paramCount)
  3763. {
  3764. case 2:
  3765. {
  3766. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  3767. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL))
  3768. {
  3769. // Get parameter 1 off the stack.
  3770. ScriptUtil::LuaArray<const char> param1 = ScriptUtil::getString(2, false);
  3771. CheckBox* instance = getInstance(state);
  3772. instance->setText(param1);
  3773. return 0;
  3774. }
  3775. else
  3776. {
  3777. lua_pushstring(state, "lua_CheckBox_setText - Failed to match the given parameters to a valid function signature.");
  3778. lua_error(state);
  3779. }
  3780. break;
  3781. }
  3782. default:
  3783. {
  3784. lua_pushstring(state, "Invalid number of parameters (expected 2).");
  3785. lua_error(state);
  3786. break;
  3787. }
  3788. }
  3789. return 0;
  3790. }
  3791. int lua_CheckBox_setTextAlignment(lua_State* state)
  3792. {
  3793. // Get the number of parameters.
  3794. int paramCount = lua_gettop(state);
  3795. // Attempt to match the parameters to a valid binding.
  3796. switch (paramCount)
  3797. {
  3798. case 2:
  3799. {
  3800. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  3801. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL))
  3802. {
  3803. // Get parameter 1 off the stack.
  3804. Font::Justify param1 = (Font::Justify)lua_enumFromString_FontJustify(luaL_checkstring(state, 2));
  3805. CheckBox* instance = getInstance(state);
  3806. instance->setTextAlignment(param1);
  3807. return 0;
  3808. }
  3809. else
  3810. {
  3811. lua_pushstring(state, "lua_CheckBox_setTextAlignment - Failed to match the given parameters to a valid function signature.");
  3812. lua_error(state);
  3813. }
  3814. break;
  3815. }
  3816. case 3:
  3817. {
  3818. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  3819. (lua_type(state, 2) == LUA_TSTRING || lua_type(state, 2) == LUA_TNIL) &&
  3820. lua_type(state, 3) == LUA_TNUMBER)
  3821. {
  3822. // Get parameter 1 off the stack.
  3823. Font::Justify param1 = (Font::Justify)lua_enumFromString_FontJustify(luaL_checkstring(state, 2));
  3824. // Get parameter 2 off the stack.
  3825. unsigned char param2 = (unsigned char)luaL_checkunsigned(state, 3);
  3826. CheckBox* instance = getInstance(state);
  3827. instance->setTextAlignment(param1, param2);
  3828. return 0;
  3829. }
  3830. else
  3831. {
  3832. lua_pushstring(state, "lua_CheckBox_setTextAlignment - Failed to match the given parameters to a valid function signature.");
  3833. lua_error(state);
  3834. }
  3835. break;
  3836. }
  3837. default:
  3838. {
  3839. lua_pushstring(state, "Invalid number of parameters (expected 2 or 3).");
  3840. lua_error(state);
  3841. break;
  3842. }
  3843. }
  3844. return 0;
  3845. }
  3846. int lua_CheckBox_setTextColor(lua_State* state)
  3847. {
  3848. // Get the number of parameters.
  3849. int paramCount = lua_gettop(state);
  3850. // Attempt to match the parameters to a valid binding.
  3851. switch (paramCount)
  3852. {
  3853. case 2:
  3854. {
  3855. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  3856. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TNIL))
  3857. {
  3858. // Get parameter 1 off the stack.
  3859. ScriptUtil::LuaArray<Vector4> param1 = ScriptUtil::getObjectPointer<Vector4>(2, "Vector4", true);
  3860. CheckBox* instance = getInstance(state);
  3861. instance->setTextColor(*param1);
  3862. return 0;
  3863. }
  3864. else
  3865. {
  3866. lua_pushstring(state, "lua_CheckBox_setTextColor - Failed to match the given parameters to a valid function signature.");
  3867. lua_error(state);
  3868. }
  3869. break;
  3870. }
  3871. case 3:
  3872. {
  3873. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  3874. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TNIL) &&
  3875. lua_type(state, 3) == LUA_TNUMBER)
  3876. {
  3877. // Get parameter 1 off the stack.
  3878. ScriptUtil::LuaArray<Vector4> param1 = ScriptUtil::getObjectPointer<Vector4>(2, "Vector4", true);
  3879. // Get parameter 2 off the stack.
  3880. unsigned char param2 = (unsigned char)luaL_checkunsigned(state, 3);
  3881. CheckBox* instance = getInstance(state);
  3882. instance->setTextColor(*param1, param2);
  3883. return 0;
  3884. }
  3885. else
  3886. {
  3887. lua_pushstring(state, "lua_CheckBox_setTextColor - Failed to match the given parameters to a valid function signature.");
  3888. lua_error(state);
  3889. }
  3890. break;
  3891. }
  3892. default:
  3893. {
  3894. lua_pushstring(state, "Invalid number of parameters (expected 2 or 3).");
  3895. lua_error(state);
  3896. break;
  3897. }
  3898. }
  3899. return 0;
  3900. }
  3901. int lua_CheckBox_setTextRightToLeft(lua_State* state)
  3902. {
  3903. // Get the number of parameters.
  3904. int paramCount = lua_gettop(state);
  3905. // Attempt to match the parameters to a valid binding.
  3906. switch (paramCount)
  3907. {
  3908. case 2:
  3909. {
  3910. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  3911. lua_type(state, 2) == LUA_TBOOLEAN)
  3912. {
  3913. // Get parameter 1 off the stack.
  3914. bool param1 = ScriptUtil::luaCheckBool(state, 2);
  3915. CheckBox* instance = getInstance(state);
  3916. instance->setTextRightToLeft(param1);
  3917. return 0;
  3918. }
  3919. else
  3920. {
  3921. lua_pushstring(state, "lua_CheckBox_setTextRightToLeft - Failed to match the given parameters to a valid function signature.");
  3922. lua_error(state);
  3923. }
  3924. break;
  3925. }
  3926. case 3:
  3927. {
  3928. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  3929. lua_type(state, 2) == LUA_TBOOLEAN &&
  3930. lua_type(state, 3) == LUA_TNUMBER)
  3931. {
  3932. // Get parameter 1 off the stack.
  3933. bool param1 = ScriptUtil::luaCheckBool(state, 2);
  3934. // Get parameter 2 off the stack.
  3935. unsigned char param2 = (unsigned char)luaL_checkunsigned(state, 3);
  3936. CheckBox* instance = getInstance(state);
  3937. instance->setTextRightToLeft(param1, param2);
  3938. return 0;
  3939. }
  3940. else
  3941. {
  3942. lua_pushstring(state, "lua_CheckBox_setTextRightToLeft - Failed to match the given parameters to a valid function signature.");
  3943. lua_error(state);
  3944. }
  3945. break;
  3946. }
  3947. default:
  3948. {
  3949. lua_pushstring(state, "Invalid number of parameters (expected 2 or 3).");
  3950. lua_error(state);
  3951. break;
  3952. }
  3953. }
  3954. return 0;
  3955. }
  3956. int lua_CheckBox_setZIndex(lua_State* state)
  3957. {
  3958. // Get the number of parameters.
  3959. int paramCount = lua_gettop(state);
  3960. // Attempt to match the parameters to a valid binding.
  3961. switch (paramCount)
  3962. {
  3963. case 2:
  3964. {
  3965. if ((lua_type(state, 1) == LUA_TUSERDATA) &&
  3966. lua_type(state, 2) == LUA_TNUMBER)
  3967. {
  3968. // Get parameter 1 off the stack.
  3969. int param1 = (int)luaL_checkint(state, 2);
  3970. CheckBox* instance = getInstance(state);
  3971. instance->setZIndex(param1);
  3972. return 0;
  3973. }
  3974. else
  3975. {
  3976. lua_pushstring(state, "lua_CheckBox_setZIndex - Failed to match the given parameters to a valid function signature.");
  3977. lua_error(state);
  3978. }
  3979. break;
  3980. }
  3981. default:
  3982. {
  3983. lua_pushstring(state, "Invalid number of parameters (expected 2).");
  3984. lua_error(state);
  3985. break;
  3986. }
  3987. }
  3988. return 0;
  3989. }
  3990. int lua_CheckBox_static_ANIMATE_OPACITY(lua_State* state)
  3991. {
  3992. // Validate the number of parameters.
  3993. if (lua_gettop(state) > 0)
  3994. {
  3995. lua_pushstring(state, "Invalid number of parameters (expected 0).");
  3996. lua_error(state);
  3997. }
  3998. int result = CheckBox::ANIMATE_OPACITY;
  3999. // Push the return value onto the stack.
  4000. lua_pushinteger(state, result);
  4001. return 1;
  4002. }
  4003. int lua_CheckBox_static_ANIMATE_POSITION(lua_State* state)
  4004. {
  4005. // Validate the number of parameters.
  4006. if (lua_gettop(state) > 0)
  4007. {
  4008. lua_pushstring(state, "Invalid number of parameters (expected 0).");
  4009. lua_error(state);
  4010. }
  4011. int result = CheckBox::ANIMATE_POSITION;
  4012. // Push the return value onto the stack.
  4013. lua_pushinteger(state, result);
  4014. return 1;
  4015. }
  4016. int lua_CheckBox_static_ANIMATE_POSITION_X(lua_State* state)
  4017. {
  4018. // Validate the number of parameters.
  4019. if (lua_gettop(state) > 0)
  4020. {
  4021. lua_pushstring(state, "Invalid number of parameters (expected 0).");
  4022. lua_error(state);
  4023. }
  4024. int result = CheckBox::ANIMATE_POSITION_X;
  4025. // Push the return value onto the stack.
  4026. lua_pushinteger(state, result);
  4027. return 1;
  4028. }
  4029. int lua_CheckBox_static_ANIMATE_POSITION_Y(lua_State* state)
  4030. {
  4031. // Validate the number of parameters.
  4032. if (lua_gettop(state) > 0)
  4033. {
  4034. lua_pushstring(state, "Invalid number of parameters (expected 0).");
  4035. lua_error(state);
  4036. }
  4037. int result = CheckBox::ANIMATE_POSITION_Y;
  4038. // Push the return value onto the stack.
  4039. lua_pushinteger(state, result);
  4040. return 1;
  4041. }
  4042. int lua_CheckBox_static_ANIMATE_SIZE(lua_State* state)
  4043. {
  4044. // Validate the number of parameters.
  4045. if (lua_gettop(state) > 0)
  4046. {
  4047. lua_pushstring(state, "Invalid number of parameters (expected 0).");
  4048. lua_error(state);
  4049. }
  4050. int result = CheckBox::ANIMATE_SIZE;
  4051. // Push the return value onto the stack.
  4052. lua_pushinteger(state, result);
  4053. return 1;
  4054. }
  4055. int lua_CheckBox_static_ANIMATE_SIZE_HEIGHT(lua_State* state)
  4056. {
  4057. // Validate the number of parameters.
  4058. if (lua_gettop(state) > 0)
  4059. {
  4060. lua_pushstring(state, "Invalid number of parameters (expected 0).");
  4061. lua_error(state);
  4062. }
  4063. int result = CheckBox::ANIMATE_SIZE_HEIGHT;
  4064. // Push the return value onto the stack.
  4065. lua_pushinteger(state, result);
  4066. return 1;
  4067. }
  4068. int lua_CheckBox_static_ANIMATE_SIZE_WIDTH(lua_State* state)
  4069. {
  4070. // Validate the number of parameters.
  4071. if (lua_gettop(state) > 0)
  4072. {
  4073. lua_pushstring(state, "Invalid number of parameters (expected 0).");
  4074. lua_error(state);
  4075. }
  4076. int result = CheckBox::ANIMATE_SIZE_WIDTH;
  4077. // Push the return value onto the stack.
  4078. lua_pushinteger(state, result);
  4079. return 1;
  4080. }
  4081. int lua_CheckBox_static_create(lua_State* state)
  4082. {
  4083. // Get the number of parameters.
  4084. int paramCount = lua_gettop(state);
  4085. // Attempt to match the parameters to a valid binding.
  4086. switch (paramCount)
  4087. {
  4088. case 2:
  4089. {
  4090. if ((lua_type(state, 1) == LUA_TSTRING || lua_type(state, 1) == LUA_TNIL) &&
  4091. (lua_type(state, 2) == LUA_TUSERDATA || lua_type(state, 2) == LUA_TTABLE || lua_type(state, 2) == LUA_TNIL))
  4092. {
  4093. // Get parameter 1 off the stack.
  4094. ScriptUtil::LuaArray<const char> param1 = ScriptUtil::getString(1, false);
  4095. // Get parameter 2 off the stack.
  4096. ScriptUtil::LuaArray<Theme::Style> param2 = ScriptUtil::getObjectPointer<Theme::Style>(2, "ThemeStyle", false);
  4097. void* returnPtr = (void*)CheckBox::create(param1, param2);
  4098. if (returnPtr)
  4099. {
  4100. ScriptUtil::LuaObject* object = (ScriptUtil::LuaObject*)lua_newuserdata(state, sizeof(ScriptUtil::LuaObject));
  4101. object->instance = returnPtr;
  4102. object->owns = true;
  4103. luaL_getmetatable(state, "CheckBox");
  4104. lua_setmetatable(state, -2);
  4105. }
  4106. else
  4107. {
  4108. lua_pushnil(state);
  4109. }
  4110. return 1;
  4111. }
  4112. else
  4113. {
  4114. lua_pushstring(state, "lua_CheckBox_static_create - Failed to match the given parameters to a valid function signature.");
  4115. lua_error(state);
  4116. }
  4117. break;
  4118. }
  4119. default:
  4120. {
  4121. lua_pushstring(state, "Invalid number of parameters (expected 2).");
  4122. lua_error(state);
  4123. break;
  4124. }
  4125. }
  4126. return 0;
  4127. }
  4128. }