12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537253825392540254125422543254425452546254725482549255025512552255325542555255625572558255925602561256225632564256525662567256825692570257125722573257425752576257725782579258025812582258325842585258625872588258925902591259225932594259525962597259825992600260126022603260426052606260726082609261026112612261326142615261626172618261926202621262226232624262526262627262826292630263126322633263426352636263726382639264026412642264326442645264626472648264926502651265226532654265526562657265826592660266126622663266426652666266726682669267026712672267326742675267626772678267926802681268226832684268526862687268826892690269126922693269426952696269726982699270027012702270327042705270627072708270927102711271227132714271527162717271827192720272127222723272427252726272727282729273027312732273327342735273627372738273927402741274227432744274527462747274827492750275127522753275427552756275727582759276027612762276327642765276627672768276927702771277227732774277527762777277827792780278127822783278427852786278727882789279027912792279327942795279627972798279928002801280228032804280528062807280828092810281128122813281428152816281728182819282028212822282328242825282628272828282928302831283228332834283528362837283828392840284128422843284428452846284728482849285028512852285328542855285628572858285928602861286228632864286528662867286828692870287128722873287428752876287728782879288028812882288328842885288628872888288928902891289228932894289528962897289828992900290129022903290429052906290729082909291029112912291329142915291629172918291929202921292229232924292529262927292829292930293129322933293429352936293729382939294029412942294329442945294629472948294929502951295229532954295529562957295829592960296129622963296429652966296729682969297029712972297329742975297629772978297929802981298229832984298529862987298829892990299129922993299429952996299729982999300030013002300330043005300630073008300930103011301230133014301530163017301830193020302130223023302430253026302730283029303030313032303330343035303630373038303930403041304230433044304530463047304830493050305130523053305430553056305730583059306030613062306330643065306630673068306930703071307230733074307530763077307830793080308130823083308430853086308730883089309030913092309330943095309630973098309931003101310231033104310531063107310831093110311131123113311431153116311731183119312031213122312331243125312631273128312931303131313231333134313531363137313831393140314131423143314431453146314731483149315031513152315331543155315631573158315931603161316231633164316531663167316831693170317131723173317431753176317731783179318031813182318331843185318631873188318931903191319231933194319531963197319831993200320132023203320432053206320732083209321032113212321332143215321632173218321932203221322232233224322532263227322832293230323132323233323432353236323732383239324032413242324332443245324632473248324932503251325232533254325532563257325832593260326132623263326432653266326732683269327032713272327332743275327632773278327932803281328232833284328532863287328832893290329132923293329432953296329732983299330033013302330333043305330633073308330933103311331233133314331533163317331833193320332133223323332433253326332733283329333033313332333333343335333633373338333933403341334233433344334533463347334833493350335133523353335433553356335733583359336033613362336333643365336633673368336933703371337233733374337533763377337833793380338133823383338433853386338733883389339033913392339333943395339633973398339934003401340234033404340534063407340834093410341134123413341434153416341734183419342034213422342334243425342634273428342934303431343234333434343534363437343834393440344134423443344434453446344734483449345034513452345334543455345634573458345934603461346234633464346534663467346834693470347134723473347434753476347734783479348034813482348334843485348634873488348934903491349234933494349534963497349834993500350135023503350435053506350735083509351035113512351335143515351635173518351935203521352235233524352535263527352835293530353135323533353435353536353735383539354035413542354335443545354635473548354935503551355235533554355535563557355835593560356135623563356435653566356735683569357035713572357335743575357635773578357935803581358235833584358535863587358835893590359135923593359435953596359735983599360036013602360336043605360636073608360936103611361236133614361536163617361836193620362136223623362436253626362736283629363036313632363336343635363636373638363936403641364236433644364536463647364836493650365136523653365436553656365736583659366036613662366336643665366636673668366936703671367236733674367536763677367836793680368136823683368436853686368736883689369036913692369336943695369636973698369937003701370237033704370537063707370837093710371137123713371437153716371737183719372037213722372337243725372637273728372937303731373237333734373537363737373837393740374137423743374437453746374737483749375037513752375337543755375637573758375937603761376237633764376537663767376837693770377137723773377437753776377737783779378037813782378337843785378637873788378937903791379237933794379537963797379837993800380138023803380438053806380738083809381038113812381338143815381638173818381938203821382238233824382538263827382838293830383138323833383438353836383738383839384038413842384338443845384638473848384938503851385238533854385538563857385838593860386138623863386438653866386738683869387038713872387338743875387638773878387938803881388238833884388538863887388838893890389138923893389438953896389738983899390039013902390339043905390639073908390939103911391239133914391539163917391839193920392139223923392439253926392739283929393039313932393339343935393639373938393939403941394239433944394539463947394839493950395139523953395439553956395739583959396039613962396339643965396639673968396939703971397239733974397539763977397839793980398139823983398439853986398739883989399039913992399339943995399639973998399940004001400240034004400540064007400840094010401140124013401440154016401740184019402040214022402340244025402640274028402940304031403240334034403540364037403840394040404140424043404440454046404740484049405040514052405340544055405640574058405940604061406240634064406540664067406840694070407140724073407440754076407740784079408040814082408340844085408640874088408940904091409240934094409540964097409840994100410141024103410441054106410741084109411041114112411341144115411641174118411941204121412241234124412541264127412841294130413141324133413441354136413741384139414041414142414341444145414641474148414941504151415241534154415541564157415841594160416141624163416441654166416741684169417041714172417341744175417641774178417941804181418241834184418541864187418841894190419141924193419441954196419741984199420042014202420342044205420642074208420942104211421242134214421542164217421842194220422142224223422442254226422742284229423042314232423342344235423642374238423942404241424242434244424542464247424842494250425142524253425442554256425742584259426042614262426342644265426642674268426942704271427242734274427542764277427842794280428142824283428442854286428742884289429042914292429342944295429642974298429943004301430243034304430543064307430843094310431143124313431443154316431743184319432043214322432343244325432643274328432943304331433243334334433543364337433843394340434143424343434443454346434743484349435043514352435343544355435643574358435943604361436243634364436543664367436843694370437143724373437443754376437743784379438043814382438343844385438643874388438943904391439243934394439543964397439843994400440144024403440444054406440744084409441044114412441344144415441644174418441944204421442244234424442544264427442844294430443144324433443444354436443744384439444044414442444344444445444644474448444944504451445244534454445544564457445844594460446144624463446444654466446744684469447044714472447344744475447644774478447944804481448244834484448544864487448844894490449144924493449444954496449744984499450045014502450345044505450645074508450945104511451245134514451545164517451845194520452145224523452445254526452745284529453045314532453345344535453645374538453945404541454245434544454545464547454845494550455145524553455445554556455745584559456045614562456345644565456645674568456945704571457245734574457545764577457845794580458145824583458445854586458745884589459045914592459345944595459645974598459946004601460246034604460546064607460846094610461146124613461446154616461746184619462046214622462346244625462646274628462946304631463246334634463546364637463846394640464146424643464446454646464746484649465046514652465346544655465646574658465946604661466246634664466546664667466846694670467146724673467446754676467746784679468046814682468346844685468646874688468946904691469246934694469546964697469846994700470147024703470447054706470747084709471047114712471347144715471647174718471947204721472247234724472547264727472847294730473147324733473447354736473747384739474047414742474347444745474647474748474947504751475247534754475547564757475847594760476147624763476447654766476747684769477047714772477347744775477647774778477947804781478247834784478547864787478847894790479147924793479447954796479747984799480048014802480348044805480648074808480948104811481248134814481548164817481848194820482148224823482448254826482748284829483048314832483348344835483648374838483948404841484248434844484548464847484848494850485148524853485448554856485748584859486048614862486348644865486648674868486948704871487248734874487548764877487848794880488148824883488448854886488748884889489048914892489348944895489648974898489949004901490249034904490549064907490849094910491149124913491449154916491749184919492049214922492349244925492649274928492949304931493249334934493549364937493849394940494149424943494449454946494749484949495049514952495349544955495649574958495949604961496249634964496549664967496849694970497149724973497449754976497749784979498049814982498349844985498649874988498949904991499249934994499549964997499849995000500150025003500450055006500750085009501050115012501350145015501650175018501950205021502250235024502550265027502850295030503150325033503450355036503750385039504050415042504350445045504650475048504950505051505250535054505550565057505850595060506150625063506450655066506750685069507050715072507350745075507650775078507950805081508250835084508550865087508850895090509150925093509450955096509750985099510051015102510351045105510651075108510951105111511251135114511551165117511851195120512151225123512451255126512751285129513051315132513351345135513651375138513951405141514251435144514551465147514851495150515151525153515451555156515751585159516051615162516351645165516651675168516951705171517251735174517551765177517851795180518151825183518451855186518751885189519051915192519351945195519651975198519952005201520252035204520552065207520852095210521152125213521452155216521752185219522052215222522352245225522652275228522952305231523252335234523552365237523852395240524152425243524452455246524752485249525052515252525352545255525652575258525952605261526252635264526552665267526852695270527152725273527452755276527752785279528052815282528352845285528652875288528952905291529252935294529552965297529852995300530153025303530453055306530753085309531053115312531353145315531653175318531953205321532253235324532553265327532853295330533153325333533453355336533753385339534053415342534353445345534653475348534953505351535253535354535553565357535853595360536153625363536453655366536753685369537053715372537353745375537653775378537953805381538253835384538553865387538853895390539153925393539453955396539753985399540054015402540354045405540654075408540954105411541254135414541554165417541854195420542154225423542454255426542754285429543054315432543354345435543654375438543954405441544254435444544554465447544854495450545154525453545454555456545754585459546054615462546354645465546654675468546954705471547254735474547554765477547854795480548154825483548454855486548754885489549054915492549354945495549654975498549955005501550255035504550555065507550855095510551155125513551455155516551755185519552055215522552355245525552655275528552955305531553255335534553555365537553855395540554155425543554455455546554755485549555055515552555355545555555655575558555955605561556255635564556555665567556855695570557155725573557455755576557755785579558055815582558355845585558655875588558955905591559255935594559555965597559855995600560156025603560456055606560756085609561056115612561356145615561656175618561956205621562256235624562556265627562856295630563156325633563456355636563756385639564056415642564356445645564656475648564956505651565256535654565556565657565856595660566156625663566456655666566756685669567056715672567356745675567656775678567956805681568256835684568556865687568856895690569156925693569456955696569756985699570057015702570357045705570657075708570957105711571257135714571557165717571857195720572157225723572457255726572757285729573057315732573357345735573657375738573957405741574257435744574557465747574857495750575157525753575457555756575757585759576057615762576357645765576657675768576957705771577257735774577557765777577857795780578157825783578457855786578757885789579057915792579357945795579657975798579958005801580258035804580558065807580858095810581158125813581458155816581758185819582058215822582358245825582658275828582958305831583258335834583558365837583858395840584158425843584458455846584758485849585058515852585358545855585658575858585958605861586258635864586558665867586858695870587158725873587458755876587758785879588058815882588358845885588658875888588958905891589258935894589558965897589858995900590159025903590459055906590759085909591059115912591359145915591659175918591959205921592259235924592559265927592859295930593159325933593459355936593759385939594059415942594359445945594659475948594959505951595259535954595559565957595859595960596159625963596459655966596759685969597059715972597359745975597659775978597959805981598259835984598559865987598859895990599159925993599459955996599759985999600060016002600360046005600660076008600960106011601260136014601560166017601860196020602160226023602460256026602760286029603060316032603360346035603660376038603960406041604260436044604560466047604860496050605160526053605460556056605760586059606060616062606360646065606660676068606960706071607260736074607560766077607860796080608160826083608460856086608760886089609060916092609360946095609660976098609961006101610261036104610561066107610861096110611161126113611461156116611761186119612061216122612361246125612661276128612961306131613261336134613561366137613861396140614161426143614461456146614761486149615061516152615361546155615661576158615961606161616261636164616561666167616861696170617161726173617461756176617761786179618061816182618361846185618661876188618961906191619261936194619561966197619861996200620162026203620462056206620762086209621062116212621362146215621662176218621962206221622262236224622562266227622862296230623162326233623462356236623762386239624062416242624362446245624662476248624962506251625262536254625562566257625862596260626162626263626462656266626762686269627062716272627362746275627662776278627962806281628262836284628562866287628862896290629162926293629462956296629762986299630063016302630363046305630663076308630963106311631263136314631563166317631863196320632163226323632463256326632763286329633063316332633363346335633663376338633963406341634263436344634563466347634863496350635163526353635463556356635763586359636063616362636363646365636663676368636963706371637263736374637563766377637863796380638163826383638463856386638763886389639063916392639363946395639663976398639964006401640264036404640564066407640864096410641164126413641464156416641764186419642064216422642364246425642664276428642964306431643264336434643564366437643864396440644164426443644464456446644764486449645064516452645364546455645664576458645964606461646264636464646564666467646864696470647164726473647464756476647764786479648064816482648364846485648664876488648964906491649264936494649564966497649864996500650165026503650465056506650765086509651065116512651365146515651665176518651965206521652265236524652565266527652865296530653165326533653465356536653765386539654065416542654365446545654665476548654965506551655265536554655565566557655865596560656165626563656465656566656765686569657065716572657365746575657665776578657965806581658265836584658565866587658865896590659165926593659465956596659765986599660066016602660366046605660666076608660966106611661266136614661566166617661866196620662166226623662466256626662766286629663066316632663366346635663666376638663966406641664266436644664566466647664866496650665166526653665466556656665766586659666066616662666366646665666666676668666966706671667266736674667566766677667866796680668166826683668466856686668766886689669066916692669366946695669666976698669967006701670267036704670567066707670867096710671167126713671467156716671767186719672067216722672367246725672667276728672967306731673267336734673567366737673867396740674167426743674467456746674767486749675067516752675367546755675667576758675967606761676267636764676567666767676867696770677167726773677467756776677767786779678067816782678367846785678667876788678967906791679267936794679567966797679867996800680168026803680468056806680768086809681068116812681368146815681668176818681968206821682268236824682568266827682868296830683168326833683468356836683768386839684068416842684368446845684668476848684968506851685268536854685568566857685868596860686168626863686468656866686768686869687068716872687368746875687668776878687968806881688268836884688568866887688868896890689168926893689468956896689768986899690069016902690369046905690669076908690969106911691269136914691569166917691869196920692169226923692469256926692769286929693069316932693369346935693669376938693969406941694269436944694569466947694869496950695169526953695469556956695769586959696069616962696369646965696669676968696969706971697269736974697569766977697869796980698169826983698469856986698769886989699069916992699369946995699669976998699970007001700270037004700570067007700870097010701170127013701470157016701770187019702070217022702370247025702670277028702970307031703270337034703570367037703870397040704170427043704470457046704770487049705070517052705370547055705670577058705970607061706270637064706570667067706870697070707170727073707470757076707770787079708070817082708370847085708670877088708970907091709270937094709570967097709870997100710171027103710471057106710771087109711071117112711371147115711671177118711971207121712271237124712571267127712871297130713171327133713471357136713771387139714071417142714371447145714671477148714971507151715271537154715571567157715871597160716171627163716471657166716771687169717071717172717371747175717671777178717971807181718271837184718571867187718871897190719171927193719471957196719771987199720072017202720372047205720672077208720972107211721272137214721572167217721872197220722172227223722472257226722772287229723072317232723372347235723672377238723972407241724272437244724572467247724872497250725172527253725472557256725772587259726072617262726372647265726672677268726972707271727272737274727572767277727872797280728172827283728472857286728772887289729072917292729372947295729672977298729973007301730273037304730573067307730873097310731173127313731473157316731773187319732073217322732373247325732673277328732973307331733273337334733573367337733873397340734173427343734473457346734773487349735073517352735373547355735673577358735973607361736273637364736573667367736873697370737173727373737473757376737773787379738073817382738373847385738673877388738973907391739273937394739573967397739873997400740174027403740474057406740774087409741074117412741374147415741674177418741974207421742274237424742574267427742874297430743174327433743474357436743774387439744074417442744374447445744674477448744974507451745274537454745574567457745874597460746174627463746474657466746774687469747074717472747374747475747674777478747974807481748274837484748574867487748874897490749174927493749474957496749774987499750075017502750375047505750675077508750975107511751275137514751575167517751875197520752175227523752475257526752775287529753075317532753375347535753675377538753975407541754275437544754575467547754875497550755175527553755475557556755775587559756075617562756375647565756675677568756975707571757275737574757575767577757875797580758175827583758475857586758775887589759075917592759375947595759675977598759976007601760276037604760576067607760876097610761176127613761476157616761776187619762076217622762376247625762676277628762976307631763276337634763576367637763876397640764176427643764476457646764776487649765076517652765376547655765676577658765976607661766276637664766576667667766876697670767176727673767476757676767776787679768076817682768376847685768676877688768976907691769276937694769576967697769876997700770177027703770477057706770777087709771077117712771377147715771677177718771977207721772277237724772577267727772877297730773177327733773477357736773777387739774077417742774377447745774677477748774977507751775277537754775577567757775877597760776177627763776477657766776777687769777077717772777377747775777677777778777977807781778277837784778577867787778877897790779177927793779477957796779777987799780078017802780378047805780678077808780978107811781278137814781578167817781878197820782178227823782478257826782778287829783078317832783378347835783678377838783978407841784278437844784578467847784878497850785178527853785478557856785778587859786078617862786378647865786678677868786978707871787278737874787578767877787878797880788178827883788478857886788778887889789078917892789378947895789678977898789979007901790279037904790579067907790879097910791179127913791479157916791779187919792079217922792379247925792679277928792979307931793279337934793579367937793879397940794179427943794479457946794779487949795079517952795379547955795679577958795979607961796279637964796579667967796879697970797179727973797479757976797779787979798079817982798379847985798679877988798979907991799279937994799579967997799879998000800180028003800480058006800780088009801080118012801380148015801680178018801980208021802280238024802580268027802880298030803180328033803480358036803780388039804080418042804380448045804680478048804980508051805280538054805580568057805880598060806180628063806480658066806780688069807080718072807380748075807680778078807980808081808280838084808580868087808880898090809180928093809480958096809780988099810081018102810381048105810681078108810981108111811281138114811581168117811881198120812181228123812481258126812781288129813081318132813381348135813681378138813981408141814281438144814581468147814881498150815181528153815481558156815781588159816081618162816381648165816681678168816981708171817281738174817581768177817881798180818181828183818481858186818781888189819081918192819381948195819681978198819982008201820282038204820582068207820882098210821182128213821482158216821782188219822082218222822382248225822682278228822982308231823282338234823582368237823882398240824182428243824482458246824782488249825082518252825382548255825682578258825982608261826282638264826582668267826882698270827182728273827482758276827782788279828082818282828382848285828682878288828982908291829282938294829582968297829882998300830183028303830483058306830783088309831083118312831383148315831683178318831983208321832283238324832583268327832883298330833183328333833483358336833783388339834083418342834383448345834683478348834983508351835283538354835583568357835883598360836183628363836483658366836783688369837083718372837383748375837683778378837983808381838283838384838583868387838883898390839183928393839483958396839783988399840084018402840384048405840684078408840984108411841284138414841584168417841884198420842184228423842484258426842784288429843084318432843384348435843684378438843984408441844284438444844584468447844884498450845184528453845484558456845784588459846084618462846384648465846684678468846984708471847284738474847584768477847884798480848184828483848484858486848784888489849084918492849384948495849684978498849985008501850285038504850585068507850885098510851185128513851485158516851785188519852085218522852385248525852685278528852985308531853285338534853585368537853885398540854185428543854485458546854785488549855085518552855385548555855685578558855985608561856285638564856585668567856885698570857185728573857485758576857785788579858085818582858385848585858685878588858985908591859285938594859585968597859885998600860186028603860486058606860786088609861086118612861386148615861686178618861986208621862286238624862586268627862886298630863186328633863486358636863786388639864086418642864386448645864686478648864986508651865286538654865586568657865886598660866186628663866486658666866786688669867086718672867386748675867686778678867986808681868286838684868586868687868886898690869186928693869486958696869786988699870087018702870387048705870687078708870987108711871287138714871587168717871887198720872187228723872487258726872787288729873087318732873387348735873687378738873987408741874287438744874587468747874887498750875187528753875487558756875787588759876087618762876387648765876687678768876987708771877287738774877587768777877887798780878187828783878487858786878787888789879087918792879387948795879687978798879988008801880288038804880588068807880888098810881188128813881488158816881788188819882088218822882388248825882688278828882988308831883288338834883588368837883888398840884188428843884488458846884788488849885088518852885388548855885688578858885988608861886288638864886588668867886888698870887188728873887488758876887788788879888088818882888388848885888688878888888988908891889288938894889588968897889888998900890189028903890489058906890789088909891089118912891389148915891689178918891989208921892289238924892589268927892889298930893189328933893489358936893789388939894089418942894389448945894689478948894989508951895289538954895589568957895889598960896189628963896489658966896789688969897089718972897389748975897689778978897989808981898289838984898589868987898889898990899189928993899489958996899789988999900090019002900390049005900690079008900990109011901290139014901590169017901890199020902190229023902490259026902790289029903090319032903390349035903690379038903990409041904290439044904590469047904890499050905190529053905490559056905790589059906090619062906390649065906690679068906990709071907290739074907590769077907890799080908190829083908490859086908790889089909090919092909390949095909690979098909991009101910291039104910591069107910891099110911191129113911491159116911791189119912091219122912391249125912691279128912991309131913291339134913591369137913891399140914191429143914491459146914791489149915091519152915391549155915691579158915991609161916291639164916591669167916891699170917191729173917491759176917791789179918091819182918391849185918691879188918991909191919291939194919591969197919891999200920192029203920492059206920792089209921092119212921392149215921692179218921992209221922292239224922592269227922892299230923192329233923492359236923792389239924092419242924392449245924692479248924992509251925292539254925592569257925892599260926192629263926492659266926792689269927092719272927392749275927692779278927992809281928292839284928592869287928892899290929192929293929492959296929792989299930093019302930393049305930693079308930993109311931293139314931593169317931893199320932193229323932493259326932793289329933093319332933393349335933693379338933993409341934293439344934593469347934893499350935193529353935493559356935793589359936093619362936393649365936693679368936993709371937293739374937593769377937893799380938193829383938493859386938793889389939093919392939393949395939693979398939994009401940294039404940594069407940894099410941194129413941494159416941794189419942094219422942394249425942694279428942994309431943294339434943594369437943894399440944194429443944494459446944794489449945094519452945394549455945694579458945994609461946294639464946594669467946894699470947194729473947494759476947794789479948094819482948394849485948694879488948994909491949294939494949594969497949894999500950195029503950495059506950795089509951095119512951395149515951695179518951995209521952295239524952595269527952895299530953195329533953495359536953795389539954095419542954395449545954695479548954995509551955295539554955595569557955895599560956195629563956495659566956795689569957095719572957395749575957695779578957995809581958295839584958595869587958895899590959195929593959495959596959795989599960096019602960396049605960696079608960996109611961296139614961596169617961896199620962196229623962496259626962796289629963096319632963396349635963696379638963996409641964296439644964596469647964896499650965196529653965496559656965796589659966096619662966396649665966696679668966996709671967296739674967596769677967896799680968196829683968496859686968796889689969096919692969396949695969696979698969997009701970297039704970597069707970897099710971197129713971497159716971797189719972097219722972397249725972697279728972997309731973297339734973597369737973897399740974197429743974497459746974797489749975097519752975397549755975697579758975997609761976297639764976597669767976897699770977197729773977497759776977797789779978097819782978397849785978697879788978997909791979297939794979597969797979897999800980198029803980498059806980798089809981098119812981398149815981698179818981998209821982298239824982598269827982898299830983198329833983498359836983798389839984098419842984398449845984698479848984998509851985298539854985598569857985898599860986198629863986498659866986798689869987098719872987398749875987698779878987998809881988298839884988598869887988898899890989198929893989498959896989798989899990099019902990399049905990699079908990999109911991299139914991599169917991899199920992199229923992499259926992799289929993099319932993399349935993699379938993999409941994299439944994599469947994899499950995199529953995499559956995799589959996099619962996399649965996699679968996999709971997299739974997599769977997899799980998199829983998499859986998799889989999099919992999399949995999699979998999910000100011000210003100041000510006100071000810009100101001110012100131001410015100161001710018100191002010021100221002310024100251002610027100281002910030100311003210033100341003510036100371003810039100401004110042100431004410045100461004710048100491005010051100521005310054100551005610057100581005910060100611006210063100641006510066100671006810069100701007110072100731007410075100761007710078100791008010081100821008310084100851008610087100881008910090100911009210093100941009510096100971009810099101001010110102101031010410105101061010710108101091011010111101121011310114101151011610117101181011910120101211012210123101241012510126101271012810129101301013110132101331013410135101361013710138101391014010141101421014310144101451014610147101481014910150101511015210153101541015510156101571015810159101601016110162101631016410165101661016710168101691017010171101721017310174101751017610177101781017910180101811018210183101841018510186101871018810189101901019110192101931019410195101961019710198101991020010201102021020310204102051020610207102081020910210102111021210213102141021510216102171021810219102201022110222102231022410225102261022710228102291023010231102321023310234102351023610237102381023910240102411024210243102441024510246102471024810249102501025110252102531025410255102561025710258102591026010261102621026310264102651026610267102681026910270102711027210273102741027510276102771027810279102801028110282102831028410285102861028710288102891029010291102921029310294102951029610297102981029910300103011030210303103041030510306103071030810309103101031110312103131031410315103161031710318103191032010321103221032310324103251032610327103281032910330103311033210333103341033510336103371033810339103401034110342103431034410345103461034710348103491035010351103521035310354103551035610357103581035910360103611036210363103641036510366103671036810369103701037110372103731037410375103761037710378103791038010381103821038310384103851038610387103881038910390103911039210393103941039510396103971039810399104001040110402104031040410405104061040710408104091041010411104121041310414104151041610417104181041910420104211042210423104241042510426104271042810429104301043110432104331043410435104361043710438104391044010441104421044310444104451044610447104481044910450104511045210453104541045510456104571045810459104601046110462104631046410465104661046710468104691047010471104721047310474104751047610477104781047910480104811048210483104841048510486104871048810489104901049110492104931049410495104961049710498104991050010501105021050310504105051050610507105081050910510105111051210513105141051510516105171051810519105201052110522105231052410525105261052710528105291053010531105321053310534105351053610537105381053910540105411054210543105441054510546105471054810549105501055110552105531055410555105561055710558105591056010561105621056310564105651056610567105681056910570105711057210573105741057510576105771057810579105801058110582105831058410585105861058710588105891059010591105921059310594105951059610597105981059910600106011060210603106041060510606106071060810609106101061110612106131061410615106161061710618106191062010621106221062310624106251062610627106281062910630106311063210633106341063510636106371063810639106401064110642106431064410645106461064710648106491065010651106521065310654106551065610657106581065910660106611066210663106641066510666106671066810669106701067110672106731067410675106761067710678106791068010681106821068310684106851068610687106881068910690106911069210693106941069510696 |
- define(["amber/boot"
- //>>excludeStart("imports", pragmas.excludeImports);
- , "codemirror/addon/hint/show-hint", "codemirror/lib/codemirror", "codemirror/mode/smalltalk/smalltalk", "css!./resources/amber", "css!codemirror/addon/hint/show-hint", "css!codemirror/lib/codemirror", "css!codemirror/theme/ambiance", "jquery-ui"
- //>>excludeEnd("imports");
- , "amber/web/Web", "amber_core/Kernel-Objects"], function($boot
- //>>excludeStart("imports", pragmas.excludeImports);
- //>>excludeEnd("imports");
- ){"use strict";
- if(!$boot.nilAsReceiver)$boot.nilAsReceiver=$boot.nil;
- var $core=$boot.api,nil=$boot.nilAsReceiver,$recv=$boot.asReceiver,$globals=$boot.globals;
- if(!$boot.nilAsClass)$boot.nilAsClass=$boot.dnu;
- $core.addPackage('IDE');
- $core.packages["IDE"].innerEval = function (expr) { return eval(expr); };
- $core.packages["IDE"].imports = ["codemirror/addon/hint/show-hint", "codemirror/lib/codemirror", "codemirror/mode/smalltalk/smalltalk", "css!./resources/amber", "css!codemirror/addon/hint/show-hint", "css!codemirror/lib/codemirror", "css!codemirror/theme/ambiance", "jquery-ui"];
- $core.packages["IDE"].transport = {"type":"amd","amdNamespace":"amber/legacy"};
- $core.addClass('ClassesList', $globals.Widget, ['browser', 'ul', 'nodes'], 'IDE');
- $core.addMethod(
- $core.method({
- selector: "browser",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- return self["@browser"];
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "browser\x0a\x09^ browser",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: []
- }),
- $globals.ClassesList);
- $core.addMethod(
- $core.method({
- selector: "browser:",
- protocol: 'accessing',
- fn: function (aBrowser){
- var self=this;
- self["@browser"]=aBrowser;
- return self;
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["aBrowser"],
- source: "browser: aBrowser\x0a\x09browser := aBrowser",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: []
- }),
- $globals.ClassesList);
- $core.addMethod(
- $core.method({
- selector: "category",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- return $recv(self._browser())._selectedPackage();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"category",{},$globals.ClassesList)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "category\x0a\x09^ self browser selectedPackage",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["selectedPackage", "browser"]
- }),
- $globals.ClassesList);
- $core.addMethod(
- $core.method({
- selector: "getNodes",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- var classes,children,others;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$2;
- $1=self._browser();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["browser"]=1;
- //>>excludeEnd("ctx");
- classes=$recv($1)._classes();
- children=[];
- others=[];
- $recv(classes)._do_((function(each){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- $2=$recv(classes)._includes_($recv(each)._superclass());
- if($core.assert($2)){
- return $recv(others)._add_(each);
- } else {
- return $recv(children)._add_(each);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["add:"]=1;
- //>>excludeEnd("ctx");
- };
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- return $recv(children)._collect_((function(each){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return $recv($globals.ClassesListNode)._on_browser_classes_level_(each,self._browser(),others,(0));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,4)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"getNodes",{classes:classes,children:children,others:others},$globals.ClassesList)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "getNodes\x0a\x09| classes children others |\x0a\x09classes := self browser classes.\x0a\x09children := #().\x0a\x09others := #().\x0a\x09classes do: [ :each |\x0a\x09\x09(classes includes: each superclass)\x0a\x09\x09\x09ifFalse: [ children add: each ]\x0a\x09\x09\x09ifTrue: [ others add: each ]].\x0a\x09^ children collect: [ :each |\x0a\x09\x09ClassesListNode on: each browser: self browser classes: others level: 0 ]",
- referencedClasses: ["ClassesListNode"],
- //>>excludeEnd("ide");
- messageSends: ["classes", "browser", "do:", "ifFalse:ifTrue:", "includes:", "superclass", "add:", "collect:", "on:browser:classes:level:"]
- }),
- $globals.ClassesList);
- $core.addMethod(
- $core.method({
- selector: "nodes",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$receiver;
- $1=self["@nodes"];
- if(($receiver = $1) == null || $receiver.isNil){
- self["@nodes"]=self._getNodes();
- self["@nodes"];
- } else {
- $1;
- };
- return self["@nodes"];
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"nodes",{},$globals.ClassesList)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "nodes\x0a\x09nodes ifNil: [ nodes := self getNodes ].\x0a\x09^ nodes",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["ifNil:", "getNodes"]
- }),
- $globals.ClassesList);
- $core.addMethod(
- $core.method({
- selector: "renderOn:",
- protocol: 'rendering',
- fn: function (html){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1;
- $1=$recv(html)._ul();
- $recv($1)._class_("amber_column browser classes");
- self["@ul"]=$recv($1)._yourself();
- self._updateNodes();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"renderOn:",{html:html},$globals.ClassesList)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["html"],
- source: "renderOn: html\x0a\x09ul := html ul\x0a\x09\x09class: 'amber_column browser classes';\x0a\x09\x09yourself.\x0a\x09self updateNodes",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["class:", "ul", "yourself", "updateNodes"]
- }),
- $globals.ClassesList);
- $core.addMethod(
- $core.method({
- selector: "resetNodes",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- self["@nodes"]=nil;
- return self;
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "resetNodes\x0a\x09nodes := nil",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: []
- }),
- $globals.ClassesList);
- $core.addMethod(
- $core.method({
- selector: "updateNodes",
- protocol: 'rendering',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- $recv(self["@ul"])._contents_((function(html){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return $recv(self._nodes())._do_((function(each){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- return $recv(each)._renderOn_(html);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({each:each},$ctx2,2)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({html:html},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"updateNodes",{},$globals.ClassesList)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "updateNodes\x0a\x09ul contents: [ :html |\x0a\x09\x09self nodes do: [ :each |\x0a\x09\x09\x09each renderOn: html ]]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["contents:", "do:", "nodes", "renderOn:"]
- }),
- $globals.ClassesList);
- $core.addMethod(
- $core.method({
- selector: "on:",
- protocol: 'instance creation',
- fn: function (aBrowser){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1;
- $1=self._new();
- $recv($1)._browser_(aBrowser);
- return $recv($1)._yourself();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"on:",{aBrowser:aBrowser},$globals.ClassesList.klass)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["aBrowser"],
- source: "on: aBrowser\x0a\x09^ self new\x0a\x09\x09browser: aBrowser;\x0a\x09\x09yourself",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["browser:", "new", "yourself"]
- }),
- $globals.ClassesList.klass);
- $core.addClass('ClassesListNode', $globals.Widget, ['browser', 'theClass', 'level', 'nodes'], 'IDE');
- $core.addMethod(
- $core.method({
- selector: "browser",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- return self["@browser"];
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "browser\x0a\x09^ browser",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: []
- }),
- $globals.ClassesListNode);
- $core.addMethod(
- $core.method({
- selector: "browser:",
- protocol: 'accessing',
- fn: function (aBrowser){
- var self=this;
- self["@browser"]=aBrowser;
- return self;
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["aBrowser"],
- source: "browser: aBrowser\x0a\x09browser := aBrowser",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: []
- }),
- $globals.ClassesListNode);
- $core.addMethod(
- $core.method({
- selector: "getNodesFrom:",
- protocol: 'accessing',
- fn: function (aCollection){
- var self=this;
- var children,others;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1;
- children=[];
- others=[];
- $recv(aCollection)._do_((function(each){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- $1=$recv($recv(each)._superclass()).__eq(self._theClass());
- if($core.assert($1)){
- return $recv(children)._add_(each);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["add:"]=1;
- //>>excludeEnd("ctx");
- } else {
- return $recv(others)._add_(each);
- };
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- self["@nodes"]=$recv(children)._collect_((function(each){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return $recv($globals.ClassesListNode)._on_browser_classes_level_(each,self._browser(),others,$recv(self._level()).__plus((1)));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,4)});
- //>>excludeEnd("ctx");
- }));
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"getNodesFrom:",{aCollection:aCollection,children:children,others:others},$globals.ClassesListNode)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["aCollection"],
- source: "getNodesFrom: aCollection\x0a\x09| children others |\x0a\x09children := #().\x0a\x09others := #().\x0a\x09aCollection do: [ :each |\x0a\x09\x09(each superclass = self theClass)\x0a\x09\x09\x09ifTrue: [ children add: each ]\x0a\x09\x09\x09ifFalse: [ others add: each ]].\x0a\x09nodes:= children collect: [ :each |\x0a\x09\x09ClassesListNode on: each browser: self browser classes: others level: self level + 1 ]",
- referencedClasses: ["ClassesListNode"],
- //>>excludeEnd("ide");
- messageSends: ["do:", "ifTrue:ifFalse:", "=", "superclass", "theClass", "add:", "collect:", "on:browser:classes:level:", "browser", "+", "level"]
- }),
- $globals.ClassesListNode);
- $core.addMethod(
- $core.method({
- selector: "label",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- var str;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- str=$recv($recv($globals.String)._new())._writeStream();
- $recv(self._level())._timesRepeat_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return $recv(str)._nextPutAll_(" ");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["nextPutAll:"]=1;
- //>>excludeEnd("ctx");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- $recv(str)._nextPutAll_($recv(self._theClass())._name());
- return $recv(str)._contents();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"label",{str:str},$globals.ClassesListNode)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "label\x0a\x09| str |\x0a\x09str := String new writeStream.\x0a\x09self level timesRepeat: [\x0a\x09\x09str nextPutAll: ' ' ].\x0a\x09str nextPutAll: self theClass name.\x0a\x09^ str contents",
- referencedClasses: ["String"],
- //>>excludeEnd("ide");
- messageSends: ["writeStream", "new", "timesRepeat:", "level", "nextPutAll:", "name", "theClass", "contents"]
- }),
- $globals.ClassesListNode);
- $core.addMethod(
- $core.method({
- selector: "level",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- return self["@level"];
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "level\x0a\x09^ level",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: []
- }),
- $globals.ClassesListNode);
- $core.addMethod(
- $core.method({
- selector: "level:",
- protocol: 'accessing',
- fn: function (anInteger){
- var self=this;
- self["@level"]=anInteger;
- return self;
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["anInteger"],
- source: "level: anInteger\x0a\x09level := anInteger",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: []
- }),
- $globals.ClassesListNode);
- $core.addMethod(
- $core.method({
- selector: "nodes",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- return self["@nodes"];
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "nodes\x0a\x09^ nodes",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: []
- }),
- $globals.ClassesListNode);
- $core.addMethod(
- $core.method({
- selector: "renderOn:",
- protocol: 'rendering',
- fn: function (html){
- var self=this;
- var li,cssClass;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$2,$4,$5,$3;
- cssClass="";
- li=$recv($recv(html)._li())._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- $1=self._browser();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["browser"]=1;
- //>>excludeEnd("ctx");
- $2=self._theClass();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["theClass"]=1;
- //>>excludeEnd("ctx");
- return $recv($1)._selectClass_($2);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- $recv($recv(li)._asJQuery())._html_(self._label());
- $4=$recv(self._browser())._selectedClass();
- $5=self._theClass();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["theClass"]=2;
- //>>excludeEnd("ctx");
- $3=$recv($4).__eq($5);
- if($core.assert($3)){
- cssClass=$recv(cssClass).__comma(" selected");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx[","]=1;
- //>>excludeEnd("ctx");
- cssClass;
- };
- $recv($recv(self._theClass())._comment())._ifNotEmpty_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- cssClass=$recv(cssClass).__comma(" commented");
- return cssClass;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,3)});
- //>>excludeEnd("ctx");
- }));
- $recv(li)._class_(cssClass);
- $recv(self._nodes())._do_((function(each){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return $recv(each)._renderOn_(html);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,4)});
- //>>excludeEnd("ctx");
- }));
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"renderOn:",{html:html,li:li,cssClass:cssClass},$globals.ClassesListNode)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["html"],
- source: "renderOn: html\x0a\x09| li cssClass |\x0a\x09cssClass := ''.\x0a\x09li := html li\x0a\x09\x09onClick: [ self browser selectClass: self theClass ].\x0a\x09li asJQuery html: self label.\x0a\x0a\x09self browser selectedClass = self theClass ifTrue: [\x0a\x09\x09cssClass := cssClass, ' selected' ].\x0a\x0a\x09self theClass comment ifNotEmpty: [\x0a\x09\x09cssClass := cssClass, ' commented' ].\x0a\x0a\x09li class: cssClass.\x0a\x0a\x09self nodes do: [ :each |\x0a\x09\x09each renderOn: html ]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["onClick:", "li", "selectClass:", "browser", "theClass", "html:", "asJQuery", "label", "ifTrue:", "=", "selectedClass", ",", "ifNotEmpty:", "comment", "class:", "do:", "nodes", "renderOn:"]
- }),
- $globals.ClassesListNode);
- $core.addMethod(
- $core.method({
- selector: "theClass",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- return self["@theClass"];
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "theClass\x0a\x09^ theClass",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: []
- }),
- $globals.ClassesListNode);
- $core.addMethod(
- $core.method({
- selector: "theClass:",
- protocol: 'accessing',
- fn: function (aClass){
- var self=this;
- self["@theClass"]=aClass;
- return self;
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["aClass"],
- source: "theClass: aClass\x0a\x09theClass := aClass",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: []
- }),
- $globals.ClassesListNode);
- $core.addMethod(
- $core.method({
- selector: "on:browser:classes:level:",
- protocol: 'instance creation',
- fn: function (aClass,aBrowser,aCollection,anInteger){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1;
- $1=self._new();
- $recv($1)._theClass_(aClass);
- $recv($1)._browser_(aBrowser);
- $recv($1)._level_(anInteger);
- $recv($1)._getNodesFrom_(aCollection);
- return $recv($1)._yourself();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"on:browser:classes:level:",{aClass:aClass,aBrowser:aBrowser,aCollection:aCollection,anInteger:anInteger},$globals.ClassesListNode.klass)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["aClass", "aBrowser", "aCollection", "anInteger"],
- source: "on: aClass browser: aBrowser classes: aCollection level: anInteger\x0a\x09^ self new\x0a\x09\x09theClass: aClass;\x0a\x09\x09browser: aBrowser;\x0a\x09\x09level: anInteger;\x0a\x09\x09getNodesFrom: aCollection;\x0a\x09\x09yourself",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["theClass:", "new", "browser:", "level:", "getNodesFrom:", "yourself"]
- }),
- $globals.ClassesListNode.klass);
- $core.addClass('DebugErrorHandler', $globals.Object, [], 'IDE');
- $core.addMethod(
- $core.method({
- selector: "handleError:",
- protocol: 'error handling',
- fn: function (anError){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1;
- $recv((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- $1=$recv($globals.Debugger)._new();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["new"]=1;
- //>>excludeEnd("ctx");
- $recv($1)._error_(anError);
- return $recv($1)._open();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
- //>>excludeEnd("ctx");
- }))._on_do_($globals.Error,(function(error){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return $recv($recv($globals.ConsoleErrorHandler)._new())._handleError_(error);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({error:error},$ctx1,2)});
- //>>excludeEnd("ctx");
- }));
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"handleError:",{anError:anError},$globals.DebugErrorHandler)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["anError"],
- source: "handleError: anError\x0a\x09[ Debugger new\x0a\x09\x09error: anError;\x0a\x09\x09open ] on: Error do: [ :error |\x0a\x09\x09\x09ConsoleErrorHandler new handleError: error ]",
- referencedClasses: ["Debugger", "Error", "ConsoleErrorHandler"],
- //>>excludeEnd("ide");
- messageSends: ["on:do:", "error:", "new", "open", "handleError:"]
- }),
- $globals.DebugErrorHandler);
- $core.addMethod(
- $core.method({
- selector: "initialize",
- protocol: 'initialization',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- $recv($globals.ErrorHandler)._register_(self._new());
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"initialize",{},$globals.DebugErrorHandler.klass)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "initialize\x0a\x09ErrorHandler register: self new",
- referencedClasses: ["ErrorHandler"],
- //>>excludeEnd("ide");
- messageSends: ["register:", "new"]
- }),
- $globals.DebugErrorHandler.klass);
- $core.addClass('SourceArea', $globals.Widget, ['editor', 'div', 'receiver', 'onDoIt'], 'IDE');
- $core.addMethod(
- $core.method({
- selector: "clear",
- protocol: 'actions',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- self._val_("");
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"clear",{},$globals.SourceArea)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "clear\x0a\x09self val: ''",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["val:"]
- }),
- $globals.SourceArea);
- $core.addMethod(
- $core.method({
- selector: "currentLine",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- return $recv(self["@editor"])._getLine_($recv($recv(self["@editor"])._getCursor())._line());
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"currentLine",{},$globals.SourceArea)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "currentLine\x0a\x09^ editor getLine: (editor getCursor line)",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["getLine:", "line", "getCursor"]
- }),
- $globals.SourceArea);
- $core.addMethod(
- $core.method({
- selector: "currentLineOrSelection",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1;
- $1=$recv(self["@editor"])._somethingSelected();
- if($core.assert($1)){
- return self._selection();
- } else {
- return self._currentLine();
- };
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"currentLineOrSelection",{},$globals.SourceArea)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "currentLineOrSelection\x0a\x09^ editor somethingSelected\x0a\x09ifFalse: [ self currentLine ]\x0a\x09ifTrue: [ self selection ]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["ifFalse:ifTrue:", "somethingSelected", "currentLine", "selection"]
- }),
- $globals.SourceArea);
- $core.addMethod(
- $core.method({
- selector: "doIt",
- protocol: 'actions',
- fn: function (){
- var self=this;
- var result;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$receiver;
- result=self._eval_(self._currentLineOrSelection());
- $1=self._onDoIt();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["onDoIt"]=1;
- //>>excludeEnd("ctx");
- if(($receiver = $1) == null || $receiver.isNil){
- $1;
- } else {
- $recv(self._onDoIt())._value();
- };
- return result;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"doIt",{result:result},$globals.SourceArea)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "doIt\x0a\x09| result |\x0a\x09result := self eval: self currentLineOrSelection.\x0a\x09self onDoIt ifNotNil: [ self onDoIt value ].\x0a\x09^ result",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["eval:", "currentLineOrSelection", "ifNotNil:", "onDoIt", "value"]
- }),
- $globals.SourceArea);
- $core.addMethod(
- $core.method({
- selector: "editor",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- return self["@editor"];
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "editor\x0a\x09^ editor",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: []
- }),
- $globals.SourceArea);
- $core.addMethod(
- $core.method({
- selector: "eval:",
- protocol: 'actions',
- fn: function (aString){
- var self=this;
- var compiler;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $early={};
- try {
- compiler=$recv($globals.Compiler)._new();
- $recv((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return $recv(compiler)._parseExpression_(aString);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
- //>>excludeEnd("ctx");
- }))._on_do_($globals.Error,(function(ex){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- throw $early=[$recv($globals.Terminal)._alert_($recv(ex)._messageText())];
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({ex:ex},$ctx1,2)});
- //>>excludeEnd("ctx");
- }));
- return $recv(compiler)._evaluateExpression_on_(aString,self._receiver());
- }
- catch(e) {if(e===$early)return e[0]; throw e}
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"eval:",{aString:aString,compiler:compiler},$globals.SourceArea)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["aString"],
- source: "eval: aString\x0a\x09| compiler |\x0a\x09compiler := Compiler new.\x0a\x09[ compiler parseExpression: aString ] on: Error do: [ :ex |\x0a\x09\x09^ Terminal alert: ex messageText ].\x0a\x09^ compiler evaluateExpression: aString on: self receiver",
- referencedClasses: ["Compiler", "Error", "Terminal"],
- //>>excludeEnd("ide");
- messageSends: ["new", "on:do:", "parseExpression:", "alert:", "messageText", "evaluateExpression:on:", "receiver"]
- }),
- $globals.SourceArea);
- $core.addMethod(
- $core.method({
- selector: "fileIn",
- protocol: 'actions',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- $recv($recv($globals.Importer)._new())._import_($recv(self._currentLineOrSelection())._readStream());
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"fileIn",{},$globals.SourceArea)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "fileIn\x0a\x09Importer new import: self currentLineOrSelection readStream",
- referencedClasses: ["Importer"],
- //>>excludeEnd("ide");
- messageSends: ["import:", "new", "readStream", "currentLineOrSelection"]
- }),
- $globals.SourceArea);
- $core.addMethod(
- $core.method({
- selector: "focus",
- protocol: 'actions',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- $recv(self._editor())._focus();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"focus",{},$globals.SourceArea)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "focus\x0a\x09self editor focus.",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["focus", "editor"]
- }),
- $globals.SourceArea);
- $core.addMethod(
- $core.method({
- selector: "handleKeyDown:",
- protocol: 'actions',
- fn: function (anEvent){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- if(anEvent.ctrlKey) {
- if(anEvent.keyCode === 80) { //ctrl+p
- self._printIt();
- anEvent.preventDefault();
- return false;
- }
- if(anEvent.keyCode === 68) { //ctrl+d
- self._doIt();
- anEvent.preventDefault();
- return false;
- }
- if(anEvent.keyCode === 73) { //ctrl+i
- self._inspectIt();
- anEvent.preventDefault();
- return false;
- }
- };
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"handleKeyDown:",{anEvent:anEvent},$globals.SourceArea)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["anEvent"],
- source: "handleKeyDown: anEvent\x0a\x09<if(anEvent.ctrlKey) {\x0a\x09\x09if(anEvent.keyCode === 80) { //ctrl+p\x0a\x09\x09\x09self._printIt();\x0a\x09\x09\x09anEvent.preventDefault();\x0a\x09\x09\x09return false;\x0a\x09\x09}\x0a\x09\x09if(anEvent.keyCode === 68) { //ctrl+d\x0a\x09\x09\x09self._doIt();\x0a\x09\x09\x09anEvent.preventDefault();\x0a\x09\x09\x09return false;\x0a\x09\x09}\x0a\x09\x09if(anEvent.keyCode === 73) { //ctrl+i\x0a\x09\x09\x09self._inspectIt();\x0a\x09\x09\x09anEvent.preventDefault();\x0a\x09\x09\x09return false;\x0a\x09\x09}\x0a\x09}>",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: []
- }),
- $globals.SourceArea);
- $core.addMethod(
- $core.method({
- selector: "inspectIt",
- protocol: 'actions',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- $recv(self._doIt())._inspect();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"inspectIt",{},$globals.SourceArea)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "inspectIt\x0a\x09self doIt inspect",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["inspect", "doIt"]
- }),
- $globals.SourceArea);
- $core.addMethod(
- $core.method({
- selector: "onDoIt",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- return self["@onDoIt"];
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "onDoIt\x0a\x09^ onDoIt",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: []
- }),
- $globals.SourceArea);
- $core.addMethod(
- $core.method({
- selector: "onDoIt:",
- protocol: 'accessing',
- fn: function (aBlock){
- var self=this;
- self["@onDoIt"]=aBlock;
- return self;
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["aBlock"],
- source: "onDoIt: aBlock\x0a\x09onDoIt := aBlock",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: []
- }),
- $globals.SourceArea);
- $core.addMethod(
- $core.method({
- selector: "onKeyDown:",
- protocol: 'events',
- fn: function (aBlock){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- $recv(self["@div"])._onKeyDown_(aBlock);
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"onKeyDown:",{aBlock:aBlock},$globals.SourceArea)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["aBlock"],
- source: "onKeyDown: aBlock\x0a\x09div onKeyDown: aBlock",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["onKeyDown:"]
- }),
- $globals.SourceArea);
- $core.addMethod(
- $core.method({
- selector: "onKeyUp:",
- protocol: 'events',
- fn: function (aBlock){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- $recv(self["@div"])._onKeyUp_(aBlock);
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"onKeyUp:",{aBlock:aBlock},$globals.SourceArea)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["aBlock"],
- source: "onKeyUp: aBlock\x0a\x09div onKeyUp: aBlock",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["onKeyUp:"]
- }),
- $globals.SourceArea);
- $core.addMethod(
- $core.method({
- selector: "print:",
- protocol: 'actions',
- fn: function (aString){
- var self=this;
- var start,stop,currentLine;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$2,$4,$3,$5,$6,$7,$8,$9,$10,$12,$11;
- $1=$recv(self["@editor"])._getCursor_(false);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["getCursor:"]=1;
- //>>excludeEnd("ctx");
- currentLine=$recv($1)._line();
- start=$recv($globals.HashedCollection)._new();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["new"]=1;
- //>>excludeEnd("ctx");
- $recv(start)._at_put_("line",currentLine);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["at:put:"]=1;
- //>>excludeEnd("ctx");
- $2=start;
- $4=$recv(self["@editor"])._getCursor_(false);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["getCursor:"]=2;
- //>>excludeEnd("ctx");
- $3=$recv($4)._ch();
- $recv($2)._at_put_("ch",$3);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["at:put:"]=2;
- //>>excludeEnd("ctx");
- $5=$recv(self["@editor"])._getSelection();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["getSelection"]=1;
- //>>excludeEnd("ctx");
- $recv($5)._ifEmpty_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- $6=start;
- $7=$recv($recv(self["@editor"])._getLine_(currentLine))._size();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["size"]=1;
- //>>excludeEnd("ctx");
- $recv($6)._at_put_("ch",$7);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["at:put:"]=3;
- //>>excludeEnd("ctx");
- return $recv(self["@editor"])._setSelection_end_($globals.HashedCollection._newFromPairs_(["line",currentLine,"ch",(0)]),start);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["setSelection:end:"]=1;
- //>>excludeEnd("ctx");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- stop=$recv($globals.HashedCollection)._new();
- $recv(stop)._at_put_("line",currentLine);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["at:put:"]=4;
- //>>excludeEnd("ctx");
- $8=stop;
- $9=$recv($recv($recv(start)._at_("ch")).__plus($recv(aString)._size())).__plus((2));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["+"]=1;
- //>>excludeEnd("ctx");
- $recv($8)._at_put_("ch",$9);
- $10=self["@editor"];
- $12=$recv($recv($recv(self["@editor"])._getSelection()).__comma(" ")).__comma(aString);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx[","]=2;
- //>>excludeEnd("ctx");
- $11=$recv($12).__comma(" ");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx[","]=1;
- //>>excludeEnd("ctx");
- $recv($10)._replaceSelection_($11);
- $recv(self["@editor"])._setCursor_($recv(self["@editor"])._getCursor_(true));
- $recv(self["@editor"])._setSelection_end_(stop,start);
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"print:",{aString:aString,start:start,stop:stop,currentLine:currentLine},$globals.SourceArea)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["aString"],
- source: "print: aString\x0a\x09| start stop currentLine |\x0a\x09currentLine := (editor getCursor: false) line.\x0a\x09start := HashedCollection new.\x0a\x09start at: 'line' put: currentLine.\x0a\x09start at: 'ch' put: (editor getCursor: false) ch.\x0a\x09(editor getSelection) ifEmpty: [\x0a\x09\x09\x22select current line if selection is empty\x22\x0a\x09\x09start at: 'ch' put: (editor getLine: currentLine) size.\x0a\x09\x09editor setSelection: #{'line' -> currentLine. 'ch' -> 0} end: start.\x0a\x09].\x0a\x09stop := HashedCollection new.\x0a\x09stop at: 'line' put: currentLine.\x0a\x09stop at: 'ch' put: ((start at: 'ch') + aString size + 2).\x0a\x0a\x09editor replaceSelection: (editor getSelection, ' ', aString, ' ').\x0a\x09editor setCursor: (editor getCursor: true).\x0a\x09editor setSelection: stop end: start",
- referencedClasses: ["HashedCollection"],
- //>>excludeEnd("ide");
- messageSends: ["line", "getCursor:", "new", "at:put:", "ch", "ifEmpty:", "getSelection", "size", "getLine:", "setSelection:end:", "+", "at:", "replaceSelection:", ",", "setCursor:"]
- }),
- $globals.SourceArea);
- $core.addMethod(
- $core.method({
- selector: "printIt",
- protocol: 'actions',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- self._print_($recv(self._doIt())._printString());
- self._focus();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"printIt",{},$globals.SourceArea)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "printIt\x0a\x09self print: self doIt printString.\x0a\x09self focus.",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["print:", "printString", "doIt", "focus"]
- }),
- $globals.SourceArea);
- $core.addMethod(
- $core.method({
- selector: "receiver",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$receiver;
- $1=self["@receiver"];
- if(($receiver = $1) == null || $receiver.isNil){
- return $recv($globals.DoIt)._new();
- } else {
- return $1;
- };
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"receiver",{},$globals.SourceArea)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "receiver\x0a\x09^ receiver ifNil: [ DoIt new ]",
- referencedClasses: ["DoIt"],
- //>>excludeEnd("ide");
- messageSends: ["ifNil:", "new"]
- }),
- $globals.SourceArea);
- $core.addMethod(
- $core.method({
- selector: "receiver:",
- protocol: 'accessing',
- fn: function (anObject){
- var self=this;
- self["@receiver"]=anObject;
- return self;
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["anObject"],
- source: "receiver: anObject\x0a\x09receiver := anObject",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: []
- }),
- $globals.SourceArea);
- $core.addMethod(
- $core.method({
- selector: "renderOn:",
- protocol: 'rendering',
- fn: function (html){
- var self=this;
- var textarea;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- self["@div"]=$recv($recv(html)._div())._class_("source");
- $recv(self["@div"])._with_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- textarea=$recv(html)._textarea();
- return textarea;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- self._setEditorOn_($recv(textarea)._element());
- $recv(self["@div"])._onKeyDown_((function(e){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return self._handleKeyDown_(e);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({e:e},$ctx1,2)});
- //>>excludeEnd("ctx");
- }));
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"renderOn:",{html:html,textarea:textarea},$globals.SourceArea)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["html"],
- source: "renderOn: html\x0a\x09| textarea |\x0a\x09div := html div class: 'source'.\x0a\x09div with: [ textarea := html textarea ].\x0a\x09self setEditorOn: textarea element.\x0a\x09div onKeyDown: [ :e | self handleKeyDown: e ]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["class:", "div", "with:", "textarea", "setEditorOn:", "element", "onKeyDown:", "handleKeyDown:"]
- }),
- $globals.SourceArea);
- $core.addMethod(
- $core.method({
- selector: "selection",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- return $recv(self["@editor"])._getSelection();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"selection",{},$globals.SourceArea)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "selection\x0a\x09^ editor getSelection",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["getSelection"]
- }),
- $globals.SourceArea);
- $core.addMethod(
- $core.method({
- selector: "setEditorOn:",
- protocol: 'accessing',
- fn: function (aTextarea){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- self['@editor'] = self._class()._codeMirror().fromTextArea(aTextarea, {
- theme: 'ide.codeMirrorTheme'._settingValueIfAbsent_('default'),
- mode: 'text/x-stsrc',
- lineNumbers: true,
- enterMode: 'flat',
- indentWithTabs: true,
- indentUnit: 4,
- matchBrackets: true,
- electricChars: false
- });
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"setEditorOn:",{aTextarea:aTextarea},$globals.SourceArea)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["aTextarea"],
- source: "setEditorOn: aTextarea\x0a\x09<self['@editor'] = self._class()._codeMirror().fromTextArea(aTextarea, {\x0a\x09\x09theme: 'ide.codeMirrorTheme'._settingValueIfAbsent_('default'),\x0a\x09\x09mode: 'text/x-stsrc',\x0a\x09\x09lineNumbers: true,\x0a\x09\x09enterMode: 'flat',\x0a\x09\x09indentWithTabs: true,\x0a\x09\x09indentUnit: 4,\x0a\x09\x09matchBrackets: true,\x0a\x09\x09electricChars: false\x0a\x09})>",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: []
- }),
- $globals.SourceArea);
- $core.addMethod(
- $core.method({
- selector: "val",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- return $recv(self["@editor"])._getValue();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"val",{},$globals.SourceArea)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "val\x0a\x09^ editor getValue",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["getValue"]
- }),
- $globals.SourceArea);
- $core.addMethod(
- $core.method({
- selector: "val:",
- protocol: 'accessing',
- fn: function (aString){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- $recv(self["@editor"])._setValue_(aString);
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"val:",{aString:aString},$globals.SourceArea)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["aString"],
- source: "val: aString\x0a\x09editor setValue: aString",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["setValue:"]
- }),
- $globals.SourceArea);
- $core.addMethod(
- $core.method({
- selector: "codeMirror",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- return $recv(require)._value_("codemirror/lib/codemirror");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"codeMirror",{},$globals.SourceArea.klass)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "codeMirror\x0a\x09^ require value: 'codemirror/lib/codemirror'",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["value:"]
- }),
- $globals.SourceArea.klass);
- $core.addMethod(
- $core.method({
- selector: "initialize",
- protocol: 'initialization',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- (
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.supercall = true,
- //>>excludeEnd("ctx");
- ($globals.SourceArea.klass.superclass||$boot.nilAsClass).fn.prototype._initialize.apply($recv(self), []));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.supercall = false;
- //>>excludeEnd("ctx");;
- self._setupCodeMirror();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"initialize",{},$globals.SourceArea.klass)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "initialize\x0a\x09super initialize.\x0a\x09self setupCodeMirror",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["initialize", "setupCodeMirror"]
- }),
- $globals.SourceArea.klass);
- $core.addMethod(
- $core.method({
- selector: "setupCodeMirror",
- protocol: 'initialization',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- self._codeMirror().keyMap["default"].fallthrough = ["basic"] ;
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"setupCodeMirror",{},$globals.SourceArea.klass)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "setupCodeMirror\x0a\x09< self._codeMirror().keyMap[\x22default\x22].fallthrough = [\x22basic\x22] >",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: []
- }),
- $globals.SourceArea.klass);
- $core.addClass('TabManager', $globals.Widget, ['selectedTab', 'tabs', 'opened', 'ul', 'input'], 'IDE');
- $core.addMethod(
- $core.method({
- selector: "addTab:",
- protocol: 'adding/Removing',
- fn: function (aWidget){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- $recv(self._tabs())._add_(aWidget);
- $recv(aWidget)._appendToJQuery_("#amber"._asJQuery());
- $recv(aWidget)._hide();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"addTab:",{aWidget:aWidget},$globals.TabManager)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["aWidget"],
- source: "addTab: aWidget\x0a\x09self tabs add: aWidget.\x0a\x09aWidget appendToJQuery: '#amber' asJQuery.\x0a\x09aWidget hide",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["add:", "tabs", "appendToJQuery:", "asJQuery", "hide"]
- }),
- $globals.TabManager);
- $core.addMethod(
- $core.method({
- selector: "close",
- protocol: 'actions',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$2,$3;
- $1=self["@opened"];
- if($core.assert($1)){
- $2="#amber"._asJQuery();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["asJQuery"]=1;
- //>>excludeEnd("ctx");
- $recv($2)._hide();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["hide"]=1;
- //>>excludeEnd("ctx");
- $3=$recv(self["@ul"])._asJQuery();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["asJQuery"]=2;
- //>>excludeEnd("ctx");
- $recv($3)._hide();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["hide"]=2;
- //>>excludeEnd("ctx");
- $recv(self["@selectedTab"])._hide();
- self._removeBodyMargin();
- $recv("body"._asJQuery())._removeClass_("amberBody");
- self["@opened"]=false;
- self["@opened"];
- };
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"close",{},$globals.TabManager)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "close\x0a\x09opened ifTrue: [\x0a\x09'#amber' asJQuery hide.\x0a\x09ul asJQuery hide.\x0a\x09selectedTab hide.\x0a\x09self removeBodyMargin.\x0a\x09'body' asJQuery removeClass: 'amberBody'.\x0a\x09opened := false ]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["ifTrue:", "hide", "asJQuery", "removeBodyMargin", "removeClass:"]
- }),
- $globals.TabManager);
- $core.addMethod(
- $core.method({
- selector: "closeTab:",
- protocol: 'actions',
- fn: function (aWidget){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- self._removeTab_(aWidget);
- self._selectTab_($recv(self._tabs())._last());
- $recv(aWidget)._remove();
- self._update();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"closeTab:",{aWidget:aWidget},$globals.TabManager)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["aWidget"],
- source: "closeTab: aWidget\x0a\x09self removeTab: aWidget.\x0a\x09self selectTab: self tabs last.\x0a\x09aWidget remove.\x0a\x09self update",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["removeTab:", "selectTab:", "last", "tabs", "remove", "update"]
- }),
- $globals.TabManager);
- $core.addMethod(
- $core.method({
- selector: "initialize",
- protocol: 'initialization',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$2,$3,$4,$5;
- (
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.supercall = true,
- //>>excludeEnd("ctx");
- ($globals.TabManager.superclass||$boot.nilAsClass).fn.prototype._initialize.apply($recv(self), []));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.supercall = false;
- //>>excludeEnd("ctx");;
- $recv($globals.Inspector)._register_($globals.IDEInspector);
- self["@opened"]=true;
- $1=(function(html){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return $recv($recv(html)._div())._id_("amber");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({html:html},$ctx1,1)});
- //>>excludeEnd("ctx");
- });
- $2="body"._asJQuery();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["asJQuery"]=1;
- //>>excludeEnd("ctx");
- $recv($1)._appendToJQuery_($2);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["appendToJQuery:"]=1;
- //>>excludeEnd("ctx");
- $3="body"._asJQuery();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["asJQuery"]=2;
- //>>excludeEnd("ctx");
- $recv($3)._addClass_("amberBody");
- self._appendToJQuery_("#amber"._asJQuery());
- self._addTab_($recv($globals.IDETranscript)._current());
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["addTab:"]=1;
- //>>excludeEnd("ctx");
- $4=$recv($globals.Workspace)._new();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["new"]=1;
- //>>excludeEnd("ctx");
- self._addTab_($4);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["addTab:"]=2;
- //>>excludeEnd("ctx");
- self._addTab_($recv($globals.TestRunner)._new());
- self._selectTab_($recv(self._tabs())._last());
- self._onResize_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- self._updateBodyMargin();
- $5=self._updatePosition();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["updatePosition"]=1;
- //>>excludeEnd("ctx");
- return $5;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
- //>>excludeEnd("ctx");
- }));
- self._onWindowResize_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return self._updatePosition();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,3)});
- //>>excludeEnd("ctx");
- }));
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"initialize",{},$globals.TabManager)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "initialize\x0a\x09super initialize.\x0a\x09Inspector register: IDEInspector.\x0a\x09opened := true.\x0a\x09[ :html | html div id: 'amber' ] appendToJQuery: 'body' asJQuery.\x0a\x09'body' asJQuery\x0a\x09addClass: 'amberBody'.\x0a\x09self appendToJQuery: '#amber' asJQuery.\x0a\x09self\x0a\x09addTab: IDETranscript current;\x0a\x09addTab: Workspace new;\x0a\x09addTab: TestRunner new.\x0a\x09self selectTab: self tabs last.\x0a\x09self\x0a\x09onResize: [ self updateBodyMargin; updatePosition ];\x0a\x09onWindowResize: [ self updatePosition ]",
- referencedClasses: ["Inspector", "IDEInspector", "IDETranscript", "Workspace", "TestRunner"],
- //>>excludeEnd("ide");
- messageSends: ["initialize", "register:", "appendToJQuery:", "id:", "div", "asJQuery", "addClass:", "addTab:", "current", "new", "selectTab:", "last", "tabs", "onResize:", "updateBodyMargin", "updatePosition", "onWindowResize:"]
- }),
- $globals.TabManager);
- $core.addMethod(
- $core.method({
- selector: "labelFor:",
- protocol: 'accessing',
- fn: function (aWidget){
- var self=this;
- var label,maxSize;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$4,$3,$2,$5;
- maxSize=(15);
- $1=$recv(aWidget)._label();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["label"]=1;
- //>>excludeEnd("ctx");
- $4=$recv(aWidget)._label();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["label"]=2;
- //>>excludeEnd("ctx");
- $3=$recv($4)._size();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["size"]=1;
- //>>excludeEnd("ctx");
- $2=$recv($3)._min_(maxSize);
- label=$recv($1)._copyFrom_to_((0),$2);
- $5=$recv($recv($recv(aWidget)._label())._size()).__gt(maxSize);
- if($core.assert($5)){
- label=$recv(label).__comma("...");
- label;
- };
- return label;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"labelFor:",{aWidget:aWidget,label:label,maxSize:maxSize},$globals.TabManager)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["aWidget"],
- source: "labelFor: aWidget\x0a\x09| label maxSize |\x0a\x09maxSize := 15.\x0a\x09label := aWidget label copyFrom: 0 to: (aWidget label size min: maxSize).\x0a\x09aWidget label size > maxSize ifTrue: [\x0a\x09\x09label := label, '...' ].\x0a\x09^ label",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["copyFrom:to:", "label", "min:", "size", "ifTrue:", ">", ","]
- }),
- $globals.TabManager);
- $core.addMethod(
- $core.method({
- selector: "newBrowserTab",
- protocol: 'actions',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- $recv($globals.Browser)._open();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"newBrowserTab",{},$globals.TabManager)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "newBrowserTab\x0a\x09Browser open",
- referencedClasses: ["Browser"],
- //>>excludeEnd("ide");
- messageSends: ["open"]
- }),
- $globals.TabManager);
- $core.addMethod(
- $core.method({
- selector: "onResize:",
- protocol: 'actions',
- fn: function (aBlock){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- $recv("#amber"._asJQuery())._resizable_($globals.HashedCollection._newFromPairs_(["handles","n","resize",aBlock,"minHeight",(230)]));
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"onResize:",{aBlock:aBlock},$globals.TabManager)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["aBlock"],
- source: "onResize: aBlock\x0a\x09'#amber' asJQuery resizable: #{\x0a\x09\x09'handles' -> 'n'.\x0a\x09\x09'resize' -> aBlock.\x0a\x09\x09'minHeight' -> 230\x0a\x09}",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["resizable:", "asJQuery"]
- }),
- $globals.TabManager);
- $core.addMethod(
- $core.method({
- selector: "onWindowResize:",
- protocol: 'actions',
- fn: function (aBlock){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- $recv($recv(window)._asJQuery())._resize_(aBlock);
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"onWindowResize:",{aBlock:aBlock},$globals.TabManager)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["aBlock"],
- source: "onWindowResize: aBlock\x0a\x09window asJQuery resize: aBlock",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["resize:", "asJQuery"]
- }),
- $globals.TabManager);
- $core.addMethod(
- $core.method({
- selector: "open",
- protocol: 'actions',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$2,$3;
- $1=self["@opened"];
- if(!$core.assert($1)){
- $2="body"._asJQuery();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["asJQuery"]=1;
- //>>excludeEnd("ctx");
- $recv($2)._addClass_("amberBody");
- $3="#amber"._asJQuery();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["asJQuery"]=2;
- //>>excludeEnd("ctx");
- $recv($3)._show();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["show"]=1;
- //>>excludeEnd("ctx");
- $recv($recv(self["@ul"])._asJQuery())._show();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["show"]=2;
- //>>excludeEnd("ctx");
- self._updateBodyMargin();
- $recv(self["@selectedTab"])._show();
- self["@opened"]=true;
- self["@opened"];
- };
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"open",{},$globals.TabManager)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "open\x0a\x09opened ifFalse: [\x0a\x09'body' asJQuery addClass: 'amberBody'.\x0a\x09'#amber' asJQuery show.\x0a\x09ul asJQuery show.\x0a\x09self updateBodyMargin.\x0a\x09selectedTab show.\x0a\x09opened := true ]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["ifFalse:", "addClass:", "asJQuery", "show", "updateBodyMargin"]
- }),
- $globals.TabManager);
- $core.addMethod(
- $core.method({
- selector: "removeBodyMargin",
- protocol: 'actions',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- self._setBodyMargin_((0));
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"removeBodyMargin",{},$globals.TabManager)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "removeBodyMargin\x0a\x09self setBodyMargin: 0",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["setBodyMargin:"]
- }),
- $globals.TabManager);
- $core.addMethod(
- $core.method({
- selector: "removeTab:",
- protocol: 'adding/Removing',
- fn: function (aWidget){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- $recv(self._tabs())._remove_(aWidget);
- self._update();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"removeTab:",{aWidget:aWidget},$globals.TabManager)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["aWidget"],
- source: "removeTab: aWidget\x0a\x09self tabs remove: aWidget.\x0a\x09self update",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["remove:", "tabs", "update"]
- }),
- $globals.TabManager);
- $core.addMethod(
- $core.method({
- selector: "renderOn:",
- protocol: 'rendering',
- fn: function (html){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1;
- $recv($recv(html)._div())._id_("logo");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["id:"]=1;
- //>>excludeEnd("ctx");
- self._renderToolbarOn_(html);
- $1=$recv(html)._ul();
- $recv($1)._id_("amberTabs");
- self["@ul"]=$recv($1)._yourself();
- self._renderTabs();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"renderOn:",{html:html},$globals.TabManager)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["html"],
- source: "renderOn: html\x0a\x09html div id: 'logo'.\x0a\x09self renderToolbarOn: html.\x0a\x09ul := html ul\x0a\x09\x09id: 'amberTabs';\x0a\x09\x09yourself.\x0a\x09self renderTabs",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["id:", "div", "renderToolbarOn:", "ul", "yourself", "renderTabs"]
- }),
- $globals.TabManager);
- $core.addMethod(
- $core.method({
- selector: "renderTabFor:on:",
- protocol: 'rendering',
- fn: function (aWidget,html){
- var self=this;
- var li;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$2,$3,$4,$6,$7,$8,$9,$5;
- li=$recv(html)._li();
- $1=$recv(self["@selectedTab"]).__eq(aWidget);
- if($core.assert($1)){
- $recv(li)._class_("selected");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["class:"]=1;
- //>>excludeEnd("ctx");
- };
- $2=li;
- $recv($2)._with_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- $3=$recv(html)._span();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["span"]=1;
- //>>excludeEnd("ctx");
- $recv($3)._class_("ltab");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["class:"]=2;
- //>>excludeEnd("ctx");
- $4=$recv(html)._span();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["span"]=2;
- //>>excludeEnd("ctx");
- $recv($4)._class_("mtab");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["class:"]=3;
- //>>excludeEnd("ctx");
- $5=$recv($4)._with_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- $6=$recv(aWidget)._canBeClosed();
- if($core.assert($6)){
- $7=$recv(html)._span();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["span"]=3;
- //>>excludeEnd("ctx");
- $recv($7)._class_("close");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["class:"]=4;
- //>>excludeEnd("ctx");
- $recv($7)._with_("x");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["with:"]=3;
- //>>excludeEnd("ctx");
- $8=$recv($7)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx4) {
- //>>excludeEnd("ctx");
- return self._closeTab_(aWidget);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx4) {$ctx4.fillBlock({},$ctx3,5)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["onClick:"]=1;
- //>>excludeEnd("ctx");
- $8;
- };
- $9=$recv(html)._span();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["span"]=4;
- //>>excludeEnd("ctx");
- return $recv($9)._with_(self._labelFor_(aWidget));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({},$ctx2,3)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["with:"]=2;
- //>>excludeEnd("ctx");
- $5;
- return $recv($recv(html)._span())._class_("rtab");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["with:"]=1;
- //>>excludeEnd("ctx");
- $recv($2)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return self._selectTab_(aWidget);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,6)});
- //>>excludeEnd("ctx");
- }));
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"renderTabFor:on:",{aWidget:aWidget,html:html,li:li},$globals.TabManager)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["aWidget", "html"],
- source: "renderTabFor: aWidget on: html\x0a\x09| li |\x0a\x09li := html li.\x0a\x09selectedTab = aWidget ifTrue: [\x0a\x09li class: 'selected' ].\x0a\x09li with: [\x0a\x09\x09html span class: 'ltab'.\x0a\x09\x09html span\x0a\x09\x09\x09class: 'mtab';\x0a\x09\x09\x09with: [\x0a\x09\x09\x09\x09aWidget canBeClosed ifTrue: [\x0a\x09\x09\x09\x09\x09html span\x0a\x09\x09\x09\x09\x09\x09class: 'close';\x0a\x09\x09\x09\x09\x09\x09with: 'x';\x0a\x09\x09\x09\x09\x09onClick: [ self closeTab: aWidget ]].\x0a\x09\x09\x09html span with: (self labelFor: aWidget) ].\x0a\x09\x09html span class: 'rtab' ];\x0a\x09onClick: [ self selectTab: aWidget ]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["li", "ifTrue:", "=", "class:", "with:", "span", "canBeClosed", "onClick:", "closeTab:", "labelFor:", "selectTab:"]
- }),
- $globals.TabManager);
- $core.addMethod(
- $core.method({
- selector: "renderTabs",
- protocol: 'rendering',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$2,$3;
- $recv(self["@ul"])._contents_((function(html){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- $recv(self._tabs())._do_((function(each){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- return self._renderTabFor_on_(each,html);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({each:each},$ctx2,2)});
- //>>excludeEnd("ctx");
- }));
- $1=$recv(html)._li();
- $recv($1)._class_("newtab");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["class:"]=1;
- //>>excludeEnd("ctx");
- $recv($1)._with_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- $2=$recv(html)._span();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["span"]=1;
- //>>excludeEnd("ctx");
- $recv($2)._class_("ltab");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["class:"]=2;
- //>>excludeEnd("ctx");
- $3=$recv(html)._span();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["span"]=2;
- //>>excludeEnd("ctx");
- $recv($3)._class_("mtab");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["class:"]=3;
- //>>excludeEnd("ctx");
- $recv($3)._with_(" + ");
- return $recv($recv(html)._span())._class_("rtab");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({},$ctx2,3)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["with:"]=1;
- //>>excludeEnd("ctx");
- return $recv($1)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- return self._newBrowserTab();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({},$ctx2,4)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({html:html},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"renderTabs",{},$globals.TabManager)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "renderTabs\x0a\x09ul contents: [ :html |\x0a\x09\x09self tabs do: [ :each |\x0a\x09\x09self renderTabFor: each on: html ].\x0a\x09\x09html li\x0a\x09\x09class: 'newtab';\x0a\x09\x09with: [\x0a\x09\x09\x09html span class: 'ltab'.\x0a\x09\x09\x09html span class: 'mtab'; with: ' + '.\x0a\x09\x09\x09html span class: 'rtab' ];\x0a\x09\x09onClick: [ self newBrowserTab ]]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["contents:", "do:", "tabs", "renderTabFor:on:", "class:", "li", "with:", "span", "onClick:", "newBrowserTab"]
- }),
- $globals.TabManager);
- $core.addMethod(
- $core.method({
- selector: "renderToolbarOn:",
- protocol: 'rendering',
- fn: function (html){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$2,$3,$4;
- $1=$recv(html)._div();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["div"]=1;
- //>>excludeEnd("ctx");
- $recv($1)._id_("amber_toolbar");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["id:"]=1;
- //>>excludeEnd("ctx");
- $recv($1)._with_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- $2=$recv(html)._input();
- $recv($2)._class_("implementors");
- self["@input"]=$recv($2)._yourself();
- self["@input"];
- $recv(self["@input"])._onKeyPress_((function(event){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- $3=$recv($recv(event)._keyCode()).__eq((13));
- if($core.assert($3)){
- return self._search_($recv($recv(self["@input"])._asJQuery())._val());
- };
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({event:event},$ctx2,2)});
- //>>excludeEnd("ctx");
- }));
- $4=$recv(html)._div();
- $recv($4)._id_("amber_close");
- return $recv($4)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- return self._close();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({},$ctx2,4)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"renderToolbarOn:",{html:html},$globals.TabManager)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["html"],
- source: "renderToolbarOn: html\x0a\x09html div\x0a\x09\x09id: 'amber_toolbar';\x0a\x09\x09with: [\x0a\x09\x09\x09input := html input\x0a\x09\x09\x09\x09class: 'implementors';\x0a\x09\x09\x09\x09yourself.\x0a\x09\x09\x09input onKeyPress: [ :event |\x0a\x09\x09\x09\x09event keyCode = 13 ifTrue: [\x0a\x09\x09\x09\x09self search: input asJQuery val ]].\x0a\x09\x09\x09html div id: 'amber_close'; onClick: [ self close ]]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["id:", "div", "with:", "class:", "input", "yourself", "onKeyPress:", "ifTrue:", "=", "keyCode", "search:", "val", "asJQuery", "onClick:", "close"]
- }),
- $globals.TabManager);
- $core.addMethod(
- $core.method({
- selector: "search:",
- protocol: 'actions',
- fn: function (aString){
- var self=this;
- var searchedClass;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1;
- searchedClass=$recv($recv($globals.Smalltalk)._globals())._at_(aString);
- $1=$recv(searchedClass)._isClass();
- if($core.assert($1)){
- $recv($globals.Browser)._openOn_(searchedClass);
- } else {
- $recv($globals.ReferencesBrowser)._search_(aString);
- };
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"search:",{aString:aString,searchedClass:searchedClass},$globals.TabManager)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["aString"],
- source: "search: aString\x0a\x09| searchedClass |\x0a\x09searchedClass := Smalltalk globals at: aString.\x0a\x09\x09searchedClass isClass\x0a\x09\x09\x09ifTrue: [ Browser openOn: searchedClass ]\x0a\x09\x09\x09ifFalse: [ ReferencesBrowser search: aString ]",
- referencedClasses: ["Smalltalk", "Browser", "ReferencesBrowser"],
- //>>excludeEnd("ide");
- messageSends: ["at:", "globals", "ifTrue:ifFalse:", "isClass", "openOn:", "search:"]
- }),
- $globals.TabManager);
- $core.addMethod(
- $core.method({
- selector: "selectTab:",
- protocol: 'actions',
- fn: function (aWidget){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- self._open();
- self["@selectedTab"]=aWidget;
- $recv(self._tabs())._do_((function(each){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return $recv(each)._hide();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- $recv(aWidget)._show();
- self._update();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"selectTab:",{aWidget:aWidget},$globals.TabManager)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["aWidget"],
- source: "selectTab: aWidget\x0a\x09self open.\x0a\x09selectedTab := aWidget.\x0a\x09self tabs do: [ :each |\x0a\x09each hide ].\x0a\x09aWidget show.\x0a\x09\x0a\x09self update",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["open", "do:", "tabs", "hide", "show", "update"]
- }),
- $globals.TabManager);
- $core.addMethod(
- $core.method({
- selector: "setBodyMargin:",
- protocol: 'actions',
- fn: function (anInteger){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- $recv(".amberBody"._asJQuery())._css_put_("margin-bottom",$recv($recv(anInteger)._asString()).__comma("px"));
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"setBodyMargin:",{anInteger:anInteger},$globals.TabManager)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["anInteger"],
- source: "setBodyMargin: anInteger\x0a\x09'.amberBody' asJQuery css: 'margin-bottom' put: anInteger asString, 'px'",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["css:put:", "asJQuery", ",", "asString"]
- }),
- $globals.TabManager);
- $core.addMethod(
- $core.method({
- selector: "tabs",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$receiver;
- $1=self["@tabs"];
- if(($receiver = $1) == null || $receiver.isNil){
- self["@tabs"]=$recv($globals.Array)._new();
- return self["@tabs"];
- } else {
- return $1;
- };
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"tabs",{},$globals.TabManager)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "tabs\x0a\x09^ tabs ifNil: [ tabs := Array new ]",
- referencedClasses: ["Array"],
- //>>excludeEnd("ide");
- messageSends: ["ifNil:", "new"]
- }),
- $globals.TabManager);
- $core.addMethod(
- $core.method({
- selector: "update",
- protocol: 'updating',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- self._renderTabs();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"update",{},$globals.TabManager)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "update\x0a\x09self renderTabs",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["renderTabs"]
- }),
- $globals.TabManager);
- $core.addMethod(
- $core.method({
- selector: "updateBodyMargin",
- protocol: 'actions',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- self._setBodyMargin_($recv("#amber"._asJQuery())._height());
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"updateBodyMargin",{},$globals.TabManager)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "updateBodyMargin\x0a\x09self setBodyMargin: '#amber' asJQuery height",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["setBodyMargin:", "height", "asJQuery"]
- }),
- $globals.TabManager);
- $core.addMethod(
- $core.method({
- selector: "updatePosition",
- protocol: 'actions',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1;
- $1="#amber"._asJQuery();
- $recv($1)._css_put_("top","");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["css:put:"]=1;
- //>>excludeEnd("ctx");
- $recv($1)._css_put_("bottom","0px");
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"updatePosition",{},$globals.TabManager)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "updatePosition\x0a\x09'#amber' asJQuery\x0a\x09\x09css: 'top' put: '';\x0a\x09\x09css: 'bottom' put: '0px'",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["css:put:", "asJQuery"]
- }),
- $globals.TabManager);
- $globals.TabManager.klass.iVarNames = ['current'];
- $core.addMethod(
- $core.method({
- selector: "current",
- protocol: 'instance creation',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$receiver;
- $1=self["@current"];
- if(($receiver = $1) == null || $receiver.isNil){
- self["@current"]=(
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.supercall = true,
- //>>excludeEnd("ctx");
- ($globals.TabManager.klass.superclass||$boot.nilAsClass).fn.prototype._new.apply($recv(self), []));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.supercall = false;
- //>>excludeEnd("ctx");;
- return self["@current"];
- } else {
- return $1;
- };
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"current",{},$globals.TabManager.klass)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "current\x0a\x09^ current ifNil: [ current := super new ]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["ifNil:", "new"]
- }),
- $globals.TabManager.klass);
- $core.addMethod(
- $core.method({
- selector: "new",
- protocol: 'instance creation',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- self._shouldNotImplement();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"new",{},$globals.TabManager.klass)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "new\x0a\x09self shouldNotImplement",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["shouldNotImplement"]
- }),
- $globals.TabManager.klass);
- $core.addMethod(
- $core.method({
- selector: "toggleAmberIDE",
- protocol: 'actions',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $3,$2,$1,$4,$5;
- $3="#amber"._asJQuery();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["asJQuery"]=1;
- //>>excludeEnd("ctx");
- $2=$recv($3)._length();
- $1=$recv($2).__eq((0));
- if($core.assert($1)){
- $recv($globals.Browser)._open();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["open"]=1;
- //>>excludeEnd("ctx");
- } else {
- $4=$recv("#amber"._asJQuery())._is_(":visible");
- if($core.assert($4)){
- $5=$recv($globals.TabManager)._current();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["current"]=1;
- //>>excludeEnd("ctx");
- $recv($5)._close();
- } else {
- $recv($recv($globals.TabManager)._current())._open();
- };
- };
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"toggleAmberIDE",{},$globals.TabManager.klass)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "toggleAmberIDE\x0a\x09'#amber' asJQuery length = 0\x0a\x09\x09ifTrue: [ Browser open ]\x0a\x09\x09ifFalse: [\x0a\x09\x09\x09('#amber' asJQuery is: ':visible')\x0a\x09\x09\x09\x09ifTrue: [ TabManager current close ]\x0a\x09\x09\x09\x09ifFalse: [ TabManager current open ] ]",
- referencedClasses: ["Browser", "TabManager"],
- //>>excludeEnd("ide");
- messageSends: ["ifTrue:ifFalse:", "=", "length", "asJQuery", "open", "is:", "close", "current"]
- }),
- $globals.TabManager.klass);
- $core.addClass('TabWidget', $globals.Widget, ['div'], 'IDE');
- $core.addMethod(
- $core.method({
- selector: "canBeClosed",
- protocol: 'testing',
- fn: function (){
- var self=this;
- return false;
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "canBeClosed\x0a\x09^ false",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: []
- }),
- $globals.TabWidget);
- $core.addMethod(
- $core.method({
- selector: "close",
- protocol: 'actions',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- $recv($recv($globals.TabManager)._current())._closeTab_(self);
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"close",{},$globals.TabWidget)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "close\x0a\x09TabManager current closeTab: self",
- referencedClasses: ["TabManager"],
- //>>excludeEnd("ide");
- messageSends: ["closeTab:", "current"]
- }),
- $globals.TabWidget);
- $core.addMethod(
- $core.method({
- selector: "hide",
- protocol: 'actions',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- $recv($recv(self["@div"])._asJQuery())._hide();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"hide",{},$globals.TabWidget)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "hide\x0a\x09div asJQuery hide",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["hide", "asJQuery"]
- }),
- $globals.TabWidget);
- $core.addMethod(
- $core.method({
- selector: "label",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- self._subclassResponsibility();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"label",{},$globals.TabWidget)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "label\x0a\x09self subclassResponsibility",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["subclassResponsibility"]
- }),
- $globals.TabWidget);
- $core.addMethod(
- $core.method({
- selector: "open",
- protocol: 'actions',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1;
- $1=$recv($globals.TabManager)._current();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["current"]=1;
- //>>excludeEnd("ctx");
- $recv($1)._addTab_(self);
- $recv($recv($globals.TabManager)._current())._selectTab_(self);
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"open",{},$globals.TabWidget)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "open\x0a\x09TabManager current addTab: self.\x0a\x09TabManager current selectTab: self",
- referencedClasses: ["TabManager"],
- //>>excludeEnd("ide");
- messageSends: ["addTab:", "current", "selectTab:"]
- }),
- $globals.TabWidget);
- $core.addMethod(
- $core.method({
- selector: "remove",
- protocol: 'actions',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- $recv($recv(self["@div"])._asJQuery())._remove();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"remove",{},$globals.TabWidget)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "remove\x0a\x09div asJQuery remove",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["remove", "asJQuery"]
- }),
- $globals.TabWidget);
- $core.addMethod(
- $core.method({
- selector: "renderBoxOn:",
- protocol: 'rendering',
- fn: function (html){
- var self=this;
- return self;
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["html"],
- source: "renderBoxOn: html",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: []
- }),
- $globals.TabWidget);
- $core.addMethod(
- $core.method({
- selector: "renderButtonsOn:",
- protocol: 'rendering',
- fn: function (html){
- var self=this;
- return self;
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["html"],
- source: "renderButtonsOn: html",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: []
- }),
- $globals.TabWidget);
- $core.addMethod(
- $core.method({
- selector: "renderOn:",
- protocol: 'rendering',
- fn: function (html){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1;
- $1=$recv(html)._div();
- $recv($1)._class_("amberTool");
- self["@div"]=$recv($1)._yourself();
- self._renderTab();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"renderOn:",{html:html},$globals.TabWidget)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["html"],
- source: "renderOn: html\x0a\x09div := html div\x0a\x09\x09class: 'amberTool';\x0a\x09\x09yourself.\x0a\x09self renderTab",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["class:", "div", "yourself", "renderTab"]
- }),
- $globals.TabWidget);
- $core.addMethod(
- $core.method({
- selector: "renderTab",
- protocol: 'rendering',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$2,$3;
- $recv(self["@div"])._contents_((function(html){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- $1=$recv(html)._div();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["div"]=1;
- //>>excludeEnd("ctx");
- $recv($1)._class_("amber_box");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["class:"]=1;
- //>>excludeEnd("ctx");
- $2=$recv($1)._with_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- return self._renderBoxOn_(html);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({},$ctx2,2)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["with:"]=1;
- //>>excludeEnd("ctx");
- $2;
- $3=$recv(html)._div();
- $recv($3)._class_("amber_buttons");
- return $recv($3)._with_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- return self._renderButtonsOn_(html);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({},$ctx2,3)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({html:html},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"renderTab",{},$globals.TabWidget)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "renderTab\x0a\x09div contents: [ :html |\x0a\x09\x09html div\x0a\x09\x09class: 'amber_box';\x0a\x09\x09with: [ self renderBoxOn: html ].\x0a\x09\x09html div\x0a\x09\x09class: 'amber_buttons';\x0a\x09\x09with: [ self renderButtonsOn: html ]]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["contents:", "class:", "div", "with:", "renderBoxOn:", "renderButtonsOn:"]
- }),
- $globals.TabWidget);
- $core.addMethod(
- $core.method({
- selector: "show",
- protocol: 'actions',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- $recv($recv(self["@div"])._asJQuery())._show();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"show",{},$globals.TabWidget)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "show\x0a\x09div asJQuery show",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["show", "asJQuery"]
- }),
- $globals.TabWidget);
- $core.addMethod(
- $core.method({
- selector: "update",
- protocol: 'rendering',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- self._renderTab();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"update",{},$globals.TabWidget)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "update\x0a\x09self renderTab",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["renderTab"]
- }),
- $globals.TabWidget);
- $core.addMethod(
- $core.method({
- selector: "open",
- protocol: 'instance creation',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- return $recv(self._new())._open();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"open",{},$globals.TabWidget.klass)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "open\x0a\x09^ self new open",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["open", "new"]
- }),
- $globals.TabWidget.klass);
- $core.addClass('Browser', $globals.TabWidget, ['selectedPackage', 'selectedClass', 'selectedProtocol', 'selectedMethod', 'packagesList', 'classesList', 'protocolsList', 'methodsList', 'sourceArea', 'tabsList', 'selectedTab', 'saveButton', 'classButtons', 'methodButtons', 'unsavedChanges'], 'IDE');
- $core.addMethod(
- $core.method({
- selector: "addInstanceVariableNamed:toClass:",
- protocol: 'actions',
- fn: function (aString,aClass){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$2,$3,$5,$4;
- $1=$recv($globals.ClassBuilder)._new();
- $2=$recv(aClass)._superclass();
- $3=$recv(aClass)._name();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["name"]=1;
- //>>excludeEnd("ctx");
- $5=$recv($recv(aClass)._instanceVariableNames())._copy();
- $recv($5)._add_(aString);
- $4=$recv($5)._yourself();
- $recv($1)._addSubclassOf_named_instanceVariableNames_package_($2,$3,$4,$recv($recv(aClass)._package())._name());
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"addInstanceVariableNamed:toClass:",{aString:aString,aClass:aClass},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["aString", "aClass"],
- source: "addInstanceVariableNamed: aString toClass: aClass\x0a\x09ClassBuilder new\x0a\x09\x09addSubclassOf: aClass superclass\x0a\x09\x09named: aClass name\x0a\x09\x09instanceVariableNames: (aClass instanceVariableNames copy add: aString; yourself)\x0a\x09\x09package: aClass package name",
- referencedClasses: ["ClassBuilder"],
- //>>excludeEnd("ide");
- messageSends: ["addSubclassOf:named:instanceVariableNames:package:", "new", "superclass", "name", "add:", "copy", "instanceVariableNames", "yourself", "package"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "addNewClass",
- protocol: 'actions',
- fn: function (){
- var self=this;
- var className;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1;
- className=$recv($globals.Terminal)._prompt_("New class");
- $1=$recv($recv(className)._notNil())._and_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return $recv(className)._notEmpty();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- if($core.assert($1)){
- $recv($globals.Object)._subclass_instanceVariableNames_package_(className,"",self._selectedPackage());
- self._resetClassesList();
- self._updateClassesList();
- self._selectClass_($recv($recv($globals.Smalltalk)._globals())._at_(className));
- };
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"addNewClass",{className:className},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "addNewClass\x0a\x09| className |\x0a\x09className := Terminal prompt: 'New class'.\x0a\x09(className notNil and: [ className notEmpty ]) ifTrue: [\x0a\x09\x09Object subclass: className instanceVariableNames: '' package: self selectedPackage.\x0a\x09\x09\x09self\x0a\x09\x09\x09resetClassesList;\x0a\x09\x09\x09updateClassesList.\x0a\x09\x09self selectClass: (Smalltalk globals at: className) ]",
- referencedClasses: ["Terminal", "Object", "Smalltalk"],
- //>>excludeEnd("ide");
- messageSends: ["prompt:", "ifTrue:", "and:", "notNil", "notEmpty", "subclass:instanceVariableNames:package:", "selectedPackage", "resetClassesList", "updateClassesList", "selectClass:", "at:", "globals"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "addNewProtocol",
- protocol: 'actions',
- fn: function (){
- var self=this;
- var newProtocol;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1;
- newProtocol=$recv($globals.Terminal)._prompt_("New method protocol");
- $1=$recv($recv(newProtocol)._notNil())._and_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return $recv(newProtocol)._notEmpty();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- if($core.assert($1)){
- $recv(self["@selectedMethod"])._protocol_(newProtocol);
- self._setMethodProtocol_(newProtocol);
- };
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"addNewProtocol",{newProtocol:newProtocol},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "addNewProtocol\x0a\x09| newProtocol |\x0a\x09\x0a\x09newProtocol := Terminal prompt: 'New method protocol'.\x0a\x09\x0a\x09(newProtocol notNil and: [ newProtocol notEmpty ]) ifTrue: [\x0a\x09\x09selectedMethod protocol: newProtocol.\x0a\x09\x09self setMethodProtocol: newProtocol ]",
- referencedClasses: ["Terminal"],
- //>>excludeEnd("ide");
- messageSends: ["prompt:", "ifTrue:", "and:", "notNil", "notEmpty", "protocol:", "setMethodProtocol:"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "canBeClosed",
- protocol: 'testing',
- fn: function (){
- var self=this;
- return true;
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "canBeClosed\x0a\x09^ true",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: []
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "cancelChanges",
- protocol: 'actions',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1;
- $1=self["@unsavedChanges"];
- if($core.assert($1)){
- return $recv($globals.Terminal)._confirm_("Cancel changes?");
- } else {
- return true;
- };
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"cancelChanges",{},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "cancelChanges\x0a\x09^ unsavedChanges\x0a\x09ifTrue: [ Terminal confirm: 'Cancel changes?' ]\x0a\x09ifFalse: [ true ]",
- referencedClasses: ["Terminal"],
- //>>excludeEnd("ide");
- messageSends: ["ifTrue:ifFalse:", "confirm:"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "classCommentSource",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- return $recv(self["@selectedClass"])._comment();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"classCommentSource",{},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "classCommentSource\x0a\x09^ selectedClass comment",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["comment"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "classDeclarationSource",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- var stream;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$2,$4,$5,$3,$6,$7,$8,$receiver;
- stream=""._writeStream();
- $1=self["@selectedClass"];
- if(($receiver = $1) == null || $receiver.isNil){
- return self._classDeclarationTemplate();
- } else {
- $1;
- };
- $2=stream;
- $recv($2)._nextPutAll_($recv($recv(self["@selectedClass"])._superclass())._asString());
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["nextPutAll:"]=1;
- //>>excludeEnd("ctx");
- $recv($2)._nextPutAll_(" subclass: #");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["nextPutAll:"]=2;
- //>>excludeEnd("ctx");
- $recv($2)._nextPutAll_($recv(self["@selectedClass"])._name());
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["nextPutAll:"]=3;
- //>>excludeEnd("ctx");
- $4=$recv($globals.String)._lf();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["lf"]=1;
- //>>excludeEnd("ctx");
- $5=$recv($globals.String)._tab();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["tab"]=1;
- //>>excludeEnd("ctx");
- $3=$recv($4).__comma($5);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx[","]=1;
- //>>excludeEnd("ctx");
- $recv($2)._nextPutAll_($3);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["nextPutAll:"]=4;
- //>>excludeEnd("ctx");
- $6=$recv($2)._nextPutAll_("instanceVariableNames: '");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["nextPutAll:"]=5;
- //>>excludeEnd("ctx");
- $recv($recv(self["@selectedClass"])._instanceVariableNames())._do_separatedBy_((function(each){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return $recv(stream)._nextPutAll_(each);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["nextPutAll:"]=6;
- //>>excludeEnd("ctx");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,2)});
- //>>excludeEnd("ctx");
- }),(function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return $recv(stream)._nextPutAll_(" ");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["nextPutAll:"]=7;
- //>>excludeEnd("ctx");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,3)});
- //>>excludeEnd("ctx");
- }));
- $7=stream;
- $8=$recv("'".__comma($recv($globals.String)._lf())).__comma($recv($globals.String)._tab());
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx[","]=2;
- //>>excludeEnd("ctx");
- $recv($7)._nextPutAll_($8);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["nextPutAll:"]=8;
- //>>excludeEnd("ctx");
- $recv($7)._nextPutAll_("package: '");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["nextPutAll:"]=9;
- //>>excludeEnd("ctx");
- $recv($7)._nextPutAll_($recv(self["@selectedClass"])._category());
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["nextPutAll:"]=10;
- //>>excludeEnd("ctx");
- $recv($7)._nextPutAll_("'");
- return $recv(stream)._contents();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"classDeclarationSource",{stream:stream},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "classDeclarationSource\x0a\x09| stream |\x0a\x09stream := '' writeStream.\x0a\x09selectedClass ifNil: [ ^ self classDeclarationTemplate ].\x0a\x09stream\x0a\x09\x09nextPutAll: selectedClass superclass asString;\x0a\x09\x09nextPutAll: ' subclass: #';\x0a\x09\x09nextPutAll: selectedClass name;\x0a\x09\x09nextPutAll: String lf, String tab;\x0a\x09\x09nextPutAll: 'instanceVariableNames: '''.\x0a\x09selectedClass instanceVariableNames\x0a\x09\x09do: [ :each | stream nextPutAll: each ]\x0a\x09\x09separatedBy: [ stream nextPutAll: ' ' ].\x0a\x09stream\x0a\x09\x09nextPutAll: '''', String lf, String tab;\x0a\x09\x09nextPutAll: 'package: ''';\x0a\x09\x09nextPutAll: selectedClass category;\x0a\x09\x09nextPutAll: ''''.\x0a\x09^ stream contents",
- referencedClasses: ["String"],
- //>>excludeEnd("ide");
- messageSends: ["writeStream", "ifNil:", "classDeclarationTemplate", "nextPutAll:", "asString", "superclass", "name", ",", "lf", "tab", "do:separatedBy:", "instanceVariableNames", "category", "contents"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "classDeclarationTemplate",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1;
- $1=$recv("Object subclass: #NameOfSubclass\x0a\x09instanceVariableNames: ''\x0a\x09package: '".__comma(self._selectedPackage())).__comma("'");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx[","]=1;
- //>>excludeEnd("ctx");
- return $1;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"classDeclarationTemplate",{},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "classDeclarationTemplate\x0a\x09^ 'Object subclass: #NameOfSubclass\x0a\x09instanceVariableNames: ''''\x0a\x09package: ''', self selectedPackage, ''''",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: [",", "selectedPackage"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "classes",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1;
- return $recv($recv($recv($recv($globals.Smalltalk)._classes())._select_((function(each){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return $recv($recv(each)._category()).__eq(self["@selectedPackage"]);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
- //>>excludeEnd("ctx");
- })))._sort_((function(a,b){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- $1=$recv(a)._name();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["name"]=1;
- //>>excludeEnd("ctx");
- return $recv($1).__lt($recv(b)._name());
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({a:a,b:b},$ctx1,2)});
- //>>excludeEnd("ctx");
- })))._asSet();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"classes",{},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "classes\x0a\x09^ ((Smalltalk classes\x0a\x09select: [ :each | each category = selectedPackage ])\x0a\x09sort: [ :a :b | a name < b name ]) asSet",
- referencedClasses: ["Smalltalk"],
- //>>excludeEnd("ide");
- messageSends: ["asSet", "sort:", "select:", "classes", "=", "category", "<", "name"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "commitPackage",
- protocol: 'actions',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$receiver;
- $1=self["@selectedPackage"];
- if(($receiver = $1) == null || $receiver.isNil){
- $1;
- } else {
- $recv($recv($globals.Package)._named_(self["@selectedPackage"]))._commit();
- };
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"commitPackage",{},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "commitPackage\x0a\x09selectedPackage ifNotNil: [\x0a\x09\x09(Package named: selectedPackage) commit ]",
- referencedClasses: ["Package"],
- //>>excludeEnd("ide");
- messageSends: ["ifNotNil:", "commit", "named:"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "compile",
- protocol: 'actions',
- fn: function (){
- var self=this;
- var currentEditLine;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$2,$3,$5,$4,$receiver;
- self._disableSaveButton();
- $1=$recv(self["@sourceArea"])._editor();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["editor"]=1;
- //>>excludeEnd("ctx");
- currentEditLine=$recv($1)._getCursor();
- $2=$recv(self["@selectedTab"]).__eq("comment");
- if($core.assert($2)){
- $3=self["@selectedClass"];
- if(($receiver = $3) == null || $receiver.isNil){
- $3;
- } else {
- self._compileClassComment();
- };
- } else {
- $5=$recv(self["@selectedProtocol"])._notNil();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["notNil"]=1;
- //>>excludeEnd("ctx");
- $4=$recv($5)._or_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return $recv(self["@selectedMethod"])._notNil();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,4)});
- //>>excludeEnd("ctx");
- }));
- if($core.assert($4)){
- self._compileMethodDefinition();
- } else {
- self._compileDefinition();
- };
- };
- $recv($recv(self["@sourceArea"])._editor())._setCursor_(currentEditLine);
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"compile",{currentEditLine:currentEditLine},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "compile\x0a\x09| currentEditLine |\x0a\x09self disableSaveButton.\x0a\x09currentEditLine := sourceArea editor getCursor.\x0a\x09selectedTab = #comment\x0a\x09ifTrue: [\x0a\x09\x09\x09selectedClass ifNotNil: [\x0a\x09\x09\x09\x09self compileClassComment ]]\x0a\x09ifFalse: [\x0a\x09\x09\x09(selectedProtocol notNil or: [ selectedMethod notNil ])\x0a\x09\x09\x09\x09ifFalse: [ self compileDefinition ]\x0a\x09\x09\x09\x09ifTrue: [ self compileMethodDefinition ]].\x0a\x09sourceArea editor setCursor: currentEditLine.",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["disableSaveButton", "getCursor", "editor", "ifTrue:ifFalse:", "=", "ifNotNil:", "compileClassComment", "ifFalse:ifTrue:", "or:", "notNil", "compileDefinition", "compileMethodDefinition", "setCursor:"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "compileClassComment",
- protocol: 'actions',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- $recv(self["@selectedClass"])._comment_($recv(self["@sourceArea"])._val());
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"compileClassComment",{},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "compileClassComment\x0a\x09selectedClass comment: sourceArea val",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["comment:", "val"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "compileDefinition",
- protocol: 'actions',
- fn: function (){
- var self=this;
- var newClass;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- newClass=$recv($recv($globals.Compiler)._new())._evaluateExpression_($recv(self["@sourceArea"])._val());
- self._resetClassesList();
- self._updateCategoriesList();
- self._updateClassesList();
- self._selectClass_(newClass);
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"compileDefinition",{newClass:newClass},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "compileDefinition\x0a\x09| newClass |\x0a\x09newClass := Compiler new evaluateExpression: sourceArea val.\x0a\x09self\x0a\x09resetClassesList;\x0a\x09updateCategoriesList;\x0a\x09updateClassesList.\x0a\x09self selectClass: newClass",
- referencedClasses: ["Compiler"],
- //>>excludeEnd("ide");
- messageSends: ["evaluateExpression:", "new", "val", "resetClassesList", "updateCategoriesList", "updateClassesList", "selectClass:"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "compileMethodDefinition",
- protocol: 'actions',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1;
- $1=$recv(self["@selectedTab"]).__eq("instance");
- if($core.assert($1)){
- self._compileMethodDefinitionFor_(self["@selectedClass"]);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["compileMethodDefinitionFor:"]=1;
- //>>excludeEnd("ctx");
- } else {
- self._compileMethodDefinitionFor_($recv(self["@selectedClass"])._class());
- };
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"compileMethodDefinition",{},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "compileMethodDefinition\x0a\x09selectedTab = #instance\x0a\x09ifTrue: [ self compileMethodDefinitionFor: selectedClass ]\x0a\x09ifFalse: [ self compileMethodDefinitionFor: selectedClass class ]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["ifTrue:ifFalse:", "=", "compileMethodDefinitionFor:", "class"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "compileMethodDefinitionFor:",
- protocol: 'actions',
- fn: function (aClass){
- var self=this;
- var compiler,package_,method,compiledSource,source,node;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$2,$5,$4,$3,$6,$8,$7,$receiver;
- var $early={};
- try {
- source=$recv(self["@sourceArea"])._val();
- $1=self["@selectedProtocol"];
- if(($receiver = $1) == null || $receiver.isNil){
- self["@selectedProtocol"]=$recv(self["@selectedMethod"])._protocol();
- self["@selectedProtocol"];
- } else {
- $1;
- };
- compiler=$recv($globals.Compiler)._new();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["new"]=1;
- //>>excludeEnd("ctx");
- $recv(compiler)._source_(source);
- node=$recv(compiler)._parse_(source);
- $2=$recv(node)._isParseFailure();
- if($core.assert($2)){
- $5="PARSE ERROR: ".__comma($recv(node)._reason());
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx[","]=3;
- //>>excludeEnd("ctx");
- $4=$recv($5).__comma(", position: ");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx[","]=2;
- //>>excludeEnd("ctx");
- $3=$recv($4).__comma($recv($recv(node)._position())._asString());
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx[","]=1;
- //>>excludeEnd("ctx");
- return $recv($globals.Terminal)._alert_($3);
- };
- package_=$recv(aClass)._packageOfProtocol_(self["@selectedProtocol"]);
- compiledSource=$recv(compiler)._compileNode_forClass_package_(node,aClass,package_);
- method=$recv(compiler)._eval_forPackage_(compiledSource,package_);
- $recv($recv(compiler)._unknownVariables())._do_((function(each){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- $6=$recv($globals.Smalltalk)._existsJsGlobal_(each);
- if(!$core.assert($6)){
- $8=$recv("Declare '".__comma(each)).__comma("' as instance variable?");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx[","]=4;
- //>>excludeEnd("ctx");
- $7=$recv($globals.Terminal)._confirm_($8);
- if($core.assert($7)){
- self._addInstanceVariableNamed_toClass_(each,aClass);
- throw $early=[self._compileMethodDefinitionFor_(aClass)];
- };
- };
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,3)});
- //>>excludeEnd("ctx");
- }));
- $recv($recv($globals.ClassBuilder)._new())._installMethod_forClass_protocol_(method,aClass,self["@selectedProtocol"]);
- self._updateMethodsList();
- self._selectMethod_(method);
- return self;
- }
- catch(e) {if(e===$early)return e[0]; throw e}
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"compileMethodDefinitionFor:",{aClass:aClass,compiler:compiler,package_:package_,method:method,compiledSource:compiledSource,source:source,node:node},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["aClass"],
- source: "compileMethodDefinitionFor: aClass\x0a\x09| compiler package method compiledSource source node |\x0a\x09source := sourceArea val.\x0a\x09selectedProtocol ifNil: [ selectedProtocol := selectedMethod protocol ].\x0a\x09compiler := Compiler new.\x0a\x09compiler source: source.\x0a\x09node := compiler parse: source.\x0a\x09node isParseFailure ifTrue: [\x0a\x09^ Terminal alert: 'PARSE ERROR: ', node reason, ', position: ', node position asString ].\x0a\x09package := aClass packageOfProtocol: selectedProtocol.\x0a\x09compiledSource := compiler compileNode: node forClass: aClass package: package.\x0a\x09method := compiler eval: compiledSource forPackage: package.\x0a\x09compiler unknownVariables do: [ :each |\x0a\x09\x09\x22Do not try to redeclare javascript's objects\x22\x0a\x09\x09(Smalltalk existsJsGlobal: each) ifFalse: [\x0a\x09\x09(Terminal confirm: 'Declare ''', each, ''' as instance variable?') ifTrue: [\x0a\x09\x09\x09self addInstanceVariableNamed: each toClass: aClass.\x0a\x09\x09\x09^ self compileMethodDefinitionFor: aClass ]] ].\x0a\x09ClassBuilder new installMethod: method forClass: aClass protocol: selectedProtocol.\x0a\x09self updateMethodsList.\x0a\x09self selectMethod: method",
- referencedClasses: ["Compiler", "Terminal", "Smalltalk", "ClassBuilder"],
- //>>excludeEnd("ide");
- messageSends: ["val", "ifNil:", "protocol", "new", "source:", "parse:", "ifTrue:", "isParseFailure", "alert:", ",", "reason", "asString", "position", "packageOfProtocol:", "compileNode:forClass:package:", "eval:forPackage:", "do:", "unknownVariables", "ifFalse:", "existsJsGlobal:", "confirm:", "addInstanceVariableNamed:toClass:", "compileMethodDefinitionFor:", "installMethod:forClass:protocol:", "updateMethodsList", "selectMethod:"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "copyClass",
- protocol: 'actions',
- fn: function (){
- var self=this;
- var className;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1;
- className=$recv($globals.Terminal)._prompt_("Copy class");
- $1=$recv($recv(className)._notNil())._and_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return $recv(className)._notEmpty();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- if($core.assert($1)){
- $recv($recv($globals.ClassBuilder)._new())._copyClass_named_(self._selectedClass(),className);
- self._resetClassesList();
- self._updateClassesList();
- self._selectClass_($recv($recv($globals.Smalltalk)._globals())._at_(className));
- };
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"copyClass",{className:className},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "copyClass\x0a\x09| className |\x0a\x09className := Terminal prompt: 'Copy class'.\x0a\x09(className notNil and: [ className notEmpty ]) ifTrue: [\x0a\x09\x09ClassBuilder new copyClass: self selectedClass named: className.\x0a\x09\x09\x09self\x0a\x09\x09\x09resetClassesList;\x0a\x09\x09\x09updateClassesList.\x0a\x09\x09self selectClass: (Smalltalk globals at: className) ]",
- referencedClasses: ["Terminal", "ClassBuilder", "Smalltalk"],
- //>>excludeEnd("ide");
- messageSends: ["prompt:", "ifTrue:", "and:", "notNil", "notEmpty", "copyClass:named:", "new", "selectedClass", "resetClassesList", "updateClassesList", "selectClass:", "at:", "globals"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "declarationSource",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1;
- $1=$recv(self["@selectedTab"]).__eq("instance");
- if($core.assert($1)){
- return self._classDeclarationSource();
- } else {
- return self._metaclassDeclarationSource();
- };
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"declarationSource",{},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "declarationSource\x0a\x09^ selectedTab = #instance\x0a\x09ifTrue: [ self classDeclarationSource ]\x0a\x09ifFalse: [ self metaclassDeclarationSource ]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["ifTrue:ifFalse:", "=", "classDeclarationSource", "metaclassDeclarationSource"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "disableSaveButton",
- protocol: 'actions',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$receiver;
- $1=self["@saveButton"];
- if(($receiver = $1) == null || $receiver.isNil){
- $1;
- } else {
- $recv(self["@saveButton"])._at_put_("disabled",true);
- };
- self["@unsavedChanges"]=false;
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"disableSaveButton",{},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "disableSaveButton\x0a\x09saveButton ifNotNil: [\x0a\x09saveButton at: 'disabled' put: true ].\x0a\x09unsavedChanges := false",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["ifNotNil:", "at:put:"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "dummyMethodSource",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- return "messageSelectorAndArgumentNames\x0a\x09\x22comment stating purpose of message\x22\x0a\x0a\x09| temporary variable names |\x0a\x09statements";
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "dummyMethodSource\x0a\x09^ 'messageSelectorAndArgumentNames\x0a\x09\x22comment stating purpose of message\x22\x0a\x0a\x09| temporary variable names |\x0a\x09statements'",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: []
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "handleSourceAreaKeyDown:",
- protocol: 'actions',
- fn: function (anEvent){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- if(anEvent.ctrlKey) {
- if(anEvent.keyCode === 83) { //ctrl+s
- self._compile();
- anEvent.preventDefault();
- return false;
- }
- }
- ;
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"handleSourceAreaKeyDown:",{anEvent:anEvent},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["anEvent"],
- source: "handleSourceAreaKeyDown: anEvent\x0a\x09<if(anEvent.ctrlKey) {\x0a\x09\x09if(anEvent.keyCode === 83) { //ctrl+s\x0a\x09\x09\x09self._compile();\x0a\x09\x09\x09anEvent.preventDefault();\x0a\x09\x09\x09return false;\x0a\x09\x09}\x0a\x09}\x0a\x09>",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: []
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "hideClassButtons",
- protocol: 'actions',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- $recv($recv(self["@classButtons"])._asJQuery())._hide();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"hideClassButtons",{},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "hideClassButtons\x0a\x09classButtons asJQuery hide",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["hide", "asJQuery"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "hideMethodButtons",
- protocol: 'actions',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- $recv($recv(self["@methodButtons"])._asJQuery())._hide();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"hideMethodButtons",{},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "hideMethodButtons\x0a\x09methodButtons asJQuery hide",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["hide", "asJQuery"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "initialize",
- protocol: 'initialization',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- (
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.supercall = true,
- //>>excludeEnd("ctx");
- ($globals.Browser.superclass||$boot.nilAsClass).fn.prototype._initialize.apply($recv(self), []));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.supercall = false;
- //>>excludeEnd("ctx");;
- self["@selectedTab"]="instance";
- self["@selectedPackage"]=$recv(self._packages())._first();
- self["@unsavedChanges"]=false;
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"initialize",{},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "initialize\x0a\x09super initialize.\x0a\x09selectedTab := #instance.\x0a\x09selectedPackage := self packages first.\x0a\x09unsavedChanges := false",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["initialize", "first", "packages"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "label",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$receiver;
- $1=self["@selectedClass"];
- if(($receiver = $1) == null || $receiver.isNil){
- return "Browser (nil)";
- } else {
- return "Browser: ".__comma($recv(self["@selectedClass"])._name());
- };
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"label",{},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "label\x0a\x09^ selectedClass\x0a\x09ifNil: [ 'Browser (nil)' ]\x0a\x09ifNotNil: [ 'Browser: ', selectedClass name ]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["ifNil:ifNotNil:", ",", "name"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "metaclassDeclarationSource",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- var stream;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$2,$3,$receiver;
- stream=""._writeStream();
- $1=self["@selectedClass"];
- if(($receiver = $1) == null || $receiver.isNil){
- $1;
- } else {
- $2=stream;
- $recv($2)._nextPutAll_($recv(self["@selectedClass"])._asString());
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["nextPutAll:"]=1;
- //>>excludeEnd("ctx");
- $recv($2)._nextPutAll_(" class ");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["nextPutAll:"]=2;
- //>>excludeEnd("ctx");
- $3=$recv($2)._nextPutAll_("instanceVariableNames: '");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["nextPutAll:"]=3;
- //>>excludeEnd("ctx");
- $3;
- $recv($recv($recv(self["@selectedClass"])._class())._instanceVariableNames())._do_separatedBy_((function(each){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return $recv(stream)._nextPutAll_(each);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["nextPutAll:"]=4;
- //>>excludeEnd("ctx");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,2)});
- //>>excludeEnd("ctx");
- }),(function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return $recv(stream)._nextPutAll_(" ");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["nextPutAll:"]=5;
- //>>excludeEnd("ctx");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,3)});
- //>>excludeEnd("ctx");
- }));
- $recv(stream)._nextPutAll_("'");
- };
- return $recv(stream)._contents();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"metaclassDeclarationSource",{stream:stream},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "metaclassDeclarationSource\x0a\x09| stream |\x0a\x09stream := '' writeStream.\x0a\x09selectedClass ifNotNil: [\x0a\x09stream\x0a\x09\x09nextPutAll: selectedClass asString;\x0a\x09\x09nextPutAll: ' class ';\x0a\x09\x09nextPutAll: 'instanceVariableNames: '''.\x0a\x09selectedClass class instanceVariableNames\x0a\x09\x09do: [ :each | stream nextPutAll: each ]\x0a\x09\x09separatedBy: [ stream nextPutAll: ' ' ].\x0a\x09stream nextPutAll: '''' ].\x0a\x09^ stream contents",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["writeStream", "ifNotNil:", "nextPutAll:", "asString", "do:separatedBy:", "instanceVariableNames", "class", "contents"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "methodSource",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$receiver;
- $1=self["@selectedMethod"];
- if(($receiver = $1) == null || $receiver.isNil){
- return self._dummyMethodSource();
- } else {
- return $recv(self["@selectedMethod"])._source();
- };
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"methodSource",{},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "methodSource\x0a\x09^ selectedMethod\x0a\x09ifNil: [ self dummyMethodSource ]\x0a\x09ifNotNil: [ selectedMethod source ]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["ifNil:ifNotNil:", "dummyMethodSource", "source"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "methods",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- var klass;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$2,$3,$5,$6,$4,$7,$receiver;
- $1=$recv(self["@selectedTab"]).__eq("comment");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["="]=1;
- //>>excludeEnd("ctx");
- if($core.assert($1)){
- return [];
- };
- $2=self["@selectedClass"];
- if(($receiver = $2) == null || $receiver.isNil){
- $2;
- } else {
- $3=$recv(self["@selectedTab"]).__eq("instance");
- if($core.assert($3)){
- klass=self["@selectedClass"];
- } else {
- klass=$recv(self["@selectedClass"])._class();
- };
- klass;
- };
- $5=self["@selectedProtocol"];
- if(($receiver = $5) == null || $receiver.isNil){
- $6=klass;
- if(($receiver = $6) == null || $receiver.isNil){
- $4=[];
- } else {
- $4=$recv($recv(klass)._methodDictionary())._values();
- };
- } else {
- $4=$recv(klass)._methodsInProtocol_(self["@selectedProtocol"]);
- };
- return $recv($4)._sort_((function(a,b){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- $7=$recv(a)._selector();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["selector"]=1;
- //>>excludeEnd("ctx");
- return $recv($7).__lt($recv(b)._selector());
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({a:a,b:b},$ctx1,9)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"methods",{klass:klass},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "methods\x0a\x09| klass |\x0a\x09selectedTab = #comment ifTrue: [ ^ #() ].\x0a\x09selectedClass ifNotNil: [\x0a\x09klass := selectedTab = #instance\x0a\x09\x09ifTrue: [ selectedClass ]\x0a\x09\x09ifFalse: [ selectedClass class ]].\x0a\x09^ (selectedProtocol\x0a\x09ifNil: [\x0a\x09\x09klass\x0a\x09\x09ifNil: [ #() ]\x0a\x09\x09ifNotNil: [ klass methodDictionary values ]]\x0a\x09ifNotNil: [\x0a\x09\x09klass methodsInProtocol: selectedProtocol ]) \x0a\x09\x09\x09\x09sort: [ :a :b | a selector < b selector ]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["ifTrue:", "=", "ifNotNil:", "ifTrue:ifFalse:", "class", "sort:", "ifNil:ifNotNil:", "values", "methodDictionary", "methodsInProtocol:", "<", "selector"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "packages",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- var packages;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $2,$3,$1;
- packages=$recv($globals.Array)._new();
- $recv($recv($globals.Smalltalk)._classes())._do_((function(each){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- $2=packages;
- $3=$recv(each)._category();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["category"]=1;
- //>>excludeEnd("ctx");
- $1=$recv($2)._includes_($3);
- if(!$core.assert($1)){
- return $recv(packages)._add_($recv(each)._category());
- };
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- return $recv(packages)._sort();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"packages",{packages:packages},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "packages\x0a\x09| packages |\x0a\x09packages := Array new.\x0a\x09Smalltalk classes do: [ :each |\x0a\x09(packages includes: each category) ifFalse: [\x0a\x09\x09packages add: each category ]].\x0a\x09^ packages sort",
- referencedClasses: ["Array", "Smalltalk"],
- //>>excludeEnd("ide");
- messageSends: ["new", "do:", "classes", "ifFalse:", "includes:", "category", "add:", "sort"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "protocols",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- var klass;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$2,$3,$receiver;
- var $early={};
- try {
- $1=self["@selectedClass"];
- if(($receiver = $1) == null || $receiver.isNil){
- $1;
- } else {
- $2=$recv(self["@selectedTab"]).__eq("comment");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["="]=1;
- //>>excludeEnd("ctx");
- if($core.assert($2)){
- return [];
- };
- $3=$recv(self["@selectedTab"]).__eq("instance");
- if($core.assert($3)){
- klass=self["@selectedClass"];
- } else {
- klass=$recv(self["@selectedClass"])._class();
- };
- klass;
- $recv($recv(klass)._methodDictionary())._ifEmpty_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- throw $early=[$recv($globals.Array)._with_("not yet classified")];
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,5)});
- //>>excludeEnd("ctx");
- }));
- return $recv(klass)._protocols();
- };
- return $recv($globals.Array)._new();
- }
- catch(e) {if(e===$early)return e[0]; throw e}
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"protocols",{klass:klass},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "protocols\x0a\x09| klass |\x0a\x09selectedClass ifNotNil: [\x0a\x09selectedTab = #comment ifTrue: [ ^ #() ].\x0a\x09klass := selectedTab = #instance\x0a\x09\x09ifTrue: [ selectedClass ]\x0a\x09\x09ifFalse: [ selectedClass class ].\x0a\x09klass methodDictionary ifEmpty: [\x0a\x09\x09^ Array with: 'not yet classified' ].\x0a\x09^ klass protocols ].\x0a\x09^ Array new",
- referencedClasses: ["Array"],
- //>>excludeEnd("ide");
- messageSends: ["ifNotNil:", "ifTrue:", "=", "ifTrue:ifFalse:", "class", "ifEmpty:", "methodDictionary", "with:", "protocols", "new"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "removeClass",
- protocol: 'actions',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $2,$1;
- $2=$recv("Do you really want to remove ".__comma($recv(self["@selectedClass"])._name())).__comma("?");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx[","]=1;
- //>>excludeEnd("ctx");
- $1=$recv($globals.Terminal)._confirm_($2);
- if($core.assert($1)){
- $recv($globals.Smalltalk)._removeClass_(self["@selectedClass"]);
- self._resetClassesList();
- self._selectClass_(nil);
- };
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"removeClass",{},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "removeClass\x0a\x09(Terminal confirm: 'Do you really want to remove ', selectedClass name, '?')\x0a\x09ifTrue: [\x0a\x09\x09Smalltalk removeClass: selectedClass.\x0a\x09\x09self resetClassesList.\x0a\x09\x09self selectClass: nil ]",
- referencedClasses: ["Terminal", "Smalltalk"],
- //>>excludeEnd("ide");
- messageSends: ["ifTrue:", "confirm:", ",", "name", "removeClass:", "resetClassesList", "selectClass:"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "removeMethod",
- protocol: 'actions',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$3,$2,$4;
- $1=self._cancelChanges();
- if($core.assert($1)){
- $3=$recv("Do you really want to remove #".__comma($recv(self["@selectedMethod"])._selector())).__comma("?");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx[","]=1;
- //>>excludeEnd("ctx");
- $2=$recv($globals.Terminal)._confirm_($3);
- if($core.assert($2)){
- $4=$recv(self["@selectedTab"]).__eq("instance");
- if($core.assert($4)){
- $recv(self["@selectedClass"])._removeCompiledMethod_(self["@selectedMethod"]);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["removeCompiledMethod:"]=1;
- //>>excludeEnd("ctx");
- } else {
- $recv($recv(self["@selectedClass"])._class())._removeCompiledMethod_(self["@selectedMethod"]);
- };
- self._selectMethod_(nil);
- };
- };
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"removeMethod",{},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "removeMethod\x0a\x09self cancelChanges ifTrue: [\x0a\x09(Terminal confirm: 'Do you really want to remove #', selectedMethod selector, '?')\x0a\x09\x09ifTrue: [\x0a\x09\x09selectedTab = #instance\x0a\x09\x09\x09ifTrue: [ selectedClass removeCompiledMethod: selectedMethod ]\x0a\x09\x09\x09ifFalse: [ selectedClass class removeCompiledMethod: selectedMethod ].\x0a\x09\x09self selectMethod: nil ]]",
- referencedClasses: ["Terminal"],
- //>>excludeEnd("ide");
- messageSends: ["ifTrue:", "cancelChanges", "confirm:", ",", "selector", "ifTrue:ifFalse:", "=", "removeCompiledMethod:", "class", "selectMethod:"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "removePackage",
- protocol: 'actions',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $2,$1;
- $2=$recv("Do you really want to remove the whole package ".__comma(self["@selectedPackage"])).__comma(" with all its classes?");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx[","]=1;
- //>>excludeEnd("ctx");
- $1=$recv($globals.Terminal)._confirm_($2);
- if($core.assert($1)){
- $recv($globals.Smalltalk)._removePackage_(self["@selectedPackage"]);
- self._updateCategoriesList();
- };
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"removePackage",{},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "removePackage\x0a\x0a\x09(Terminal confirm: 'Do you really want to remove the whole package ', selectedPackage, ' with all its classes?')\x0a\x09ifTrue: [\x0a\x09\x09Smalltalk removePackage: selectedPackage.\x0a\x09\x09self updateCategoriesList ]",
- referencedClasses: ["Terminal", "Smalltalk"],
- //>>excludeEnd("ide");
- messageSends: ["ifTrue:", "confirm:", ",", "removePackage:", "updateCategoriesList"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "renameClass",
- protocol: 'actions',
- fn: function (){
- var self=this;
- var newName;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1;
- newName=$recv($globals.Terminal)._prompt_("Rename class ".__comma($recv(self["@selectedClass"])._name()));
- $1=$recv($recv(newName)._notNil())._and_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return $recv(newName)._notEmpty();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- if($core.assert($1)){
- $recv(self["@selectedClass"])._rename_(newName);
- self._updateClassesList();
- self._updateSourceAndButtons();
- };
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"renameClass",{newName:newName},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "renameClass\x0a\x09| newName |\x0a\x09newName := Terminal prompt: 'Rename class ', selectedClass name.\x0a\x09(newName notNil and: [ newName notEmpty ]) ifTrue: [\x0a\x09selectedClass rename: newName.\x0a\x09self\x0a\x09\x09updateClassesList;\x0a\x09\x09updateSourceAndButtons ]",
- referencedClasses: ["Terminal"],
- //>>excludeEnd("ide");
- messageSends: ["prompt:", ",", "name", "ifTrue:", "and:", "notNil", "notEmpty", "rename:", "updateClassesList", "updateSourceAndButtons"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "renamePackage",
- protocol: 'actions',
- fn: function (){
- var self=this;
- var newName;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$receiver;
- newName=$recv($globals.Terminal)._prompt_("Rename package ".__comma(self["@selectedPackage"]));
- $1=newName;
- if(($receiver = $1) == null || $receiver.isNil){
- $1;
- } else {
- $recv(newName)._ifNotEmpty_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- $recv($globals.Smalltalk)._renamePackage_to_(self["@selectedPackage"],newName);
- return self._updateCategoriesList();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
- //>>excludeEnd("ctx");
- }));
- };
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"renamePackage",{newName:newName},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "renamePackage\x0a\x0a\x09| newName |\x0a\x09newName := Terminal prompt: 'Rename package ', selectedPackage.\x0a\x09newName ifNotNil: [ newName ifNotEmpty: [\x0a\x09Smalltalk renamePackage: selectedPackage to: newName.\x0a\x09self updateCategoriesList ]]",
- referencedClasses: ["Terminal", "Smalltalk"],
- //>>excludeEnd("ide");
- messageSends: ["prompt:", ",", "ifNotNil:", "ifNotEmpty:", "renamePackage:to:", "updateCategoriesList"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "renderBottomPanelOn:",
- protocol: 'rendering',
- fn: function (html){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1;
- $1=$recv(html)._div();
- $recv($1)._class_("amber_sourceCode");
- $recv($1)._with_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- self["@sourceArea"]=$recv($globals.SourceArea)._new();
- self["@sourceArea"];
- $recv(self["@sourceArea"])._renderOn_(html);
- $recv(self["@sourceArea"])._onKeyDown_((function(e){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- return self._handleSourceAreaKeyDown_(e);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({e:e},$ctx2,2)});
- //>>excludeEnd("ctx");
- }));
- return $recv(self["@sourceArea"])._onKeyUp_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- return self._updateStatus();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({},$ctx2,3)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"renderBottomPanelOn:",{html:html},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["html"],
- source: "renderBottomPanelOn: html\x0a\x09html div\x0a\x09class: 'amber_sourceCode';\x0a\x09with: [\x0a\x09\x09sourceArea := SourceArea new.\x0a\x09\x09sourceArea renderOn: html.\x0a\x09\x09\x09sourceArea onKeyDown: [ :e |\x0a\x09\x09\x09\x09self handleSourceAreaKeyDown: e ].\x0a\x09\x09sourceArea onKeyUp: [ self updateStatus ]]",
- referencedClasses: ["SourceArea"],
- //>>excludeEnd("ide");
- messageSends: ["class:", "div", "with:", "new", "renderOn:", "onKeyDown:", "handleSourceAreaKeyDown:", "onKeyUp:", "updateStatus"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "renderBoxOn:",
- protocol: 'rendering',
- fn: function (html){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- self._renderTopPanelOn_(html);
- self._renderTabsOn_(html);
- self._renderBottomPanelOn_(html);
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"renderBoxOn:",{html:html},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["html"],
- source: "renderBoxOn: html\x0a\x09self\x0a\x09renderTopPanelOn: html;\x0a\x09renderTabsOn: html;\x0a\x09renderBottomPanelOn: html",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["renderTopPanelOn:", "renderTabsOn:", "renderBottomPanelOn:"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "renderButtonsOn:",
- protocol: 'rendering',
- fn: function (html){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$2,$3,$5,$6,$7,$8,$9,$4;
- self["@saveButton"]=$recv(html)._button();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["button"]=1;
- //>>excludeEnd("ctx");
- $1=self["@saveButton"];
- $recv($1)._with_("Save");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["with:"]=1;
- //>>excludeEnd("ctx");
- $2=$recv($1)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return self._compile();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["onClick:"]=1;
- //>>excludeEnd("ctx");
- self["@methodButtons"]=$recv(html)._span();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["span"]=1;
- //>>excludeEnd("ctx");
- self["@classButtons"]=$recv(html)._span();
- $3=$recv(html)._div();
- $recv($3)._class_("right");
- $4=$recv($3)._with_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- $5=$recv(html)._button();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["button"]=2;
- //>>excludeEnd("ctx");
- $recv($5)._with_("DoIt");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["with:"]=3;
- //>>excludeEnd("ctx");
- $6=$recv($5)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- return $recv(self["@sourceArea"])._doIt();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({},$ctx2,3)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["onClick:"]=2;
- //>>excludeEnd("ctx");
- $6;
- $7=$recv(html)._button();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["button"]=3;
- //>>excludeEnd("ctx");
- $recv($7)._with_("PrintIt");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["with:"]=4;
- //>>excludeEnd("ctx");
- $8=$recv($7)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- return $recv(self["@sourceArea"])._printIt();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({},$ctx2,4)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["onClick:"]=3;
- //>>excludeEnd("ctx");
- $8;
- $9=$recv(html)._button();
- $recv($9)._with_("InspectIt");
- return $recv($9)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- return $recv(self["@sourceArea"])._inspectIt();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({},$ctx2,5)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["with:"]=2;
- //>>excludeEnd("ctx");
- self._updateSourceAndButtons();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"renderButtonsOn:",{html:html},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["html"],
- source: "renderButtonsOn: html\x0a\x09saveButton := html button.\x0a\x09saveButton\x0a\x09with: 'Save';\x0a\x09onClick: [ self compile ].\x0a\x09methodButtons := html span.\x0a\x09classButtons := html span.\x0a\x09html div\x0a\x09class: 'right';\x0a\x09with: [\x0a\x09\x09html button\x0a\x09\x09\x09with: 'DoIt';\x0a\x09\x09\x09onClick: [ sourceArea doIt ].\x0a\x09\x09html button\x0a\x09\x09\x09with: 'PrintIt';\x0a\x09\x09\x09onClick: [ sourceArea printIt ].\x0a\x09\x09html button with: 'InspectIt';\x0a\x09\x09\x09onClick: [ sourceArea inspectIt ]].\x0a\x09self updateSourceAndButtons",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["button", "with:", "onClick:", "compile", "span", "class:", "div", "doIt", "printIt", "inspectIt", "updateSourceAndButtons"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "renderTabsOn:",
- protocol: 'rendering',
- fn: function (html){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- self["@tabsList"]=$recv($recv(html)._ul())._class_("amber_tabs amber_browser");
- self._updateTabsList();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"renderTabsOn:",{html:html},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["html"],
- source: "renderTabsOn: html\x0a\x09tabsList := html ul class: 'amber_tabs amber_browser'.\x0a\x09self updateTabsList.",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["class:", "ul", "updateTabsList"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "renderTopPanelOn:",
- protocol: 'rendering',
- fn: function (html){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$3,$4,$6,$7,$8,$9,$10,$5,$11,$2;
- $1=$recv(html)._div();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["div"]=1;
- //>>excludeEnd("ctx");
- $recv($1)._class_("top");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["class:"]=1;
- //>>excludeEnd("ctx");
- $2=$recv($1)._with_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- $3=$recv(html)._ul();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["ul"]=1;
- //>>excludeEnd("ctx");
- self["@packagesList"]=$recv($3)._class_("amber_column browser packages");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["class:"]=2;
- //>>excludeEnd("ctx");
- self["@packagesList"];
- $4=$recv(html)._div();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["div"]=2;
- //>>excludeEnd("ctx");
- $recv($4)._class_("amber_packagesButtons");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["class:"]=3;
- //>>excludeEnd("ctx");
- $5=$recv($4)._with_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- $6=$recv(html)._button();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["button"]=1;
- //>>excludeEnd("ctx");
- $recv($6)._title_("Commit classes in this package to disk");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["title:"]=1;
- //>>excludeEnd("ctx");
- $recv($6)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx4) {
- //>>excludeEnd("ctx");
- return self._commitPackage();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx4) {$ctx4.fillBlock({},$ctx3,3)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["onClick:"]=1;
- //>>excludeEnd("ctx");
- $7=$recv($6)._with_("Commit");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["with:"]=3;
- //>>excludeEnd("ctx");
- $7;
- $8=$recv(html)._button();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["button"]=2;
- //>>excludeEnd("ctx");
- $recv($8)._title_("Rename package");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["title:"]=2;
- //>>excludeEnd("ctx");
- $recv($8)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx4) {
- //>>excludeEnd("ctx");
- return self._renamePackage();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx4) {$ctx4.fillBlock({},$ctx3,4)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["onClick:"]=2;
- //>>excludeEnd("ctx");
- $9=$recv($8)._with_("Rename");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["with:"]=4;
- //>>excludeEnd("ctx");
- $9;
- $10=$recv(html)._button();
- $recv($10)._title_("Remove this package from the system");
- $recv($10)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx4) {
- //>>excludeEnd("ctx");
- return self._removePackage();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx4) {$ctx4.fillBlock({},$ctx3,5)});
- //>>excludeEnd("ctx");
- }));
- return $recv($10)._with_("Remove");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({},$ctx2,2)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["with:"]=2;
- //>>excludeEnd("ctx");
- $5;
- self["@classesList"]=$recv($globals.ClassesList)._on_(self);
- self["@classesList"];
- $recv(self["@classesList"])._renderOn_(html);
- $11=$recv(html)._ul();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["ul"]=2;
- //>>excludeEnd("ctx");
- self["@protocolsList"]=$recv($11)._class_("amber_column browser protocols");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["class:"]=4;
- //>>excludeEnd("ctx");
- self["@protocolsList"];
- self["@methodsList"]=$recv($recv(html)._ul())._class_("amber_column browser methods");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["class:"]=5;
- //>>excludeEnd("ctx");
- self["@methodsList"];
- self._updateCategoriesList();
- self._updateClassesList();
- self._updateProtocolsList();
- self._updateMethodsList();
- return $recv($recv(html)._div())._class_("amber_clear");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["with:"]=1;
- //>>excludeEnd("ctx");
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"renderTopPanelOn:",{html:html},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["html"],
- source: "renderTopPanelOn: html\x0a\x09html div\x0a\x09\x09class: 'top';\x0a\x09\x09with: [\x0a\x09\x09\x09packagesList := html ul class: 'amber_column browser packages'.\x0a\x09\x09\x09\x09html div class: 'amber_packagesButtons'; with: [\x0a\x09\x09\x09\x09html button\x0a\x09\x09\x09\x09\x09title: 'Commit classes in this package to disk';\x0a\x09\x09\x09\x09\x09onClick: [ self commitPackage ];\x0a\x09\x09\x09\x09\x09with: 'Commit'.\x0a\x09\x09\x09\x09\x09html button\x0a\x09\x09\x09\x09\x09title: 'Rename package';\x0a\x09\x09\x09\x09\x09onClick: [ self renamePackage ];\x0a\x09\x09\x09\x09\x09with: 'Rename'.\x0a\x09\x09\x09\x09\x09html button\x0a\x09\x09\x09\x09\x09title: 'Remove this package from the system';\x0a\x09\x09\x09\x09\x09onClick: [ self removePackage ];\x0a\x09\x09\x09\x09\x09with: 'Remove' ].\x0a\x09\x09\x09classesList := ClassesList on: self.\x0a\x09\x09\x09classesList renderOn: html.\x0a\x09\x09\x09protocolsList := html ul class: 'amber_column browser protocols'.\x0a\x09\x09\x09methodsList := html ul class: 'amber_column browser methods'.\x0a\x09\x09\x09self\x0a\x09\x09\x09\x09updateCategoriesList;\x0a\x09\x09\x09\x09updateClassesList;\x0a\x09\x09\x09\x09updateProtocolsList;\x0a\x09\x09\x09\x09updateMethodsList.\x0a\x09\x09\x09html div class: 'amber_clear' ]",
- referencedClasses: ["ClassesList"],
- //>>excludeEnd("ide");
- messageSends: ["class:", "div", "with:", "ul", "title:", "button", "onClick:", "commitPackage", "renamePackage", "removePackage", "on:", "renderOn:", "updateCategoriesList", "updateClassesList", "updateProtocolsList", "updateMethodsList"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "resetClassesList",
- protocol: 'updating',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- $recv(self["@classesList"])._resetNodes();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"resetClassesList",{},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "resetClassesList\x0a\x09classesList resetNodes",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["resetNodes"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "search:",
- protocol: 'actions',
- fn: function (aString){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$2;
- $1=self._cancelChanges();
- if($core.assert($1)){
- var searchedClass;
- searchedClass=$recv($recv($globals.Smalltalk)._globals())._at_(aString);
- searchedClass;
- $2=$recv(searchedClass)._isClass();
- if($core.assert($2)){
- $recv(self._class())._openOn_(searchedClass);
- } else {
- self._searchReferencesOf_(aString);
- };
- };
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"search:",{aString:aString},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["aString"],
- source: "search: aString\x0a\x09self cancelChanges ifTrue: [ | searchedClass |\x0a\x09\x09searchedClass := Smalltalk globals at: aString.\x0a\x09\x09searchedClass isClass\x0a\x09\x09\x09ifTrue: [ self class openOn: searchedClass ]\x0a\x09\x09\x09ifFalse: [ self searchReferencesOf: aString ]]",
- referencedClasses: ["Smalltalk"],
- //>>excludeEnd("ide");
- messageSends: ["ifTrue:", "cancelChanges", "at:", "globals", "ifTrue:ifFalse:", "isClass", "openOn:", "class", "searchReferencesOf:"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "searchClassReferences",
- protocol: 'actions',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- $recv($globals.ReferencesBrowser)._search_($recv(self["@selectedClass"])._name());
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"searchClassReferences",{},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "searchClassReferences\x0a\x09ReferencesBrowser search: selectedClass name",
- referencedClasses: ["ReferencesBrowser"],
- //>>excludeEnd("ide");
- messageSends: ["search:", "name"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "searchReferencesOf:",
- protocol: 'actions',
- fn: function (aString){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- $recv($globals.ReferencesBrowser)._search_(aString);
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"searchReferencesOf:",{aString:aString},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["aString"],
- source: "searchReferencesOf: aString\x0a\x09ReferencesBrowser search: aString",
- referencedClasses: ["ReferencesBrowser"],
- //>>excludeEnd("ide");
- messageSends: ["search:"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "selectCategory:",
- protocol: 'actions',
- fn: function (aCategory){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1;
- $1=self._cancelChanges();
- if($core.assert($1)){
- self["@selectedPackage"]=aCategory;
- self["@selectedPackage"];
- self["@selectedMethod"]=nil;
- self["@selectedProtocol"]=self["@selectedMethod"];
- self["@selectedClass"]=self["@selectedProtocol"];
- self["@selectedClass"];
- self._resetClassesList();
- self._updateCategoriesList();
- self._updateClassesList();
- self._updateProtocolsList();
- self._updateMethodsList();
- self._updateSourceAndButtons();
- };
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"selectCategory:",{aCategory:aCategory},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["aCategory"],
- source: "selectCategory: aCategory\x0a\x09self cancelChanges ifTrue: [\x0a\x09selectedPackage := aCategory.\x0a\x09selectedClass := selectedProtocol := selectedMethod := nil.\x0a\x09self resetClassesList.\x0a\x09self\x0a\x09\x09updateCategoriesList;\x0a\x09\x09updateClassesList;\x0a\x09\x09updateProtocolsList;\x0a\x09\x09updateMethodsList;\x0a\x09\x09updateSourceAndButtons ]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["ifTrue:", "cancelChanges", "resetClassesList", "updateCategoriesList", "updateClassesList", "updateProtocolsList", "updateMethodsList", "updateSourceAndButtons"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "selectClass:",
- protocol: 'actions',
- fn: function (aClass){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1;
- $1=self._cancelChanges();
- if($core.assert($1)){
- self["@selectedClass"]=aClass;
- self["@selectedClass"];
- self["@selectedMethod"]=nil;
- self["@selectedProtocol"]=self["@selectedMethod"];
- self["@selectedProtocol"];
- self._updateClassesList();
- self._updateProtocolsList();
- self._updateMethodsList();
- self._updateSourceAndButtons();
- };
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"selectClass:",{aClass:aClass},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["aClass"],
- source: "selectClass: aClass\x0a\x09self cancelChanges ifTrue: [\x0a\x09selectedClass := aClass.\x0a\x09selectedProtocol := selectedMethod := nil.\x0a\x09self\x0a\x09\x09updateClassesList;\x0a\x09\x09updateProtocolsList;\x0a\x09\x09updateMethodsList;\x0a\x09\x09updateSourceAndButtons ]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["ifTrue:", "cancelChanges", "updateClassesList", "updateProtocolsList", "updateMethodsList", "updateSourceAndButtons"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "selectMethod:",
- protocol: 'actions',
- fn: function (aMethod){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1;
- $1=self._cancelChanges();
- if($core.assert($1)){
- self["@selectedMethod"]=aMethod;
- self["@selectedMethod"];
- self._updateProtocolsList();
- self._updateMethodsList();
- self._updateSourceAndButtons();
- };
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"selectMethod:",{aMethod:aMethod},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["aMethod"],
- source: "selectMethod: aMethod\x0a\x09self cancelChanges ifTrue: [\x0a\x09selectedMethod := aMethod.\x0a\x09self\x0a\x09\x09updateProtocolsList;\x0a\x09\x09updateMethodsList;\x0a\x09\x09updateSourceAndButtons ]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["ifTrue:", "cancelChanges", "updateProtocolsList", "updateMethodsList", "updateSourceAndButtons"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "selectProtocol:",
- protocol: 'actions',
- fn: function (aString){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1;
- $1=self._cancelChanges();
- if($core.assert($1)){
- self["@selectedProtocol"]=aString;
- self["@selectedProtocol"];
- self["@selectedMethod"]=nil;
- self["@selectedMethod"];
- self._updateProtocolsList();
- self._updateMethodsList();
- self._updateSourceAndButtons();
- };
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"selectProtocol:",{aString:aString},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["aString"],
- source: "selectProtocol: aString\x0a\x09self cancelChanges ifTrue: [\x0a\x09selectedProtocol := aString.\x0a\x09selectedMethod := nil.\x0a\x09self\x0a\x09\x09updateProtocolsList;\x0a\x09\x09updateMethodsList;\x0a\x09\x09updateSourceAndButtons ]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["ifTrue:", "cancelChanges", "updateProtocolsList", "updateMethodsList", "updateSourceAndButtons"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "selectTab:",
- protocol: 'actions',
- fn: function (aString){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1;
- $1=self._cancelChanges();
- if($core.assert($1)){
- self["@selectedTab"]=aString;
- self["@selectedTab"];
- self._selectProtocol_(nil);
- self._updateTabsList();
- };
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"selectTab:",{aString:aString},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["aString"],
- source: "selectTab: aString\x0a\x09self cancelChanges ifTrue: [\x0a\x09selectedTab := aString.\x0a\x09self selectProtocol: nil.\x0a\x09self updateTabsList ]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["ifTrue:", "cancelChanges", "selectProtocol:", "updateTabsList"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "selectedClass",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- return self["@selectedClass"];
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "selectedClass\x0a\x09^ selectedClass",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: []
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "selectedPackage",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- return self["@selectedPackage"];
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "selectedPackage\x0a\x09^ selectedPackage",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: []
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "setMethodProtocol:",
- protocol: 'actions',
- fn: function (aString){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$2;
- $1=self._cancelChanges();
- if($core.assert($1)){
- $2=$recv(self._protocols())._includes_(aString);
- if($core.assert($2)){
- $recv(self["@selectedMethod"])._protocol_(aString);
- self["@selectedProtocol"]=aString;
- self["@selectedProtocol"];
- self["@selectedMethod"]=self["@selectedMethod"];
- self["@selectedMethod"];
- self._updateProtocolsList();
- self._updateMethodsList();
- self._updateSourceAndButtons();
- } else {
- self._addNewProtocol();
- };
- };
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"setMethodProtocol:",{aString:aString},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["aString"],
- source: "setMethodProtocol: aString\x0a\x09self cancelChanges ifTrue: [\x0a\x09(self protocols includes: aString)\x0a\x09\x09ifFalse: [ self addNewProtocol ]\x0a\x09\x09ifTrue: [\x0a\x09\x09selectedMethod protocol: aString.\x0a\x09\x09selectedProtocol := aString.\x0a\x09\x09selectedMethod := selectedMethod.\x0a\x09\x09self\x0a\x09\x09\x09updateProtocolsList;\x0a\x09\x09\x09updateMethodsList;\x0a\x09\x09\x09updateSourceAndButtons ]]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["ifTrue:", "cancelChanges", "ifFalse:ifTrue:", "includes:", "protocols", "addNewProtocol", "protocol:", "updateProtocolsList", "updateMethodsList", "updateSourceAndButtons"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "showClassButtons",
- protocol: 'actions',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- $recv($recv(self["@classButtons"])._asJQuery())._show();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"showClassButtons",{},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "showClassButtons\x0a\x09classButtons asJQuery show",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["show", "asJQuery"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "showMethodButtons",
- protocol: 'actions',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- $recv($recv(self["@methodButtons"])._asJQuery())._show();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"showMethodButtons",{},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "showMethodButtons\x0a\x09methodButtons asJQuery show",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["show", "asJQuery"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "source",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$3,$2,$4,$receiver;
- $1=$recv(self["@selectedTab"]).__eq("comment");
- if(!$core.assert($1)){
- $3=$recv(self["@selectedProtocol"])._notNil();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["notNil"]=1;
- //>>excludeEnd("ctx");
- $2=$recv($3)._or_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return $recv(self["@selectedMethod"])._notNil();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
- //>>excludeEnd("ctx");
- }));
- return $recv($2)._ifFalse_ifTrue_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return self._declarationSource();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,3)});
- //>>excludeEnd("ctx");
- }),(function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return self._methodSource();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,4)});
- //>>excludeEnd("ctx");
- }));
- };
- $4=self["@selectedClass"];
- if(($receiver = $4) == null || $receiver.isNil){
- return "";
- } else {
- return self._classCommentSource();
- };
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"source",{},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "source\x0a\x09selectedTab = #comment ifFalse: [\x0a\x09^ (selectedProtocol notNil or: [ selectedMethod notNil ])\x0a\x09\x09ifFalse: [ self declarationSource ]\x0a\x09\x09ifTrue: [ self methodSource ]].\x0a\x09^ selectedClass\x0a\x09ifNil: [ '' ]\x0a\x09ifNotNil: [ self classCommentSource ]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["ifFalse:", "=", "ifFalse:ifTrue:", "or:", "notNil", "declarationSource", "methodSource", "ifNil:ifNotNil:", "classCommentSource"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "updateCategoriesList",
- protocol: 'updating',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$2;
- $recv(self["@packagesList"])._contents_((function(html){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return $recv(self._packages())._do_((function(each){
- var li,label;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- label=$recv(each)._ifEmpty_((function(){
- return "Unclassified";
- }));
- label;
- li=$recv(html)._li();
- li;
- $1=$recv(self["@selectedPackage"]).__eq(each);
- if($core.assert($1)){
- $recv(li)._class_("selected");
- };
- $2=li;
- $recv($2)._with_(label);
- return $recv($2)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx4) {
- //>>excludeEnd("ctx");
- return self._selectCategory_(each);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx4) {$ctx4.fillBlock({},$ctx3,5)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({each:each,li:li,label:label},$ctx2,2)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({html:html},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"updateCategoriesList",{},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "updateCategoriesList\x0a\x09packagesList contents: [ :html |\x0a\x09self packages do: [ :each || li label |\x0a\x09\x09label := each ifEmpty: [ 'Unclassified' ].\x0a\x09\x09li := html li.\x0a\x09\x09selectedPackage = each ifTrue: [\x0a\x09\x09li class: 'selected' ].\x0a\x09\x09li\x0a\x09\x09with: label;\x0a\x09\x09onClick: [ self selectCategory: each ]] ]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["contents:", "do:", "packages", "ifEmpty:", "li", "ifTrue:", "=", "class:", "with:", "onClick:", "selectCategory:"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "updateClassesList",
- protocol: 'updating',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- $recv($recv($globals.TabManager)._current())._update();
- $recv(self["@classesList"])._updateNodes();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"updateClassesList",{},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "updateClassesList\x0a\x09TabManager current update.\x0a\x09classesList updateNodes",
- referencedClasses: ["TabManager"],
- //>>excludeEnd("ide");
- messageSends: ["update", "current", "updateNodes"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "updateMethodsList",
- protocol: 'updating',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$2;
- $recv(self["@methodsList"])._contents_((function(html){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return $recv(self._methods())._do_((function(each){
- var li;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- li=$recv(html)._li();
- li;
- $1=$recv(self["@selectedMethod"]).__eq(each);
- if($core.assert($1)){
- $recv(li)._class_("selected");
- };
- $2=li;
- $recv($2)._with_($recv(each)._selector());
- return $recv($2)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx4) {
- //>>excludeEnd("ctx");
- return self._selectMethod_(each);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx4) {$ctx4.fillBlock({},$ctx3,4)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({each:each,li:li},$ctx2,2)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({html:html},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"updateMethodsList",{},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "updateMethodsList\x0a\x09methodsList contents: [ :html |\x0a\x09self methods do: [ :each || li |\x0a\x09\x09li := html li.\x0a\x09\x09selectedMethod = each ifTrue: [\x0a\x09\x09li class: 'selected' ].\x0a\x09\x09li\x0a\x09\x09with: each selector;\x0a\x09\x09onClick: [ self selectMethod: each ]] ]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["contents:", "do:", "methods", "li", "ifTrue:", "=", "class:", "with:", "selector", "onClick:", "selectMethod:"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "updateProtocolsList",
- protocol: 'updating',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$2;
- $recv(self["@protocolsList"])._contents_((function(html){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return $recv(self._protocols())._do_((function(each){
- var li;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- li=$recv(html)._li();
- li;
- $1=$recv(self["@selectedProtocol"]).__eq(each);
- if($core.assert($1)){
- $recv(li)._class_("selected");
- };
- $2=li;
- $recv($2)._with_(each);
- return $recv($2)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx4) {
- //>>excludeEnd("ctx");
- return self._selectProtocol_(each);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx4) {$ctx4.fillBlock({},$ctx3,4)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({each:each,li:li},$ctx2,2)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({html:html},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"updateProtocolsList",{},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "updateProtocolsList\x0a\x09protocolsList contents: [ :html |\x0a\x09self protocols do: [ :each || li |\x0a\x09\x09li := html li.\x0a\x09\x09selectedProtocol = each ifTrue: [\x0a\x09\x09li class: 'selected' ].\x0a\x09\x09li\x0a\x09\x09with: each;\x0a\x09\x09onClick: [ self selectProtocol: each ]] ]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["contents:", "do:", "protocols", "li", "ifTrue:", "=", "class:", "with:", "onClick:", "selectProtocol:"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "updateSourceAndButtons",
- protocol: 'updating',
- fn: function (){
- var self=this;
- var currentProtocol;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$2,$3,$4,$5,$6,$7,$8,$9,$10,$11,$12,$14,$13,$16,$17,$18,$19,$21,$20,$22,$23,$15,$24,$25,$27,$28,$29,$26,$30,$31;
- self._disableSaveButton();
- $recv(self["@classButtons"])._contents_((function(html){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- $1=$recv(html)._button();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["button"]=1;
- //>>excludeEnd("ctx");
- $recv($1)._title_("Create a new class");
- $recv($1)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- return self._addNewClass();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({},$ctx2,2)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["onClick:"]=1;
- //>>excludeEnd("ctx");
- $2=$recv($1)._with_("New class");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["with:"]=1;
- //>>excludeEnd("ctx");
- $2;
- $3=$recv(html)._button();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["button"]=2;
- //>>excludeEnd("ctx");
- $recv($3)._with_("Rename class");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["with:"]=2;
- //>>excludeEnd("ctx");
- $4=$recv($3)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- return self._renameClass();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({},$ctx2,3)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["onClick:"]=2;
- //>>excludeEnd("ctx");
- $4;
- $5=$recv(html)._button();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["button"]=3;
- //>>excludeEnd("ctx");
- $recv($5)._with_("Copy class");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["with:"]=3;
- //>>excludeEnd("ctx");
- $6=$recv($5)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- return self._copyClass();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({},$ctx2,4)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["onClick:"]=3;
- //>>excludeEnd("ctx");
- $6;
- $7=$recv(html)._button();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["button"]=4;
- //>>excludeEnd("ctx");
- $recv($7)._with_("Remove class");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["with:"]=4;
- //>>excludeEnd("ctx");
- $8=$recv($7)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- return self._removeClass();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({},$ctx2,5)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["onClick:"]=4;
- //>>excludeEnd("ctx");
- $8;
- $9=$recv(html)._button();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["button"]=5;
- //>>excludeEnd("ctx");
- $recv($9)._with_("References");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["with:"]=5;
- //>>excludeEnd("ctx");
- $10=$recv($9)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- return self._searchClassReferences();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({},$ctx2,6)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["onClick:"]=5;
- //>>excludeEnd("ctx");
- return $10;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({html:html},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["contents:"]=1;
- //>>excludeEnd("ctx");
- $recv(self["@methodButtons"])._contents_((function(html){
- var protocolSelect,referencesSelect;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- $11=$recv(html)._button();
- $recv($11)._with_("Remove method");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["with:"]=6;
- //>>excludeEnd("ctx");
- $recv($11)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- return self._removeMethod();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({},$ctx2,8)});
- //>>excludeEnd("ctx");
- }));
- protocolSelect=$recv(html)._select();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["select"]=1;
- //>>excludeEnd("ctx");
- protocolSelect;
- $12=protocolSelect;
- $recv($12)._onChange_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- $14=$recv(protocolSelect)._asJQuery();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["asJQuery"]=1;
- //>>excludeEnd("ctx");
- $13=$recv($14)._val();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["val"]=1;
- //>>excludeEnd("ctx");
- return self._setMethodProtocol_($13);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({},$ctx2,9)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["onChange:"]=1;
- //>>excludeEnd("ctx");
- $15=$recv($12)._with_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- $16=$recv(html)._option();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["option"]=1;
- //>>excludeEnd("ctx");
- $recv($16)._with_("Method protocol");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["with:"]=8;
- //>>excludeEnd("ctx");
- $17=$recv($16)._at_put_("disabled","disabled");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["at:put:"]=1;
- //>>excludeEnd("ctx");
- $17;
- $18=$recv(html)._option();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["option"]=2;
- //>>excludeEnd("ctx");
- $recv($18)._class_("important");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["class:"]=1;
- //>>excludeEnd("ctx");
- $19=$recv($18)._with_("New...");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["with:"]=9;
- //>>excludeEnd("ctx");
- $19;
- currentProtocol=self["@selectedProtocol"];
- currentProtocol;
- $21=$recv(currentProtocol)._isNil();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["isNil"]=1;
- //>>excludeEnd("ctx");
- $20=$recv($21)._and_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx4) {
- //>>excludeEnd("ctx");
- return $recv(self["@selectedMethod"])._notNil();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx4.sendIdx["notNil"]=1;
- //>>excludeEnd("ctx");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx4) {$ctx4.fillBlock({},$ctx3,11)});
- //>>excludeEnd("ctx");
- }));
- if($core.assert($20)){
- currentProtocol=$recv(self["@selectedMethod"])._category();
- currentProtocol;
- };
- return $recv(self._protocols())._do_((function(each){
- var option;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx4) {
- //>>excludeEnd("ctx");
- $22=$recv(html)._option();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx4.sendIdx["option"]=3;
- //>>excludeEnd("ctx");
- option=$recv($22)._with_(each);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx4.sendIdx["with:"]=10;
- //>>excludeEnd("ctx");
- option;
- $23=$recv(currentProtocol).__eq(each);
- if($core.assert($23)){
- return $recv(option)._at_put_("selected","selected");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx4.sendIdx["at:put:"]=2;
- //>>excludeEnd("ctx");
- };
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx4) {$ctx4.fillBlock({each:each,option:option},$ctx3,13)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["do:"]=1;
- //>>excludeEnd("ctx");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({},$ctx2,10)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["with:"]=7;
- //>>excludeEnd("ctx");
- $15;
- $24=$recv(self["@selectedMethod"])._isNil();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["isNil"]=2;
- //>>excludeEnd("ctx");
- if(!$core.assert($24)){
- referencesSelect=$recv(html)._select();
- referencesSelect;
- $25=referencesSelect;
- $recv($25)._onChange_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- return self._searchReferencesOf_($recv($recv(referencesSelect)._asJQuery())._val());
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({},$ctx2,16)});
- //>>excludeEnd("ctx");
- }));
- $26=$recv($25)._with_((function(){
- var option;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- $27=$recv(html)._option();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["option"]=4;
- //>>excludeEnd("ctx");
- $recv($27)._with_("References");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["with:"]=12;
- //>>excludeEnd("ctx");
- $recv($27)._at_put_("disabled","disabled");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["at:put:"]=3;
- //>>excludeEnd("ctx");
- $recv($27)._at_put_("selected","selected");
- $28=$recv(html)._option();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["option"]=5;
- //>>excludeEnd("ctx");
- $recv($28)._class_("important");
- $29=$recv($28)._with_($recv(self["@selectedMethod"])._selector());
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["with:"]=13;
- //>>excludeEnd("ctx");
- $29;
- return $recv($recv($recv(self["@selectedMethod"])._messageSends())._sorted())._do_((function(each){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx4) {
- //>>excludeEnd("ctx");
- return $recv($recv(html)._option())._with_(each);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx4) {$ctx4.fillBlock({each:each},$ctx3,18)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({option:option},$ctx2,17)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["with:"]=11;
- //>>excludeEnd("ctx");
- return $26;
- };
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({html:html,protocolSelect:protocolSelect,referencesSelect:referencesSelect},$ctx1,7)});
- //>>excludeEnd("ctx");
- }));
- $30=$recv(self["@selectedMethod"])._isNil();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["isNil"]=3;
- //>>excludeEnd("ctx");
- if($core.assert($30)){
- self._hideMethodButtons();
- $31=$recv($recv(self["@selectedClass"])._isNil())._or_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return $recv(self["@selectedProtocol"])._notNil();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,20)});
- //>>excludeEnd("ctx");
- }));
- if($core.assert($31)){
- self._hideClassButtons();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["hideClassButtons"]=1;
- //>>excludeEnd("ctx");
- } else {
- self._showClassButtons();
- };
- } else {
- self._hideClassButtons();
- self._showMethodButtons();
- };
- $recv(self["@sourceArea"])._val_(self._source());
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"updateSourceAndButtons",{currentProtocol:currentProtocol},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "updateSourceAndButtons\x0a\x09| currentProtocol |\x0a\x0a\x09self disableSaveButton.\x0a\x09classButtons contents: [ :html |\x0a\x09\x09html button\x0a\x09\x09\x09title: 'Create a new class';\x0a\x09\x09\x09onClick: [ self addNewClass ];\x0a\x09\x09\x09with: 'New class'.\x0a\x09\x09html button\x0a\x09\x09\x09with: 'Rename class';\x0a\x09\x09\x09onClick: [ self renameClass ].\x0a\x09\x09html button\x0a\x09\x09\x09with: 'Copy class';\x0a\x09\x09\x09onClick: [ self copyClass ].\x0a\x09\x09html button\x0a\x09\x09\x09with: 'Remove class';\x0a\x09\x09\x09onClick: [ self removeClass ].\x0a\x09\x09html button\x0a\x09\x09\x09with: 'References';\x0a\x09\x09\x09onClick: [ self searchClassReferences ]].\x0a\x09methodButtons contents: [ :html | | protocolSelect referencesSelect |\x0a\x09\x09html button\x0a\x09\x09\x09with: 'Remove method';\x0a\x09\x09\x09onClick: [ self removeMethod ].\x0a\x09\x09protocolSelect := html select.\x0a\x09\x09\x09\x09protocolSelect\x0a\x09\x09\x09onChange: [ self setMethodProtocol: protocolSelect asJQuery val ];\x0a\x09\x09\x09with: [\x0a\x09\x09\x09\x09html option\x0a\x09\x09\x09\x09\x09with: 'Method protocol';\x0a\x09\x09\x09\x09\x09at: 'disabled' put: 'disabled'.\x0a\x09\x09\x09\x09html option\x0a\x09\x09\x09\x09\x09class: 'important';\x0a\x09\x09\x09\x09\x09with: 'New...'.\x0a\x09\x09\x09\x09currentProtocol := selectedProtocol.\x0a\x09\x09\x09\x09(currentProtocol isNil and: [ selectedMethod notNil ])\x0a\x09\x09\x09\x09\x09ifTrue: [ currentProtocol := selectedMethod category ].\x0a\x09\x09\x09\x09self protocols do: [ :each | | option |\x0a\x09\x09\x09\x09\x09option := html option with: each.\x0a\x09\x09\x09\x09\x09currentProtocol = each ifTrue: [ option at: 'selected' put: 'selected' ] ] ].\x0a\x09\x09selectedMethod isNil ifFalse: [\x0a\x09\x09\x09referencesSelect := html select.\x0a\x09\x09\x09\x09\x09\x09referencesSelect\x0a\x09\x09\x09\x09onChange: [ self searchReferencesOf: referencesSelect asJQuery val ];\x0a\x09\x09\x09\x09with: [ |option|\x0a\x09\x09\x09\x09\x09html option\x0a\x09\x09\x09\x09\x09\x09with: 'References';\x0a\x09\x09\x09\x09\x09\x09at: 'disabled' put: 'disabled';\x0a\x09\x09\x09\x09\x09\x09at: 'selected' put: 'selected'.\x0a\x09\x09\x09\x09\x09html option\x0a\x09\x09\x09\x09\x09\x09class: 'important';\x0a\x09\x09\x09\x09\x09\x09with: selectedMethod selector.\x0a\x09\x09\x09\x09\x09selectedMethod messageSends sorted do: [ :each |\x0a\x09\x09\x09\x09\x09\x09html option with: each ]] ]].\x0a\x09selectedMethod isNil\x0a\x09\x09ifTrue: [\x0a\x09\x09\x09self hideMethodButtons.\x0a\x09\x09\x09\x09(selectedClass isNil or: [ selectedProtocol notNil ])\x0a\x09\x09\x09\x09\x09ifTrue: [ self hideClassButtons ]\x0a\x09\x09\x09\x09\x09ifFalse: [ self showClassButtons ]]\x0a\x09\x09ifFalse: [\x0a\x09\x09\x09self hideClassButtons.\x0a\x09\x09\x09self showMethodButtons ].\x0a\x09sourceArea val: self source",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["disableSaveButton", "contents:", "title:", "button", "onClick:", "addNewClass", "with:", "renameClass", "copyClass", "removeClass", "searchClassReferences", "removeMethod", "select", "onChange:", "setMethodProtocol:", "val", "asJQuery", "option", "at:put:", "class:", "ifTrue:", "and:", "isNil", "notNil", "category", "do:", "protocols", "=", "ifFalse:", "searchReferencesOf:", "selector", "sorted", "messageSends", "ifTrue:ifFalse:", "hideMethodButtons", "or:", "hideClassButtons", "showClassButtons", "showMethodButtons", "val:", "source"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "updateStatus",
- protocol: 'updating',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$2,$3,$receiver;
- $1=$recv($recv(self["@sourceArea"])._val()).__eq(self._source());
- if($core.assert($1)){
- $2=self["@saveButton"];
- if(($receiver = $2) == null || $receiver.isNil){
- $2;
- } else {
- $recv(self["@saveButton"])._at_put_("disabled",true);
- };
- self["@unsavedChanges"]=false;
- self["@unsavedChanges"];
- } else {
- $3=self["@saveButton"];
- if(($receiver = $3) == null || $receiver.isNil){
- $3;
- } else {
- $recv(self["@saveButton"])._removeAt_("disabled");
- };
- self["@unsavedChanges"]=true;
- self["@unsavedChanges"];
- };
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"updateStatus",{},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "updateStatus\x0a\x09sourceArea val = self source\x0a\x09\x09ifTrue: [\x0a\x09\x09\x09saveButton ifNotNil: [\x0a\x09\x09\x09\x09saveButton at: 'disabled' put: true ].\x0a\x09\x09\x09\x09unsavedChanges := false ]\x0a\x09\x09ifFalse: [\x0a\x09\x09\x09saveButton ifNotNil: [\x0a\x09\x09\x09\x09saveButton removeAt: 'disabled' ].\x0a\x09\x09\x09unsavedChanges := true ]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["ifTrue:ifFalse:", "=", "val", "source", "ifNotNil:", "at:put:", "removeAt:"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "updateTabsList",
- protocol: 'updating',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$2,$3,$4,$5,$6,$7,$8,$9,$10,$11,$12,$13,$14,$15,$16,$17,$18;
- $recv(self["@tabsList"])._contents_((function(html){
- var li;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- li=$recv(html)._li();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["li"]=1;
- //>>excludeEnd("ctx");
- li;
- $1=$recv(self["@selectedTab"]).__eq("instance");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["="]=1;
- //>>excludeEnd("ctx");
- if($core.assert($1)){
- $recv(li)._class_("selected");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["class:"]=1;
- //>>excludeEnd("ctx");
- };
- $2=li;
- $recv($2)._with_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- $3=$recv(html)._span();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["span"]=1;
- //>>excludeEnd("ctx");
- $recv($3)._class_("ltab");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["class:"]=2;
- //>>excludeEnd("ctx");
- $4=$recv(html)._span();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["span"]=2;
- //>>excludeEnd("ctx");
- $recv($4)._class_("mtab");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["class:"]=3;
- //>>excludeEnd("ctx");
- $5=$recv($4)._with_("Instance");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["with:"]=2;
- //>>excludeEnd("ctx");
- $5;
- $6=$recv(html)._span();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["span"]=3;
- //>>excludeEnd("ctx");
- return $recv($6)._class_("rtab");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["class:"]=4;
- //>>excludeEnd("ctx");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({},$ctx2,3)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["with:"]=1;
- //>>excludeEnd("ctx");
- $7=$recv($2)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- return self._selectTab_("instance");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["selectTab:"]=1;
- //>>excludeEnd("ctx");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({},$ctx2,4)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["onClick:"]=1;
- //>>excludeEnd("ctx");
- $7;
- li=$recv(html)._li();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["li"]=2;
- //>>excludeEnd("ctx");
- li;
- $8=$recv(self["@selectedTab"]).__eq("class");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["="]=2;
- //>>excludeEnd("ctx");
- if($core.assert($8)){
- $recv(li)._class_("selected");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["class:"]=5;
- //>>excludeEnd("ctx");
- };
- $9=li;
- $recv($9)._with_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- $10=$recv(html)._span();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["span"]=4;
- //>>excludeEnd("ctx");
- $recv($10)._class_("ltab");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["class:"]=6;
- //>>excludeEnd("ctx");
- $11=$recv(html)._span();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["span"]=5;
- //>>excludeEnd("ctx");
- $recv($11)._class_("mtab");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["class:"]=7;
- //>>excludeEnd("ctx");
- $12=$recv($11)._with_("Class");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["with:"]=4;
- //>>excludeEnd("ctx");
- $12;
- $13=$recv(html)._span();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["span"]=6;
- //>>excludeEnd("ctx");
- return $recv($13)._class_("rtab");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["class:"]=8;
- //>>excludeEnd("ctx");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({},$ctx2,6)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["with:"]=3;
- //>>excludeEnd("ctx");
- $14=$recv($9)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- return self._selectTab_("class");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["selectTab:"]=2;
- //>>excludeEnd("ctx");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({},$ctx2,7)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["onClick:"]=2;
- //>>excludeEnd("ctx");
- $14;
- li=$recv(html)._li();
- li;
- $15=$recv(self["@selectedTab"]).__eq("comment");
- if($core.assert($15)){
- $recv(li)._class_("selected");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["class:"]=9;
- //>>excludeEnd("ctx");
- };
- $16=li;
- $recv($16)._with_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- $17=$recv(html)._span();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["span"]=7;
- //>>excludeEnd("ctx");
- $recv($17)._class_("ltab");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["class:"]=10;
- //>>excludeEnd("ctx");
- $18=$recv(html)._span();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["span"]=8;
- //>>excludeEnd("ctx");
- $recv($18)._class_("mtab");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["class:"]=11;
- //>>excludeEnd("ctx");
- $recv($18)._with_("Comment");
- return $recv($recv(html)._span())._class_("rtab");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({},$ctx2,9)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["with:"]=5;
- //>>excludeEnd("ctx");
- return $recv($16)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- return self._selectTab_("comment");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({},$ctx2,10)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({html:html,li:li},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"updateTabsList",{},$globals.Browser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "updateTabsList\x0a\x09tabsList contents: [ :html || li |\x0a\x09li := html li.\x0a\x09selectedTab = #instance ifTrue: [ li class: 'selected' ].\x0a\x09li\x0a\x09\x09with: [\x0a\x09\x09html span class: 'ltab'.\x0a\x09\x09html span class: 'mtab'; with: 'Instance'.\x0a\x09\x09html span class: 'rtab' ];\x0a\x09\x09onClick: [ self selectTab: #instance ].\x0a\x09li := html li.\x0a\x09selectedTab = #class ifTrue: [ li class: 'selected' ].\x0a\x09li\x0a\x09\x09with: [\x0a\x09\x09html span class: 'ltab'.\x0a\x09\x09html span class: 'mtab'; with: 'Class'.\x0a\x09\x09html span class: 'rtab' ];\x0a\x09\x09onClick: [ self selectTab: #class ].\x0a\x09li := html li.\x0a\x09selectedTab = #comment ifTrue: [ li class: 'selected' ].\x0a\x09li\x0a\x09\x09with: [\x0a\x09\x09html span class: 'ltab'.\x0a\x09\x09html span class: 'mtab'; with: 'Comment'.\x0a\x09\x09html span class: 'rtab' ];\x0a\x09\x09onClick: [ self selectTab: #comment ]]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["contents:", "li", "ifTrue:", "=", "class:", "with:", "span", "onClick:", "selectTab:"]
- }),
- $globals.Browser);
- $core.addMethod(
- $core.method({
- selector: "open",
- protocol: 'convenience',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- $recv(self._new())._open();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"open",{},$globals.Browser.klass)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "open\x0a\x09self new open",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["open", "new"]
- }),
- $globals.Browser.klass);
- $core.addMethod(
- $core.method({
- selector: "openOn:",
- protocol: 'convenience',
- fn: function (aClass){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1;
- $1=self._new();
- $recv($1)._open();
- $recv($1)._selectCategory_($recv(aClass)._category());
- return $recv($1)._selectClass_(aClass);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"openOn:",{aClass:aClass},$globals.Browser.klass)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["aClass"],
- source: "openOn: aClass\x0a\x09^ self new\x0a\x09open;\x0a\x09selectCategory: aClass category;\x0a\x09selectClass: aClass",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["open", "new", "selectCategory:", "category", "selectClass:"]
- }),
- $globals.Browser.klass);
- $core.addClass('Debugger', $globals.TabWidget, ['error', 'selectedContext', 'sourceArea', 'ul', 'ul2', 'inspector', 'saveButton', 'unsavedChanges', 'selectedVariable', 'selectedVariableName', 'inspectButton'], 'IDE');
- $core.addMethod(
- $core.method({
- selector: "allVariables",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- var all;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $3,$2,$1;
- all=$recv($globals.Dictionary)._new();
- $3=self._receiver();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["receiver"]=1;
- //>>excludeEnd("ctx");
- $2=$recv($3)._class();
- $1=$recv($2)._allInstanceVariableNames();
- $recv($1)._do_((function(each){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return $recv(all)._at_put_(each,$recv(self._receiver())._instVarAt_(each));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["at:put:"]=1;
- //>>excludeEnd("ctx");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- $recv($recv(self["@selectedContext"])._locals())._keysAndValuesDo_((function(key,value){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return $recv(all)._at_put_(key,value);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({key:key,value:value},$ctx1,2)});
- //>>excludeEnd("ctx");
- }));
- return all;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"allVariables",{all:all},$globals.Debugger)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "allVariables\x0a\x09| all |\x0a\x09all := Dictionary new.\x0a\x0a\x09self receiver class allInstanceVariableNames do: [ :each |\x0a\x09\x09all at: each put: (self receiver instVarAt: each) ].\x0a\x09\x0a\x09selectedContext locals keysAndValuesDo: [ :key :value |\x0a\x09\x09all at: key put: value ].\x0a\x09\x0a\x09^ all",
- referencedClasses: ["Dictionary"],
- //>>excludeEnd("ide");
- messageSends: ["new", "do:", "allInstanceVariableNames", "class", "receiver", "at:put:", "instVarAt:", "keysAndValuesDo:", "locals"]
- }),
- $globals.Debugger);
- $core.addMethod(
- $core.method({
- selector: "canBeClosed",
- protocol: 'testing',
- fn: function (){
- var self=this;
- return true;
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "canBeClosed\x0a\x09^ true",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: []
- }),
- $globals.Debugger);
- $core.addMethod(
- $core.method({
- selector: "error",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- return self["@error"];
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "error\x0a\x09^ error",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: []
- }),
- $globals.Debugger);
- $core.addMethod(
- $core.method({
- selector: "error:",
- protocol: 'accessing',
- fn: function (anError){
- var self=this;
- self["@error"]=anError;
- return self;
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["anError"],
- source: "error: anError\x0a\x09error := anError",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: []
- }),
- $globals.Debugger);
- $core.addMethod(
- $core.method({
- selector: "initialize",
- protocol: 'initialization',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- (
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.supercall = true,
- //>>excludeEnd("ctx");
- ($globals.Debugger.superclass||$boot.nilAsClass).fn.prototype._initialize.apply($recv(self), []));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.supercall = false;
- //>>excludeEnd("ctx");;
- $recv(self["@unsavedChanges"]).__eq(false);
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"initialize",{},$globals.Debugger)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "initialize\x0a\x09super initialize.\x0a\x09unsavedChanges = false",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["initialize", "="]
- }),
- $globals.Debugger);
- $core.addMethod(
- $core.method({
- selector: "inspectSelectedVariable",
- protocol: 'actions',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- $recv(self["@selectedVariable"])._inspect();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"inspectSelectedVariable",{},$globals.Debugger)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "inspectSelectedVariable\x0a\x09selectedVariable inspect",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["inspect"]
- }),
- $globals.Debugger);
- $core.addMethod(
- $core.method({
- selector: "label",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- return "[ Debugger ]";
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "label\x0a\x09^ '[ Debugger ]'",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: []
- }),
- $globals.Debugger);
- $core.addMethod(
- $core.method({
- selector: "method",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- return $recv(self["@selectedContext"])._method();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"method",{},$globals.Debugger)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "method\x0a\x09^ selectedContext method",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["method"]
- }),
- $globals.Debugger);
- $core.addMethod(
- $core.method({
- selector: "proceed",
- protocol: 'actions',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- self._close();
- $recv($recv(self["@selectedContext"])._receiver())._perform_withArguments_($recv(self["@selectedContext"])._selector(),$recv(self["@selectedContext"])._locals());
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"proceed",{},$globals.Debugger)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "proceed\x0a\x09self close.\x0a\x09selectedContext receiver perform: selectedContext selector withArguments: selectedContext locals",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["close", "perform:withArguments:", "receiver", "selector", "locals"]
- }),
- $globals.Debugger);
- $core.addMethod(
- $core.method({
- selector: "receiver",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- return $recv(self["@selectedContext"])._receiver();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"receiver",{},$globals.Debugger)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "receiver\x0a\x09^ selectedContext receiver",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["receiver"]
- }),
- $globals.Debugger);
- $core.addMethod(
- $core.method({
- selector: "renderBottomPanelOn:",
- protocol: 'rendering',
- fn: function (html){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1;
- $1=$recv(html)._div();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["div"]=1;
- //>>excludeEnd("ctx");
- $recv($1)._class_("amber_sourceCode debugger");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["class:"]=1;
- //>>excludeEnd("ctx");
- $recv($1)._with_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- self["@sourceArea"]=$recv($globals.SourceArea)._new();
- self["@sourceArea"];
- return $recv(self["@sourceArea"])._renderOn_(html);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- self["@ul2"]=$recv($recv(html)._ul())._class_("amber_column debugger variables");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["class:"]=2;
- //>>excludeEnd("ctx");
- self["@inspector"]=$recv($recv(html)._div())._class_("amber_column debugger inspector");
- $recv(self["@sourceArea"])._onKeyUp_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return self._updateStatus();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
- //>>excludeEnd("ctx");
- }));
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"renderBottomPanelOn:",{html:html},$globals.Debugger)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["html"],
- source: "renderBottomPanelOn: html\x0a\x09html div\x0a\x09\x09class: 'amber_sourceCode debugger';\x0a\x09\x09with: [\x0a\x09\x09\x09sourceArea := SourceArea new.\x0a\x09\x09\x09sourceArea renderOn: html ].\x0a\x09ul2 := html ul class: 'amber_column debugger variables'.\x0a\x09inspector := html div class: 'amber_column debugger inspector'.\x0a\x09sourceArea\x0a\x09\x09onKeyUp: [ self updateStatus ]",
- referencedClasses: ["SourceArea"],
- //>>excludeEnd("ide");
- messageSends: ["class:", "div", "with:", "new", "renderOn:", "ul", "onKeyUp:", "updateStatus"]
- }),
- $globals.Debugger);
- $core.addMethod(
- $core.method({
- selector: "renderBoxOn:",
- protocol: 'rendering',
- fn: function (html){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- self._renderTopPanelOn_(html);
- self._renderBottomPanelOn_(html);
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"renderBoxOn:",{html:html},$globals.Debugger)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["html"],
- source: "renderBoxOn: html\x0a\x09self\x0a\x09\x09renderTopPanelOn: html;\x0a\x09\x09renderBottomPanelOn: html",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["renderTopPanelOn:", "renderBottomPanelOn:"]
- }),
- $globals.Debugger);
- $core.addMethod(
- $core.method({
- selector: "renderButtonsOn:",
- protocol: 'rendering',
- fn: function (html){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$2,$3,$4,$5,$6,$7,$8,$9,$10,$11,$12,$13;
- $1=$recv(html)._button();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["button"]=1;
- //>>excludeEnd("ctx");
- $recv($1)._with_("Save");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["with:"]=1;
- //>>excludeEnd("ctx");
- $2=$recv($1)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return self._save();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["onClick:"]=1;
- //>>excludeEnd("ctx");
- self["@saveButton"]=$2;
- $3=$recv(html)._button();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["button"]=2;
- //>>excludeEnd("ctx");
- $recv($3)._with_("DoIt");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["with:"]=2;
- //>>excludeEnd("ctx");
- $4=$recv($3)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return $recv(self["@sourceArea"])._doIt();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["onClick:"]=2;
- //>>excludeEnd("ctx");
- $5=$recv(html)._button();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["button"]=3;
- //>>excludeEnd("ctx");
- $recv($5)._with_("PrintIt");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["with:"]=3;
- //>>excludeEnd("ctx");
- $6=$recv($5)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return $recv(self["@sourceArea"])._printIt();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,3)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["onClick:"]=3;
- //>>excludeEnd("ctx");
- $7=$recv(html)._button();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["button"]=4;
- //>>excludeEnd("ctx");
- $recv($7)._with_("InspectIt");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["with:"]=4;
- //>>excludeEnd("ctx");
- $8=$recv($7)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return $recv(self["@sourceArea"])._inspectIt();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,4)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["onClick:"]=4;
- //>>excludeEnd("ctx");
- $9=$recv(html)._button();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["button"]=5;
- //>>excludeEnd("ctx");
- $recv($9)._with_("Proceed");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["with:"]=5;
- //>>excludeEnd("ctx");
- $10=$recv($9)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return self._proceed();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,5)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["onClick:"]=5;
- //>>excludeEnd("ctx");
- $11=$recv(html)._button();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["button"]=6;
- //>>excludeEnd("ctx");
- $recv($11)._with_("Abandon");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["with:"]=6;
- //>>excludeEnd("ctx");
- $12=$recv($11)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return self._close();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,6)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["onClick:"]=6;
- //>>excludeEnd("ctx");
- $13=$recv(html)._button();
- $recv($13)._class_("amber_button debugger inspect");
- $recv($13)._with_("Inspect");
- self["@inspectButton"]=$recv($13)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return self._inspectSelectedVariable();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,7)});
- //>>excludeEnd("ctx");
- }));
- self._updateSourceArea();
- self._updateStatus();
- self._updateVariablesList();
- self._updateInspector();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"renderButtonsOn:",{html:html},$globals.Debugger)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["html"],
- source: "renderButtonsOn: html\x0a\x09saveButton := html button\x0a\x09\x09with: 'Save';\x0a\x09\x09onClick: [ self save ].\x0a\x09html button\x0a\x09\x09with: 'DoIt';\x0a\x09\x09onClick: [ sourceArea doIt ].\x0a\x09html button\x0a\x09\x09with: 'PrintIt';\x0a\x09\x09onClick: [ sourceArea printIt ].\x0a\x09html button\x0a\x09\x09with: 'InspectIt';\x0a\x09\x09onClick: [ sourceArea inspectIt ].\x0a\x09html button\x0a\x09\x09with: 'Proceed';\x0a\x09\x09onClick: [ self proceed ].\x0a\x09html button\x0a\x09\x09with: 'Abandon';\x0a\x09\x09onClick: [ self close ].\x0a\x09inspectButton := html button\x0a\x09\x09class: 'amber_button debugger inspect';\x0a\x09\x09with: 'Inspect';\x0a\x09\x09onClick: [ self inspectSelectedVariable ].\x0a\x09self\x0a\x09\x09updateSourceArea;\x0a\x09\x09updateStatus;\x0a\x09\x09updateVariablesList;\x0a\x09\x09updateInspector",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["with:", "button", "onClick:", "save", "doIt", "printIt", "inspectIt", "proceed", "close", "class:", "inspectSelectedVariable", "updateSourceArea", "updateStatus", "updateVariablesList", "updateInspector"]
- }),
- $globals.Debugger);
- $core.addMethod(
- $core.method({
- selector: "renderContext:on:",
- protocol: 'rendering',
- fn: function (aContext,html){
- var self=this;
- var li;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$2,$3,$receiver;
- li=$recv(html)._li();
- $1=$recv(self["@selectedContext"]).__eq(aContext);
- if($core.assert($1)){
- $recv(li)._class_("selected");
- };
- $2=li;
- $recv($2)._with_($recv(aContext)._asString());
- $recv($2)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return self._selectContext_(aContext);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
- //>>excludeEnd("ctx");
- }));
- $3=$recv(aContext)._outerContext();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["outerContext"]=1;
- //>>excludeEnd("ctx");
- if(($receiver = $3) == null || $receiver.isNil){
- $3;
- } else {
- self._renderContext_on_($recv(aContext)._outerContext(),html);
- };
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"renderContext:on:",{aContext:aContext,html:html,li:li},$globals.Debugger)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["aContext", "html"],
- source: "renderContext: aContext on: html\x0a\x09| li |\x0a\x09li := html li.\x0a\x09selectedContext = aContext ifTrue: [\x0a\x09\x09li class: 'selected' ].\x0a\x09li\x0a\x09\x09with: aContext asString;\x0a\x09\x09onClick: [ self selectContext: aContext ].\x0a\x09aContext outerContext ifNotNil: [ self renderContext: aContext outerContext on: html ]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["li", "ifTrue:", "=", "class:", "with:", "asString", "onClick:", "selectContext:", "ifNotNil:", "outerContext", "renderContext:on:"]
- }),
- $globals.Debugger);
- $core.addMethod(
- $core.method({
- selector: "renderTopPanelOn:",
- protocol: 'rendering',
- fn: function (html){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$2,$4,$7,$6,$5,$8,$3;
- $1=self._error();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["error"]=1;
- //>>excludeEnd("ctx");
- self["@selectedContext"]=$recv($1)._context();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["context"]=1;
- //>>excludeEnd("ctx");
- $2=$recv(html)._div();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["div"]=1;
- //>>excludeEnd("ctx");
- $recv($2)._class_("top");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["class:"]=1;
- //>>excludeEnd("ctx");
- $3=$recv($2)._with_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- $4=$recv(html)._div();
- $recv($4)._class_("label");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["class:"]=2;
- //>>excludeEnd("ctx");
- $7=self._error();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["error"]=2;
- //>>excludeEnd("ctx");
- $6=$recv($7)._messageText();
- $5=$recv($4)._with_($6);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["with:"]=2;
- //>>excludeEnd("ctx");
- $5;
- $8=$recv(html)._ul();
- $recv($8)._class_("amber_column debugger contexts");
- self["@ul"]=$recv($8)._with_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- return self._renderContext_on_($recv(self._error())._context(),html);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({},$ctx2,2)});
- //>>excludeEnd("ctx");
- }));
- return self["@ul"];
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["with:"]=1;
- //>>excludeEnd("ctx");
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"renderTopPanelOn:",{html:html},$globals.Debugger)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["html"],
- source: "renderTopPanelOn: html\x0a\x09selectedContext := self error context.\x0a\x09html div\x0a\x09\x09class: 'top';\x0a\x09\x09with: [\x0a\x09\x09\x09html div\x0a\x09\x09\x09\x09class: 'label';\x0a\x09\x09\x09\x09with: self error messageText.\x0a\x09\x09\x09ul := html ul\x0a\x09\x09\x09\x09class: 'amber_column debugger contexts';\x0a\x09\x09\x09\x09with: [ self renderContext: self error context on: html ]]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["context", "error", "class:", "div", "with:", "messageText", "ul", "renderContext:on:"]
- }),
- $globals.Debugger);
- $core.addMethod(
- $core.method({
- selector: "save",
- protocol: 'actions',
- fn: function (){
- var self=this;
- var protocol;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $4,$3,$2,$1;
- $4=$recv(self["@selectedContext"])._receiver();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["receiver"]=1;
- //>>excludeEnd("ctx");
- $3=$recv($4)._class();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["class"]=1;
- //>>excludeEnd("ctx");
- $2=$recv($3)._methodDictionary();
- $1=$recv($2)._at_($recv(self["@selectedContext"])._selector());
- protocol=$recv($1)._category();
- $recv($recv($recv(self["@selectedContext"])._receiver())._class())._compile_protocol_($recv(self["@sourceArea"])._val(),protocol);
- self._updateStatus();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"save",{protocol:protocol},$globals.Debugger)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "save\x0a\x09| protocol |\x0a\x09protocol := (selectedContext receiver class methodDictionary at: selectedContext selector) category.\x0a\x09selectedContext receiver class compile: sourceArea val protocol: protocol.\x0a\x09self updateStatus",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["category", "at:", "methodDictionary", "class", "receiver", "selector", "compile:protocol:", "val", "updateStatus"]
- }),
- $globals.Debugger);
- $core.addMethod(
- $core.method({
- selector: "selectContext:",
- protocol: 'actions',
- fn: function (aContext){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- self["@selectedContext"]=aContext;
- self["@selectedVariable"]=nil;
- self["@selectedVariableName"]=nil;
- self._updateContextsList();
- self._updateSourceArea();
- self._updateInspector();
- self._updateVariablesList();
- self._updateStatus();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"selectContext:",{aContext:aContext},$globals.Debugger)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["aContext"],
- source: "selectContext: aContext\x0a\x09selectedContext := aContext.\x0a\x09selectedVariable := nil.\x0a\x09selectedVariableName := nil.\x0a\x09self\x0a\x09\x09updateContextsList;\x0a\x09\x09updateSourceArea;\x0a\x09\x09updateInspector;\x0a\x09\x09updateVariablesList;\x0a\x09\x09updateStatus",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["updateContextsList", "updateSourceArea", "updateInspector", "updateVariablesList", "updateStatus"]
- }),
- $globals.Debugger);
- $core.addMethod(
- $core.method({
- selector: "selectVariable:named:",
- protocol: 'actions',
- fn: function (anObject,aString){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- self["@selectedVariable"]=anObject;
- self["@selectedVariableName"]=aString;
- $recv(self["@inspector"])._contents_((function(html){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return $recv(html)._with_($recv(anObject)._printString());
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({html:html},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- self._updateVariablesList();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"selectVariable:named:",{anObject:anObject,aString:aString},$globals.Debugger)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["anObject", "aString"],
- source: "selectVariable: anObject named: aString\x0a\x09\x0a\x09selectedVariable := anObject.\x0a\x09selectedVariableName := aString.\x0a\x09inspector contents: [ :html | html with: anObject printString ].\x0a\x09self updateVariablesList",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["contents:", "with:", "printString", "updateVariablesList"]
- }),
- $globals.Debugger);
- $core.addMethod(
- $core.method({
- selector: "source",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$receiver;
- $1=self._method();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["method"]=1;
- //>>excludeEnd("ctx");
- if(($receiver = $1) == null || $receiver.isNil){
- return "Method doesn't exist!";
- } else {
- return $recv(self._method())._source();
- };
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"source",{},$globals.Debugger)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "source\x0a\x09^ self method\x0a\x09\x09ifNil: [ 'Method doesn''t exist!' ]\x0a\x09\x09ifNotNil: [ self method source ]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["ifNil:ifNotNil:", "method", "source"]
- }),
- $globals.Debugger);
- $core.addMethod(
- $core.method({
- selector: "updateContextsList",
- protocol: 'updating',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- $recv(self["@ul"])._contents_((function(html){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return self._renderContext_on_($recv(self._error())._context(),html);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({html:html},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"updateContextsList",{},$globals.Debugger)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "updateContextsList\x0a\x09ul contents: [ :html |\x0a\x09\x09self renderContext: self error context on: html ]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["contents:", "renderContext:on:", "context", "error"]
- }),
- $globals.Debugger);
- $core.addMethod(
- $core.method({
- selector: "updateInspector",
- protocol: 'updating',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- $recv(self["@inspector"])._contents_((function(html){
- }));
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"updateInspector",{},$globals.Debugger)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "updateInspector\x0a\x09inspector contents: [ :html | ]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["contents:"]
- }),
- $globals.Debugger);
- $core.addMethod(
- $core.method({
- selector: "updateSourceArea",
- protocol: 'updating',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- $recv(self["@sourceArea"])._val_(self._source());
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"updateSourceArea",{},$globals.Debugger)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "updateSourceArea\x0a\x09sourceArea val: self source",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["val:", "source"]
- }),
- $globals.Debugger);
- $core.addMethod(
- $core.method({
- selector: "updateStatus",
- protocol: 'updating',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$2,$3,$receiver;
- $1=$recv($recv(self["@sourceArea"])._val()).__eq(self._source());
- if($core.assert($1)){
- $2=self["@saveButton"];
- if(($receiver = $2) == null || $receiver.isNil){
- $2;
- } else {
- $recv(self["@saveButton"])._at_put_("disabled",true);
- };
- self["@unsavedChanges"]=false;
- self["@unsavedChanges"];
- } else {
- $3=self["@saveButton"];
- if(($receiver = $3) == null || $receiver.isNil){
- $3;
- } else {
- $recv(self["@saveButton"])._removeAt_("disabled");
- };
- self["@unsavedChanges"]=true;
- self["@unsavedChanges"];
- };
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"updateStatus",{},$globals.Debugger)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "updateStatus\x0a\x09sourceArea val = self source\x0a\x09\x09ifTrue: [\x0a\x09\x09\x09saveButton ifNotNil: [\x0a\x09\x09\x09\x09saveButton at: 'disabled' put: true ].\x0a\x09\x09\x09unsavedChanges := false ]\x0a\x09\x09ifFalse: [\x0a\x09\x09\x09saveButton ifNotNil: [\x0a\x09\x09\x09\x09saveButton removeAt: 'disabled' ].\x0a\x09\x09\x09unsavedChanges := true ]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["ifTrue:ifFalse:", "=", "val", "source", "ifNotNil:", "at:put:", "removeAt:"]
- }),
- $globals.Debugger);
- $core.addMethod(
- $core.method({
- selector: "updateVariablesList",
- protocol: 'updating',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$2,$3,$4,$5,$6,$receiver;
- $recv(self["@ul2"])._contents_((function(html){
- var li;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- $1=$recv(html)._li();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["li"]=1;
- //>>excludeEnd("ctx");
- $recv($1)._with_("self");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["with:"]=1;
- //>>excludeEnd("ctx");
- $2=$recv($1)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- return self._selectVariable_named_(self._receiver(),"self");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["selectVariable:named:"]=1;
- //>>excludeEnd("ctx");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({},$ctx2,2)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["onClick:"]=1;
- //>>excludeEnd("ctx");
- li=$2;
- li;
- $3=$recv(self["@selectedVariableName"]).__eq("self");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["="]=1;
- //>>excludeEnd("ctx");
- if($core.assert($3)){
- $recv(li)._class_("selected");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["class:"]=1;
- //>>excludeEnd("ctx");
- };
- return $recv(self._allVariables())._keysAndValuesDo_((function(key,value){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- $4=$recv(html)._li();
- $recv($4)._with_(key);
- li=$recv($4)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx4) {
- //>>excludeEnd("ctx");
- return self._selectVariable_named_(value,key);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx4) {$ctx4.fillBlock({},$ctx3,5)});
- //>>excludeEnd("ctx");
- }));
- li;
- $5=$recv(self["@selectedVariableName"]).__eq(key);
- if($core.assert($5)){
- return $recv(li)._class_("selected");
- };
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({key:key,value:value},$ctx2,4)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({html:html,li:li},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- $6=self["@selectedVariable"];
- if(($receiver = $6) == null || $receiver.isNil){
- $recv(self["@inspectButton"])._at_put_("disabled",true);
- } else {
- $recv(self["@inspectButton"])._removeAt_("disabled");
- };
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"updateVariablesList",{},$globals.Debugger)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "updateVariablesList\x0a\x09ul2 contents: [ :html | | li |\x0a\x09\x09li := html li\x0a\x09\x09\x09with: 'self';\x0a\x09\x09\x09onClick: [ self selectVariable: self receiver named: 'self' ].\x0a\x09\x09\x09\x09selectedVariableName = 'self' ifTrue: [ li class: 'selected' ].\x0a\x09\x09\x0a\x09\x09self allVariables keysAndValuesDo: [ :key :value |\x0a\x09\x09\x09\x09\x09\x09li := html li\x0a\x09\x09\x09\x09\x09\x09\x09with: key;\x0a\x09\x09\x09\x09\x09\x09\x09onClick: [ self selectVariable: value named: key ].\x0a\x09\x09\x09\x09\x09\x09selectedVariableName = key ifTrue: [\x0a\x09\x09\x09\x09\x09\x09\x09li class: 'selected' ] ] ].\x0a\x09\x09\x09\x09\x09\x09\x09\x0a\x09selectedVariable\x0a\x09\x09ifNil: [ inspectButton at: 'disabled' put: true ]\x0a\x09\x09ifNotNil: [ inspectButton removeAt: 'disabled' ]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["contents:", "with:", "li", "onClick:", "selectVariable:named:", "receiver", "ifTrue:", "=", "class:", "keysAndValuesDo:", "allVariables", "ifNil:ifNotNil:", "at:put:", "removeAt:"]
- }),
- $globals.Debugger);
- $core.addClass('IDEInspector', $globals.TabWidget, ['label', 'variables', 'object', 'selectedVariable', 'variablesList', 'valueTextarea', 'diveButton', 'sourceArea'], 'IDE');
- $core.addMethod(
- $core.method({
- selector: "canBeClosed",
- protocol: 'testing',
- fn: function (){
- var self=this;
- return true;
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "canBeClosed\x0a\x09^ true",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: []
- }),
- $globals.IDEInspector);
- $core.addMethod(
- $core.method({
- selector: "dive",
- protocol: 'actions',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- $recv($recv(self._variables())._at_(self._selectedVariable()))._inspect();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"dive",{},$globals.IDEInspector)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "dive\x0a\x09(self variables at: self selectedVariable) inspect",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["inspect", "at:", "variables", "selectedVariable"]
- }),
- $globals.IDEInspector);
- $core.addMethod(
- $core.method({
- selector: "inspect:",
- protocol: 'actions',
- fn: function (anObject){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- self["@object"]=anObject;
- self["@variables"]=[];
- $recv(self["@object"])._inspectOn_(self);
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"inspect:",{anObject:anObject},$globals.IDEInspector)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["anObject"],
- source: "inspect: anObject\x0a\x09object := anObject.\x0a\x09variables := #().\x0a\x09object inspectOn: self",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["inspectOn:"]
- }),
- $globals.IDEInspector);
- $core.addMethod(
- $core.method({
- selector: "label",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$receiver;
- $1=self["@label"];
- if(($receiver = $1) == null || $receiver.isNil){
- return "Inspector (nil)";
- } else {
- return $1;
- };
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"label",{},$globals.IDEInspector)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "label\x0a\x09^ label ifNil: [ 'Inspector (nil)' ]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["ifNil:"]
- }),
- $globals.IDEInspector);
- $core.addMethod(
- $core.method({
- selector: "refresh",
- protocol: 'actions',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- self._inspect_(self["@object"]);
- self._updateVariablesList();
- self._updateValueTextarea();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"refresh",{},$globals.IDEInspector)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "refresh\x0a\x09self\x0a\x09\x09inspect: object;\x0a\x09\x09updateVariablesList;\x0a\x09\x09updateValueTextarea",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["inspect:", "updateVariablesList", "updateValueTextarea"]
- }),
- $globals.IDEInspector);
- $core.addMethod(
- $core.method({
- selector: "renderBottomPanelOn:",
- protocol: 'rendering',
- fn: function (html){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$2;
- $1=$recv(html)._div();
- $recv($1)._class_("amber_sourceCode");
- $recv($1)._with_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- $2=$recv($globals.SourceArea)._new();
- $recv($2)._receiver_(self["@object"]);
- $recv($2)._onDoIt_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- return self._refresh();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({},$ctx2,2)});
- //>>excludeEnd("ctx");
- }));
- self["@sourceArea"]=$recv($2)._yourself();
- self["@sourceArea"];
- return $recv(self["@sourceArea"])._renderOn_(html);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"renderBottomPanelOn:",{html:html},$globals.IDEInspector)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["html"],
- source: "renderBottomPanelOn: html\x0a\x09html div\x0a\x09class: 'amber_sourceCode';\x0a\x09with: [\x0a\x09\x09sourceArea := SourceArea new\x0a\x09\x09receiver: object;\x0a\x09\x09onDoIt: [ self refresh ];\x0a\x09\x09yourself.\x0a\x09\x09\x09sourceArea renderOn: html ]",
- referencedClasses: ["SourceArea"],
- //>>excludeEnd("ide");
- messageSends: ["class:", "div", "with:", "receiver:", "new", "onDoIt:", "refresh", "yourself", "renderOn:"]
- }),
- $globals.IDEInspector);
- $core.addMethod(
- $core.method({
- selector: "renderBoxOn:",
- protocol: 'rendering',
- fn: function (html){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- self._renderTopPanelOn_(html);
- self._renderBottomPanelOn_(html);
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"renderBoxOn:",{html:html},$globals.IDEInspector)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["html"],
- source: "renderBoxOn: html\x0a\x09self\x0a\x09\x09renderTopPanelOn: html;\x0a\x09\x09renderBottomPanelOn: html",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["renderTopPanelOn:", "renderBottomPanelOn:"]
- }),
- $globals.IDEInspector);
- $core.addMethod(
- $core.method({
- selector: "renderButtonsOn:",
- protocol: 'rendering',
- fn: function (html){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$3,$2,$4,$6,$5,$7;
- $1=$recv(html)._button();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["button"]=1;
- //>>excludeEnd("ctx");
- $recv($1)._with_("DoIt");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["with:"]=1;
- //>>excludeEnd("ctx");
- $2=$recv($1)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- $3=self._sourceArea();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["sourceArea"]=1;
- //>>excludeEnd("ctx");
- return $recv($3)._doIt();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["onClick:"]=1;
- //>>excludeEnd("ctx");
- $4=$recv(html)._button();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["button"]=2;
- //>>excludeEnd("ctx");
- $recv($4)._with_("PrintIt");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["with:"]=2;
- //>>excludeEnd("ctx");
- $5=$recv($4)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- $6=self._sourceArea();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["sourceArea"]=2;
- //>>excludeEnd("ctx");
- return $recv($6)._printIt();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["onClick:"]=2;
- //>>excludeEnd("ctx");
- $7=$recv(html)._button();
- $recv($7)._with_("InspectIt");
- $recv($7)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return $recv(self._sourceArea())._inspectIt();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,3)});
- //>>excludeEnd("ctx");
- }));
- self._updateButtons();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"renderButtonsOn:",{html:html},$globals.IDEInspector)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["html"],
- source: "renderButtonsOn: html\x0a\x09html button\x0a\x09\x09with: 'DoIt';\x0a\x09\x09onClick: [ self sourceArea doIt ].\x0a\x09html button\x0a\x09\x09with: 'PrintIt';\x0a\x09\x09onClick: [ self sourceArea printIt ].\x0a\x09html button\x0a\x09\x09with: 'InspectIt';\x0a\x09\x09onClick: [ self sourceArea inspectIt ].\x0a\x09self updateButtons",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["with:", "button", "onClick:", "doIt", "sourceArea", "printIt", "inspectIt", "updateButtons"]
- }),
- $globals.IDEInspector);
- $core.addMethod(
- $core.method({
- selector: "renderTopPanelOn:",
- protocol: 'rendering',
- fn: function (html){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$3,$4,$6,$7,$8,$5,$2;
- $1=$recv(html)._div();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["div"]=1;
- //>>excludeEnd("ctx");
- $recv($1)._class_("top");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["class:"]=1;
- //>>excludeEnd("ctx");
- $2=$recv($1)._with_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- self["@variablesList"]=$recv($recv(html)._ul())._class_("amber_column variables");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["class:"]=2;
- //>>excludeEnd("ctx");
- self["@variablesList"];
- $3=$recv(html)._textarea();
- $recv($3)._class_("amber_column value");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["class:"]=3;
- //>>excludeEnd("ctx");
- $recv($3)._at_put_("readonly","readonly");
- self["@valueTextarea"]=$recv($3)._yourself();
- self["@valueTextarea"];
- $4=$recv(html)._div();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["div"]=2;
- //>>excludeEnd("ctx");
- $recv($4)._class_("amber_tabs inspector");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["class:"]=4;
- //>>excludeEnd("ctx");
- $5=$recv($4)._with_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- $6=$recv(html)._button();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["button"]=1;
- //>>excludeEnd("ctx");
- $recv($6)._class_("amber_button inspector refresh");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["class:"]=5;
- //>>excludeEnd("ctx");
- $recv($6)._with_("Refresh");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["with:"]=3;
- //>>excludeEnd("ctx");
- $7=$recv($6)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx4) {
- //>>excludeEnd("ctx");
- return self._refresh();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx4) {$ctx4.fillBlock({},$ctx3,3)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["onClick:"]=1;
- //>>excludeEnd("ctx");
- $7;
- $8=$recv(html)._button();
- $recv($8)._class_("amber_button inspector dive");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["class:"]=6;
- //>>excludeEnd("ctx");
- $recv($8)._with_("Dive");
- self["@diveButton"]=$recv($8)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx4) {
- //>>excludeEnd("ctx");
- return self._dive();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx4) {$ctx4.fillBlock({},$ctx3,4)});
- //>>excludeEnd("ctx");
- }));
- return self["@diveButton"];
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({},$ctx2,2)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["with:"]=2;
- //>>excludeEnd("ctx");
- $5;
- return $recv($recv(html)._div())._class_("amber_clear");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["with:"]=1;
- //>>excludeEnd("ctx");
- self._updateVariablesList();
- self._updateValueTextarea();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"renderTopPanelOn:",{html:html},$globals.IDEInspector)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["html"],
- source: "renderTopPanelOn: html\x0a\x09html div\x0a\x09\x09class: 'top';\x0a\x09\x09with: [\x0a\x09\x09\x09variablesList := html ul class: 'amber_column variables'.\x0a\x09\x09\x09valueTextarea := html textarea class: 'amber_column value'; at: 'readonly' put: 'readonly'; yourself.\x0a\x09\x09\x09html div class: 'amber_tabs inspector'; with: [\x0a\x09\x09\x09\x09html button\x0a\x09\x09\x09\x09\x09class: 'amber_button inspector refresh';\x0a\x09\x09\x09\x09\x09with: 'Refresh';\x0a\x09\x09\x09\x09\x09onClick: [ self refresh ].\x0a\x09\x09\x09\x09diveButton := html button\x0a\x09\x09\x09\x09\x09class: 'amber_button inspector dive';\x0a\x09\x09\x09\x09\x09with: 'Dive';\x0a\x09\x09\x09\x09\x09onClick: [ self dive ]].\x0a\x09\x09\x09html div class: 'amber_clear' ].\x0a\x09self\x0a\x09\x09updateVariablesList;\x0a\x09\x09updateValueTextarea.",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["class:", "div", "with:", "ul", "textarea", "at:put:", "yourself", "button", "onClick:", "refresh", "dive", "updateVariablesList", "updateValueTextarea"]
- }),
- $globals.IDEInspector);
- $core.addMethod(
- $core.method({
- selector: "selectVariable:",
- protocol: 'updating',
- fn: function (aString){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- self._selectedVariable_(aString);
- self._updateVariablesList();
- self._updateValueTextarea();
- self._updateButtons();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"selectVariable:",{aString:aString},$globals.IDEInspector)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["aString"],
- source: "selectVariable: aString\x0a\x09self selectedVariable: aString.\x0a\x09self\x0a\x09\x09updateVariablesList;\x0a\x09\x09updateValueTextarea;\x0a\x09\x09updateButtons",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["selectedVariable:", "updateVariablesList", "updateValueTextarea", "updateButtons"]
- }),
- $globals.IDEInspector);
- $core.addMethod(
- $core.method({
- selector: "selectedVariable",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- return self["@selectedVariable"];
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "selectedVariable\x0a\x09^ selectedVariable",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: []
- }),
- $globals.IDEInspector);
- $core.addMethod(
- $core.method({
- selector: "selectedVariable:",
- protocol: 'accessing',
- fn: function (aString){
- var self=this;
- self["@selectedVariable"]=aString;
- return self;
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["aString"],
- source: "selectedVariable: aString\x0a\x09selectedVariable := aString",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: []
- }),
- $globals.IDEInspector);
- $core.addMethod(
- $core.method({
- selector: "setLabel:",
- protocol: 'accessing',
- fn: function (aString){
- var self=this;
- self["@label"]=aString;
- return self;
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["aString"],
- source: "setLabel: aString\x0a\x09label := aString",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: []
- }),
- $globals.IDEInspector);
- $core.addMethod(
- $core.method({
- selector: "setVariables:",
- protocol: 'accessing',
- fn: function (aCollection){
- var self=this;
- self["@variables"]=aCollection;
- return self;
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["aCollection"],
- source: "setVariables: aCollection\x0a\x09variables := aCollection",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: []
- }),
- $globals.IDEInspector);
- $core.addMethod(
- $core.method({
- selector: "sourceArea",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- return self["@sourceArea"];
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "sourceArea\x0a\x09^ sourceArea",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: []
- }),
- $globals.IDEInspector);
- $core.addMethod(
- $core.method({
- selector: "updateButtons",
- protocol: 'updating',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $3,$2,$1;
- $3=self._selectedVariable();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["selectedVariable"]=1;
- //>>excludeEnd("ctx");
- $2=$recv($3)._notNil();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["notNil"]=1;
- //>>excludeEnd("ctx");
- $1=$recv($2)._and_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return $recv($recv(self._variables())._at_(self._selectedVariable()))._notNil();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- if($core.assert($1)){
- $recv(self["@diveButton"])._removeAt_("disabled");
- } else {
- $recv(self["@diveButton"])._at_put_("disabled",true);
- };
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"updateButtons",{},$globals.IDEInspector)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "updateButtons\x0a\x09(self selectedVariable notNil and: [ (self variables at: self selectedVariable) notNil ])\x0a\x09\x09ifFalse: [ diveButton at: 'disabled' put: true ]\x0a\x09\x09ifTrue: [ diveButton removeAt: 'disabled' ]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["ifFalse:ifTrue:", "and:", "notNil", "selectedVariable", "at:", "variables", "at:put:", "removeAt:"]
- }),
- $globals.IDEInspector);
- $core.addMethod(
- $core.method({
- selector: "updateValueTextarea",
- protocol: 'updating',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$4,$3,$2;
- $1=$recv(self["@valueTextarea"])._asJQuery();
- $4=self._selectedVariable();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["selectedVariable"]=1;
- //>>excludeEnd("ctx");
- $3=$recv($4)._isNil();
- if($core.assert($3)){
- $2="";
- } else {
- $2=$recv($recv(self._variables())._at_(self._selectedVariable()))._printString();
- };
- $recv($1)._val_($2);
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"updateValueTextarea",{},$globals.IDEInspector)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "updateValueTextarea\x0a\x09valueTextarea asJQuery val: (self selectedVariable isNil\x0a\x09\x09ifTrue: [ '' ]\x0a\x09\x09ifFalse: [ (self variables at: self selectedVariable) printString ])",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["val:", "asJQuery", "ifTrue:ifFalse:", "isNil", "selectedVariable", "printString", "at:", "variables"]
- }),
- $globals.IDEInspector);
- $core.addMethod(
- $core.method({
- selector: "updateVariablesList",
- protocol: 'updating',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$2;
- $recv(self["@variablesList"])._contents_((function(html){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return $recv(self._variables())._keysDo_((function(each){
- var li;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- li=$recv(html)._li();
- li;
- $1=li;
- $recv($1)._with_(each);
- $recv($1)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx4) {
- //>>excludeEnd("ctx");
- return self._selectVariable_(each);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx4) {$ctx4.fillBlock({},$ctx3,3)});
- //>>excludeEnd("ctx");
- }));
- $2=$recv(self._selectedVariable()).__eq(each);
- if($core.assert($2)){
- return $recv(li)._class_("selected");
- };
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({each:each,li:li},$ctx2,2)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({html:html},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"updateVariablesList",{},$globals.IDEInspector)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "updateVariablesList\x0a\x09variablesList contents: [ :html |\x0a\x09\x09self variables keysDo: [ :each || li |\x0a\x09\x09\x09li := html li.\x0a\x09\x09\x09li\x0a\x09\x09\x09\x09with: each;\x0a\x09\x09\x09\x09onClick: [ self selectVariable: each ].\x0a\x09\x09\x09self selectedVariable = each ifTrue: [\x0a\x09\x09\x09\x09li class: 'selected' ]] ]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["contents:", "keysDo:", "variables", "li", "with:", "onClick:", "selectVariable:", "ifTrue:", "=", "selectedVariable", "class:"]
- }),
- $globals.IDEInspector);
- $core.addMethod(
- $core.method({
- selector: "variables",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- return self["@variables"];
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "variables\x0a\x09^ variables",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: []
- }),
- $globals.IDEInspector);
- $core.addMethod(
- $core.method({
- selector: "inspect:",
- protocol: 'instance creation',
- fn: function (anObject){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1;
- $1=self._new();
- $recv($1)._inspect_(anObject);
- $recv($1)._open();
- return $recv($1)._yourself();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"inspect:",{anObject:anObject},$globals.IDEInspector.klass)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["anObject"],
- source: "inspect: anObject\x0a\x09^ self new\x0a\x09\x09inspect: anObject;\x0a\x09\x09open;\x0a\x09\x09yourself",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["inspect:", "new", "open", "yourself"]
- }),
- $globals.IDEInspector.klass);
- $core.addMethod(
- $core.method({
- selector: "on:",
- protocol: 'instance creation',
- fn: function (anObject){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1;
- $1=self._new();
- $recv($1)._inspect_(anObject);
- return $recv($1)._yourself();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"on:",{anObject:anObject},$globals.IDEInspector.klass)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["anObject"],
- source: "on: anObject\x0a\x09^ self new\x0a\x09\x09inspect: anObject;\x0a\x09\x09yourself",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["inspect:", "new", "yourself"]
- }),
- $globals.IDEInspector.klass);
- $core.addClass('IDETranscript', $globals.TabWidget, ['textarea'], 'IDE');
- $core.addMethod(
- $core.method({
- selector: "clear",
- protocol: 'actions',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- $recv($recv(self["@textarea"])._asJQuery())._val_("");
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"clear",{},$globals.IDETranscript)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "clear\x0a\x09textarea asJQuery val: ''",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["val:", "asJQuery"]
- }),
- $globals.IDETranscript);
- $core.addMethod(
- $core.method({
- selector: "cr",
- protocol: 'actions',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1;
- $1=$recv(self["@textarea"])._asJQuery();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["asJQuery"]=1;
- //>>excludeEnd("ctx");
- $recv($1)._val_($recv($recv($recv(self["@textarea"])._asJQuery())._val()).__comma($recv($globals.String)._cr()));
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"cr",{},$globals.IDETranscript)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "cr\x0a\x09textarea asJQuery val: textarea asJQuery val, String cr.",
- referencedClasses: ["String"],
- //>>excludeEnd("ide");
- messageSends: ["val:", "asJQuery", ",", "val", "cr"]
- }),
- $globals.IDETranscript);
- $core.addMethod(
- $core.method({
- selector: "label",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- return "Transcript";
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "label\x0a\x09^ 'Transcript'",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: []
- }),
- $globals.IDETranscript);
- $core.addMethod(
- $core.method({
- selector: "open",
- protocol: 'actions',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1;
- $1=$recv($globals.TabManager)._current();
- $recv($1)._open();
- $recv($1)._selectTab_(self);
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"open",{},$globals.IDETranscript)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "open\x0a\x09TabManager current\x0a\x09open;\x0a\x09selectTab: self",
- referencedClasses: ["TabManager"],
- //>>excludeEnd("ide");
- messageSends: ["open", "current", "selectTab:"]
- }),
- $globals.IDETranscript);
- $core.addMethod(
- $core.method({
- selector: "renderBoxOn:",
- protocol: 'rendering',
- fn: function (html){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1;
- self["@textarea"]=$recv(html)._textarea();
- $1=self["@textarea"];
- $recv($1)._class_("amber_transcript");
- $recv($1)._at_put_("spellcheck","false");
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"renderBoxOn:",{html:html},$globals.IDETranscript)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["html"],
- source: "renderBoxOn: html\x0a\x09textarea := html textarea.\x0a\x09textarea\x0a\x09class: 'amber_transcript';\x0a\x09at: 'spellcheck' put: 'false'",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["textarea", "class:", "at:put:"]
- }),
- $globals.IDETranscript);
- $core.addMethod(
- $core.method({
- selector: "renderButtonsOn:",
- protocol: 'rendering',
- fn: function (html){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1;
- $1=$recv(html)._button();
- $recv($1)._with_("Clear transcript");
- $recv($1)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return self._clear();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"renderButtonsOn:",{html:html},$globals.IDETranscript)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["html"],
- source: "renderButtonsOn: html\x0a\x09html button\x0a\x09with: 'Clear transcript';\x0a\x09onClick: [ self clear ]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["with:", "button", "onClick:", "clear"]
- }),
- $globals.IDETranscript);
- $core.addMethod(
- $core.method({
- selector: "show:",
- protocol: 'actions',
- fn: function (anObject){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$2,$receiver;
- $1=self["@textarea"];
- if(($receiver = $1) == null || $receiver.isNil){
- self._open();
- } else {
- $1;
- };
- $2=$recv(self["@textarea"])._asJQuery();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["asJQuery"]=1;
- //>>excludeEnd("ctx");
- $recv($2)._val_($recv($recv($recv(self["@textarea"])._asJQuery())._val()).__comma($recv(anObject)._asString()));
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"show:",{anObject:anObject},$globals.IDETranscript)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["anObject"],
- source: "show: anObject\x0a\x09textarea ifNil: [ self open ].\x0a\x09textarea asJQuery val: textarea asJQuery val, anObject asString.",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["ifNil:", "open", "val:", "asJQuery", ",", "val", "asString"]
- }),
- $globals.IDETranscript);
- $globals.IDETranscript.klass.iVarNames = ['current'];
- $core.addMethod(
- $core.method({
- selector: "current",
- protocol: 'instance creation',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$receiver;
- $1=self["@current"];
- if(($receiver = $1) == null || $receiver.isNil){
- self["@current"]=(
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.supercall = true,
- //>>excludeEnd("ctx");
- ($globals.IDETranscript.klass.superclass||$boot.nilAsClass).fn.prototype._new.apply($recv(self), []));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.supercall = false;
- //>>excludeEnd("ctx");;
- return self["@current"];
- } else {
- return $1;
- };
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"current",{},$globals.IDETranscript.klass)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "current\x0a\x09^ current ifNil: [ current := super new ]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["ifNil:", "new"]
- }),
- $globals.IDETranscript.klass);
- $core.addMethod(
- $core.method({
- selector: "initialize",
- protocol: 'initialization',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- $recv($globals.Transcript)._register_(self._current());
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"initialize",{},$globals.IDETranscript.klass)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "initialize\x0a\x09Transcript register: self current",
- referencedClasses: ["Transcript"],
- //>>excludeEnd("ide");
- messageSends: ["register:", "current"]
- }),
- $globals.IDETranscript.klass);
- $core.addMethod(
- $core.method({
- selector: "new",
- protocol: 'instance creation',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- self._shouldNotImplement();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"new",{},$globals.IDETranscript.klass)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "new\x0a\x09self shouldNotImplement",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["shouldNotImplement"]
- }),
- $globals.IDETranscript.klass);
- $core.addMethod(
- $core.method({
- selector: "open",
- protocol: 'instance creation',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1;
- $1=$recv($globals.TabManager)._current();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["current"]=1;
- //>>excludeEnd("ctx");
- $recv($1)._open();
- $recv($1)._selectTab_(self._current());
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"open",{},$globals.IDETranscript.klass)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "open\x0a\x09TabManager current\x0a\x09\x09open;\x0a\x09\x09selectTab: self current",
- referencedClasses: ["TabManager"],
- //>>excludeEnd("ide");
- messageSends: ["open", "current", "selectTab:"]
- }),
- $globals.IDETranscript.klass);
- $core.addClass('ProgressBar', $globals.TabWidget, ['percent', 'progressDiv', 'div'], 'IDE');
- $core.addMethod(
- $core.method({
- selector: "percent",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$receiver;
- $1=self["@percent"];
- if(($receiver = $1) == null || $receiver.isNil){
- return (0);
- } else {
- return $1;
- };
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"percent",{},$globals.ProgressBar)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "percent\x0a\x09^ percent ifNil: [ 0 ]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["ifNil:"]
- }),
- $globals.ProgressBar);
- $core.addMethod(
- $core.method({
- selector: "percent:",
- protocol: 'accessing',
- fn: function (aNumber){
- var self=this;
- self["@percent"]=aNumber;
- return self;
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["aNumber"],
- source: "percent: aNumber\x0a\x09percent := aNumber",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: []
- }),
- $globals.ProgressBar);
- $core.addMethod(
- $core.method({
- selector: "renderOn:",
- protocol: 'rendering',
- fn: function (html){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1;
- $1=$recv(html)._div();
- $recv($1)._class_("progress_bar");
- self["@div"]=$recv($1)._yourself();
- self._renderProgressBar();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"renderOn:",{html:html},$globals.ProgressBar)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["html"],
- source: "renderOn: html\x0a\x09div := html div\x0a\x09\x09class: 'progress_bar';\x0a\x09\x09yourself.\x0a\x09self renderProgressBar",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["class:", "div", "yourself", "renderProgressBar"]
- }),
- $globals.ProgressBar);
- $core.addMethod(
- $core.method({
- selector: "renderProgressBar",
- protocol: 'rendering',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$2;
- $recv(self["@div"])._contents_((function(html){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- $1=$recv(html)._div();
- $recv($1)._class_("progress");
- $2=$recv("width:".__comma($recv(self._percent())._asString())).__comma("%");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx[","]=1;
- //>>excludeEnd("ctx");
- return $recv($1)._style_($2);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({html:html},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"renderProgressBar",{},$globals.ProgressBar)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "renderProgressBar\x0a\x09div contents: [ :html |\x0a\x09\x09html div\x0a\x09\x09\x09class: 'progress';\x0a\x09\x09\x09style: 'width:', self percent asString, '%' ]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["contents:", "class:", "div", "style:", ",", "asString", "percent"]
- }),
- $globals.ProgressBar);
- $core.addMethod(
- $core.method({
- selector: "updatePercent:",
- protocol: 'updating',
- fn: function (aNumber){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- self._percent_(aNumber);
- self._renderProgressBar();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"updatePercent:",{aNumber:aNumber},$globals.ProgressBar)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["aNumber"],
- source: "updatePercent: aNumber\x0a\x09self percent: aNumber.\x0a\x09self renderProgressBar",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["percent:", "renderProgressBar"]
- }),
- $globals.ProgressBar);
- $core.addClass('ReferencesBrowser', $globals.TabWidget, ['implementors', 'senders', 'implementorsList', 'input', 'timer', 'selector', 'sendersList', 'referencedClasses', 'referencedClassesList', 'matches', 'matchesList'], 'IDE');
- $core.addMethod(
- $core.method({
- selector: "canBeClosed",
- protocol: 'testing',
- fn: function (){
- var self=this;
- return true;
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "canBeClosed\x0a\x09^ true",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: []
- }),
- $globals.ReferencesBrowser);
- $core.addMethod(
- $core.method({
- selector: "classesAndMetaclasses",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1;
- $1=$recv($globals.Smalltalk)._classes();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["classes"]=1;
- //>>excludeEnd("ctx");
- return $recv($1).__comma($recv($recv($globals.Smalltalk)._classes())._collect_((function(each){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return $recv(each)._class();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
- //>>excludeEnd("ctx");
- })));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"classesAndMetaclasses",{},$globals.ReferencesBrowser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "classesAndMetaclasses\x0a\x09^ Smalltalk classes, (Smalltalk classes collect: [ :each | each class ])",
- referencedClasses: ["Smalltalk"],
- //>>excludeEnd("ide");
- messageSends: [",", "classes", "collect:", "class"]
- }),
- $globals.ReferencesBrowser);
- $core.addMethod(
- $core.method({
- selector: "implementors",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$receiver;
- $1=self["@implementors"];
- if(($receiver = $1) == null || $receiver.isNil){
- self["@implementors"]=$recv($globals.Array)._new();
- return self["@implementors"];
- } else {
- return $1;
- };
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"implementors",{},$globals.ReferencesBrowser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "implementors\x0a\x09^ implementors ifNil: [ implementors := Array new ]",
- referencedClasses: ["Array"],
- //>>excludeEnd("ide");
- messageSends: ["ifNil:", "new"]
- }),
- $globals.ReferencesBrowser);
- $core.addMethod(
- $core.method({
- selector: "initialize",
- protocol: 'initialization',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- (
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.supercall = true,
- //>>excludeEnd("ctx");
- ($globals.ReferencesBrowser.superclass||$boot.nilAsClass).fn.prototype._initialize.apply($recv(self), []));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.supercall = false;
- //>>excludeEnd("ctx");;
- self["@selector"]="";
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"initialize",{},$globals.ReferencesBrowser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "initialize\x0a\x09super initialize.\x0a\x09selector := ''",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["initialize"]
- }),
- $globals.ReferencesBrowser);
- $core.addMethod(
- $core.method({
- selector: "label",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- return "[ References ]";
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "label\x0a\x09^ '[ References ]'",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: []
- }),
- $globals.ReferencesBrowser);
- $core.addMethod(
- $core.method({
- selector: "matches",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$receiver;
- $1=self["@matches"];
- if(($receiver = $1) == null || $receiver.isNil){
- self["@matches"]=$recv($globals.Array)._new();
- return self["@matches"];
- } else {
- return $1;
- };
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"matches",{},$globals.ReferencesBrowser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "matches\x0a\x09^ matches ifNil: [ matches := Array new ]",
- referencedClasses: ["Array"],
- //>>excludeEnd("ide");
- messageSends: ["ifNil:", "new"]
- }),
- $globals.ReferencesBrowser);
- $core.addMethod(
- $core.method({
- selector: "openBrowserOn:",
- protocol: 'actions',
- fn: function (aMethod){
- var self=this;
- var browser;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $3,$2,$4,$1,$5,$6;
- $3=$recv(aMethod)._methodClass();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["methodClass"]=1;
- //>>excludeEnd("ctx");
- $2=$recv($3)._isMetaclass();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["isMetaclass"]=1;
- //>>excludeEnd("ctx");
- if($core.assert($2)){
- $4=$recv(aMethod)._methodClass();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["methodClass"]=2;
- //>>excludeEnd("ctx");
- $1=$recv($4)._instanceClass();
- } else {
- $1=$recv(aMethod)._methodClass();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["methodClass"]=3;
- //>>excludeEnd("ctx");
- };
- browser=$recv($globals.Browser)._openOn_($1);
- $5=$recv($recv(aMethod)._methodClass())._isMetaclass();
- if($core.assert($5)){
- $recv(browser)._selectTab_("class");
- };
- $6=browser;
- $recv($6)._selectProtocol_($recv(aMethod)._category());
- $recv($6)._selectMethod_(aMethod);
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"openBrowserOn:",{aMethod:aMethod,browser:browser},$globals.ReferencesBrowser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["aMethod"],
- source: "openBrowserOn: aMethod\x0a\x09| browser |\x0a\x09browser := Browser openOn: (aMethod methodClass isMetaclass\x0a\x09\x09ifTrue: [ aMethod methodClass instanceClass ] ifFalse: [ aMethod methodClass ]).\x0a\x09aMethod methodClass isMetaclass ifTrue: [ browser selectTab: #class ].\x0a\x09browser\x0a\x09\x09selectProtocol: aMethod category;\x0a\x09\x09selectMethod: aMethod",
- referencedClasses: ["Browser"],
- //>>excludeEnd("ide");
- messageSends: ["openOn:", "ifTrue:ifFalse:", "isMetaclass", "methodClass", "instanceClass", "ifTrue:", "selectTab:", "selectProtocol:", "category", "selectMethod:"]
- }),
- $globals.ReferencesBrowser);
- $core.addMethod(
- $core.method({
- selector: "referencedClasses",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$receiver;
- $1=self["@referencedClasses"];
- if(($receiver = $1) == null || $receiver.isNil){
- self["@referencedClasses"]=$recv($globals.Array)._new();
- return self["@referencedClasses"];
- } else {
- return $1;
- };
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"referencedClasses",{},$globals.ReferencesBrowser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "referencedClasses\x0a\x09^ referencedClasses ifNil: [ referencedClasses := Array new ]",
- referencedClasses: ["Array"],
- //>>excludeEnd("ide");
- messageSends: ["ifNil:", "new"]
- }),
- $globals.ReferencesBrowser);
- $core.addMethod(
- $core.method({
- selector: "renderBoxOn:",
- protocol: 'rendering',
- fn: function (html){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- self._renderInputOn_(html);
- self._renderImplementorsOn_(html);
- self._renderSendersOn_(html);
- self._renderReferencedClassesOn_(html);
- self._renderMatchesOn_(html);
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"renderBoxOn:",{html:html},$globals.ReferencesBrowser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["html"],
- source: "renderBoxOn: html\x0a\x09self\x0a\x09\x09renderInputOn: html;\x0a\x09\x09renderImplementorsOn: html;\x0a\x09\x09renderSendersOn: html;\x0a\x09\x09renderReferencedClassesOn: html;\x0a\x09\x09renderMatchesOn: html",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["renderInputOn:", "renderImplementorsOn:", "renderSendersOn:", "renderReferencedClassesOn:", "renderMatchesOn:"]
- }),
- $globals.ReferencesBrowser);
- $core.addMethod(
- $core.method({
- selector: "renderImplementorsOn:",
- protocol: 'rendering',
- fn: function (html){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- self["@implementorsList"]=$recv($recv(html)._ul())._class_("amber_column implementors");
- self._updateImplementorsList();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"renderImplementorsOn:",{html:html},$globals.ReferencesBrowser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["html"],
- source: "renderImplementorsOn: html\x0a\x09implementorsList := html ul class: 'amber_column implementors'.\x0a\x09self updateImplementorsList",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["class:", "ul", "updateImplementorsList"]
- }),
- $globals.ReferencesBrowser);
- $core.addMethod(
- $core.method({
- selector: "renderInputOn:",
- protocol: 'rendering',
- fn: function (html){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1;
- $1=$recv(html)._input();
- $recv($1)._class_("implementors");
- self["@input"]=$recv($1)._yourself();
- $recv($recv(self["@input"])._asJQuery())._val_(self["@selector"]);
- self._setInputEvents();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"renderInputOn:",{html:html},$globals.ReferencesBrowser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["html"],
- source: "renderInputOn: html\x0a\x09input := html input\x0a\x09\x09class: 'implementors';\x0a\x09\x09yourself.\x0a\x09input asJQuery val: selector.\x0a\x09self setInputEvents",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["class:", "input", "yourself", "val:", "asJQuery", "setInputEvents"]
- }),
- $globals.ReferencesBrowser);
- $core.addMethod(
- $core.method({
- selector: "renderMatchesOn:",
- protocol: 'rendering',
- fn: function (html){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- self["@matchesList"]=$recv($recv(html)._ul())._class_("amber_column matches");
- self._updateMatchesList();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"renderMatchesOn:",{html:html},$globals.ReferencesBrowser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["html"],
- source: "renderMatchesOn: html\x0a\x09matchesList := html ul class: 'amber_column matches'.\x0a\x09self updateMatchesList",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["class:", "ul", "updateMatchesList"]
- }),
- $globals.ReferencesBrowser);
- $core.addMethod(
- $core.method({
- selector: "renderReferencedClassesOn:",
- protocol: 'rendering',
- fn: function (html){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- self["@referencedClassesList"]=$recv($recv(html)._ul())._class_("amber_column referenced_classes");
- self._updateReferencedClassesList();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"renderReferencedClassesOn:",{html:html},$globals.ReferencesBrowser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["html"],
- source: "renderReferencedClassesOn: html\x0a\x09referencedClassesList := html ul class: 'amber_column referenced_classes'.\x0a\x09self updateReferencedClassesList",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["class:", "ul", "updateReferencedClassesList"]
- }),
- $globals.ReferencesBrowser);
- $core.addMethod(
- $core.method({
- selector: "renderSendersOn:",
- protocol: 'rendering',
- fn: function (html){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- self["@sendersList"]=$recv($recv(html)._ul())._class_("amber_column senders");
- self._updateSendersList();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"renderSendersOn:",{html:html},$globals.ReferencesBrowser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["html"],
- source: "renderSendersOn: html\x0a\x09sendersList := html ul class: 'amber_column senders'.\x0a\x09self updateSendersList",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["class:", "ul", "updateSendersList"]
- }),
- $globals.ReferencesBrowser);
- $core.addMethod(
- $core.method({
- selector: "search:",
- protocol: 'actions',
- fn: function (aString){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- self._searchReferencesFor_(aString);
- self._updateImplementorsList();
- self._updateSendersList();
- self._updateReferencedClassesList();
- self._updateMatchesList();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"search:",{aString:aString},$globals.ReferencesBrowser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["aString"],
- source: "search: aString\x0a\x09self\x0a\x09\x09searchReferencesFor: aString;\x0a\x09\x09updateImplementorsList;\x0a\x09\x09updateSendersList;\x0a\x09\x09updateReferencedClassesList;\x0a\x09\x09updateMatchesList",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["searchReferencesFor:", "updateImplementorsList", "updateSendersList", "updateReferencedClassesList", "updateMatchesList"]
- }),
- $globals.ReferencesBrowser);
- $core.addMethod(
- $core.method({
- selector: "searchMethodSource",
- protocol: 'actions',
- fn: function (){
- var self=this;
- var regex;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1;
- regex=$recv(self["@selector"])._allButFirst();
- $recv(self._classesAndMetaclasses())._do_((function(each){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return $recv($recv(each)._methodDictionary())._valuesDo_((function(value){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- $1=$recv($recv(value)._source())._match_(regex);
- if($core.assert($1)){
- return $recv(self._matches())._add_(value);
- };
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({value:value},$ctx2,2)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"searchMethodSource",{regex:regex},$globals.ReferencesBrowser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "searchMethodSource\x0a\x09| regex |\x0a\x09regex := selector allButFirst.\x0a\x09self classesAndMetaclasses do: [ :each |\x0a\x09\x09each methodDictionary valuesDo: [ :value |\x0a\x09\x09\x09(value source match: regex) ifTrue: [\x0a\x09\x09\x09\x09self matches add: value ]] ]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["allButFirst", "do:", "classesAndMetaclasses", "valuesDo:", "methodDictionary", "ifTrue:", "match:", "source", "add:", "matches"]
- }),
- $globals.ReferencesBrowser);
- $core.addMethod(
- $core.method({
- selector: "searchReferencedClasses",
- protocol: 'actions',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $2,$1;
- $recv(self._classesAndMetaclasses())._do_((function(each){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return $recv($recv(each)._methodDictionary())._valuesDo_((function(value){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- $2=$recv(value)._referencedClasses();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["referencedClasses"]=1;
- //>>excludeEnd("ctx");
- $1=$recv($2)._includes_(self["@selector"]);
- if($core.assert($1)){
- return $recv(self._referencedClasses())._add_(value);
- };
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({value:value},$ctx2,2)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"searchReferencedClasses",{},$globals.ReferencesBrowser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "searchReferencedClasses\x0a\x09self classesAndMetaclasses do: [ :each |\x0a\x09\x09each methodDictionary valuesDo: [ :value |\x0a\x09\x09\x09(value referencedClasses includes: selector) ifTrue: [\x0a\x09\x09\x09\x09self referencedClasses add: value ]] ]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["do:", "classesAndMetaclasses", "valuesDo:", "methodDictionary", "ifTrue:", "includes:", "referencedClasses", "add:"]
- }),
- $globals.ReferencesBrowser);
- $core.addMethod(
- $core.method({
- selector: "searchReferencesFor:",
- protocol: 'actions',
- fn: function (aString){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1;
- self["@selector"]=aString;
- self["@implementors"]=$recv($globals.Array)._new();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["new"]=1;
- //>>excludeEnd("ctx");
- self["@senders"]=$recv($globals.Array)._new();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["new"]=2;
- //>>excludeEnd("ctx");
- self["@referencedClasses"]=$recv($globals.Array)._new();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["new"]=3;
- //>>excludeEnd("ctx");
- self["@matches"]=$recv($globals.Array)._new();
- self._searchMethodSource();
- $1=$recv(self["@selector"])._match_("^[A-Z]");
- if($core.assert($1)){
- self._searchReferencedClasses();
- } else {
- self._searchSelectorReferences();
- };
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"searchReferencesFor:",{aString:aString},$globals.ReferencesBrowser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["aString"],
- source: "searchReferencesFor: aString\x0a\x09selector := aString.\x0a\x09implementors := Array new.\x0a\x09senders := Array new.\x0a\x09referencedClasses := Array new.\x0a\x09matches := Array new.\x0a\x09self searchMethodSource.\x0a\x09(selector match: '^[A-Z]')\x0a\x09\x09ifFalse: [ self searchSelectorReferences ]\x0a\x09\x09ifTrue: [ self searchReferencedClasses ]",
- referencedClasses: ["Array"],
- //>>excludeEnd("ide");
- messageSends: ["new", "searchMethodSource", "ifFalse:ifTrue:", "match:", "searchSelectorReferences", "searchReferencedClasses"]
- }),
- $globals.ReferencesBrowser);
- $core.addMethod(
- $core.method({
- selector: "searchSelectorReferences",
- protocol: 'actions',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$2;
- $recv(self._classesAndMetaclasses())._do_((function(each){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return $recv($recv(each)._methodDictionary())._keysAndValuesDo_((function(key,value){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- $1=$recv(key).__eq(self["@selector"]);
- if($core.assert($1)){
- $recv(self._implementors())._add_(value);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["add:"]=1;
- //>>excludeEnd("ctx");
- };
- $2=$recv($recv(value)._messageSends())._includes_(self["@selector"]);
- if($core.assert($2)){
- return $recv(self._senders())._add_(value);
- };
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({key:key,value:value},$ctx2,2)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"searchSelectorReferences",{},$globals.ReferencesBrowser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "searchSelectorReferences\x0a\x09self classesAndMetaclasses do: [ :each |\x0a\x09\x09each methodDictionary keysAndValuesDo: [ :key :value |\x0a\x09\x09\x09key = selector ifTrue: [ self implementors add: value ].\x0a\x09\x09\x09(value messageSends includes: selector) ifTrue: [\x0a\x09\x09\x09\x09self senders add: value ]] ]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["do:", "classesAndMetaclasses", "keysAndValuesDo:", "methodDictionary", "ifTrue:", "=", "add:", "implementors", "includes:", "messageSends", "senders"]
- }),
- $globals.ReferencesBrowser);
- $core.addMethod(
- $core.method({
- selector: "selector",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- return self["@selector"];
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "selector\x0a\x09^ selector",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: []
- }),
- $globals.ReferencesBrowser);
- $core.addMethod(
- $core.method({
- selector: "senders",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$receiver;
- $1=self["@senders"];
- if(($receiver = $1) == null || $receiver.isNil){
- self["@senders"]=$recv($globals.Array)._new();
- return self["@senders"];
- } else {
- return $1;
- };
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"senders",{},$globals.ReferencesBrowser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "senders\x0a\x09^ senders ifNil: [ senders := Array new ]",
- referencedClasses: ["Array"],
- //>>excludeEnd("ide");
- messageSends: ["ifNil:", "new"]
- }),
- $globals.ReferencesBrowser);
- $core.addMethod(
- $core.method({
- selector: "setInputEvents",
- protocol: 'private',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$2,$receiver;
- $1=self["@input"];
- $recv($1)._onKeyUp_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- self["@timer"]=$recv((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- return self._search_($recv($recv(self["@input"])._asJQuery())._val());
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({},$ctx2,2)});
- //>>excludeEnd("ctx");
- }))._valueWithTimeout_((100));
- return self["@timer"];
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- $recv($1)._onKeyDown_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- $2=self["@timer"];
- if(($receiver = $2) == null || $receiver.isNil){
- return $2;
- } else {
- return $recv(self["@timer"])._clearTimeout();
- };
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,3)});
- //>>excludeEnd("ctx");
- }));
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"setInputEvents",{},$globals.ReferencesBrowser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "setInputEvents\x0a\x09input\x0a\x09\x09onKeyUp: [ timer := [ self search: input asJQuery val ] valueWithTimeout: 100 ];\x0a\x09\x09onKeyDown: [ timer ifNotNil: [ timer clearTimeout ]]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["onKeyUp:", "valueWithTimeout:", "search:", "val", "asJQuery", "onKeyDown:", "ifNotNil:", "clearTimeout"]
- }),
- $globals.ReferencesBrowser);
- $core.addMethod(
- $core.method({
- selector: "updateImplementorsList",
- protocol: 'updating',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$6,$5,$4,$3,$2,$7,$8;
- $recv(self["@implementorsList"])._contents_((function(html){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- $1=$recv(html)._li();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["li"]=1;
- //>>excludeEnd("ctx");
- $recv($1)._class_("column_label");
- $6=self._implementors();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["implementors"]=1;
- //>>excludeEnd("ctx");
- $5=$recv($6)._size();
- $4=$recv($5)._asString();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["asString"]=1;
- //>>excludeEnd("ctx");
- $3="Implementors (".__comma($4);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx[","]=2;
- //>>excludeEnd("ctx");
- $2=$recv($3).__comma(")");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx[","]=1;
- //>>excludeEnd("ctx");
- $recv($1)._with_($2);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["with:"]=1;
- //>>excludeEnd("ctx");
- $recv($1)._style_("font-weight: bold");
- return $recv(self._implementors())._do_((function(each){
- var li;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- li=$recv(html)._li();
- li;
- $7=li;
- $8=$recv($recv($recv($recv(each)._methodClass())._asString()).__comma(" >> ")).__comma(self._selector());
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx[","]=3;
- //>>excludeEnd("ctx");
- $recv($7)._with_($8);
- return $recv($7)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx4) {
- //>>excludeEnd("ctx");
- return self._openBrowserOn_(each);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx4) {$ctx4.fillBlock({},$ctx3,3)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({each:each,li:li},$ctx2,2)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({html:html},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"updateImplementorsList",{},$globals.ReferencesBrowser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "updateImplementorsList\x0a\x09implementorsList contents: [ :html |\x0a\x09html li\x0a\x09\x09class: 'column_label';\x0a\x09\x09with: 'Implementors (', self implementors size asString, ')';\x0a\x09\x09style: 'font-weight: bold'.\x0a\x09self implementors do: [ :each || li |\x0a\x09\x09li := html li.\x0a\x09\x09li\x0a\x09\x09with: (each methodClass asString, ' >> ', self selector);\x0a\x09\x09onClick: [ self openBrowserOn: each ]] ]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["contents:", "class:", "li", "with:", ",", "asString", "size", "implementors", "style:", "do:", "methodClass", "selector", "onClick:", "openBrowserOn:"]
- }),
- $globals.ReferencesBrowser);
- $core.addMethod(
- $core.method({
- selector: "updateMatchesList",
- protocol: 'updating',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$6,$5,$4,$3,$2,$7,$8;
- $recv(self["@matchesList"])._contents_((function(html){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- $1=$recv(html)._li();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["li"]=1;
- //>>excludeEnd("ctx");
- $recv($1)._class_("column_label");
- $6=self._matches();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["matches"]=1;
- //>>excludeEnd("ctx");
- $5=$recv($6)._size();
- $4=$recv($5)._asString();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["asString"]=1;
- //>>excludeEnd("ctx");
- $3="Regex matches (".__comma($4);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx[","]=2;
- //>>excludeEnd("ctx");
- $2=$recv($3).__comma(")");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx[","]=1;
- //>>excludeEnd("ctx");
- $recv($1)._with_($2);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["with:"]=1;
- //>>excludeEnd("ctx");
- $recv($1)._style_("font-weight: bold");
- return $recv(self._matches())._do_((function(each){
- var li;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- li=$recv(html)._li();
- li;
- $7=li;
- $8=$recv($recv($recv($recv(each)._methodClass())._asString()).__comma(" >> ")).__comma($recv(each)._selector());
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx[","]=3;
- //>>excludeEnd("ctx");
- $recv($7)._with_($8);
- return $recv($7)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx4) {
- //>>excludeEnd("ctx");
- return self._openBrowserOn_(each);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx4) {$ctx4.fillBlock({},$ctx3,3)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({each:each,li:li},$ctx2,2)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({html:html},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"updateMatchesList",{},$globals.ReferencesBrowser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "updateMatchesList\x0a\x09matchesList contents: [ :html |\x0a\x09html li\x0a\x09\x09class: 'column_label';\x0a\x09\x09with: 'Regex matches (', self matches size asString, ')';\x0a\x09\x09style: 'font-weight: bold'.\x0a\x09self matches do: [ :each || li |\x0a\x09\x09li := html li.\x0a\x09\x09li\x0a\x09\x09with: (each methodClass asString, ' >> ', each selector);\x0a\x09\x09onClick: [ self openBrowserOn: each ]] ]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["contents:", "class:", "li", "with:", ",", "asString", "size", "matches", "style:", "do:", "methodClass", "selector", "onClick:", "openBrowserOn:"]
- }),
- $globals.ReferencesBrowser);
- $core.addMethod(
- $core.method({
- selector: "updateReferencedClassesList",
- protocol: 'updating',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$6,$5,$4,$3,$2,$7,$8;
- $recv(self["@referencedClassesList"])._contents_((function(html){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- $1=$recv(html)._li();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["li"]=1;
- //>>excludeEnd("ctx");
- $recv($1)._class_("column_label");
- $6=self._referencedClasses();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["referencedClasses"]=1;
- //>>excludeEnd("ctx");
- $5=$recv($6)._size();
- $4=$recv($5)._asString();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["asString"]=1;
- //>>excludeEnd("ctx");
- $3="Class references (".__comma($4);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx[","]=2;
- //>>excludeEnd("ctx");
- $2=$recv($3).__comma(")");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx[","]=1;
- //>>excludeEnd("ctx");
- $recv($1)._with_($2);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["with:"]=1;
- //>>excludeEnd("ctx");
- $recv($1)._style_("font-weight: bold");
- return $recv(self._referencedClasses())._do_((function(each){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- $7=$recv(html)._li();
- $8=$recv($recv($recv($recv(each)._methodClass())._asString()).__comma(" >> ")).__comma($recv(each)._selector());
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx[","]=3;
- //>>excludeEnd("ctx");
- $recv($7)._with_($8);
- return $recv($7)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx4) {
- //>>excludeEnd("ctx");
- return self._openBrowserOn_(each);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx4) {$ctx4.fillBlock({},$ctx3,3)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({each:each},$ctx2,2)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({html:html},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"updateReferencedClassesList",{},$globals.ReferencesBrowser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "updateReferencedClassesList\x0a\x09referencedClassesList contents: [ :html |\x0a\x09html li\x0a\x09\x09class: 'column_label';\x0a\x09\x09with: 'Class references (', self referencedClasses size asString, ')';\x0a\x09\x09style: 'font-weight: bold'.\x0a\x09self referencedClasses do: [ :each |\x0a\x09\x09html li\x0a\x09\x09\x09with: (each methodClass asString, ' >> ', each selector);\x0a\x09\x09\x09onClick: [ self openBrowserOn: each ]] ]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["contents:", "class:", "li", "with:", ",", "asString", "size", "referencedClasses", "style:", "do:", "methodClass", "selector", "onClick:", "openBrowserOn:"]
- }),
- $globals.ReferencesBrowser);
- $core.addMethod(
- $core.method({
- selector: "updateSendersList",
- protocol: 'updating',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$6,$5,$4,$3,$2,$7,$8;
- $recv(self["@sendersList"])._contents_((function(html){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- $1=$recv(html)._li();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["li"]=1;
- //>>excludeEnd("ctx");
- $recv($1)._class_("column_label");
- $6=self._senders();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["senders"]=1;
- //>>excludeEnd("ctx");
- $5=$recv($6)._size();
- $4=$recv($5)._asString();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["asString"]=1;
- //>>excludeEnd("ctx");
- $3="Senders (".__comma($4);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx[","]=2;
- //>>excludeEnd("ctx");
- $2=$recv($3).__comma(")");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx[","]=1;
- //>>excludeEnd("ctx");
- $recv($1)._with_($2);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["with:"]=1;
- //>>excludeEnd("ctx");
- $recv($1)._style_("font-weight: bold");
- return $recv(self._senders())._do_((function(each){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- $7=$recv(html)._li();
- $8=$recv($recv($recv($recv(each)._methodClass())._asString()).__comma(" >> ")).__comma($recv(each)._selector());
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx[","]=3;
- //>>excludeEnd("ctx");
- $recv($7)._with_($8);
- return $recv($7)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx4) {
- //>>excludeEnd("ctx");
- return self._openBrowserOn_(each);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx4) {$ctx4.fillBlock({},$ctx3,3)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({each:each},$ctx2,2)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({html:html},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"updateSendersList",{},$globals.ReferencesBrowser)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "updateSendersList\x0a\x09sendersList contents: [ :html |\x0a\x09html li\x0a\x09\x09class: 'column_label';\x0a\x09\x09with: 'Senders (', self senders size asString, ')';\x0a\x09\x09style: 'font-weight: bold'.\x0a\x09self senders do: [ :each |\x0a\x09\x09html li\x0a\x09\x09\x09with: (each methodClass asString, ' >> ', each selector);\x0a\x09\x09\x09onClick: [ self openBrowserOn: each ]] ]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["contents:", "class:", "li", "with:", ",", "asString", "size", "senders", "style:", "do:", "methodClass", "selector", "onClick:", "openBrowserOn:"]
- }),
- $globals.ReferencesBrowser);
- $core.addMethod(
- $core.method({
- selector: "search:",
- protocol: 'instance creation',
- fn: function (aString){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1;
- $1=self._new();
- $recv($1)._searchReferencesFor_(aString);
- return $recv($1)._open();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"search:",{aString:aString},$globals.ReferencesBrowser.klass)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["aString"],
- source: "search: aString\x0a\x09^ self new\x0a\x09\x09searchReferencesFor: aString;\x0a\x09\x09open",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["searchReferencesFor:", "new", "open"]
- }),
- $globals.ReferencesBrowser.klass);
- $core.addClass('TestRunner', $globals.TabWidget, ['selectedCategories', 'packagesList', 'selectedClasses', 'classesList', 'selectedMethods', 'progressBar', 'methodsList', 'result', 'statusDiv'], 'IDE');
- $core.addMethod(
- $core.method({
- selector: "allClasses",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- return $recv($recv($globals.TestCase)._allSubclasses())._select_((function(each){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return $recv($recv(each)._isAbstract())._not();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"allClasses",{},$globals.TestRunner)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "allClasses\x0a\x09^ TestCase allSubclasses select: [ :each | each isAbstract not ]",
- referencedClasses: ["TestCase"],
- //>>excludeEnd("ide");
- messageSends: ["select:", "allSubclasses", "not", "isAbstract"]
- }),
- $globals.TestRunner);
- $core.addMethod(
- $core.method({
- selector: "classes",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1;
- return $recv($recv(self._allClasses())._select_((function(each){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return $recv(self._selectedCategories())._includes_($recv(each)._category());
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
- //>>excludeEnd("ctx");
- })))._sort_((function(a,b){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- $1=$recv(a)._name();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["name"]=1;
- //>>excludeEnd("ctx");
- return $recv($1).__gt($recv(b)._name());
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({a:a,b:b},$ctx1,2)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"classes",{},$globals.TestRunner)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "classes\x0a\x09^ (self allClasses\x0a\x09select: [ :each | self selectedCategories includes: each category ])\x0a\x09sort: [ :a :b | a name > b name ]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["sort:", "select:", "allClasses", "includes:", "selectedCategories", "category", ">", "name"]
- }),
- $globals.TestRunner);
- $core.addMethod(
- $core.method({
- selector: "initialize",
- protocol: 'initialization',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- (
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.supercall = true,
- //>>excludeEnd("ctx");
- ($globals.TestRunner.superclass||$boot.nilAsClass).fn.prototype._initialize.apply($recv(self), []));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.supercall = false;
- //>>excludeEnd("ctx");;
- self["@result"]=$recv($globals.TestResult)._new();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"initialize",{},$globals.TestRunner)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "initialize\x0a\x09super initialize.\x0a\x09result := TestResult new",
- referencedClasses: ["TestResult"],
- //>>excludeEnd("ide");
- messageSends: ["initialize", "new"]
- }),
- $globals.TestRunner);
- $core.addMethod(
- $core.method({
- selector: "isSelectedCategory:",
- protocol: 'testing',
- fn: function (aCategory){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- return $recv(self._selectedCategories())._includes_(aCategory);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"isSelectedCategory:",{aCategory:aCategory},$globals.TestRunner)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["aCategory"],
- source: "isSelectedCategory: aCategory\x0a\x09^ (self selectedCategories includes: aCategory)",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["includes:", "selectedCategories"]
- }),
- $globals.TestRunner);
- $core.addMethod(
- $core.method({
- selector: "isSelectedClass:",
- protocol: 'testing',
- fn: function (aClass){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- return $recv(self._selectedClasses())._includes_(aClass);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"isSelectedClass:",{aClass:aClass},$globals.TestRunner)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["aClass"],
- source: "isSelectedClass: aClass\x0a\x09^ (self selectedClasses includes: aClass)",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["includes:", "selectedClasses"]
- }),
- $globals.TestRunner);
- $core.addMethod(
- $core.method({
- selector: "label",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- return "SUnit";
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "label\x0a\x09^ 'SUnit'",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: []
- }),
- $globals.TestRunner);
- $core.addMethod(
- $core.method({
- selector: "packages",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- var packages;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $2,$3,$1;
- packages=$recv($globals.Array)._new();
- $recv(self._allClasses())._do_((function(each){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- $2=packages;
- $3=$recv(each)._category();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["category"]=1;
- //>>excludeEnd("ctx");
- $1=$recv($2)._includes_($3);
- if(!$core.assert($1)){
- return $recv(packages)._add_($recv(each)._category());
- };
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- return $recv(packages)._sort();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"packages",{packages:packages},$globals.TestRunner)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "packages\x0a\x09| packages |\x0a\x09packages := Array new.\x0a\x09self allClasses do: [ :each |\x0a\x09(packages includes: each category) ifFalse: [\x0a\x09\x09packages add: each category ]].\x0a\x09^ packages sort",
- referencedClasses: ["Array"],
- //>>excludeEnd("ide");
- messageSends: ["new", "do:", "allClasses", "ifFalse:", "includes:", "category", "add:", "sort"]
- }),
- $globals.TestRunner);
- $core.addMethod(
- $core.method({
- selector: "performFailure:",
- protocol: 'actions',
- fn: function (aTestCase){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- $recv(aTestCase)._runCase();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"performFailure:",{aTestCase:aTestCase},$globals.TestRunner)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["aTestCase"],
- source: "performFailure: aTestCase\x0a\x09aTestCase runCase",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["runCase"]
- }),
- $globals.TestRunner);
- $core.addMethod(
- $core.method({
- selector: "printErrors",
- protocol: 'printing',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- return $recv($recv($recv($recv(self._result())._errors())._size())._asString()).__comma(" errors, ");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"printErrors",{},$globals.TestRunner)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "printErrors\x0a\x09^ self result errors size asString , ' errors, '",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: [",", "asString", "size", "errors", "result"]
- }),
- $globals.TestRunner);
- $core.addMethod(
- $core.method({
- selector: "printFailures",
- protocol: 'printing',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- return $recv($recv($recv($recv(self._result())._failures())._size())._asString()).__comma(" failures");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"printFailures",{},$globals.TestRunner)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "printFailures\x0a\x09^ self result failures size asString, ' failures'",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: [",", "asString", "size", "failures", "result"]
- }),
- $globals.TestRunner);
- $core.addMethod(
- $core.method({
- selector: "printPasses",
- protocol: 'printing',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $5,$4,$8,$7,$6,$3,$2,$1;
- $5=self._result();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["result"]=1;
- //>>excludeEnd("ctx");
- $4=$recv($5)._runs();
- $8=self._result();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["result"]=2;
- //>>excludeEnd("ctx");
- $7=$recv($8)._errors();
- $6=$recv($7)._size();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["size"]=1;
- //>>excludeEnd("ctx");
- $3=$recv($4).__minus($6);
- $2=$recv($3).__minus($recv($recv(self._result())._failures())._size());
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["-"]=1;
- //>>excludeEnd("ctx");
- $1=$recv($2)._asString();
- return $recv($1).__comma(" passes, ");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"printPasses",{},$globals.TestRunner)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "printPasses\x0a\x09^ (self result runs - self result errors size - self result failures size) asString , ' passes, '",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: [",", "asString", "-", "runs", "result", "size", "errors", "failures"]
- }),
- $globals.TestRunner);
- $core.addMethod(
- $core.method({
- selector: "printTotal",
- protocol: 'printing',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- return $recv($recv($recv(self._result())._total())._asString()).__comma(" runs, ");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"printTotal",{},$globals.TestRunner)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "printTotal\x0a\x09^ self result total asString, ' runs, '",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: [",", "asString", "total", "result"]
- }),
- $globals.TestRunner);
- $core.addMethod(
- $core.method({
- selector: "progressBar",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$receiver;
- $1=self["@progressBar"];
- if(($receiver = $1) == null || $receiver.isNil){
- self["@progressBar"]=$recv($globals.ProgressBar)._new();
- return self["@progressBar"];
- } else {
- return $1;
- };
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"progressBar",{},$globals.TestRunner)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "progressBar\x0a\x09^ progressBar ifNil: [ progressBar := ProgressBar new ]",
- referencedClasses: ["ProgressBar"],
- //>>excludeEnd("ide");
- messageSends: ["ifNil:", "new"]
- }),
- $globals.TestRunner);
- $core.addMethod(
- $core.method({
- selector: "renderBoxOn:",
- protocol: 'rendering',
- fn: function (html){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- self._renderCategoriesOn_(html);
- self._renderClassesOn_(html);
- self._renderResultsOn_(html);
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"renderBoxOn:",{html:html},$globals.TestRunner)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["html"],
- source: "renderBoxOn: html\x0a\x09self\x0a\x09renderCategoriesOn: html;\x0a\x09renderClassesOn: html;\x0a\x09renderResultsOn: html",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["renderCategoriesOn:", "renderClassesOn:", "renderResultsOn:"]
- }),
- $globals.TestRunner);
- $core.addMethod(
- $core.method({
- selector: "renderButtonsOn:",
- protocol: 'rendering',
- fn: function (html){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1;
- $1=$recv(html)._button();
- $recv($1)._with_("Run selected");
- $recv($1)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return self._run_(self._testCases());
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"renderButtonsOn:",{html:html},$globals.TestRunner)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["html"],
- source: "renderButtonsOn: html\x0a\x09html button\x0a\x09with: 'Run selected';\x0a\x09onClick: [ self run: self testCases ]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["with:", "button", "onClick:", "run:", "testCases"]
- }),
- $globals.TestRunner);
- $core.addMethod(
- $core.method({
- selector: "renderCategoriesOn:",
- protocol: 'rendering',
- fn: function (html){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- self["@packagesList"]=$recv($recv(html)._ul())._class_("amber_column sunit packages");
- self._updateCategoriesList();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"renderCategoriesOn:",{html:html},$globals.TestRunner)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["html"],
- source: "renderCategoriesOn: html\x0a\x09packagesList := html ul class: 'amber_column sunit packages'.\x0a\x09self updateCategoriesList",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["class:", "ul", "updateCategoriesList"]
- }),
- $globals.TestRunner);
- $core.addMethod(
- $core.method({
- selector: "renderClassesOn:",
- protocol: 'rendering',
- fn: function (html){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- self["@classesList"]=$recv($recv(html)._ul())._class_("amber_column sunit classes");
- self._updateClassesList();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"renderClassesOn:",{html:html},$globals.TestRunner)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["html"],
- source: "renderClassesOn: html\x0a\x09classesList := html ul class: 'amber_column sunit classes'.\x0a\x09self updateClassesList",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["class:", "ul", "updateClassesList"]
- }),
- $globals.TestRunner);
- $core.addMethod(
- $core.method({
- selector: "renderErrorsOn:",
- protocol: 'rendering',
- fn: function (html){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$2;
- $recv($recv(self._result())._errors())._do_((function(each){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- $1=$recv(html)._li();
- $recv($1)._class_("errors");
- $2=$recv($recv($recv($recv(each)._class())._name()).__comma(" >> ")).__comma($recv(each)._selector());
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx[","]=1;
- //>>excludeEnd("ctx");
- $recv($1)._with_($2);
- return $recv($1)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- return self._performFailure_(each);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({},$ctx2,2)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"renderErrorsOn:",{html:html},$globals.TestRunner)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["html"],
- source: "renderErrorsOn: html\x0a\x09self result errors do: [ :each |\x0a\x09\x09html li\x0a\x09\x09\x09class: 'errors';\x0a\x09\x09\x09with: each class name, ' >> ', each selector;\x0a\x09\x09\x09\x09\x09\x09onClick: [ self performFailure: each ]]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["do:", "errors", "result", "class:", "li", "with:", ",", "name", "class", "selector", "onClick:", "performFailure:"]
- }),
- $globals.TestRunner);
- $core.addMethod(
- $core.method({
- selector: "renderFailuresOn:",
- protocol: 'rendering',
- fn: function (html){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$2;
- $recv($recv(self._result())._failures())._do_((function(each){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- $1=$recv(html)._li();
- $recv($1)._class_("failures");
- $2=$recv($recv($recv($recv(each)._class())._name()).__comma(" >> ")).__comma($recv(each)._selector());
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx[","]=1;
- //>>excludeEnd("ctx");
- $recv($1)._with_($2);
- return $recv($1)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- return self._performFailure_(each);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({},$ctx2,2)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"renderFailuresOn:",{html:html},$globals.TestRunner)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["html"],
- source: "renderFailuresOn: html\x0a\x09self result failures do: [ :each |\x0a\x09\x09html li\x0a\x09\x09\x09class: 'failures';\x0a\x09\x09\x09with: each class name, ' >> ', each selector;\x0a\x09\x09\x09\x09\x09\x09onClick: [ self performFailure: each ]]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["do:", "failures", "result", "class:", "li", "with:", ",", "name", "class", "selector", "onClick:", "performFailure:"]
- }),
- $globals.TestRunner);
- $core.addMethod(
- $core.method({
- selector: "renderResultsOn:",
- protocol: 'rendering',
- fn: function (html){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- self["@statusDiv"]=$recv(html)._div();
- $recv(html)._with_(self._progressBar());
- self["@methodsList"]=$recv($recv(html)._ul())._class_("amber_column sunit results");
- self._updateMethodsList();
- self._updateStatusDiv();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"renderResultsOn:",{html:html},$globals.TestRunner)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["html"],
- source: "renderResultsOn: html\x0a\x09statusDiv := html div.\x0a\x09html with: self progressBar.\x0a\x09methodsList := html ul class: 'amber_column sunit results'.\x0a\x09self updateMethodsList.\x0a\x09self updateStatusDiv",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["div", "with:", "progressBar", "class:", "ul", "updateMethodsList", "updateStatusDiv"]
- }),
- $globals.TestRunner);
- $core.addMethod(
- $core.method({
- selector: "result",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- return self["@result"];
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "result\x0a\x09^ result",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: []
- }),
- $globals.TestRunner);
- $core.addMethod(
- $core.method({
- selector: "run:",
- protocol: 'actions',
- fn: function (aCollection){
- var self=this;
- var worker;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1;
- worker=$recv($globals.TestSuiteRunner)._on_(aCollection);
- self["@result"]=$recv(worker)._result();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["result"]=1;
- //>>excludeEnd("ctx");
- $recv($recv(worker)._announcer())._on_do_($globals.ResultAnnouncement,(function(ann){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- $1=$recv($recv(ann)._result()).__eq_eq(self["@result"]);
- if($core.assert($1)){
- $recv(self._progressBar())._updatePercent_($recv($recv($recv(self["@result"])._runs()).__slash($recv(self["@result"])._total())).__star((100)));
- self._updateStatusDiv();
- return self._updateMethodsList();
- };
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- $recv(worker)._run();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"run:",{aCollection:aCollection,worker:worker},$globals.TestRunner)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["aCollection"],
- source: "run: aCollection\x0a| worker |\x0a\x09worker := TestSuiteRunner on: aCollection.\x0a\x09result := worker result.\x0a\x09worker announcer on: ResultAnnouncement do: [ :ann |\x0a\x09\x09ann result == result ifTrue: [\x0a\x09\x09\x09self progressBar updatePercent: result runs / result total * 100.\x0a\x09\x09\x09self updateStatusDiv.\x0a\x09\x09\x09self updateMethodsList\x0a\x09\x09]\x0a\x09].\x0a\x09worker run",
- referencedClasses: ["TestSuiteRunner", "ResultAnnouncement"],
- //>>excludeEnd("ide");
- messageSends: ["on:", "result", "on:do:", "announcer", "ifTrue:", "==", "updatePercent:", "progressBar", "*", "/", "runs", "total", "updateStatusDiv", "updateMethodsList", "run"]
- }),
- $globals.TestRunner);
- $core.addMethod(
- $core.method({
- selector: "selectAllCategories",
- protocol: 'actions',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1;
- $recv(self._packages())._do_((function(each){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- $1=$recv(self["@selectedCategories"])._includes_(each);
- if(!$core.assert($1)){
- return $recv(self._selectedCategories())._add_(each);
- };
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- self._updateCategoriesList();
- self._updateClassesList();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"selectAllCategories",{},$globals.TestRunner)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "selectAllCategories\x0a\x09self packages do: [ :each |\x0a\x09\x09(selectedCategories includes: each) ifFalse: [\x0a\x09\x09\x09self selectedCategories add: each ]].\x0a\x09self\x0a\x09\x09updateCategoriesList;\x0a\x09\x09updateClassesList",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["do:", "packages", "ifFalse:", "includes:", "add:", "selectedCategories", "updateCategoriesList", "updateClassesList"]
- }),
- $globals.TestRunner);
- $core.addMethod(
- $core.method({
- selector: "selectAllClasses",
- protocol: 'actions',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1;
- $recv(self._classes())._do_((function(each){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- $1=$recv(self["@selectedClasses"])._includes_(each);
- if(!$core.assert($1)){
- return $recv(self._selectedClasses())._add_(each);
- };
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- self._updateCategoriesList();
- self._updateClassesList();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"selectAllClasses",{},$globals.TestRunner)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "selectAllClasses\x0a\x09self classes do: [ :each |\x0a\x09\x09(selectedClasses includes: each) ifFalse: [\x0a\x09\x09\x09self selectedClasses add: each ]].\x0a\x09self\x0a\x09\x09updateCategoriesList;\x0a\x09\x09updateClassesList",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["do:", "classes", "ifFalse:", "includes:", "add:", "selectedClasses", "updateCategoriesList", "updateClassesList"]
- }),
- $globals.TestRunner);
- $core.addMethod(
- $core.method({
- selector: "selectedCategories",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$receiver;
- $1=self["@selectedCategories"];
- if(($receiver = $1) == null || $receiver.isNil){
- self["@selectedCategories"]=$recv($globals.Array)._new();
- return self["@selectedCategories"];
- } else {
- return $1;
- };
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"selectedCategories",{},$globals.TestRunner)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "selectedCategories\x0a\x09^ selectedCategories ifNil: [ selectedCategories := Array new ]",
- referencedClasses: ["Array"],
- //>>excludeEnd("ide");
- messageSends: ["ifNil:", "new"]
- }),
- $globals.TestRunner);
- $core.addMethod(
- $core.method({
- selector: "selectedClasses",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$receiver;
- $1=self["@selectedClasses"];
- if(($receiver = $1) == null || $receiver.isNil){
- self["@selectedClasses"]=$recv($globals.Array)._new();
- return self["@selectedClasses"];
- } else {
- return $1;
- };
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"selectedClasses",{},$globals.TestRunner)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "selectedClasses\x0a\x09^ selectedClasses ifNil: [ selectedClasses := Array new ]",
- referencedClasses: ["Array"],
- //>>excludeEnd("ide");
- messageSends: ["ifNil:", "new"]
- }),
- $globals.TestRunner);
- $core.addMethod(
- $core.method({
- selector: "statusInfo",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $2,$1;
- $2=$recv($recv(self._printTotal()).__comma(self._printPasses())).__comma(self._printErrors());
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx[","]=2;
- //>>excludeEnd("ctx");
- $1=$recv($2).__comma(self._printFailures());
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx[","]=1;
- //>>excludeEnd("ctx");
- return $1;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"statusInfo",{},$globals.TestRunner)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "statusInfo\x0a\x09^ self printTotal, self printPasses, self printErrors, self printFailures",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: [",", "printTotal", "printPasses", "printErrors", "printFailures"]
- }),
- $globals.TestRunner);
- $core.addMethod(
- $core.method({
- selector: "testCases",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- var testCases;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- testCases=[];
- $recv($recv(self._selectedClasses())._select_((function(each){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return $recv(self._selectedCategories())._includes_($recv(each)._category());
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
- //>>excludeEnd("ctx");
- })))._do_((function(each){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return $recv(testCases)._addAll_($recv(each)._buildSuite());
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,2)});
- //>>excludeEnd("ctx");
- }));
- return testCases;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"testCases",{testCases:testCases},$globals.TestRunner)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "testCases\x0a\x09| testCases |\x0a\x09testCases := #().\x0a\x09(self selectedClasses\x0a\x09\x09select: [ :each | self selectedCategories includes: each category ])\x0a\x09\x09do: [ :each | testCases addAll: each buildSuite ].\x0a\x09^ testCases",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["do:", "select:", "selectedClasses", "includes:", "selectedCategories", "category", "addAll:", "buildSuite"]
- }),
- $globals.TestRunner);
- $core.addMethod(
- $core.method({
- selector: "toggleCategory:",
- protocol: 'actions',
- fn: function (aCategory){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1;
- $1=self._isSelectedCategory_(aCategory);
- if($core.assert($1)){
- $recv(self["@selectedCategories"])._remove_(aCategory);
- } else {
- $recv(self["@selectedCategories"])._add_(aCategory);
- };
- self._updateCategoriesList();
- self._updateClassesList();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"toggleCategory:",{aCategory:aCategory},$globals.TestRunner)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["aCategory"],
- source: "toggleCategory: aCategory\x0a\x09(self isSelectedCategory: aCategory)\x0a\x09\x09ifFalse: [ selectedCategories add: aCategory ]\x0a\x09\x09ifTrue: [ selectedCategories remove: aCategory ].\x0a\x09self\x0a\x09\x09updateCategoriesList;\x0a\x09\x09updateClassesList",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["ifFalse:ifTrue:", "isSelectedCategory:", "add:", "remove:", "updateCategoriesList", "updateClassesList"]
- }),
- $globals.TestRunner);
- $core.addMethod(
- $core.method({
- selector: "toggleClass:",
- protocol: 'actions',
- fn: function (aClass){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1;
- $1=self._isSelectedClass_(aClass);
- if($core.assert($1)){
- $recv(self["@selectedClasses"])._remove_(aClass);
- } else {
- $recv(self["@selectedClasses"])._add_(aClass);
- };
- self._updateClassesList();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"toggleClass:",{aClass:aClass},$globals.TestRunner)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["aClass"],
- source: "toggleClass: aClass\x0a\x09(self isSelectedClass: aClass)\x0a\x09\x09ifFalse: [ selectedClasses add: aClass ]\x0a\x09\x09ifTrue: [ selectedClasses remove: aClass ].\x0a\x09self\x0a\x09\x09updateClassesList",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["ifFalse:ifTrue:", "isSelectedClass:", "add:", "remove:", "updateClassesList"]
- }),
- $globals.TestRunner);
- $core.addMethod(
- $core.method({
- selector: "updateCategoriesList",
- protocol: 'updating',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$2,$3,$4;
- $recv(self["@packagesList"])._contents_((function(html){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- $1=$recv(html)._li();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["li"]=1;
- //>>excludeEnd("ctx");
- $recv($1)._class_("all");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["class:"]=1;
- //>>excludeEnd("ctx");
- $recv($1)._with_("All");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["with:"]=1;
- //>>excludeEnd("ctx");
- $2=$recv($1)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- return self._selectAllCategories();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({},$ctx2,2)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx2.sendIdx["onClick:"]=1;
- //>>excludeEnd("ctx");
- $2;
- return $recv(self._packages())._do_((function(each){
- var li;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- li=$recv(html)._li();
- li;
- $3=$recv(self._selectedCategories())._includes_(each);
- if($core.assert($3)){
- $recv(li)._class_("selected");
- };
- $4=li;
- $recv($4)._with_(each);
- return $recv($4)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx4) {
- //>>excludeEnd("ctx");
- return self._toggleCategory_(each);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx4) {$ctx4.fillBlock({},$ctx3,5)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({each:each,li:li},$ctx2,3)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({html:html},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"updateCategoriesList",{},$globals.TestRunner)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "updateCategoriesList\x0a\x09packagesList contents: [ :html |\x0a\x09\x09html li\x0a\x09\x09class: 'all';\x0a\x09\x09with: 'All';\x0a\x09\x09onClick: [ self selectAllCategories ].\x0a\x09self packages do: [ :each || li |\x0a\x09\x09li := html li.\x0a\x09\x09(self selectedCategories includes: each) ifTrue: [\x0a\x09\x09li class: 'selected' ].\x0a\x09\x09li\x0a\x09\x09with: each;\x0a\x09\x09onClick: [ self toggleCategory: each ]] ]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["contents:", "class:", "li", "with:", "onClick:", "selectAllCategories", "do:", "packages", "ifTrue:", "includes:", "selectedCategories", "toggleCategory:"]
- }),
- $globals.TestRunner);
- $core.addMethod(
- $core.method({
- selector: "updateClassesList",
- protocol: 'updating',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$2,$3,$4;
- $recv(self["@classesList"])._contents_((function(html){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- $recv(self._selectedCategories())._ifNotEmpty_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- $1=$recv(html)._li();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["li"]=1;
- //>>excludeEnd("ctx");
- $recv($1)._class_("all");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["class:"]=1;
- //>>excludeEnd("ctx");
- $recv($1)._with_("All");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["with:"]=1;
- //>>excludeEnd("ctx");
- $2=$recv($1)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx4) {
- //>>excludeEnd("ctx");
- return self._selectAllClasses();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx4) {$ctx4.fillBlock({},$ctx3,3)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx3.sendIdx["onClick:"]=1;
- //>>excludeEnd("ctx");
- return $2;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({},$ctx2,2)});
- //>>excludeEnd("ctx");
- }));
- return $recv(self._classes())._do_((function(each){
- var li;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx3) {
- //>>excludeEnd("ctx");
- li=$recv(html)._li();
- li;
- $3=$recv(self._selectedClasses())._includes_(each);
- if($core.assert($3)){
- $recv(li)._class_("selected");
- };
- $4=li;
- $recv($4)._with_($recv(each)._name());
- return $recv($4)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx4) {
- //>>excludeEnd("ctx");
- return self._toggleClass_(each);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx4) {$ctx4.fillBlock({},$ctx3,6)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx3) {$ctx3.fillBlock({each:each,li:li},$ctx2,4)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({html:html},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"updateClassesList",{},$globals.TestRunner)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "updateClassesList\x0a\x09classesList contents: [ :html |\x0a\x09self selectedCategories ifNotEmpty: [\x0a\x09\x09html li\x0a\x09\x09\x09class: 'all';\x0a\x09\x09\x09with: 'All';\x0a\x09\x09\x09onClick: [ self selectAllClasses ]].\x0a\x09self classes do: [ :each || li |\x0a\x09\x09li := html li.\x0a\x09\x09(self selectedClasses includes: each) ifTrue: [\x0a\x09\x09\x09li class: 'selected' ].\x0a\x09\x09li\x0a\x09\x09\x09with: each name;\x0a\x09\x09\x09onClick: [ self toggleClass: each ]] ]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["contents:", "ifNotEmpty:", "selectedCategories", "class:", "li", "with:", "onClick:", "selectAllClasses", "do:", "classes", "ifTrue:", "includes:", "selectedClasses", "name", "toggleClass:"]
- }),
- $globals.TestRunner);
- $core.addMethod(
- $core.method({
- selector: "updateMethodsList",
- protocol: 'updating',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- $recv(self["@methodsList"])._contents_((function(html){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- self._renderErrorsOn_(html);
- return self._renderFailuresOn_(html);
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({html:html},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"updateMethodsList",{},$globals.TestRunner)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "updateMethodsList\x0a\x09methodsList contents: [ :html |\x0a\x09\x09self renderErrorsOn: html.\x0a\x09\x09\x09\x09self renderFailuresOn: html ]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["contents:", "renderErrorsOn:", "renderFailuresOn:"]
- }),
- $globals.TestRunner);
- $core.addMethod(
- $core.method({
- selector: "updateStatusDiv",
- protocol: 'updating',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- $recv(self["@statusDiv"])._class_("sunit status ".__comma($recv(self["@result"])._status()));
- $recv(self["@statusDiv"])._contents_((function(html){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return $recv($recv(html)._span())._with_(self._statusInfo());
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({html:html},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"updateStatusDiv",{},$globals.TestRunner)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "updateStatusDiv\x0a\x09statusDiv class: 'sunit status ', result status.\x0a\x09statusDiv contents: [ :html |\x0a\x09\x09html span with: self statusInfo ]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["class:", ",", "status", "contents:", "with:", "span", "statusInfo"]
- }),
- $globals.TestRunner);
- $core.addClass('Workspace', $globals.TabWidget, ['sourceArea'], 'IDE');
- $core.addMethod(
- $core.method({
- selector: "clearWorkspace",
- protocol: 'actions',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- $recv(self["@sourceArea"])._clear();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"clearWorkspace",{},$globals.Workspace)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "clearWorkspace\x0a\x09sourceArea clear",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["clear"]
- }),
- $globals.Workspace);
- $core.addMethod(
- $core.method({
- selector: "doIt",
- protocol: 'actions',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- $recv(self["@sourceArea"])._doIt();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"doIt",{},$globals.Workspace)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "doIt\x0a\x09sourceArea doIt",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["doIt"]
- }),
- $globals.Workspace);
- $core.addMethod(
- $core.method({
- selector: "fileIn",
- protocol: 'actions',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- $recv(self["@sourceArea"])._fileIn();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"fileIn",{},$globals.Workspace)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "fileIn\x0a\x09sourceArea fileIn",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["fileIn"]
- }),
- $globals.Workspace);
- $core.addMethod(
- $core.method({
- selector: "inspectIt",
- protocol: 'actions',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- $recv(self["@sourceArea"])._inspectIt();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"inspectIt",{},$globals.Workspace)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "inspectIt\x0a\x09sourceArea inspectIt",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["inspectIt"]
- }),
- $globals.Workspace);
- $core.addMethod(
- $core.method({
- selector: "label",
- protocol: 'accessing',
- fn: function (){
- var self=this;
- return "Workspace";
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "label\x0a\x09^ 'Workspace'",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: []
- }),
- $globals.Workspace);
- $core.addMethod(
- $core.method({
- selector: "printIt",
- protocol: 'actions',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- $recv(self["@sourceArea"])._printIt();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"printIt",{},$globals.Workspace)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "printIt\x0a\x09sourceArea printIt",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["printIt"]
- }),
- $globals.Workspace);
- $core.addMethod(
- $core.method({
- selector: "renderBoxOn:",
- protocol: 'rendering',
- fn: function (html){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- self["@sourceArea"]=$recv($globals.SourceArea)._new();
- $recv(self["@sourceArea"])._renderOn_(html);
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"renderBoxOn:",{html:html},$globals.Workspace)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["html"],
- source: "renderBoxOn: html\x0a\x09sourceArea := SourceArea new.\x0a\x09sourceArea renderOn: html",
- referencedClasses: ["SourceArea"],
- //>>excludeEnd("ide");
- messageSends: ["new", "renderOn:"]
- }),
- $globals.Workspace);
- $core.addMethod(
- $core.method({
- selector: "renderButtonsOn:",
- protocol: 'rendering',
- fn: function (html){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- var $1,$2,$3,$4,$5,$6,$7,$8,$9;
- $1=$recv(html)._button();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["button"]=1;
- //>>excludeEnd("ctx");
- $recv($1)._with_("DoIt");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["with:"]=1;
- //>>excludeEnd("ctx");
- $recv($1)._title_("ctrl+d");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["title:"]=1;
- //>>excludeEnd("ctx");
- $2=$recv($1)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return self._doIt();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["onClick:"]=1;
- //>>excludeEnd("ctx");
- $3=$recv(html)._button();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["button"]=2;
- //>>excludeEnd("ctx");
- $recv($3)._with_("PrintIt");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["with:"]=2;
- //>>excludeEnd("ctx");
- $recv($3)._title_("ctrl+p");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["title:"]=2;
- //>>excludeEnd("ctx");
- $4=$recv($3)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return self._printIt();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["onClick:"]=2;
- //>>excludeEnd("ctx");
- $5=$recv(html)._button();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["button"]=3;
- //>>excludeEnd("ctx");
- $recv($5)._with_("InspectIt");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["with:"]=3;
- //>>excludeEnd("ctx");
- $recv($5)._title_("ctrl+i");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["title:"]=3;
- //>>excludeEnd("ctx");
- $6=$recv($5)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return self._inspectIt();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,3)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["onClick:"]=3;
- //>>excludeEnd("ctx");
- $7=$recv(html)._button();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["button"]=4;
- //>>excludeEnd("ctx");
- $recv($7)._with_("FileIn");
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["with:"]=4;
- //>>excludeEnd("ctx");
- $recv($7)._title_("ctrl+f");
- $8=$recv($7)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return self._fileIn();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,4)});
- //>>excludeEnd("ctx");
- }));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.sendIdx["onClick:"]=4;
- //>>excludeEnd("ctx");
- $9=$recv(html)._button();
- $recv($9)._with_("Clear workspace");
- $recv($9)._onClick_((function(){
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx2) {
- //>>excludeEnd("ctx");
- return self._clearWorkspace();
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx2) {$ctx2.fillBlock({},$ctx1,5)});
- //>>excludeEnd("ctx");
- }));
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"renderButtonsOn:",{html:html},$globals.Workspace)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: ["html"],
- source: "renderButtonsOn: html\x0a\x09html button\x0a\x09with: 'DoIt';\x0a\x09title: 'ctrl+d';\x0a\x09onClick: [ self doIt ].\x0a\x09html button\x0a\x09with: 'PrintIt';\x0a\x09title: 'ctrl+p';\x0a\x09onClick: [ self printIt ].\x0a\x09html button\x0a\x09with: 'InspectIt';\x0a\x09title: 'ctrl+i';\x0a\x09onClick: [ self inspectIt ].\x0a\x09html button\x0a\x09with: 'FileIn';\x0a\x09title: 'ctrl+f';\x0a\x09onClick: [ self fileIn ].\x0a\x09html button\x0a\x09with: 'Clear workspace';\x0a\x09onClick: [ self clearWorkspace ]",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["with:", "button", "title:", "onClick:", "doIt", "printIt", "inspectIt", "fileIn", "clearWorkspace"]
- }),
- $globals.Workspace);
- $core.addMethod(
- $core.method({
- selector: "show",
- protocol: 'actions',
- fn: function (){
- var self=this;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- return $core.withContext(function($ctx1) {
- //>>excludeEnd("ctx");
- (
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.supercall = true,
- //>>excludeEnd("ctx");
- ($globals.Workspace.superclass||$boot.nilAsClass).fn.prototype._show.apply($recv(self), []));
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- $ctx1.supercall = false;
- //>>excludeEnd("ctx");;
- $recv(self["@sourceArea"])._focus();
- return self;
- //>>excludeStart("ctx", pragmas.excludeDebugContexts);
- }, function($ctx1) {$ctx1.fill(self,"show",{},$globals.Workspace)});
- //>>excludeEnd("ctx");
- },
- //>>excludeStart("ide", pragmas.excludeIdeData);
- args: [],
- source: "show\x0a\x09super show.\x0a\x09sourceArea focus.",
- referencedClasses: [],
- //>>excludeEnd("ide");
- messageSends: ["show", "focus"]
- }),
- $globals.Workspace);
- });
|