lua_ImageControl.cpp 179 KB

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