1
0

IDE.deploy.js 165 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537253825392540254125422543254425452546254725482549255025512552255325542555255625572558255925602561256225632564256525662567256825692570257125722573257425752576257725782579258025812582258325842585258625872588258925902591259225932594259525962597259825992600260126022603260426052606260726082609261026112612261326142615261626172618261926202621262226232624262526262627262826292630263126322633263426352636263726382639264026412642264326442645264626472648264926502651265226532654265526562657265826592660266126622663266426652666266726682669267026712672267326742675267626772678267926802681268226832684268526862687268826892690269126922693269426952696269726982699270027012702270327042705270627072708270927102711271227132714271527162717271827192720272127222723272427252726272727282729273027312732273327342735273627372738273927402741274227432744274527462747274827492750275127522753275427552756275727582759276027612762276327642765276627672768276927702771277227732774277527762777277827792780278127822783278427852786278727882789279027912792279327942795279627972798279928002801280228032804280528062807280828092810281128122813281428152816281728182819282028212822282328242825282628272828282928302831283228332834283528362837283828392840284128422843284428452846284728482849285028512852285328542855285628572858285928602861286228632864286528662867286828692870287128722873287428752876287728782879288028812882288328842885288628872888288928902891289228932894289528962897289828992900290129022903290429052906290729082909291029112912291329142915291629172918291929202921292229232924292529262927292829292930293129322933293429352936293729382939294029412942294329442945294629472948294929502951295229532954295529562957295829592960296129622963296429652966296729682969297029712972297329742975297629772978297929802981298229832984298529862987298829892990299129922993299429952996299729982999300030013002300330043005300630073008300930103011301230133014301530163017301830193020302130223023302430253026302730283029303030313032303330343035303630373038303930403041304230433044304530463047304830493050305130523053305430553056305730583059306030613062306330643065306630673068306930703071307230733074307530763077307830793080308130823083308430853086308730883089309030913092309330943095309630973098309931003101310231033104310531063107310831093110311131123113311431153116311731183119312031213122312331243125312631273128312931303131313231333134313531363137313831393140314131423143314431453146314731483149315031513152315331543155315631573158315931603161316231633164316531663167316831693170317131723173317431753176317731783179318031813182318331843185318631873188318931903191319231933194319531963197319831993200320132023203320432053206320732083209321032113212321332143215321632173218321932203221322232233224322532263227322832293230323132323233323432353236323732383239324032413242324332443245324632473248324932503251325232533254325532563257325832593260326132623263326432653266326732683269327032713272327332743275327632773278327932803281328232833284328532863287328832893290329132923293329432953296329732983299330033013302330333043305330633073308330933103311331233133314331533163317331833193320332133223323332433253326332733283329333033313332333333343335333633373338333933403341334233433344334533463347334833493350335133523353335433553356335733583359336033613362336333643365336633673368336933703371337233733374337533763377337833793380338133823383338433853386338733883389339033913392339333943395339633973398339934003401340234033404340534063407340834093410341134123413
  1. smalltalk.addClass('TabManager', smalltalk.Widget, ['selectedTab', 'tabs', 'opened', 'ul', 'input'], 'IDE');
  2. smalltalk.addMethod(
  3. '_tabs',
  4. smalltalk.method({
  5. selector: 'tabs',
  6. fn: function (){
  7. var self=this;
  8. return (($receiver = self['@tabs']) == nil || $receiver == undefined) ? (function(){return self['@tabs']=smalltalk.send((smalltalk.Array || Array), "_new", []);})() : $receiver;
  9. return self;}
  10. }),
  11. smalltalk.TabManager);
  12. smalltalk.addMethod(
  13. '_labelFor_',
  14. smalltalk.method({
  15. selector: 'labelFor:',
  16. fn: function (aWidget){
  17. var self=this;
  18. var label=nil;
  19. var maxSize=nil;
  20. maxSize=(15);
  21. label=smalltalk.send(smalltalk.send(aWidget, "_label", []), "_copyFrom_to_", [(0), smalltalk.send(smalltalk.send(smalltalk.send(aWidget, "_label", []), "_size", []), "_min_", [maxSize])]);
  22. (($receiver = (($receiver = smalltalk.send(smalltalk.send(aWidget, "_label", []), "_size", [])).klass === smalltalk.Number) ? $receiver >maxSize : smalltalk.send($receiver, "__gt", [maxSize])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return label=smalltalk.send(label, "__comma", ["..."]);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return label=smalltalk.send(label, "__comma", ["..."]);})]);
  23. return label;
  24. return self;}
  25. }),
  26. smalltalk.TabManager);
  27. smalltalk.addMethod(
  28. '_updateBodyMargin',
  29. smalltalk.method({
  30. selector: 'updateBodyMargin',
  31. fn: function (){
  32. var self=this;
  33. smalltalk.send(self, "_setBodyMargin_", [smalltalk.send(smalltalk.send(unescape("%23jtalk"), "_asJQuery", []), "_height", [])]);
  34. return self;}
  35. }),
  36. smalltalk.TabManager);
  37. smalltalk.addMethod(
  38. '_updatePosition',
  39. smalltalk.method({
  40. selector: 'updatePosition',
  41. fn: function (){
  42. var self=this;
  43. jQuery('#jtalk').css('top', '').css('bottom', '0px');
  44. return self;}
  45. }),
  46. smalltalk.TabManager);
  47. smalltalk.addMethod(
  48. '_removeBodyMargin',
  49. smalltalk.method({
  50. selector: 'removeBodyMargin',
  51. fn: function (){
  52. var self=this;
  53. smalltalk.send(self, "_setBodyMargin_", [(0)]);
  54. return self;}
  55. }),
  56. smalltalk.TabManager);
  57. smalltalk.addMethod(
  58. '_setBodyMargin_',
  59. smalltalk.method({
  60. selector: 'setBodyMargin:',
  61. fn: function (anInteger){
  62. var self=this;
  63. smalltalk.send(smalltalk.send(".jtalkBody", "_asJQuery", []), "_cssAt_put_", [unescape("margin-bottom"), smalltalk.send(smalltalk.send(anInteger, "_asString", []), "__comma", ["px"])]);
  64. return self;}
  65. }),
  66. smalltalk.TabManager);
  67. smalltalk.addMethod(
  68. '_onResize_',
  69. smalltalk.method({
  70. selector: 'onResize:',
  71. fn: function (aBlock){
  72. var self=this;
  73. jQuery('#jtalk').resizable({
  74. handles: 'n',
  75. resize: aBlock,
  76. minHeight: 230
  77. });
  78. return self;}
  79. }),
  80. smalltalk.TabManager);
  81. smalltalk.addMethod(
  82. '_onWindowResize_',
  83. smalltalk.method({
  84. selector: 'onWindowResize:',
  85. fn: function (aBlock){
  86. var self=this;
  87. jQuery(window).resize(aBlock);
  88. return self;}
  89. }),
  90. smalltalk.TabManager);
  91. smalltalk.addMethod(
  92. '_open',
  93. smalltalk.method({
  94. selector: 'open',
  95. fn: function (){
  96. var self=this;
  97. (($receiver = self['@opened']).klass === smalltalk.Boolean) ? (! $receiver ? (function(){smalltalk.send(smalltalk.send("body", "_asJQuery", []), "_addClass_", ["jtalkBody"]);smalltalk.send(smalltalk.send(unescape("%23jtalk"), "_asJQuery", []), "_show", []);smalltalk.send(smalltalk.send(self['@ul'], "_asJQuery", []), "_show", []);smalltalk.send(self, "_updateBodyMargin", []);smalltalk.send(self['@selectedTab'], "_show", []);return self['@opened']=true;})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){smalltalk.send(smalltalk.send("body", "_asJQuery", []), "_addClass_", ["jtalkBody"]);smalltalk.send(smalltalk.send(unescape("%23jtalk"), "_asJQuery", []), "_show", []);smalltalk.send(smalltalk.send(self['@ul'], "_asJQuery", []), "_show", []);smalltalk.send(self, "_updateBodyMargin", []);smalltalk.send(self['@selectedTab'], "_show", []);return self['@opened']=true;})]);
  98. return self;}
  99. }),
  100. smalltalk.TabManager);
  101. smalltalk.addMethod(
  102. '_close',
  103. smalltalk.method({
  104. selector: 'close',
  105. fn: function (){
  106. var self=this;
  107. (($receiver = self['@opened']).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(smalltalk.send(unescape("%23jtalk"), "_asJQuery", []), "_hide", []);smalltalk.send(smalltalk.send(self['@ul'], "_asJQuery", []), "_hide", []);smalltalk.send(self['@selectedTab'], "_hide", []);smalltalk.send(self, "_removeBodyMargin", []);smalltalk.send(smalltalk.send("body", "_asJQuery", []), "_removeClass_", ["jtalkBody"]);return self['@opened']=false;})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(smalltalk.send(unescape("%23jtalk"), "_asJQuery", []), "_hide", []);smalltalk.send(smalltalk.send(self['@ul'], "_asJQuery", []), "_hide", []);smalltalk.send(self['@selectedTab'], "_hide", []);smalltalk.send(self, "_removeBodyMargin", []);smalltalk.send(smalltalk.send("body", "_asJQuery", []), "_removeClass_", ["jtalkBody"]);return self['@opened']=false;})]);
  108. return self;}
  109. }),
  110. smalltalk.TabManager);
  111. smalltalk.addMethod(
  112. '_newBrowserTab',
  113. smalltalk.method({
  114. selector: 'newBrowserTab',
  115. fn: function (){
  116. var self=this;
  117. smalltalk.send((smalltalk.Browser || Browser), "_open", []);
  118. return self;}
  119. }),
  120. smalltalk.TabManager);
  121. smalltalk.addMethod(
  122. '_selectTab_',
  123. smalltalk.method({
  124. selector: 'selectTab:',
  125. fn: function (aWidget){
  126. var self=this;
  127. smalltalk.send(self, "_open", []);
  128. self['@selectedTab']=aWidget;
  129. smalltalk.send(smalltalk.send(self, "_tabs", []), "_do_", [(function(each){return smalltalk.send(each, "_hide", []);})]);
  130. smalltalk.send(aWidget, "_show", []);
  131. smalltalk.send(self, "_update", []);
  132. return self;}
  133. }),
  134. smalltalk.TabManager);
  135. smalltalk.addMethod(
  136. '_closeTab_',
  137. smalltalk.method({
  138. selector: 'closeTab:',
  139. fn: function (aWidget){
  140. var self=this;
  141. smalltalk.send(self, "_removeTab_", [aWidget]);
  142. smalltalk.send(self, "_selectTab_", [smalltalk.send(smalltalk.send(self, "_tabs", []), "_last", [])]);
  143. smalltalk.send(aWidget, "_remove", []);
  144. smalltalk.send(self, "_update", []);
  145. return self;}
  146. }),
  147. smalltalk.TabManager);
  148. smalltalk.addMethod(
  149. '_search_',
  150. smalltalk.method({
  151. selector: 'search:',
  152. fn: function (aString){
  153. var self=this;
  154. var searchedClass=nil;
  155. searchedClass=smalltalk.send(smalltalk.send((smalltalk.Smalltalk || Smalltalk), "_current", []), "_at_", [aString]);
  156. (($receiver = smalltalk.send(searchedClass, "_isClass", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send((smalltalk.Browser || Browser), "_openOn_", [searchedClass]);})() : (function(){return smalltalk.send((smalltalk.ReferencesBrowser || ReferencesBrowser), "_search_", [aString]);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return smalltalk.send((smalltalk.Browser || Browser), "_openOn_", [searchedClass]);}), (function(){return smalltalk.send((smalltalk.ReferencesBrowser || ReferencesBrowser), "_search_", [aString]);})]);
  157. return self;}
  158. }),
  159. smalltalk.TabManager);
  160. smalltalk.addMethod(
  161. '_addTab_',
  162. smalltalk.method({
  163. selector: 'addTab:',
  164. fn: function (aWidget){
  165. var self=this;
  166. smalltalk.send(smalltalk.send(self, "_tabs", []), "_add_", [aWidget]);
  167. smalltalk.send(smalltalk.send(unescape("%23jtalk"), "_asJQuery", []), "_append_", [aWidget]);
  168. smalltalk.send(aWidget, "_hide", []);
  169. return self;}
  170. }),
  171. smalltalk.TabManager);
  172. smalltalk.addMethod(
  173. '_removeTab_',
  174. smalltalk.method({
  175. selector: 'removeTab:',
  176. fn: function (aWidget){
  177. var self=this;
  178. smalltalk.send(smalltalk.send(self, "_tabs", []), "_remove_", [aWidget]);
  179. smalltalk.send(self, "_update", []);
  180. return self;}
  181. }),
  182. smalltalk.TabManager);
  183. smalltalk.addMethod(
  184. '_initialize',
  185. smalltalk.method({
  186. selector: 'initialize',
  187. fn: function (){
  188. var self=this;
  189. smalltalk.send(self, "_initialize", [], smalltalk.Widget);
  190. self['@opened']=true;
  191. (function($rec){smalltalk.send($rec, "_append_", [(function(html){return smalltalk.send(smalltalk.send(html, "_div", []), "_id_", ["jtalk"]);})]);return smalltalk.send($rec, "_addClass_", ["jtalkBody"]);})(smalltalk.send("body", "_asJQuery", []));
  192. smalltalk.send(smalltalk.send(unescape("%23jtalk"), "_asJQuery", []), "_append_", [self]);
  193. (function($rec){smalltalk.send($rec, "_addTab_", [smalltalk.send((smalltalk.Transcript || Transcript), "_current", [])]);smalltalk.send($rec, "_addTab_", [smalltalk.send((smalltalk.Workspace || Workspace), "_new", [])]);return smalltalk.send($rec, "_addTab_", [smalltalk.send((smalltalk.TestRunner || TestRunner), "_new", [])]);})(self);
  194. smalltalk.send(self, "_selectTab_", [smalltalk.send(smalltalk.send(self, "_tabs", []), "_last", [])]);
  195. (function($rec){smalltalk.send($rec, "_onResize_", [(function(){return (function($rec){smalltalk.send($rec, "_updateBodyMargin", []);return smalltalk.send($rec, "_updatePosition", []);})(self);})]);return smalltalk.send($rec, "_onWindowResize_", [(function(){return smalltalk.send(self, "_updatePosition", []);})]);})(self);
  196. return self;}
  197. }),
  198. smalltalk.TabManager);
  199. smalltalk.addMethod(
  200. '_renderOn_',
  201. smalltalk.method({
  202. selector: 'renderOn:',
  203. fn: function (html){
  204. var self=this;
  205. smalltalk.send(smalltalk.send(html, "_div", []), "_id_", ["logo"]);
  206. smalltalk.send(self, "_renderToolbarOn_", [html]);
  207. self['@ul']=(function($rec){smalltalk.send($rec, "_id_", ["jtalkTabs"]);return smalltalk.send($rec, "_yourself", []);})(smalltalk.send(html, "_ul", []));
  208. smalltalk.send(self, "_renderTabs", []);
  209. return self;}
  210. }),
  211. smalltalk.TabManager);
  212. smalltalk.addMethod(
  213. '_renderTabFor_on_',
  214. smalltalk.method({
  215. selector: 'renderTabFor:on:',
  216. fn: function (aWidget, html){
  217. var self=this;
  218. var li=nil;
  219. li=smalltalk.send(html, "_li", []);
  220. (($receiver = smalltalk.send(self['@selectedTab'], "__eq", [aWidget])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(li, "_class_", ["selected"]);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return smalltalk.send(li, "_class_", ["selected"]);})]);
  221. (function($rec){smalltalk.send($rec, "_with_", [(function(){smalltalk.send(smalltalk.send(html, "_span", []), "_class_", ["ltab"]);(function($rec){smalltalk.send($rec, "_class_", ["mtab"]);return smalltalk.send($rec, "_with_", [(function(){(($receiver = smalltalk.send(aWidget, "_canBeClosed", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return (function($rec){smalltalk.send($rec, "_class_", ["close"]);smalltalk.send($rec, "_with_", ["x"]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_closeTab_", [aWidget]);})]);})(smalltalk.send(html, "_span", []));})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return (function($rec){smalltalk.send($rec, "_class_", ["close"]);smalltalk.send($rec, "_with_", ["x"]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_closeTab_", [aWidget]);})]);})(smalltalk.send(html, "_span", []));})]);return smalltalk.send(smalltalk.send(html, "_span", []), "_with_", [smalltalk.send(self, "_labelFor_", [aWidget])]);})]);})(smalltalk.send(html, "_span", []));return smalltalk.send(smalltalk.send(html, "_span", []), "_class_", ["rtab"]);})]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_selectTab_", [aWidget]);})]);})(li);
  222. return self;}
  223. }),
  224. smalltalk.TabManager);
  225. smalltalk.addMethod(
  226. '_renderTabs',
  227. smalltalk.method({
  228. selector: 'renderTabs',
  229. fn: function (){
  230. var self=this;
  231. smalltalk.send(self['@ul'], "_contents_", [(function(html){smalltalk.send(smalltalk.send(self, "_tabs", []), "_do_", [(function(each){return smalltalk.send(self, "_renderTabFor_on_", [each, html]);})]);return (function($rec){smalltalk.send($rec, "_class_", ["newtab"]);smalltalk.send($rec, "_with_", [(function(){smalltalk.send(smalltalk.send(html, "_span", []), "_class_", ["ltab"]);(function($rec){smalltalk.send($rec, "_class_", ["mtab"]);return smalltalk.send($rec, "_with_", [unescape("%20+%20")]);})(smalltalk.send(html, "_span", []));return smalltalk.send(smalltalk.send(html, "_span", []), "_class_", ["rtab"]);})]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_newBrowserTab", []);})]);})(smalltalk.send(html, "_li", []));})]);
  232. return self;}
  233. }),
  234. smalltalk.TabManager);
  235. smalltalk.addMethod(
  236. '_renderToolbarOn_',
  237. smalltalk.method({
  238. selector: 'renderToolbarOn:',
  239. fn: function (html){
  240. var self=this;
  241. (function($rec){smalltalk.send($rec, "_id_", ["jt_toolbar"]);return smalltalk.send($rec, "_with_", [(function(){self['@input']=(function($rec){smalltalk.send($rec, "_class_", ["implementors"]);return smalltalk.send($rec, "_yourself", []);})(smalltalk.send(html, "_input", []));smalltalk.send(self['@input'], "_onKeyPress_", [(function(event){return (($receiver = smalltalk.send(smalltalk.send(event, "_keyCode", []), "__eq", [(13)])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(self, "_search_", [smalltalk.send(smalltalk.send(self['@input'], "_asJQuery", []), "_val", [])]);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return smalltalk.send(self, "_search_", [smalltalk.send(smalltalk.send(self['@input'], "_asJQuery", []), "_val", [])]);})]);})]);return (function($rec){smalltalk.send($rec, "_id_", ["jt_close"]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_close", []);})]);})(smalltalk.send(html, "_div", []));})]);})(smalltalk.send(html, "_div", []));
  242. return self;}
  243. }),
  244. smalltalk.TabManager);
  245. smalltalk.addMethod(
  246. '_update',
  247. smalltalk.method({
  248. selector: 'update',
  249. fn: function (){
  250. var self=this;
  251. smalltalk.send(self, "_renderTabs", []);
  252. return self;}
  253. }),
  254. smalltalk.TabManager);
  255. smalltalk.TabManager.klass.iVarNames = ['current'];
  256. smalltalk.addMethod(
  257. '_current',
  258. smalltalk.method({
  259. selector: 'current',
  260. fn: function (){
  261. var self=this;
  262. return (($receiver = self['@current']) == nil || $receiver == undefined) ? (function(){return self['@current']=smalltalk.send(self, "_new", [], smalltalk.Widget.klass);})() : $receiver;
  263. return self;}
  264. }),
  265. smalltalk.TabManager.klass);
  266. smalltalk.addMethod(
  267. '_new',
  268. smalltalk.method({
  269. selector: 'new',
  270. fn: function (){
  271. var self=this;
  272. smalltalk.send(self, "_shouldNotImplement", []);
  273. return self;}
  274. }),
  275. smalltalk.TabManager.klass);
  276. smalltalk.addClass('TabWidget', smalltalk.Widget, ['div'], 'IDE');
  277. smalltalk.addMethod(
  278. '_label',
  279. smalltalk.method({
  280. selector: 'label',
  281. fn: function (){
  282. var self=this;
  283. smalltalk.send(self, "_subclassResponsibility", []);
  284. return self;}
  285. }),
  286. smalltalk.TabWidget);
  287. smalltalk.addMethod(
  288. '_open',
  289. smalltalk.method({
  290. selector: 'open',
  291. fn: function (){
  292. var self=this;
  293. smalltalk.send(smalltalk.send((smalltalk.TabManager || TabManager), "_current", []), "_addTab_", [self]);
  294. smalltalk.send(smalltalk.send((smalltalk.TabManager || TabManager), "_current", []), "_selectTab_", [self]);
  295. return self;}
  296. }),
  297. smalltalk.TabWidget);
  298. smalltalk.addMethod(
  299. '_show',
  300. smalltalk.method({
  301. selector: 'show',
  302. fn: function (){
  303. var self=this;
  304. smalltalk.send(smalltalk.send(self['@div'], "_asJQuery", []), "_show", []);
  305. return self;}
  306. }),
  307. smalltalk.TabWidget);
  308. smalltalk.addMethod(
  309. '_hide',
  310. smalltalk.method({
  311. selector: 'hide',
  312. fn: function (){
  313. var self=this;
  314. smalltalk.send(smalltalk.send(self['@div'], "_asJQuery", []), "_hide", []);
  315. return self;}
  316. }),
  317. smalltalk.TabWidget);
  318. smalltalk.addMethod(
  319. '_remove',
  320. smalltalk.method({
  321. selector: 'remove',
  322. fn: function (){
  323. var self=this;
  324. smalltalk.send(smalltalk.send(self['@div'], "_asJQuery", []), "_remove", []);
  325. return self;}
  326. }),
  327. smalltalk.TabWidget);
  328. smalltalk.addMethod(
  329. '_close',
  330. smalltalk.method({
  331. selector: 'close',
  332. fn: function (){
  333. var self=this;
  334. smalltalk.send(smalltalk.send((smalltalk.TabManager || TabManager), "_current", []), "_closeTab_", [self]);
  335. return self;}
  336. }),
  337. smalltalk.TabWidget);
  338. smalltalk.addMethod(
  339. '_renderOn_',
  340. smalltalk.method({
  341. selector: 'renderOn:',
  342. fn: function (html){
  343. var self=this;
  344. self['@div']=(function($rec){smalltalk.send($rec, "_class_", ["jtalkTool"]);return smalltalk.send($rec, "_yourself", []);})(smalltalk.send(html, "_div", []));
  345. smalltalk.send(self, "_renderTab", []);
  346. return self;}
  347. }),
  348. smalltalk.TabWidget);
  349. smalltalk.addMethod(
  350. '_renderBoxOn_',
  351. smalltalk.method({
  352. selector: 'renderBoxOn:',
  353. fn: function (html){
  354. var self=this;
  355. return self;}
  356. }),
  357. smalltalk.TabWidget);
  358. smalltalk.addMethod(
  359. '_renderButtonsOn_',
  360. smalltalk.method({
  361. selector: 'renderButtonsOn:',
  362. fn: function (html){
  363. var self=this;
  364. return self;}
  365. }),
  366. smalltalk.TabWidget);
  367. smalltalk.addMethod(
  368. '_update',
  369. smalltalk.method({
  370. selector: 'update',
  371. fn: function (){
  372. var self=this;
  373. smalltalk.send(self, "_renderTab", []);
  374. return self;}
  375. }),
  376. smalltalk.TabWidget);
  377. smalltalk.addMethod(
  378. '_renderTab',
  379. smalltalk.method({
  380. selector: 'renderTab',
  381. fn: function (){
  382. var self=this;
  383. smalltalk.send(self['@div'], "_contents_", [(function(html){(function($rec){smalltalk.send($rec, "_class_", ["jt_box"]);return smalltalk.send($rec, "_with_", [(function(){return smalltalk.send(self, "_renderBoxOn_", [html]);})]);})(smalltalk.send(html, "_div", []));return (function($rec){smalltalk.send($rec, "_class_", ["jt_buttons"]);return smalltalk.send($rec, "_with_", [(function(){return smalltalk.send(self, "_renderButtonsOn_", [html]);})]);})(smalltalk.send(html, "_div", []));})]);
  384. return self;}
  385. }),
  386. smalltalk.TabWidget);
  387. smalltalk.addMethod(
  388. '_canBeClosed',
  389. smalltalk.method({
  390. selector: 'canBeClosed',
  391. fn: function (){
  392. var self=this;
  393. return false;
  394. return self;}
  395. }),
  396. smalltalk.TabWidget);
  397. smalltalk.addMethod(
  398. '_open',
  399. smalltalk.method({
  400. selector: 'open',
  401. fn: function (){
  402. var self=this;
  403. return smalltalk.send(smalltalk.send(self, "_new", []), "_open", []);
  404. return self;}
  405. }),
  406. smalltalk.TabWidget.klass);
  407. smalltalk.addClass('Workspace', smalltalk.TabWidget, ['sourceArea'], 'IDE');
  408. smalltalk.addMethod(
  409. '_label',
  410. smalltalk.method({
  411. selector: 'label',
  412. fn: function (){
  413. var self=this;
  414. return "Workspace";
  415. return self;}
  416. }),
  417. smalltalk.Workspace);
  418. smalltalk.addMethod(
  419. '_clearWorkspace',
  420. smalltalk.method({
  421. selector: 'clearWorkspace',
  422. fn: function (){
  423. var self=this;
  424. smalltalk.send(self['@sourceArea'], "_clear", []);
  425. return self;}
  426. }),
  427. smalltalk.Workspace);
  428. smalltalk.addMethod(
  429. '_doIt',
  430. smalltalk.method({
  431. selector: 'doIt',
  432. fn: function (){
  433. var self=this;
  434. smalltalk.send(self['@sourceArea'], "_doIt", []);
  435. return self;}
  436. }),
  437. smalltalk.Workspace);
  438. smalltalk.addMethod(
  439. '_printIt',
  440. smalltalk.method({
  441. selector: 'printIt',
  442. fn: function (){
  443. var self=this;
  444. smalltalk.send(self['@sourceArea'], "_printIt", []);
  445. return self;}
  446. }),
  447. smalltalk.Workspace);
  448. smalltalk.addMethod(
  449. '_inspectIt',
  450. smalltalk.method({
  451. selector: 'inspectIt',
  452. fn: function (){
  453. var self=this;
  454. smalltalk.send(self['@sourceArea'], "_inspectIt", []);
  455. return self;}
  456. }),
  457. smalltalk.Workspace);
  458. smalltalk.addMethod(
  459. '_fileIn',
  460. smalltalk.method({
  461. selector: 'fileIn',
  462. fn: function (){
  463. var self=this;
  464. smalltalk.send(self['@sourceArea'], "_fileIn", []);
  465. return self;}
  466. }),
  467. smalltalk.Workspace);
  468. smalltalk.addMethod(
  469. '_renderBoxOn_',
  470. smalltalk.method({
  471. selector: 'renderBoxOn:',
  472. fn: function (html){
  473. var self=this;
  474. self['@sourceArea']=smalltalk.send((smalltalk.SourceArea || SourceArea), "_new", []);
  475. smalltalk.send(self['@sourceArea'], "_renderOn_", [html]);
  476. return self;}
  477. }),
  478. smalltalk.Workspace);
  479. smalltalk.addMethod(
  480. '_renderButtonsOn_',
  481. smalltalk.method({
  482. selector: 'renderButtonsOn:',
  483. fn: function (html){
  484. var self=this;
  485. (function($rec){smalltalk.send($rec, "_with_", ["DoIt"]);smalltalk.send($rec, "_title_", [unescape("ctrl+d")]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_doIt", []);})]);})(smalltalk.send(html, "_button", []));
  486. (function($rec){smalltalk.send($rec, "_with_", ["PrintIt"]);smalltalk.send($rec, "_title_", [unescape("ctrl+p")]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_printIt", []);})]);})(smalltalk.send(html, "_button", []));
  487. (function($rec){smalltalk.send($rec, "_with_", ["InspectIt"]);smalltalk.send($rec, "_title_", [unescape("ctrl+i")]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_inspectIt", []);})]);})(smalltalk.send(html, "_button", []));
  488. (function($rec){smalltalk.send($rec, "_with_", ["FileIn"]);smalltalk.send($rec, "_title_", [unescape("ctrl+f")]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_fileIn", []);})]);})(smalltalk.send(html, "_button", []));
  489. (function($rec){smalltalk.send($rec, "_with_", ["Clear workspace"]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_clearWorkspace", []);})]);})(smalltalk.send(html, "_button", []));
  490. return self;}
  491. }),
  492. smalltalk.Workspace);
  493. smalltalk.addClass('Transcript', smalltalk.TabWidget, ['textarea'], 'IDE');
  494. smalltalk.addMethod(
  495. '_label',
  496. smalltalk.method({
  497. selector: 'label',
  498. fn: function (){
  499. var self=this;
  500. return "Transcript";
  501. return self;}
  502. }),
  503. smalltalk.Transcript);
  504. smalltalk.addMethod(
  505. '_show_',
  506. smalltalk.method({
  507. selector: 'show:',
  508. fn: function (anObject){
  509. var self=this;
  510. smalltalk.send(smalltalk.send(self['@textarea'], "_asJQuery", []), "_val_", [smalltalk.send(smalltalk.send(smalltalk.send(self['@textarea'], "_asJQuery", []), "_val", []), "__comma", [smalltalk.send(anObject, "_asString", [])])]);
  511. return self;}
  512. }),
  513. smalltalk.Transcript);
  514. smalltalk.addMethod(
  515. '_cr',
  516. smalltalk.method({
  517. selector: 'cr',
  518. fn: function (){
  519. var self=this;
  520. smalltalk.send(smalltalk.send(self['@textarea'], "_asJQuery", []), "_val_", [smalltalk.send(smalltalk.send(smalltalk.send(self['@textarea'], "_asJQuery", []), "_val", []), "__comma", [smalltalk.send((smalltalk.String || String), "_cr", [])])]);
  521. return self;}
  522. }),
  523. smalltalk.Transcript);
  524. smalltalk.addMethod(
  525. '_clear',
  526. smalltalk.method({
  527. selector: 'clear',
  528. fn: function (){
  529. var self=this;
  530. smalltalk.send(smalltalk.send(self['@textarea'], "_asJQuery", []), "_val_", [""]);
  531. return self;}
  532. }),
  533. smalltalk.Transcript);
  534. smalltalk.addMethod(
  535. '_renderBoxOn_',
  536. smalltalk.method({
  537. selector: 'renderBoxOn:',
  538. fn: function (html){
  539. var self=this;
  540. self['@textarea']=smalltalk.send(html, "_textarea", []);
  541. smalltalk.send(smalltalk.send(self['@textarea'], "_asJQuery", []), "_call_", ["tabby"]);
  542. (function($rec){smalltalk.send($rec, "_class_", ["jt_transcript"]);return smalltalk.send($rec, "_at_put_", ["spellcheck", "false"]);})(self['@textarea']);
  543. return self;}
  544. }),
  545. smalltalk.Transcript);
  546. smalltalk.addMethod(
  547. '_renderButtonsOn_',
  548. smalltalk.method({
  549. selector: 'renderButtonsOn:',
  550. fn: function (html){
  551. var self=this;
  552. (function($rec){smalltalk.send($rec, "_with_", ["Clear transcript"]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_clear", []);})]);})(smalltalk.send(html, "_button", []));
  553. return self;}
  554. }),
  555. smalltalk.Transcript);
  556. smalltalk.Transcript.klass.iVarNames = ['current'];
  557. smalltalk.addMethod(
  558. '_open',
  559. smalltalk.method({
  560. selector: 'open',
  561. fn: function (){
  562. var self=this;
  563. (function($rec){smalltalk.send($rec, "_open", []);return smalltalk.send($rec, "_selectTab_", [smalltalk.send(self, "_current", [])]);})(smalltalk.send((smalltalk.TabManager || TabManager), "_current", []));
  564. return self;}
  565. }),
  566. smalltalk.Transcript.klass);
  567. smalltalk.addMethod(
  568. '_new',
  569. smalltalk.method({
  570. selector: 'new',
  571. fn: function (){
  572. var self=this;
  573. smalltalk.send(self, "_shouldNotImplement", []);
  574. return self;}
  575. }),
  576. smalltalk.Transcript.klass);
  577. smalltalk.addMethod(
  578. '_current',
  579. smalltalk.method({
  580. selector: 'current',
  581. fn: function (){
  582. var self=this;
  583. return (($receiver = self['@current']) == nil || $receiver == undefined) ? (function(){return self['@current']=smalltalk.send(self, "_new", [], smalltalk.TabWidget.klass);})() : $receiver;
  584. return self;}
  585. }),
  586. smalltalk.Transcript.klass);
  587. smalltalk.addMethod(
  588. '_show_',
  589. smalltalk.method({
  590. selector: 'show:',
  591. fn: function (anObject){
  592. var self=this;
  593. smalltalk.send(smalltalk.send(self, "_current", []), "_show_", [anObject]);
  594. return self;}
  595. }),
  596. smalltalk.Transcript.klass);
  597. smalltalk.addMethod(
  598. '_cr',
  599. smalltalk.method({
  600. selector: 'cr',
  601. fn: function (){
  602. var self=this;
  603. smalltalk.send(smalltalk.send(self, "_current", []), "_show_", [smalltalk.send((smalltalk.String || String), "_cr", [])]);
  604. return self;}
  605. }),
  606. smalltalk.Transcript.klass);
  607. smalltalk.addMethod(
  608. '_clear',
  609. smalltalk.method({
  610. selector: 'clear',
  611. fn: function (){
  612. var self=this;
  613. smalltalk.send(smalltalk.send(self, "_current", []), "_clear", []);
  614. return self;}
  615. }),
  616. smalltalk.Transcript.klass);
  617. smalltalk.addClass('Browser', smalltalk.TabWidget, ['selectedPackage', 'selectedClass', 'selectedProtocol', 'selectedMethod', 'commitButton', 'packagesList', 'classesList', 'protocolsList', 'methodsList', 'sourceArea', 'tabsList', 'selectedTab', 'saveButton', 'classButtons', 'methodButtons', 'unsavedChanges', 'renameButton', 'deleteButton'], 'IDE');
  618. smalltalk.addMethod(
  619. '_label',
  620. smalltalk.method({
  621. selector: 'label',
  622. fn: function (){
  623. var self=this;
  624. return (($receiver = self['@selectedClass']) == nil || $receiver == undefined) ? (function(){return unescape("Browser%20%28nil%29");})() : (function(){return smalltalk.send("Browser: ", "__comma", [smalltalk.send(self['@selectedClass'], "_name", [])]);})();
  625. return self;}
  626. }),
  627. smalltalk.Browser);
  628. smalltalk.addMethod(
  629. '_packages',
  630. smalltalk.method({
  631. selector: 'packages',
  632. fn: function (){
  633. var self=this;
  634. var packages=nil;
  635. packages=smalltalk.send((smalltalk.Array || Array), "_new", []);
  636. smalltalk.send(smalltalk.send(smalltalk.send((smalltalk.Smalltalk || Smalltalk), "_current", []), "_classes", []), "_do_", [(function(each){return (($receiver = smalltalk.send(packages, "_includes_", [smalltalk.send(each, "_category", [])])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return smalltalk.send(packages, "_add_", [smalltalk.send(each, "_category", [])]);})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return smalltalk.send(packages, "_add_", [smalltalk.send(each, "_category", [])]);})]);})]);
  637. return smalltalk.send(packages, "_sort", []);
  638. return self;}
  639. }),
  640. smalltalk.Browser);
  641. smalltalk.addMethod(
  642. '_classes',
  643. smalltalk.method({
  644. selector: 'classes',
  645. fn: function (){
  646. var self=this;
  647. return smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send((smalltalk.Smalltalk || Smalltalk), "_current", []), "_classes", []), "_select_", [(function(each){return smalltalk.send(smalltalk.send(each, "_category", []), "__eq", [self['@selectedPackage']]);})]), "_sort_", [(function(a, b){return (($receiver = smalltalk.send(a, "_name", [])).klass === smalltalk.Number) ? $receiver <smalltalk.send(b, "_name", []) : smalltalk.send($receiver, "__lt", [smalltalk.send(b, "_name", [])]);})]);
  648. return self;}
  649. }),
  650. smalltalk.Browser);
  651. smalltalk.addMethod(
  652. '_protocols',
  653. smalltalk.method({
  654. selector: 'protocols',
  655. fn: function (){
  656. var self=this;
  657. try{var klass=nil;
  658. (($receiver = self['@selectedClass']) != nil && $receiver != undefined) ? (function(){(($receiver = smalltalk.send(self['@selectedTab'], "__eq", ["comment"])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return (function(){throw({name: 'stReturn', selector: '_protocols', fn: function(){return []}})})();})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return (function(){throw({name: 'stReturn', selector: '_protocols', fn: function(){return []}})})();})]);klass=(($receiver = smalltalk.send(self['@selectedTab'], "__eq", ["instance"])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return self['@selectedClass'];})() : (function(){return smalltalk.send(self['@selectedClass'], "_class", []);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return self['@selectedClass'];}), (function(){return smalltalk.send(self['@selectedClass'], "_class", []);})]);(($receiver = smalltalk.send(smalltalk.send(klass, "_methodDictionary", []), "_isEmpty", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return (function(){throw({name: 'stReturn', selector: '_protocols', fn: function(){return smalltalk.send((smalltalk.Array || Array), "_with_", ["not yet classified"])}})})();})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return (function(){throw({name: 'stReturn', selector: '_protocols', fn: function(){return smalltalk.send((smalltalk.Array || Array), "_with_", ["not yet classified"])}})})();})]);return (function(){throw({name: 'stReturn', selector: '_protocols', fn: function(){return smalltalk.send(klass, "_protocols", [])}})})();})() : nil;
  659. (function(){throw({name: 'stReturn', selector: '_protocols', fn: function(){return smalltalk.send((smalltalk.Array || Array), "_new", [])}})})();
  660. return self;
  661. } catch(e) {if(e.name === 'stReturn' && e.selector === '_protocols'){return e.fn()} throw(e)}}
  662. }),
  663. smalltalk.Browser);
  664. smalltalk.addMethod(
  665. '_methods',
  666. smalltalk.method({
  667. selector: 'methods',
  668. fn: function (){
  669. var self=this;
  670. try{var klass=nil;
  671. (($receiver = smalltalk.send(self['@selectedTab'], "__eq", ["comment"])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return (function(){throw({name: 'stReturn', selector: '_methods', fn: function(){return []}})})();})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return (function(){throw({name: 'stReturn', selector: '_methods', fn: function(){return []}})})();})]);
  672. (($receiver = self['@selectedClass']) != nil && $receiver != undefined) ? (function(){return klass=(($receiver = smalltalk.send(self['@selectedTab'], "__eq", ["instance"])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return self['@selectedClass'];})() : (function(){return smalltalk.send(self['@selectedClass'], "_class", []);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return self['@selectedClass'];}), (function(){return smalltalk.send(self['@selectedClass'], "_class", []);})]);})() : nil;
  673. (function(){throw({name: 'stReturn', selector: '_methods', fn: function(){return smalltalk.send((($receiver = self['@selectedProtocol']) == nil || $receiver == undefined) ? (function(){return (($receiver = klass) == nil || $receiver == undefined) ? (function(){return [];})() : (function(){return smalltalk.send(smalltalk.send(klass, "_methodDictionary", []), "_values", []);})();})() : (function(){return smalltalk.send(smalltalk.send(smalltalk.send(klass, "_methodDictionary", []), "_values", []), "_select_", [(function(each){return smalltalk.send(smalltalk.send(each, "_category", []), "__eq", [self['@selectedProtocol']]);})]);})(), "_sort_", [(function(a, b){return (($receiver = smalltalk.send(a, "_selector", [])).klass === smalltalk.Number) ? $receiver <smalltalk.send(b, "_selector", []) : smalltalk.send($receiver, "__lt", [smalltalk.send(b, "_selector", [])]);})])}})})();
  674. return self;
  675. } catch(e) {if(e.name === 'stReturn' && e.selector === '_methods'){return e.fn()} throw(e)}}
  676. }),
  677. smalltalk.Browser);
  678. smalltalk.addMethod(
  679. '_source',
  680. smalltalk.method({
  681. selector: 'source',
  682. fn: function (){
  683. var self=this;
  684. try{(($receiver = smalltalk.send(self['@selectedTab'], "__eq", ["comment"])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return (function(){throw({name: 'stReturn', selector: '_source', fn: function(){return (($receiver = smalltalk.send(smalltalk.send(self['@selectedProtocol'], "_notNil", []), "_or_", [(function(){return smalltalk.send(self['@selectedMethod'], "_notNil", []);})])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return smalltalk.send(self, "_declarationSource", []);})() : (function(){return smalltalk.send(self, "_methodSource", []);})()) : smalltalk.send($receiver, "_ifFalse_ifTrue_", [(function(){return smalltalk.send(self, "_declarationSource", []);}), (function(){return smalltalk.send(self, "_methodSource", []);})])}})})();})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return (function(){throw({name: 'stReturn', selector: '_source', fn: function(){return (($receiver = smalltalk.send(smalltalk.send(self['@selectedProtocol'], "_notNil", []), "_or_", [(function(){return smalltalk.send(self['@selectedMethod'], "_notNil", []);})])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return smalltalk.send(self, "_declarationSource", []);})() : (function(){return smalltalk.send(self, "_methodSource", []);})()) : smalltalk.send($receiver, "_ifFalse_ifTrue_", [(function(){return smalltalk.send(self, "_declarationSource", []);}), (function(){return smalltalk.send(self, "_methodSource", []);})])}})})();})]);
  685. (function(){throw({name: 'stReturn', selector: '_source', fn: function(){return (($receiver = self['@selectedClass']) == nil || $receiver == undefined) ? (function(){return "";})() : (function(){return smalltalk.send(self, "_classCommentSource", []);})()}})})();
  686. return self;
  687. } catch(e) {if(e.name === 'stReturn' && e.selector === '_source'){return e.fn()} throw(e)}}
  688. }),
  689. smalltalk.Browser);
  690. smalltalk.addMethod(
  691. '_methodSource',
  692. smalltalk.method({
  693. selector: 'methodSource',
  694. fn: function (){
  695. var self=this;
  696. return (($receiver = self['@selectedMethod']) == nil || $receiver == undefined) ? (function(){return smalltalk.send(self, "_dummyMethodSource", []);})() : (function(){return smalltalk.send(self['@selectedMethod'], "_source", []);})();
  697. return self;}
  698. }),
  699. smalltalk.Browser);
  700. smalltalk.addMethod(
  701. '_dummyMethodSource',
  702. smalltalk.method({
  703. selector: 'dummyMethodSource',
  704. fn: function (){
  705. var self=this;
  706. return unescape("messageSelectorAndArgumentNames%0A%09%22comment%20stating%20purpose%20of%20message%22%0A%0A%09%7C%20temporary%20variable%20names%20%7C%0A%09statements");
  707. return self;}
  708. }),
  709. smalltalk.Browser);
  710. smalltalk.addMethod(
  711. '_declarationSource',
  712. smalltalk.method({
  713. selector: 'declarationSource',
  714. fn: function (){
  715. var self=this;
  716. return (($receiver = smalltalk.send(self['@selectedTab'], "__eq", ["instance"])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(self, "_classDeclarationSource", []);})() : (function(){return smalltalk.send(self, "_metaclassDeclarationSource", []);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return smalltalk.send(self, "_classDeclarationSource", []);}), (function(){return smalltalk.send(self, "_metaclassDeclarationSource", []);})]);
  717. return self;}
  718. }),
  719. smalltalk.Browser);
  720. smalltalk.addMethod(
  721. '_classDeclarationSource',
  722. smalltalk.method({
  723. selector: 'classDeclarationSource',
  724. fn: function (){
  725. var self=this;
  726. var stream=nil;
  727. stream=smalltalk.send("", "_writeStream", []);
  728. (($receiver = self['@selectedClass']) != nil && $receiver != undefined) ? (function(){(function($rec){smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(smalltalk.send(self['@selectedClass'], "_superclass", []), "_asString", [])]);smalltalk.send($rec, "_nextPutAll_", [unescape("%20subclass%3A%20%23")]);smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(self['@selectedClass'], "_name", [])]);smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(smalltalk.send((smalltalk.String || String), "_lf", []), "__comma", [smalltalk.send((smalltalk.String || String), "_tab", [])])]);return smalltalk.send($rec, "_nextPutAll_", [unescape("instanceVariableNames%3A%20%27")]);})(stream);smalltalk.send(smalltalk.send(self['@selectedClass'], "_instanceVariableNames", []), "_do_separatedBy_", [(function(each){return smalltalk.send(stream, "_nextPutAll_", [each]);}), (function(){return smalltalk.send(stream, "_nextPutAll_", [" "]);})]);return (function($rec){smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(smalltalk.send(unescape("%27"), "__comma", [smalltalk.send((smalltalk.String || String), "_lf", [])]), "__comma", [smalltalk.send((smalltalk.String || String), "_tab", [])])]);smalltalk.send($rec, "_nextPutAll_", [unescape("package%3A%20%27")]);smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(self['@selectedClass'], "_category", [])]);return smalltalk.send($rec, "_nextPutAll_", [unescape("%27")]);})(stream);})() : nil;
  729. return smalltalk.send(stream, "_contents", []);
  730. return self;}
  731. }),
  732. smalltalk.Browser);
  733. smalltalk.addMethod(
  734. '_metaclassDeclarationSource',
  735. smalltalk.method({
  736. selector: 'metaclassDeclarationSource',
  737. fn: function (){
  738. var self=this;
  739. var stream=nil;
  740. stream=smalltalk.send("", "_writeStream", []);
  741. (($receiver = self['@selectedClass']) != nil && $receiver != undefined) ? (function(){(function($rec){smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(self['@selectedClass'], "_asString", [])]);smalltalk.send($rec, "_nextPutAll_", [" class "]);return smalltalk.send($rec, "_nextPutAll_", [unescape("instanceVariableNames%3A%20%27")]);})(stream);smalltalk.send(smalltalk.send(smalltalk.send(self['@selectedClass'], "_class", []), "_instanceVariableNames", []), "_do_separatedBy_", [(function(each){return smalltalk.send(stream, "_nextPutAll_", [each]);}), (function(){return smalltalk.send(stream, "_nextPutAll_", [" "]);})]);return smalltalk.send(stream, "_nextPutAll_", [unescape("%27")]);})() : nil;
  742. return smalltalk.send(stream, "_contents", []);
  743. return self;}
  744. }),
  745. smalltalk.Browser);
  746. smalltalk.addMethod(
  747. '_classCommentSource',
  748. smalltalk.method({
  749. selector: 'classCommentSource',
  750. fn: function (){
  751. var self=this;
  752. return smalltalk.send(self['@selectedClass'], "_comment", []);
  753. return self;}
  754. }),
  755. smalltalk.Browser);
  756. smalltalk.addMethod(
  757. '_selectedClass',
  758. smalltalk.method({
  759. selector: 'selectedClass',
  760. fn: function (){
  761. var self=this;
  762. return self['@selectedClass'];
  763. return self;}
  764. }),
  765. smalltalk.Browser);
  766. smalltalk.addMethod(
  767. '_disableSaveButton',
  768. smalltalk.method({
  769. selector: 'disableSaveButton',
  770. fn: function (){
  771. var self=this;
  772. (($receiver = self['@saveButton']) != nil && $receiver != undefined) ? (function(){return smalltalk.send(self['@saveButton'], "_at_put_", ["disabled", true]);})() : nil;
  773. self['@unsavedChanges']=false;
  774. return self;}
  775. }),
  776. smalltalk.Browser);
  777. smalltalk.addMethod(
  778. '_hideClassButtons',
  779. smalltalk.method({
  780. selector: 'hideClassButtons',
  781. fn: function (){
  782. var self=this;
  783. smalltalk.send(smalltalk.send(self['@classButtons'], "_asJQuery", []), "_hide", []);
  784. return self;}
  785. }),
  786. smalltalk.Browser);
  787. smalltalk.addMethod(
  788. '_showClassButtons',
  789. smalltalk.method({
  790. selector: 'showClassButtons',
  791. fn: function (){
  792. var self=this;
  793. smalltalk.send(smalltalk.send(self['@classButtons'], "_asJQuery", []), "_show", []);
  794. return self;}
  795. }),
  796. smalltalk.Browser);
  797. smalltalk.addMethod(
  798. '_hideMethodButtons',
  799. smalltalk.method({
  800. selector: 'hideMethodButtons',
  801. fn: function (){
  802. var self=this;
  803. smalltalk.send(smalltalk.send(self['@methodButtons'], "_asJQuery", []), "_hide", []);
  804. return self;}
  805. }),
  806. smalltalk.Browser);
  807. smalltalk.addMethod(
  808. '_showMethodButtons',
  809. smalltalk.method({
  810. selector: 'showMethodButtons',
  811. fn: function (){
  812. var self=this;
  813. smalltalk.send(smalltalk.send(self['@methodButtons'], "_asJQuery", []), "_show", []);
  814. return self;}
  815. }),
  816. smalltalk.Browser);
  817. smalltalk.addMethod(
  818. '_compile',
  819. smalltalk.method({
  820. selector: 'compile',
  821. fn: function (){
  822. var self=this;
  823. smalltalk.send(self, "_disableSaveButton", []);
  824. (($receiver = smalltalk.send(self['@selectedTab'], "__eq", ["comment"])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return (($receiver = self['@selectedClass']) != nil && $receiver != undefined) ? (function(){return smalltalk.send(self, "_compileClassComment", []);})() : nil;})() : (function(){return (($receiver = smalltalk.send(smalltalk.send(self['@selectedProtocol'], "_notNil", []), "_or_", [(function(){return smalltalk.send(self['@selectedMethod'], "_notNil", []);})])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return smalltalk.send(self, "_compileDefinition", []);})() : (function(){return smalltalk.send(self, "_compileMethodDefinition", []);})()) : smalltalk.send($receiver, "_ifFalse_ifTrue_", [(function(){return smalltalk.send(self, "_compileDefinition", []);}), (function(){return smalltalk.send(self, "_compileMethodDefinition", []);})]);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return (($receiver = self['@selectedClass']) != nil && $receiver != undefined) ? (function(){return smalltalk.send(self, "_compileClassComment", []);})() : nil;}), (function(){return (($receiver = smalltalk.send(smalltalk.send(self['@selectedProtocol'], "_notNil", []), "_or_", [(function(){return smalltalk.send(self['@selectedMethod'], "_notNil", []);})])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return smalltalk.send(self, "_compileDefinition", []);})() : (function(){return smalltalk.send(self, "_compileMethodDefinition", []);})()) : smalltalk.send($receiver, "_ifFalse_ifTrue_", [(function(){return smalltalk.send(self, "_compileDefinition", []);}), (function(){return smalltalk.send(self, "_compileMethodDefinition", []);})]);})]);
  825. return self;}
  826. }),
  827. smalltalk.Browser);
  828. smalltalk.addMethod(
  829. '_compileClassComment',
  830. smalltalk.method({
  831. selector: 'compileClassComment',
  832. fn: function (){
  833. var self=this;
  834. smalltalk.send(self['@selectedClass'], "_comment_", [smalltalk.send(self['@sourceArea'], "_val", [])]);
  835. return self;}
  836. }),
  837. smalltalk.Browser);
  838. smalltalk.addMethod(
  839. '_compileMethodDefinition',
  840. smalltalk.method({
  841. selector: 'compileMethodDefinition',
  842. fn: function (){
  843. var self=this;
  844. (($receiver = smalltalk.send(self['@selectedTab'], "__eq", ["instance"])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(self, "_compileMethodDefinitionFor_", [self['@selectedClass']]);})() : (function(){return smalltalk.send(self, "_compileMethodDefinitionFor_", [smalltalk.send(self['@selectedClass'], "_class", [])]);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return smalltalk.send(self, "_compileMethodDefinitionFor_", [self['@selectedClass']]);}), (function(){return smalltalk.send(self, "_compileMethodDefinitionFor_", [smalltalk.send(self['@selectedClass'], "_class", [])]);})]);
  845. return self;}
  846. }),
  847. smalltalk.Browser);
  848. smalltalk.addMethod(
  849. '_compileMethodDefinitionFor_',
  850. smalltalk.method({
  851. selector: 'compileMethodDefinitionFor:',
  852. fn: function (aClass){
  853. var self=this;
  854. try{var compiler=nil;
  855. var method=nil;
  856. var source=nil;
  857. var node=nil;
  858. source=smalltalk.send(self['@sourceArea'], "_val", []);
  859. (($receiver = self['@selectedProtocol']) == nil || $receiver == undefined) ? (function(){return self['@selectedProtocol']=smalltalk.send(self['@selectedMethod'], "_category", []);})() : $receiver;
  860. compiler=smalltalk.send((smalltalk.Compiler || Compiler), "_new", []);
  861. smalltalk.send(compiler, "_source_", [source]);
  862. node=smalltalk.send(compiler, "_parse_", [source]);
  863. (($receiver = smalltalk.send(node, "_isParseFailure", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return (function(){throw({name: 'stReturn', selector: '_compileMethodDefinitionFor_', fn: function(){return smalltalk.send(self, "_alert_", [smalltalk.send(smalltalk.send(smalltalk.send("PARSE ERROR: ", "__comma", [smalltalk.send(node, "_reason", [])]), "__comma", [unescape("%2C%20position%3A%20")]), "__comma", [smalltalk.send(smalltalk.send(node, "_position", []), "_asString", [])])])}})})();})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return (function(){throw({name: 'stReturn', selector: '_compileMethodDefinitionFor_', fn: function(){return smalltalk.send(self, "_alert_", [smalltalk.send(smalltalk.send(smalltalk.send("PARSE ERROR: ", "__comma", [smalltalk.send(node, "_reason", [])]), "__comma", [unescape("%2C%20position%3A%20")]), "__comma", [smalltalk.send(smalltalk.send(node, "_position", []), "_asString", [])])])}})})();})]);
  864. smalltalk.send(compiler, "_currentClass_", [aClass]);
  865. method=smalltalk.send(compiler, "_eval_", [smalltalk.send(compiler, "_compileNode_", [node])]);
  866. smalltalk.send(method, "_category_", [self['@selectedProtocol']]);
  867. smalltalk.send(smalltalk.send(compiler, "_unknownVariables", []), "_do_", [(function(each){return (($receiver = smalltalk.send(self, "_confirm_", [smalltalk.send(smalltalk.send(unescape("Declare%20%27"), "__comma", [each]), "__comma", [unescape("%27%20as%20instance%20variable%3F")])])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(self, "_addInstanceVariableNamed_toClass_", [each, aClass]);return (function(){throw({name: 'stReturn', selector: '_compileMethodDefinitionFor_', fn: function(){return smalltalk.send(self, "_compileMethodDefinitionFor_", [aClass])}})})();})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(self, "_addInstanceVariableNamed_toClass_", [each, aClass]);return (function(){throw({name: 'stReturn', selector: '_compileMethodDefinitionFor_', fn: function(){return smalltalk.send(self, "_compileMethodDefinitionFor_", [aClass])}})})();})]);})]);
  868. smalltalk.send(aClass, "_addCompiledMethod_", [method]);
  869. smalltalk.send(compiler, "_setupClass_", [aClass]);
  870. smalltalk.send(self, "_updateMethodsList", []);
  871. smalltalk.send(self, "_selectMethod_", [method]);
  872. return self;
  873. } catch(e) {if(e.name === 'stReturn' && e.selector === '_compileMethodDefinitionFor_'){return e.fn()} throw(e)}}
  874. }),
  875. smalltalk.Browser);
  876. smalltalk.addMethod(
  877. '_compileDefinition',
  878. smalltalk.method({
  879. selector: 'compileDefinition',
  880. fn: function (){
  881. var self=this;
  882. var newClass=nil;
  883. newClass=smalltalk.send(smalltalk.send((smalltalk.Compiler || Compiler), "_new", []), "_loadExpression_", [smalltalk.send(self['@sourceArea'], "_val", [])]);
  884. (function($rec){smalltalk.send($rec, "_resetClassesList", []);smalltalk.send($rec, "_updateCategoriesList", []);return smalltalk.send($rec, "_updateClassesList", []);})(self);
  885. return self;}
  886. }),
  887. smalltalk.Browser);
  888. smalltalk.addMethod(
  889. '_cancelChanges',
  890. smalltalk.method({
  891. selector: 'cancelChanges',
  892. fn: function (){
  893. var self=this;
  894. return (($receiver = self['@unsavedChanges']).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(self, "_confirm_", [unescape("Cancel%20changes%3F")]);})() : (function(){return true;})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return smalltalk.send(self, "_confirm_", [unescape("Cancel%20changes%3F")]);}), (function(){return true;})]);
  895. return self;}
  896. }),
  897. smalltalk.Browser);
  898. smalltalk.addMethod(
  899. '_removeClass',
  900. smalltalk.method({
  901. selector: 'removeClass',
  902. fn: function (){
  903. var self=this;
  904. (($receiver = smalltalk.send(self, "_confirm_", [smalltalk.send(smalltalk.send("Do you really want to remove ", "__comma", [smalltalk.send(self['@selectedClass'], "_name", [])]), "__comma", [unescape("%3F")])])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(smalltalk.send((smalltalk.Smalltalk || Smalltalk), "_current", []), "_removeClass_", [self['@selectedClass']]);smalltalk.send(self, "_resetClassesList", []);return smalltalk.send(self, "_selectClass_", [nil]);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(smalltalk.send((smalltalk.Smalltalk || Smalltalk), "_current", []), "_removeClass_", [self['@selectedClass']]);smalltalk.send(self, "_resetClassesList", []);return smalltalk.send(self, "_selectClass_", [nil]);})]);
  905. return self;}
  906. }),
  907. smalltalk.Browser);
  908. smalltalk.addMethod(
  909. '_removeMethod',
  910. smalltalk.method({
  911. selector: 'removeMethod',
  912. fn: function (){
  913. var self=this;
  914. (($receiver = smalltalk.send(self, "_cancelChanges", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return (($receiver = smalltalk.send(self, "_confirm_", [smalltalk.send(smalltalk.send(unescape("Do%20you%20really%20want%20to%20remove%20%23"), "__comma", [smalltalk.send(self['@selectedMethod'], "_selector", [])]), "__comma", [unescape("%3F")])])).klass === smalltalk.Boolean) ? ($receiver ? (function(){(($receiver = smalltalk.send(self['@selectedTab'], "__eq", ["instance"])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(self['@selectedClass'], "_removeCompiledMethod_", [self['@selectedMethod']]);})() : (function(){return smalltalk.send(smalltalk.send(self['@selectedClass'], "_class", []), "_removeCompiledMethod_", [self['@selectedMethod']]);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return smalltalk.send(self['@selectedClass'], "_removeCompiledMethod_", [self['@selectedMethod']]);}), (function(){return smalltalk.send(smalltalk.send(self['@selectedClass'], "_class", []), "_removeCompiledMethod_", [self['@selectedMethod']]);})]);return smalltalk.send(self, "_selectMethod_", [nil]);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){(($receiver = smalltalk.send(self['@selectedTab'], "__eq", ["instance"])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(self['@selectedClass'], "_removeCompiledMethod_", [self['@selectedMethod']]);})() : (function(){return smalltalk.send(smalltalk.send(self['@selectedClass'], "_class", []), "_removeCompiledMethod_", [self['@selectedMethod']]);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return smalltalk.send(self['@selectedClass'], "_removeCompiledMethod_", [self['@selectedMethod']]);}), (function(){return smalltalk.send(smalltalk.send(self['@selectedClass'], "_class", []), "_removeCompiledMethod_", [self['@selectedMethod']]);})]);return smalltalk.send(self, "_selectMethod_", [nil]);})]);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return (($receiver = smalltalk.send(self, "_confirm_", [smalltalk.send(smalltalk.send(unescape("Do%20you%20really%20want%20to%20remove%20%23"), "__comma", [smalltalk.send(self['@selectedMethod'], "_selector", [])]), "__comma", [unescape("%3F")])])).klass === smalltalk.Boolean) ? ($receiver ? (function(){(($receiver = smalltalk.send(self['@selectedTab'], "__eq", ["instance"])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(self['@selectedClass'], "_removeCompiledMethod_", [self['@selectedMethod']]);})() : (function(){return smalltalk.send(smalltalk.send(self['@selectedClass'], "_class", []), "_removeCompiledMethod_", [self['@selectedMethod']]);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return smalltalk.send(self['@selectedClass'], "_removeCompiledMethod_", [self['@selectedMethod']]);}), (function(){return smalltalk.send(smalltalk.send(self['@selectedClass'], "_class", []), "_removeCompiledMethod_", [self['@selectedMethod']]);})]);return smalltalk.send(self, "_selectMethod_", [nil]);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){(($receiver = smalltalk.send(self['@selectedTab'], "__eq", ["instance"])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(self['@selectedClass'], "_removeCompiledMethod_", [self['@selectedMethod']]);})() : (function(){return smalltalk.send(smalltalk.send(self['@selectedClass'], "_class", []), "_removeCompiledMethod_", [self['@selectedMethod']]);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return smalltalk.send(self['@selectedClass'], "_removeCompiledMethod_", [self['@selectedMethod']]);}), (function(){return smalltalk.send(smalltalk.send(self['@selectedClass'], "_class", []), "_removeCompiledMethod_", [self['@selectedMethod']]);})]);return smalltalk.send(self, "_selectMethod_", [nil]);})]);})]);
  915. return self;}
  916. }),
  917. smalltalk.Browser);
  918. smalltalk.addMethod(
  919. '_setMethodProtocol_',
  920. smalltalk.method({
  921. selector: 'setMethodProtocol:',
  922. fn: function (aString){
  923. var self=this;
  924. (($receiver = smalltalk.send(self, "_cancelChanges", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return (($receiver = smalltalk.send(smalltalk.send(self, "_protocols", []), "_includes_", [aString])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return smalltalk.send(self, "_addNewProtocol", []);})() : (function(){smalltalk.send(self['@selectedMethod'], "_category_", [aString]);self['@selectedProtocol']=aString;self['@selectedMethod']=self['@selectedMethod'];return (function($rec){smalltalk.send($rec, "_updateProtocolsList", []);smalltalk.send($rec, "_updateMethodsList", []);return smalltalk.send($rec, "_updateSourceAndButtons", []);})(self);})()) : smalltalk.send($receiver, "_ifFalse_ifTrue_", [(function(){return smalltalk.send(self, "_addNewProtocol", []);}), (function(){smalltalk.send(self['@selectedMethod'], "_category_", [aString]);self['@selectedProtocol']=aString;self['@selectedMethod']=self['@selectedMethod'];return (function($rec){smalltalk.send($rec, "_updateProtocolsList", []);smalltalk.send($rec, "_updateMethodsList", []);return smalltalk.send($rec, "_updateSourceAndButtons", []);})(self);})]);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return (($receiver = smalltalk.send(smalltalk.send(self, "_protocols", []), "_includes_", [aString])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return smalltalk.send(self, "_addNewProtocol", []);})() : (function(){smalltalk.send(self['@selectedMethod'], "_category_", [aString]);self['@selectedProtocol']=aString;self['@selectedMethod']=self['@selectedMethod'];return (function($rec){smalltalk.send($rec, "_updateProtocolsList", []);smalltalk.send($rec, "_updateMethodsList", []);return smalltalk.send($rec, "_updateSourceAndButtons", []);})(self);})()) : smalltalk.send($receiver, "_ifFalse_ifTrue_", [(function(){return smalltalk.send(self, "_addNewProtocol", []);}), (function(){smalltalk.send(self['@selectedMethod'], "_category_", [aString]);self['@selectedProtocol']=aString;self['@selectedMethod']=self['@selectedMethod'];return (function($rec){smalltalk.send($rec, "_updateProtocolsList", []);smalltalk.send($rec, "_updateMethodsList", []);return smalltalk.send($rec, "_updateSourceAndButtons", []);})(self);})]);})]);
  925. return self;}
  926. }),
  927. smalltalk.Browser);
  928. smalltalk.addMethod(
  929. '_addNewProtocol',
  930. smalltalk.method({
  931. selector: 'addNewProtocol',
  932. fn: function (){
  933. var self=this;
  934. var newProtocol=nil;
  935. newProtocol=smalltalk.send(self, "_prompt_", ["New method protocol"]);
  936. (($receiver = smalltalk.send(smalltalk.send(newProtocol, "_notNil", []), "_and_", [(function(){return smalltalk.send(newProtocol, "_notEmpty", []);})])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(self['@selectedMethod'], "_category_", [newProtocol]);return smalltalk.send(self, "_setMethodProtocol_", [newProtocol]);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(self['@selectedMethod'], "_category_", [newProtocol]);return smalltalk.send(self, "_setMethodProtocol_", [newProtocol]);})]);
  937. return self;}
  938. }),
  939. smalltalk.Browser);
  940. smalltalk.addMethod(
  941. '_selectCategory_',
  942. smalltalk.method({
  943. selector: 'selectCategory:',
  944. fn: function (aCategory){
  945. var self=this;
  946. (($receiver = smalltalk.send(self, "_cancelChanges", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){self['@selectedPackage']=aCategory;self['@selectedClass']=self['@selectedProtocol']=self['@selectedMethod']=nil;smalltalk.send(self, "_resetClassesList", []);return (function($rec){smalltalk.send($rec, "_updateCategoriesList", []);smalltalk.send($rec, "_updateClassesList", []);smalltalk.send($rec, "_updateProtocolsList", []);smalltalk.send($rec, "_updateMethodsList", []);return smalltalk.send($rec, "_updateSourceAndButtons", []);})(self);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){self['@selectedPackage']=aCategory;self['@selectedClass']=self['@selectedProtocol']=self['@selectedMethod']=nil;smalltalk.send(self, "_resetClassesList", []);return (function($rec){smalltalk.send($rec, "_updateCategoriesList", []);smalltalk.send($rec, "_updateClassesList", []);smalltalk.send($rec, "_updateProtocolsList", []);smalltalk.send($rec, "_updateMethodsList", []);return smalltalk.send($rec, "_updateSourceAndButtons", []);})(self);})]);
  947. return self;}
  948. }),
  949. smalltalk.Browser);
  950. smalltalk.addMethod(
  951. '_selectClass_',
  952. smalltalk.method({
  953. selector: 'selectClass:',
  954. fn: function (aClass){
  955. var self=this;
  956. (($receiver = smalltalk.send(self, "_cancelChanges", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){self['@selectedClass']=aClass;self['@selectedProtocol']=self['@selectedMethod']=nil;return (function($rec){smalltalk.send($rec, "_updateClassesList", []);smalltalk.send($rec, "_updateProtocolsList", []);smalltalk.send($rec, "_updateMethodsList", []);return smalltalk.send($rec, "_updateSourceAndButtons", []);})(self);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){self['@selectedClass']=aClass;self['@selectedProtocol']=self['@selectedMethod']=nil;return (function($rec){smalltalk.send($rec, "_updateClassesList", []);smalltalk.send($rec, "_updateProtocolsList", []);smalltalk.send($rec, "_updateMethodsList", []);return smalltalk.send($rec, "_updateSourceAndButtons", []);})(self);})]);
  957. return self;}
  958. }),
  959. smalltalk.Browser);
  960. smalltalk.addMethod(
  961. '_selectProtocol_',
  962. smalltalk.method({
  963. selector: 'selectProtocol:',
  964. fn: function (aString){
  965. var self=this;
  966. (($receiver = smalltalk.send(self, "_cancelChanges", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){self['@selectedProtocol']=aString;self['@selectedMethod']=nil;return (function($rec){smalltalk.send($rec, "_updateProtocolsList", []);smalltalk.send($rec, "_updateMethodsList", []);return smalltalk.send($rec, "_updateSourceAndButtons", []);})(self);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){self['@selectedProtocol']=aString;self['@selectedMethod']=nil;return (function($rec){smalltalk.send($rec, "_updateProtocolsList", []);smalltalk.send($rec, "_updateMethodsList", []);return smalltalk.send($rec, "_updateSourceAndButtons", []);})(self);})]);
  967. return self;}
  968. }),
  969. smalltalk.Browser);
  970. smalltalk.addMethod(
  971. '_selectMethod_',
  972. smalltalk.method({
  973. selector: 'selectMethod:',
  974. fn: function (aMethod){
  975. var self=this;
  976. (($receiver = smalltalk.send(self, "_cancelChanges", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){self['@selectedMethod']=aMethod;return (function($rec){smalltalk.send($rec, "_updateProtocolsList", []);smalltalk.send($rec, "_updateMethodsList", []);return smalltalk.send($rec, "_updateSourceAndButtons", []);})(self);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){self['@selectedMethod']=aMethod;return (function($rec){smalltalk.send($rec, "_updateProtocolsList", []);smalltalk.send($rec, "_updateMethodsList", []);return smalltalk.send($rec, "_updateSourceAndButtons", []);})(self);})]);
  977. return self;}
  978. }),
  979. smalltalk.Browser);
  980. smalltalk.addMethod(
  981. '_selectTab_',
  982. smalltalk.method({
  983. selector: 'selectTab:',
  984. fn: function (aString){
  985. var self=this;
  986. (($receiver = smalltalk.send(self, "_cancelChanges", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){self['@selectedTab']=aString;smalltalk.send(self, "_selectProtocol_", [nil]);return smalltalk.send(self, "_updateTabsList", []);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){self['@selectedTab']=aString;smalltalk.send(self, "_selectProtocol_", [nil]);return smalltalk.send(self, "_updateTabsList", []);})]);
  987. return self;}
  988. }),
  989. smalltalk.Browser);
  990. smalltalk.addMethod(
  991. '_renameClass',
  992. smalltalk.method({
  993. selector: 'renameClass',
  994. fn: function (){
  995. var self=this;
  996. var newName=nil;
  997. newName=smalltalk.send(self, "_prompt_", [smalltalk.send("Rename class ", "__comma", [smalltalk.send(self['@selectedClass'], "_name", [])])]);
  998. (($receiver = smalltalk.send(newName, "_notEmpty", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(self['@selectedClass'], "_rename_", [newName]);return (function($rec){smalltalk.send($rec, "_updateClassesList", []);return smalltalk.send($rec, "_updateSourceAndButtons", []);})(self);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(self['@selectedClass'], "_rename_", [newName]);return (function($rec){smalltalk.send($rec, "_updateClassesList", []);return smalltalk.send($rec, "_updateSourceAndButtons", []);})(self);})]);
  999. return self;}
  1000. }),
  1001. smalltalk.Browser);
  1002. smalltalk.addMethod(
  1003. '_addInstanceVariableNamed_toClass_',
  1004. smalltalk.method({
  1005. selector: 'addInstanceVariableNamed:toClass:',
  1006. fn: function (aString, aClass){
  1007. var self=this;
  1008. smalltalk.send(smalltalk.send((smalltalk.ClassBuilder || ClassBuilder), "_new", []), "_addSubclassOf_named_instanceVariableNames_package_", [smalltalk.send(aClass, "_superclass", []), smalltalk.send(aClass, "_name", []), (function($rec){smalltalk.send($rec, "_add_", [aString]);return smalltalk.send($rec, "_yourself", []);})(smalltalk.send(smalltalk.send(aClass, "_instanceVariableNames", []), "_copy", [])), smalltalk.send(smalltalk.send(aClass, "_package", []), "_name", [])]);
  1009. return self;}
  1010. }),
  1011. smalltalk.Browser);
  1012. smalltalk.addMethod(
  1013. '_searchReferencesOf_',
  1014. smalltalk.method({
  1015. selector: 'searchReferencesOf:',
  1016. fn: function (aString){
  1017. var self=this;
  1018. smalltalk.send((smalltalk.ReferencesBrowser || ReferencesBrowser), "_search_", [aString]);
  1019. return self;}
  1020. }),
  1021. smalltalk.Browser);
  1022. smalltalk.addMethod(
  1023. '_searchClassReferences',
  1024. smalltalk.method({
  1025. selector: 'searchClassReferences',
  1026. fn: function (){
  1027. var self=this;
  1028. smalltalk.send((smalltalk.ReferencesBrowser || ReferencesBrowser), "_search_", [smalltalk.send(self['@selectedClass'], "_name", [])]);
  1029. return self;}
  1030. }),
  1031. smalltalk.Browser);
  1032. smalltalk.addMethod(
  1033. '_search_',
  1034. smalltalk.method({
  1035. selector: 'search:',
  1036. fn: function (aString){
  1037. var self=this;
  1038. (($receiver = smalltalk.send(self, "_cancelChanges", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){var searchedClass=nil;
  1039. searchedClass=smalltalk.send(smalltalk.send((smalltalk.Smalltalk || Smalltalk), "_current", []), "_at_", [aString]);return (($receiver = smalltalk.send(searchedClass, "_isClass", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(smalltalk.send(self, "_class", []), "_openOn_", [searchedClass]);})() : (function(){return smalltalk.send(self, "_searchReferencesOf_", [aString]);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return smalltalk.send(smalltalk.send(self, "_class", []), "_openOn_", [searchedClass]);}), (function(){return smalltalk.send(self, "_searchReferencesOf_", [aString]);})]);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){var searchedClass=nil;
  1040. searchedClass=smalltalk.send(smalltalk.send((smalltalk.Smalltalk || Smalltalk), "_current", []), "_at_", [aString]);return (($receiver = smalltalk.send(searchedClass, "_isClass", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(smalltalk.send(self, "_class", []), "_openOn_", [searchedClass]);})() : (function(){return smalltalk.send(self, "_searchReferencesOf_", [aString]);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return smalltalk.send(smalltalk.send(self, "_class", []), "_openOn_", [searchedClass]);}), (function(){return smalltalk.send(self, "_searchReferencesOf_", [aString]);})]);})]);
  1041. return self;}
  1042. }),
  1043. smalltalk.Browser);
  1044. smalltalk.addMethod(
  1045. '_handleSourceAreaKeyDown_',
  1046. smalltalk.method({
  1047. selector: 'handleSourceAreaKeyDown:',
  1048. fn: function (anEvent){
  1049. var self=this;
  1050. if(anEvent.ctrlKey) {
  1051. if(anEvent.keyCode === 83) { //ctrl+s
  1052. self._compile();
  1053. anEvent.preventDefault();
  1054. return false;
  1055. }
  1056. }
  1057. ;
  1058. return self;}
  1059. }),
  1060. smalltalk.Browser);
  1061. smalltalk.addMethod(
  1062. '_commitPackage',
  1063. smalltalk.method({
  1064. selector: 'commitPackage',
  1065. fn: function (){
  1066. var self=this;
  1067. (($receiver = self['@selectedPackage']) != nil && $receiver != undefined) ? (function(){(function($rec){smalltalk.send($rec, "_at_put_", ["type", "PUT"]);smalltalk.send($rec, "_at_put_", ["data", smalltalk.send(smalltalk.send((smalltalk.Exporter || Exporter), "_new", []), "_exportPackage_", [self['@selectedPackage']])]);smalltalk.send($rec, "_at_put_", ["error", (function(){return smalltalk.send(self, "_alert_", [unescape("Commit%20failed%21")]);})]);return smalltalk.send($rec, "_send", []);})(smalltalk.send((smalltalk.Ajax || Ajax), "_url_", [smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(self, "_class", []), "_commitPathJs", []), "__comma", [unescape("/")]), "__comma", [self['@selectedPackage']]), "__comma", [".js"])]));(function($rec){smalltalk.send($rec, "_at_put_", ["type", "PUT"]);smalltalk.send($rec, "_at_put_", ["data", smalltalk.send(smalltalk.send((smalltalk.StrippedExporter || StrippedExporter), "_new", []), "_exportPackage_", [self['@selectedPackage']])]);smalltalk.send($rec, "_at_put_", ["error", (function(){return smalltalk.send(self, "_alert_", [unescape("Commit%20failed%21")]);})]);return smalltalk.send($rec, "_send", []);})(smalltalk.send((smalltalk.Ajax || Ajax), "_url_", [smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(self, "_class", []), "_commitPathJs", []), "__comma", [unescape("/")]), "__comma", [self['@selectedPackage']]), "__comma", [".deploy.js"])]));return (function($rec){smalltalk.send($rec, "_at_put_", ["type", "PUT"]);smalltalk.send($rec, "_at_put_", ["data", smalltalk.send(smalltalk.send((smalltalk.ChunkExporter || ChunkExporter), "_new", []), "_exportPackage_", [self['@selectedPackage']])]);smalltalk.send($rec, "_at_put_", ["error", (function(){return smalltalk.send(self, "_alert_", [unescape("Commit%20failed%21")]);})]);return smalltalk.send($rec, "_send", []);})(smalltalk.send((smalltalk.Ajax || Ajax), "_url_", [smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(self, "_class", []), "_commitPathSt", []), "__comma", [unescape("/")]), "__comma", [self['@selectedPackage']]), "__comma", [".st"])]));})() : nil;
  1068. return self;}
  1069. }),
  1070. smalltalk.Browser);
  1071. smalltalk.addMethod(
  1072. '_renamePackage',
  1073. smalltalk.method({
  1074. selector: 'renamePackage',
  1075. fn: function (){
  1076. var self=this;
  1077. var newName=nil;
  1078. var package=nil;
  1079. package=smalltalk.send(smalltalk.send((smalltalk.Smalltalk || Smalltalk), "_current", []), "_packageAt_", [self['@selectedPackage']]);
  1080. newName=smalltalk.send(self, "_prompt_", [smalltalk.send("Rename package ", "__comma", [self['@selectedPackage']])]);
  1081. (($receiver = smalltalk.send(newName, "_notEmpty", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(smalltalk.send((smalltalk.Smalltalk || Smalltalk), "_current", []), "_renamePackage_to_", [self['@selectedPackage'], newName]);return smalltalk.send(self, "_updateCategoriesList", []);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(smalltalk.send((smalltalk.Smalltalk || Smalltalk), "_current", []), "_renamePackage_to_", [self['@selectedPackage'], newName]);return smalltalk.send(self, "_updateCategoriesList", []);})]);
  1082. return self;}
  1083. }),
  1084. smalltalk.Browser);
  1085. smalltalk.addMethod(
  1086. '_removePackage',
  1087. smalltalk.method({
  1088. selector: 'removePackage',
  1089. fn: function (){
  1090. var self=this;
  1091. var package=nil;
  1092. package=smalltalk.send(smalltalk.send((smalltalk.Smalltalk || Smalltalk), "_current", []), "_packageAt_", [self['@selectedPackage']]);
  1093. (($receiver = smalltalk.send(self, "_confirm_", [smalltalk.send(smalltalk.send("Do you really want to remove the whole package ", "__comma", [smalltalk.send(package, "_name", [])]), "__comma", [unescape("%20with%20all%20its%20classes%3F")])])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(smalltalk.send((smalltalk.Smalltalk || Smalltalk), "_current", []), "_removePackage_", [smalltalk.send(package, "_name", [])]);return smalltalk.send(self, "_updateCategoriesList", []);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(smalltalk.send((smalltalk.Smalltalk || Smalltalk), "_current", []), "_removePackage_", [smalltalk.send(package, "_name", [])]);return smalltalk.send(self, "_updateCategoriesList", []);})]);
  1094. return self;}
  1095. }),
  1096. smalltalk.Browser);
  1097. smalltalk.addMethod(
  1098. '_initialize',
  1099. smalltalk.method({
  1100. selector: 'initialize',
  1101. fn: function (){
  1102. var self=this;
  1103. smalltalk.send(self, "_initialize", [], smalltalk.TabWidget);
  1104. self['@selectedTab']="instance";
  1105. self['@unsavedChanges']=false;
  1106. return self;}
  1107. }),
  1108. smalltalk.Browser);
  1109. smalltalk.addMethod(
  1110. '_renderBoxOn_',
  1111. smalltalk.method({
  1112. selector: 'renderBoxOn:',
  1113. fn: function (html){
  1114. var self=this;
  1115. (function($rec){smalltalk.send($rec, "_renderTopPanelOn_", [html]);smalltalk.send($rec, "_renderTabsOn_", [html]);return smalltalk.send($rec, "_renderBottomPanelOn_", [html]);})(self);
  1116. return self;}
  1117. }),
  1118. smalltalk.Browser);
  1119. smalltalk.addMethod(
  1120. '_renderTopPanelOn_',
  1121. smalltalk.method({
  1122. selector: 'renderTopPanelOn:',
  1123. fn: function (html){
  1124. var self=this;
  1125. (function($rec){smalltalk.send($rec, "_class_", ["top"]);return smalltalk.send($rec, "_with_", [(function(){self['@packagesList']=smalltalk.send(smalltalk.send(html, "_ul", []), "_class_", ["jt_column browser packages"]);self['@commitButton']=(function($rec){smalltalk.send($rec, "_class_", ["jt_commit"]);smalltalk.send($rec, "_title_", ["Commit classes in this package to disk"]);smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_commitPackage", []);})]);return smalltalk.send($rec, "_with_", ["Commit package"]);})(smalltalk.send(html, "_button", []));self['@renameButton']=(function($rec){smalltalk.send($rec, "_class_", ["jt_rename"]);smalltalk.send($rec, "_title_", ["Rename this package"]);smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_renamePackage", []);})]);return smalltalk.send($rec, "_with_", ["Rename package"]);})(smalltalk.send(html, "_button", []));self['@deleteButton']=(function($rec){smalltalk.send($rec, "_class_", ["jt_delete"]);smalltalk.send($rec, "_title_", ["Remove this package from the system"]);smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_removePackage", []);})]);return smalltalk.send($rec, "_with_", ["Remove package"]);})(smalltalk.send(html, "_button", []));self['@classesList']=smalltalk.send((smalltalk.ClassesList || ClassesList), "_on_", [self]);smalltalk.send(self['@classesList'], "_renderOn_", [html]);self['@protocolsList']=smalltalk.send(smalltalk.send(html, "_ul", []), "_class_", ["jt_column browser protocols"]);self['@methodsList']=smalltalk.send(smalltalk.send(html, "_ul", []), "_class_", ["jt_column browser methods"]);(function($rec){smalltalk.send($rec, "_updateCategoriesList", []);smalltalk.send($rec, "_updateClassesList", []);smalltalk.send($rec, "_updateProtocolsList", []);return smalltalk.send($rec, "_updateMethodsList", []);})(self);return smalltalk.send(smalltalk.send(html, "_div", []), "_class_", ["jt_clear"]);})]);})(smalltalk.send(html, "_div", []));
  1126. return self;}
  1127. }),
  1128. smalltalk.Browser);
  1129. smalltalk.addMethod(
  1130. '_renderTabsOn_',
  1131. smalltalk.method({
  1132. selector: 'renderTabsOn:',
  1133. fn: function (html){
  1134. var self=this;
  1135. self['@tabsList']=smalltalk.send(smalltalk.send(html, "_ul", []), "_class_", ["jt_tabs jt_browser"]);
  1136. smalltalk.send(self, "_updateTabsList", []);
  1137. return self;}
  1138. }),
  1139. smalltalk.Browser);
  1140. smalltalk.addMethod(
  1141. '_renderBottomPanelOn_',
  1142. smalltalk.method({
  1143. selector: 'renderBottomPanelOn:',
  1144. fn: function (html){
  1145. var self=this;
  1146. (function($rec){smalltalk.send($rec, "_class_", ["jt_sourceCode"]);return smalltalk.send($rec, "_with_", [(function(){self['@sourceArea']=smalltalk.send((smalltalk.SourceArea || SourceArea), "_new", []);smalltalk.send(self['@sourceArea'], "_renderOn_", [html]);smalltalk.send(self['@sourceArea'], "_onKeyDown_", [(function(e){return smalltalk.send(self, "_handleSourceAreaKeyDown_", [e]);})]);return smalltalk.send(self['@sourceArea'], "_onKeyUp_", [(function(){return smalltalk.send(self, "_updateStatus", []);})]);})]);})(smalltalk.send(html, "_div", []));
  1147. return self;}
  1148. }),
  1149. smalltalk.Browser);
  1150. smalltalk.addMethod(
  1151. '_renderButtonsOn_',
  1152. smalltalk.method({
  1153. selector: 'renderButtonsOn:',
  1154. fn: function (html){
  1155. var self=this;
  1156. self['@saveButton']=smalltalk.send(html, "_button", []);
  1157. (function($rec){smalltalk.send($rec, "_with_", ["Save"]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_compile", []);})]);})(self['@saveButton']);
  1158. self['@methodButtons']=smalltalk.send(html, "_span", []);
  1159. self['@classButtons']=smalltalk.send(html, "_span", []);
  1160. (function($rec){smalltalk.send($rec, "_class_", ["right"]);return smalltalk.send($rec, "_with_", [(function(){(function($rec){smalltalk.send($rec, "_with_", ["DoIt"]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self['@sourceArea'], "_doIt", []);})]);})(smalltalk.send(html, "_button", []));(function($rec){smalltalk.send($rec, "_with_", ["PrintIt"]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self['@sourceArea'], "_printIt", []);})]);})(smalltalk.send(html, "_button", []));return (function($rec){smalltalk.send($rec, "_with_", ["InspectIt"]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self['@sourceArea'], "_inspectIt", []);})]);})(smalltalk.send(html, "_button", []));})]);})(smalltalk.send(html, "_div", []));
  1161. smalltalk.send(self, "_updateSourceAndButtons", []);
  1162. return self;}
  1163. }),
  1164. smalltalk.Browser);
  1165. smalltalk.addMethod(
  1166. '_canBeClosed',
  1167. smalltalk.method({
  1168. selector: 'canBeClosed',
  1169. fn: function (){
  1170. var self=this;
  1171. return true;
  1172. return self;}
  1173. }),
  1174. smalltalk.Browser);
  1175. smalltalk.addMethod(
  1176. '_updateCategoriesList',
  1177. smalltalk.method({
  1178. selector: 'updateCategoriesList',
  1179. fn: function (){
  1180. var self=this;
  1181. smalltalk.send(self['@packagesList'], "_contents_", [(function(html){return smalltalk.send(smalltalk.send(self, "_packages", []), "_do_", [(function(each){var li=nil;
  1182. var label=nil;
  1183. (($receiver = smalltalk.send(each, "_isEmpty", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return label="Unclassified";})() : (function(){return label=each;})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return label="Unclassified";}), (function(){return label=each;})]);li=smalltalk.send(html, "_li", []);(($receiver = smalltalk.send(self['@selectedPackage'], "__eq", [each])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(li, "_class_", ["selected"]);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return smalltalk.send(li, "_class_", ["selected"]);})]);return (function($rec){smalltalk.send($rec, "_with_", [label]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_selectCategory_", [each]);})]);})(li);})]);})]);
  1184. return self;}
  1185. }),
  1186. smalltalk.Browser);
  1187. smalltalk.addMethod(
  1188. '_updateClassesList',
  1189. smalltalk.method({
  1190. selector: 'updateClassesList',
  1191. fn: function (){
  1192. var self=this;
  1193. smalltalk.send(smalltalk.send((smalltalk.TabManager || TabManager), "_current", []), "_update", []);
  1194. smalltalk.send(self['@classesList'], "_updateNodes", []);
  1195. return self;}
  1196. }),
  1197. smalltalk.Browser);
  1198. smalltalk.addMethod(
  1199. '_updateProtocolsList',
  1200. smalltalk.method({
  1201. selector: 'updateProtocolsList',
  1202. fn: function (){
  1203. var self=this;
  1204. smalltalk.send(self['@protocolsList'], "_contents_", [(function(html){return smalltalk.send(smalltalk.send(self, "_protocols", []), "_do_", [(function(each){var li=nil;
  1205. li=smalltalk.send(html, "_li", []);(($receiver = smalltalk.send(self['@selectedProtocol'], "__eq", [each])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(li, "_class_", ["selected"]);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return smalltalk.send(li, "_class_", ["selected"]);})]);return (function($rec){smalltalk.send($rec, "_with_", [each]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_selectProtocol_", [each]);})]);})(li);})]);})]);
  1206. return self;}
  1207. }),
  1208. smalltalk.Browser);
  1209. smalltalk.addMethod(
  1210. '_updateMethodsList',
  1211. smalltalk.method({
  1212. selector: 'updateMethodsList',
  1213. fn: function (){
  1214. var self=this;
  1215. smalltalk.send(self['@methodsList'], "_contents_", [(function(html){return smalltalk.send(smalltalk.send(self, "_methods", []), "_do_", [(function(each){var li=nil;
  1216. li=smalltalk.send(html, "_li", []);(($receiver = smalltalk.send(self['@selectedMethod'], "__eq", [each])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(li, "_class_", ["selected"]);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return smalltalk.send(li, "_class_", ["selected"]);})]);return (function($rec){smalltalk.send($rec, "_with_", [smalltalk.send(each, "_selector", [])]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_selectMethod_", [each]);})]);})(li);})]);})]);
  1217. return self;}
  1218. }),
  1219. smalltalk.Browser);
  1220. smalltalk.addMethod(
  1221. '_updateTabsList',
  1222. smalltalk.method({
  1223. selector: 'updateTabsList',
  1224. fn: function (){
  1225. var self=this;
  1226. smalltalk.send(self['@tabsList'], "_contents_", [(function(html){var li=nil;
  1227. li=smalltalk.send(html, "_li", []);(($receiver = smalltalk.send(self['@selectedTab'], "__eq", ["instance"])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(li, "_class_", ["selected"]);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return smalltalk.send(li, "_class_", ["selected"]);})]);(function($rec){smalltalk.send($rec, "_with_", [(function(){smalltalk.send(smalltalk.send(html, "_span", []), "_class_", ["ltab"]);(function($rec){smalltalk.send($rec, "_class_", ["mtab"]);return smalltalk.send($rec, "_with_", ["Instance"]);})(smalltalk.send(html, "_span", []));return smalltalk.send(smalltalk.send(html, "_span", []), "_class_", ["rtab"]);})]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_selectTab_", ["instance"]);})]);})(li);li=smalltalk.send(html, "_li", []);(($receiver = smalltalk.send(self['@selectedTab'], "__eq", ["class"])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(li, "_class_", ["selected"]);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return smalltalk.send(li, "_class_", ["selected"]);})]);(function($rec){smalltalk.send($rec, "_with_", [(function(){smalltalk.send(smalltalk.send(html, "_span", []), "_class_", ["ltab"]);(function($rec){smalltalk.send($rec, "_class_", ["mtab"]);return smalltalk.send($rec, "_with_", ["Class"]);})(smalltalk.send(html, "_span", []));return smalltalk.send(smalltalk.send(html, "_span", []), "_class_", ["rtab"]);})]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_selectTab_", ["class"]);})]);})(li);li=smalltalk.send(html, "_li", []);(($receiver = smalltalk.send(self['@selectedTab'], "__eq", ["comment"])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(li, "_class_", ["selected"]);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return smalltalk.send(li, "_class_", ["selected"]);})]);return (function($rec){smalltalk.send($rec, "_with_", [(function(){smalltalk.send(smalltalk.send(html, "_span", []), "_class_", ["ltab"]);(function($rec){smalltalk.send($rec, "_class_", ["mtab"]);return smalltalk.send($rec, "_with_", ["Comment"]);})(smalltalk.send(html, "_span", []));return smalltalk.send(smalltalk.send(html, "_span", []), "_class_", ["rtab"]);})]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_selectTab_", ["comment"]);})]);})(li);})]);
  1228. return self;}
  1229. }),
  1230. smalltalk.Browser);
  1231. smalltalk.addMethod(
  1232. '_updateSourceAndButtons',
  1233. smalltalk.method({
  1234. selector: 'updateSourceAndButtons',
  1235. fn: function (){
  1236. var self=this;
  1237. smalltalk.send(self, "_disableSaveButton", []);
  1238. smalltalk.send(self['@classButtons'], "_contents_", [(function(html){(function($rec){smalltalk.send($rec, "_with_", ["Rename class"]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_renameClass", []);})]);})(smalltalk.send(html, "_button", []));(function($rec){smalltalk.send($rec, "_with_", ["Remove class"]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_removeClass", []);})]);})(smalltalk.send(html, "_button", []));return (function($rec){smalltalk.send($rec, "_with_", ["References"]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_searchClassReferences", []);})]);})(smalltalk.send(html, "_button", []));})]);
  1239. smalltalk.send(self['@methodButtons'], "_contents_", [(function(html){(function($rec){smalltalk.send($rec, "_with_", ["Remove method"]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_removeMethod", []);})]);})(smalltalk.send(html, "_button", []));(function($rec){smalltalk.send($rec, "_onChange_", [(function(e, select){return smalltalk.send(self, "_setMethodProtocol_", [smalltalk.send(select, "_val", [])]);})]);return smalltalk.send($rec, "_with_", [(function(){(function($rec){smalltalk.send($rec, "_with_", ["Method protocol"]);return smalltalk.send($rec, "_at_put_", ["disabled", "disabled"]);})(smalltalk.send(html, "_option", []));(function($rec){smalltalk.send($rec, "_class_", ["important"]);return smalltalk.send($rec, "_with_", ["New..."]);})(smalltalk.send(html, "_option", []));return smalltalk.send(smalltalk.send(self, "_protocols", []), "_do_", [(function(each){return smalltalk.send(smalltalk.send(html, "_option", []), "_with_", [each]);})]);})]);})(smalltalk.send(html, "_select", []));return (($receiver = smalltalk.send(self['@selectedMethod'], "_isNil", [])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return (function($rec){smalltalk.send($rec, "_onChange_", [(function(e, select){return smalltalk.send(self, "_searchReferencesOf_", [smalltalk.send(select, "_val", [])]);})]);return smalltalk.send($rec, "_with_", [(function(){(function($rec){smalltalk.send($rec, "_with_", ["References"]);return smalltalk.send($rec, "_at_put_", ["disabled", "disabled"]);})(smalltalk.send(html, "_option", []));(function($rec){smalltalk.send($rec, "_class_", ["important"]);return smalltalk.send($rec, "_with_", [smalltalk.send(self['@selectedMethod'], "_selector", [])]);})(smalltalk.send(html, "_option", []));return smalltalk.send(smalltalk.send(smalltalk.send(self['@selectedMethod'], "_messageSends", []), "_sorted", []), "_do_", [(function(each){return smalltalk.send(smalltalk.send(html, "_option", []), "_with_", [each]);})]);})]);})(smalltalk.send(html, "_select", []));})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return (function($rec){smalltalk.send($rec, "_onChange_", [(function(e, select){return smalltalk.send(self, "_searchReferencesOf_", [smalltalk.send(select, "_val", [])]);})]);return smalltalk.send($rec, "_with_", [(function(){(function($rec){smalltalk.send($rec, "_with_", ["References"]);return smalltalk.send($rec, "_at_put_", ["disabled", "disabled"]);})(smalltalk.send(html, "_option", []));(function($rec){smalltalk.send($rec, "_class_", ["important"]);return smalltalk.send($rec, "_with_", [smalltalk.send(self['@selectedMethod'], "_selector", [])]);})(smalltalk.send(html, "_option", []));return smalltalk.send(smalltalk.send(smalltalk.send(self['@selectedMethod'], "_messageSends", []), "_sorted", []), "_do_", [(function(each){return smalltalk.send(smalltalk.send(html, "_option", []), "_with_", [each]);})]);})]);})(smalltalk.send(html, "_select", []));})]);})]);
  1240. (($receiver = smalltalk.send(self['@selectedMethod'], "_isNil", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(self, "_hideMethodButtons", []);return (($receiver = smalltalk.send(smalltalk.send(self['@selectedClass'], "_isNil", []), "_or_", [(function(){return smalltalk.send(self['@selectedProtocol'], "_notNil", []);})])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(self, "_hideClassButtons", []);})() : (function(){return smalltalk.send(self, "_showClassButtons", []);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return smalltalk.send(self, "_hideClassButtons", []);}), (function(){return smalltalk.send(self, "_showClassButtons", []);})]);})() : (function(){smalltalk.send(self, "_hideClassButtons", []);return smalltalk.send(self, "_showMethodButtons", []);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){smalltalk.send(self, "_hideMethodButtons", []);return (($receiver = smalltalk.send(smalltalk.send(self['@selectedClass'], "_isNil", []), "_or_", [(function(){return smalltalk.send(self['@selectedProtocol'], "_notNil", []);})])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(self, "_hideClassButtons", []);})() : (function(){return smalltalk.send(self, "_showClassButtons", []);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return smalltalk.send(self, "_hideClassButtons", []);}), (function(){return smalltalk.send(self, "_showClassButtons", []);})]);}), (function(){smalltalk.send(self, "_hideClassButtons", []);return smalltalk.send(self, "_showMethodButtons", []);})]);
  1241. smalltalk.send(self['@sourceArea'], "_val_", [smalltalk.send(self, "_source", [])]);
  1242. return self;}
  1243. }),
  1244. smalltalk.Browser);
  1245. smalltalk.addMethod(
  1246. '_updateStatus',
  1247. smalltalk.method({
  1248. selector: 'updateStatus',
  1249. fn: function (){
  1250. var self=this;
  1251. (($receiver = smalltalk.send(smalltalk.send(self['@sourceArea'], "_val", []), "__eq", [smalltalk.send(self, "_source", [])])).klass === smalltalk.Boolean) ? ($receiver ? (function(){(($receiver = self['@saveButton']) != nil && $receiver != undefined) ? (function(){return smalltalk.send(self['@saveButton'], "_at_put_", ["disabled", true]);})() : nil;return self['@unsavedChanges']=false;})() : (function(){(($receiver = self['@saveButton']) != nil && $receiver != undefined) ? (function(){return smalltalk.send(self['@saveButton'], "_removeAt_", ["disabled"]);})() : nil;return self['@unsavedChanges']=true;})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){(($receiver = self['@saveButton']) != nil && $receiver != undefined) ? (function(){return smalltalk.send(self['@saveButton'], "_at_put_", ["disabled", true]);})() : nil;return self['@unsavedChanges']=false;}), (function(){(($receiver = self['@saveButton']) != nil && $receiver != undefined) ? (function(){return smalltalk.send(self['@saveButton'], "_removeAt_", ["disabled"]);})() : nil;return self['@unsavedChanges']=true;})]);
  1252. return self;}
  1253. }),
  1254. smalltalk.Browser);
  1255. smalltalk.addMethod(
  1256. '_resetClassesList',
  1257. smalltalk.method({
  1258. selector: 'resetClassesList',
  1259. fn: function (){
  1260. var self=this;
  1261. smalltalk.send(self['@classesList'], "_resetNodes", []);
  1262. return self;}
  1263. }),
  1264. smalltalk.Browser);
  1265. smalltalk.addMethod(
  1266. '_commitPathJs',
  1267. smalltalk.method({
  1268. selector: 'commitPathJs',
  1269. fn: function (){
  1270. var self=this;
  1271. return "js";
  1272. return self;}
  1273. }),
  1274. smalltalk.Browser.klass);
  1275. smalltalk.addMethod(
  1276. '_commitPathSt',
  1277. smalltalk.method({
  1278. selector: 'commitPathSt',
  1279. fn: function (){
  1280. var self=this;
  1281. return "st";
  1282. return self;}
  1283. }),
  1284. smalltalk.Browser.klass);
  1285. smalltalk.addMethod(
  1286. '_openOn_',
  1287. smalltalk.method({
  1288. selector: 'openOn:',
  1289. fn: function (aClass){
  1290. var self=this;
  1291. return (function($rec){smalltalk.send($rec, "_open", []);smalltalk.send($rec, "_selectCategory_", [smalltalk.send(aClass, "_category", [])]);return smalltalk.send($rec, "_selectClass_", [aClass]);})(smalltalk.send(self, "_new", []));
  1292. return self;}
  1293. }),
  1294. smalltalk.Browser.klass);
  1295. smalltalk.addMethod(
  1296. '_open',
  1297. smalltalk.method({
  1298. selector: 'open',
  1299. fn: function (){
  1300. var self=this;
  1301. smalltalk.send(smalltalk.send(self, "_new", []), "_open", []);
  1302. return self;}
  1303. }),
  1304. smalltalk.Browser.klass);
  1305. smalltalk.addClass('Inspector', smalltalk.TabWidget, ['label', 'variables', 'object', 'selectedVariable', 'variablesList', 'valueTextarea', 'diveButton', 'sourceArea'], 'IDE');
  1306. smalltalk.addMethod(
  1307. '_label',
  1308. smalltalk.method({
  1309. selector: 'label',
  1310. fn: function (){
  1311. var self=this;
  1312. return (($receiver = self['@label']) == nil || $receiver == undefined) ? (function(){return unescape("Inspector%20%28nil%29");})() : $receiver;
  1313. return self;}
  1314. }),
  1315. smalltalk.Inspector);
  1316. smalltalk.addMethod(
  1317. '_variables',
  1318. smalltalk.method({
  1319. selector: 'variables',
  1320. fn: function (){
  1321. var self=this;
  1322. return self['@variables'];
  1323. return self;}
  1324. }),
  1325. smalltalk.Inspector);
  1326. smalltalk.addMethod(
  1327. '_setVariables_',
  1328. smalltalk.method({
  1329. selector: 'setVariables:',
  1330. fn: function (aCollection){
  1331. var self=this;
  1332. self['@variables']=aCollection;
  1333. return self;}
  1334. }),
  1335. smalltalk.Inspector);
  1336. smalltalk.addMethod(
  1337. '_setLabel_',
  1338. smalltalk.method({
  1339. selector: 'setLabel:',
  1340. fn: function (aString){
  1341. var self=this;
  1342. self['@label']=aString;
  1343. return self;}
  1344. }),
  1345. smalltalk.Inspector);
  1346. smalltalk.addMethod(
  1347. '_selectedVariable',
  1348. smalltalk.method({
  1349. selector: 'selectedVariable',
  1350. fn: function (){
  1351. var self=this;
  1352. return self['@selectedVariable'];
  1353. return self;}
  1354. }),
  1355. smalltalk.Inspector);
  1356. smalltalk.addMethod(
  1357. '_selectedVariable_',
  1358. smalltalk.method({
  1359. selector: 'selectedVariable:',
  1360. fn: function (aString){
  1361. var self=this;
  1362. self['@selectedVariable']=aString;
  1363. return self;}
  1364. }),
  1365. smalltalk.Inspector);
  1366. smalltalk.addMethod(
  1367. '_sourceArea',
  1368. smalltalk.method({
  1369. selector: 'sourceArea',
  1370. fn: function (){
  1371. var self=this;
  1372. return self['@sourceArea'];
  1373. return self;}
  1374. }),
  1375. smalltalk.Inspector);
  1376. smalltalk.addMethod(
  1377. '_inspect_',
  1378. smalltalk.method({
  1379. selector: 'inspect:',
  1380. fn: function (anObject){
  1381. var self=this;
  1382. self['@object']=anObject;
  1383. self['@variables']=[];
  1384. smalltalk.send(self['@object'], "_inspectOn_", [self]);
  1385. return self;}
  1386. }),
  1387. smalltalk.Inspector);
  1388. smalltalk.addMethod(
  1389. '_dive',
  1390. smalltalk.method({
  1391. selector: 'dive',
  1392. fn: function (){
  1393. var self=this;
  1394. smalltalk.send(smalltalk.send(smalltalk.send(self, "_variables", []), "_at_", [smalltalk.send(self, "_selectedVariable", [])]), "_inspect", []);
  1395. return self;}
  1396. }),
  1397. smalltalk.Inspector);
  1398. smalltalk.addMethod(
  1399. '_refresh',
  1400. smalltalk.method({
  1401. selector: 'refresh',
  1402. fn: function (){
  1403. var self=this;
  1404. (function($rec){smalltalk.send($rec, "_inspect_", [self['@object']]);smalltalk.send($rec, "_updateVariablesList", []);return smalltalk.send($rec, "_updateValueTextarea", []);})(self);
  1405. return self;}
  1406. }),
  1407. smalltalk.Inspector);
  1408. smalltalk.addMethod(
  1409. '_renderBoxOn_',
  1410. smalltalk.method({
  1411. selector: 'renderBoxOn:',
  1412. fn: function (html){
  1413. var self=this;
  1414. (function($rec){smalltalk.send($rec, "_renderTopPanelOn_", [html]);return smalltalk.send($rec, "_renderBottomPanelOn_", [html]);})(self);
  1415. return self;}
  1416. }),
  1417. smalltalk.Inspector);
  1418. smalltalk.addMethod(
  1419. '_renderTopPanelOn_',
  1420. smalltalk.method({
  1421. selector: 'renderTopPanelOn:',
  1422. fn: function (html){
  1423. var self=this;
  1424. (function($rec){smalltalk.send($rec, "_class_", ["top"]);return smalltalk.send($rec, "_with_", [(function(){self['@variablesList']=smalltalk.send(smalltalk.send(html, "_ul", []), "_class_", ["jt_column variables"]);self['@valueTextarea']=(function($rec){smalltalk.send($rec, "_class_", ["jt_column value"]);return smalltalk.send($rec, "_at_put_", ["readonly", "readonly"]);})(smalltalk.send(html, "_textarea", []));(function($rec){smalltalk.send($rec, "_class_", ["jt_tabs inspector"]);return smalltalk.send($rec, "_with_", [(function(){(function($rec){smalltalk.send($rec, "_class_", ["jt_button inspector refresh"]);smalltalk.send($rec, "_with_", ["Refresh"]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_refresh", []);})]);})(smalltalk.send(html, "_button", []));return self['@diveButton']=(function($rec){smalltalk.send($rec, "_class_", ["jt_button inspector dive"]);smalltalk.send($rec, "_with_", ["Dive"]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_dive", []);})]);})(smalltalk.send(html, "_button", []));})]);})(smalltalk.send(html, "_div", []));return smalltalk.send(smalltalk.send(html, "_div", []), "_class_", ["jt_clear"]);})]);})(smalltalk.send(html, "_div", []));
  1425. (function($rec){smalltalk.send($rec, "_updateVariablesList", []);return smalltalk.send($rec, "_updateValueTextarea", []);})(self);
  1426. return self;}
  1427. }),
  1428. smalltalk.Inspector);
  1429. smalltalk.addMethod(
  1430. '_renderBottomPanelOn_',
  1431. smalltalk.method({
  1432. selector: 'renderBottomPanelOn:',
  1433. fn: function (html){
  1434. var self=this;
  1435. (function($rec){smalltalk.send($rec, "_class_", ["jt_sourceCode"]);return smalltalk.send($rec, "_with_", [(function(){self['@sourceArea']=(function($rec){smalltalk.send($rec, "_receiver_", [self['@object']]);smalltalk.send($rec, "_onDoIt_", [(function(){return smalltalk.send(self, "_refresh", []);})]);return smalltalk.send($rec, "_yourself", []);})(smalltalk.send((smalltalk.SourceArea || SourceArea), "_new", []));return smalltalk.send(self['@sourceArea'], "_renderOn_", [html]);})]);})(smalltalk.send(html, "_div", []));
  1436. return self;}
  1437. }),
  1438. smalltalk.Inspector);
  1439. smalltalk.addMethod(
  1440. '_renderButtonsOn_',
  1441. smalltalk.method({
  1442. selector: 'renderButtonsOn:',
  1443. fn: function (html){
  1444. var self=this;
  1445. (function($rec){smalltalk.send($rec, "_with_", ["DoIt"]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(smalltalk.send(self, "_sourceArea", []), "_doIt", []);})]);})(smalltalk.send(html, "_button", []));
  1446. (function($rec){smalltalk.send($rec, "_with_", ["PrintIt"]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(smalltalk.send(self, "_sourceArea", []), "_printIt", []);})]);})(smalltalk.send(html, "_button", []));
  1447. (function($rec){smalltalk.send($rec, "_with_", ["InspectIt"]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(smalltalk.send(self, "_sourceArea", []), "_inspectIt", []);})]);})(smalltalk.send(html, "_button", []));
  1448. smalltalk.send(self, "_updateButtons", []);
  1449. return self;}
  1450. }),
  1451. smalltalk.Inspector);
  1452. smalltalk.addMethod(
  1453. '_canBeClosed',
  1454. smalltalk.method({
  1455. selector: 'canBeClosed',
  1456. fn: function (){
  1457. var self=this;
  1458. return true;
  1459. return self;}
  1460. }),
  1461. smalltalk.Inspector);
  1462. smalltalk.addMethod(
  1463. '_updateVariablesList',
  1464. smalltalk.method({
  1465. selector: 'updateVariablesList',
  1466. fn: function (){
  1467. var self=this;
  1468. smalltalk.send(self['@variablesList'], "_contents_", [(function(html){return smalltalk.send(smalltalk.send(smalltalk.send(self, "_variables", []), "_keys", []), "_do_", [(function(each){var li=nil;
  1469. li=smalltalk.send(html, "_li", []);(function($rec){smalltalk.send($rec, "_with_", [each]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_selectVariable_", [each]);})]);})(li);return (($receiver = smalltalk.send(smalltalk.send(self, "_selectedVariable", []), "__eq", [each])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(li, "_class_", ["selected"]);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return smalltalk.send(li, "_class_", ["selected"]);})]);})]);})]);
  1470. return self;}
  1471. }),
  1472. smalltalk.Inspector);
  1473. smalltalk.addMethod(
  1474. '_selectVariable_',
  1475. smalltalk.method({
  1476. selector: 'selectVariable:',
  1477. fn: function (aString){
  1478. var self=this;
  1479. smalltalk.send(self, "_selectedVariable_", [aString]);
  1480. (function($rec){smalltalk.send($rec, "_updateVariablesList", []);smalltalk.send($rec, "_updateValueTextarea", []);return smalltalk.send($rec, "_updateButtons", []);})(self);
  1481. return self;}
  1482. }),
  1483. smalltalk.Inspector);
  1484. smalltalk.addMethod(
  1485. '_updateValueTextarea',
  1486. smalltalk.method({
  1487. selector: 'updateValueTextarea',
  1488. fn: function (){
  1489. var self=this;
  1490. smalltalk.send(smalltalk.send(self['@valueTextarea'], "_asJQuery", []), "_val_", [(($receiver = smalltalk.send(smalltalk.send(self, "_selectedVariable", []), "_isNil", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return "";})() : (function(){return smalltalk.send(smalltalk.send(smalltalk.send(self, "_variables", []), "_at_", [smalltalk.send(self, "_selectedVariable", [])]), "_printString", []);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return "";}), (function(){return smalltalk.send(smalltalk.send(smalltalk.send(self, "_variables", []), "_at_", [smalltalk.send(self, "_selectedVariable", [])]), "_printString", []);})])]);
  1491. return self;}
  1492. }),
  1493. smalltalk.Inspector);
  1494. smalltalk.addMethod(
  1495. '_updateButtons',
  1496. smalltalk.method({
  1497. selector: 'updateButtons',
  1498. fn: function (){
  1499. var self=this;
  1500. (($receiver = smalltalk.send(smalltalk.send(smalltalk.send(self, "_selectedVariable", []), "_notNil", []), "_and_", [(function(){return smalltalk.send(smalltalk.send(smalltalk.send(self, "_variables", []), "_at_", [smalltalk.send(self, "_selectedVariable", [])]), "_notNil", []);})])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return smalltalk.send(self['@diveButton'], "_at_put_", ["disabled", true]);})() : (function(){return smalltalk.send(self['@diveButton'], "_removeAt_", ["disabled"]);})()) : smalltalk.send($receiver, "_ifFalse_ifTrue_", [(function(){return smalltalk.send(self['@diveButton'], "_at_put_", ["disabled", true]);}), (function(){return smalltalk.send(self['@diveButton'], "_removeAt_", ["disabled"]);})]);
  1501. return self;}
  1502. }),
  1503. smalltalk.Inspector);
  1504. smalltalk.addMethod(
  1505. '_on_',
  1506. smalltalk.method({
  1507. selector: 'on:',
  1508. fn: function (anObject){
  1509. var self=this;
  1510. return (function($rec){smalltalk.send($rec, "_inspect_", [anObject]);return smalltalk.send($rec, "_yourself", []);})(smalltalk.send(self, "_new", []));
  1511. return self;}
  1512. }),
  1513. smalltalk.Inspector.klass);
  1514. smalltalk.addClass('ReferencesBrowser', smalltalk.TabWidget, ['implementors', 'senders', 'implementorsList', 'input', 'timer', 'selector', 'sendersList', 'referencedClasses', 'referencedClassesList'], 'IDE');
  1515. smalltalk.addMethod(
  1516. '_implementors',
  1517. smalltalk.method({
  1518. selector: 'implementors',
  1519. fn: function (){
  1520. var self=this;
  1521. return (($receiver = self['@implementors']) == nil || $receiver == undefined) ? (function(){return self['@implementors']=smalltalk.send((smalltalk.Array || Array), "_new", []);})() : $receiver;
  1522. return self;}
  1523. }),
  1524. smalltalk.ReferencesBrowser);
  1525. smalltalk.addMethod(
  1526. '_label',
  1527. smalltalk.method({
  1528. selector: 'label',
  1529. fn: function (){
  1530. var self=this;
  1531. return unescape("%5BReferences%5D");
  1532. return self;}
  1533. }),
  1534. smalltalk.ReferencesBrowser);
  1535. smalltalk.addMethod(
  1536. '_selector',
  1537. smalltalk.method({
  1538. selector: 'selector',
  1539. fn: function (){
  1540. var self=this;
  1541. return self['@selector'];
  1542. return self;}
  1543. }),
  1544. smalltalk.ReferencesBrowser);
  1545. smalltalk.addMethod(
  1546. '_senders',
  1547. smalltalk.method({
  1548. selector: 'senders',
  1549. fn: function (){
  1550. var self=this;
  1551. return (($receiver = self['@senders']) == nil || $receiver == undefined) ? (function(){return self['@senders']=smalltalk.send((smalltalk.Array || Array), "_new", []);})() : $receiver;
  1552. return self;}
  1553. }),
  1554. smalltalk.ReferencesBrowser);
  1555. smalltalk.addMethod(
  1556. '_classesAndMetaclasses',
  1557. smalltalk.method({
  1558. selector: 'classesAndMetaclasses',
  1559. fn: function (){
  1560. var self=this;
  1561. return smalltalk.send(smalltalk.send(smalltalk.send((smalltalk.Smalltalk || Smalltalk), "_current", []), "_classes", []), "__comma", [smalltalk.send(smalltalk.send(smalltalk.send((smalltalk.Smalltalk || Smalltalk), "_current", []), "_classes", []), "_collect_", [(function(each){return smalltalk.send(each, "_class", []);})])]);
  1562. return self;}
  1563. }),
  1564. smalltalk.ReferencesBrowser);
  1565. smalltalk.addMethod(
  1566. '_referencedClasses',
  1567. smalltalk.method({
  1568. selector: 'referencedClasses',
  1569. fn: function (){
  1570. var self=this;
  1571. return (($receiver = self['@referencedClasses']) == nil || $receiver == undefined) ? (function(){return self['@referencedClasses']=smalltalk.send((smalltalk.Array || Array), "_new", []);})() : $receiver;
  1572. return self;}
  1573. }),
  1574. smalltalk.ReferencesBrowser);
  1575. smalltalk.addMethod(
  1576. '_openBrowserOn_',
  1577. smalltalk.method({
  1578. selector: 'openBrowserOn:',
  1579. fn: function (aMethod){
  1580. var self=this;
  1581. var browser=nil;
  1582. browser=smalltalk.send((smalltalk.Browser || Browser), "_openOn_", [(($receiver = smalltalk.send(smalltalk.send(aMethod, "_methodClass", []), "_isMetaclass", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(smalltalk.send(aMethod, "_methodClass", []), "_instanceClass", []);})() : (function(){return smalltalk.send(aMethod, "_methodClass", []);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return smalltalk.send(smalltalk.send(aMethod, "_methodClass", []), "_instanceClass", []);}), (function(){return smalltalk.send(aMethod, "_methodClass", []);})])]);
  1583. (($receiver = smalltalk.send(smalltalk.send(aMethod, "_methodClass", []), "_isMetaclass", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(browser, "_selectTab_", ["class"]);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return smalltalk.send(browser, "_selectTab_", ["class"]);})]);
  1584. (function($rec){smalltalk.send($rec, "_selectProtocol_", [smalltalk.send(aMethod, "_category", [])]);return smalltalk.send($rec, "_selectMethod_", [aMethod]);})(browser);
  1585. return self;}
  1586. }),
  1587. smalltalk.ReferencesBrowser);
  1588. smalltalk.addMethod(
  1589. '_searchReferencesFor_',
  1590. smalltalk.method({
  1591. selector: 'searchReferencesFor:',
  1592. fn: function (aString){
  1593. var self=this;
  1594. self['@selector']=aString;
  1595. self['@implementors']=smalltalk.send((smalltalk.Array || Array), "_new", []);
  1596. self['@senders']=smalltalk.send((smalltalk.Array || Array), "_new", []);
  1597. self['@referencedClasses']=smalltalk.send((smalltalk.Array || Array), "_new", []);
  1598. (($receiver = smalltalk.send(self['@selector'], "_match_", [unescape("%5E%5BA-Z%5D")])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return smalltalk.send(self, "_searchSelectorReferencesFor_", [self['@selector']]);})() : (function(){return smalltalk.send(self, "_searchReferencedClassesFor_", [self['@selector']]);})()) : smalltalk.send($receiver, "_ifFalse_ifTrue_", [(function(){return smalltalk.send(self, "_searchSelectorReferencesFor_", [self['@selector']]);}), (function(){return smalltalk.send(self, "_searchReferencedClassesFor_", [self['@selector']]);})]);
  1599. return self;}
  1600. }),
  1601. smalltalk.ReferencesBrowser);
  1602. smalltalk.addMethod(
  1603. '_search_',
  1604. smalltalk.method({
  1605. selector: 'search:',
  1606. fn: function (aString){
  1607. var self=this;
  1608. (function($rec){smalltalk.send($rec, "_searchReferencesFor_", [aString]);smalltalk.send($rec, "_updateImplementorsList", []);smalltalk.send($rec, "_updateSendersList", []);return smalltalk.send($rec, "_updateReferencedClassesList", []);})(self);
  1609. return self;}
  1610. }),
  1611. smalltalk.ReferencesBrowser);
  1612. smalltalk.addMethod(
  1613. '_searchReferencedClassesFor_',
  1614. smalltalk.method({
  1615. selector: 'searchReferencedClassesFor:',
  1616. fn: function (aString){
  1617. var self=this;
  1618. smalltalk.send(smalltalk.send(self, "_classesAndMetaclasses", []), "_do_", [(function(each){return smalltalk.send(smalltalk.send(smalltalk.send(each, "_methodDictionary", []), "_values", []), "_do_", [(function(value){return (($receiver = smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(value, "_referencedClasses", []), "_select_", [(function(each){return smalltalk.send(each, "_notNil", []);})]), "_collect_", [(function(each){return smalltalk.send(each, "_name", []);})]), "_includes_", [self['@selector']])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(smalltalk.send(self, "_referencedClasses", []), "_add_", [value]);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return smalltalk.send(smalltalk.send(self, "_referencedClasses", []), "_add_", [value]);})]);})]);})]);
  1619. return self;}
  1620. }),
  1621. smalltalk.ReferencesBrowser);
  1622. smalltalk.addMethod(
  1623. '_searchSelectorReferencesFor_',
  1624. smalltalk.method({
  1625. selector: 'searchSelectorReferencesFor:',
  1626. fn: function (aString){
  1627. var self=this;
  1628. smalltalk.send(smalltalk.send(self, "_classesAndMetaclasses", []), "_do_", [(function(each){smalltalk.send(smalltalk.send(each, "_methodDictionary", []), "_keysAndValuesDo_", [(function(key, value){return (($receiver = smalltalk.send(key, "__eq", [self['@selector']])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(smalltalk.send(self, "_implementors", []), "_add_", [value]);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return smalltalk.send(smalltalk.send(self, "_implementors", []), "_add_", [value]);})]);})]);return smalltalk.send(smalltalk.send(each, "_methodDictionary", []), "_keysAndValuesDo_", [(function(key, value){return (($receiver = smalltalk.send(smalltalk.send(value, "_messageSends", []), "_includes_", [self['@selector']])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(smalltalk.send(self, "_senders", []), "_add_", [value]);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return smalltalk.send(smalltalk.send(self, "_senders", []), "_add_", [value]);})]);})]);})]);
  1629. return self;}
  1630. }),
  1631. smalltalk.ReferencesBrowser);
  1632. smalltalk.addMethod(
  1633. '_initialize',
  1634. smalltalk.method({
  1635. selector: 'initialize',
  1636. fn: function (){
  1637. var self=this;
  1638. smalltalk.send(self, "_initialize", [], smalltalk.TabWidget);
  1639. self['@selector']="";
  1640. return self;}
  1641. }),
  1642. smalltalk.ReferencesBrowser);
  1643. smalltalk.addMethod(
  1644. '_setInputEvents',
  1645. smalltalk.method({
  1646. selector: 'setInputEvents',
  1647. fn: function (){
  1648. var self=this;
  1649. (function($rec){smalltalk.send($rec, "_onKeyUp_", [(function(){return self['@timer']=smalltalk.send((function(){return smalltalk.send(self, "_search_", [smalltalk.send(smalltalk.send(self['@input'], "_asJQuery", []), "_val", [])]);}), "_valueWithTimeout_", [(100)]);})]);return smalltalk.send($rec, "_onKeyDown_", [(function(){return (($receiver = self['@timer']) != nil && $receiver != undefined) ? (function(){return smalltalk.send(self['@timer'], "_clearTimeout", []);})() : nil;})]);})(self['@input']);
  1650. return self;}
  1651. }),
  1652. smalltalk.ReferencesBrowser);
  1653. smalltalk.addMethod(
  1654. '_renderBoxOn_',
  1655. smalltalk.method({
  1656. selector: 'renderBoxOn:',
  1657. fn: function (html){
  1658. var self=this;
  1659. (function($rec){smalltalk.send($rec, "_renderInputOn_", [html]);smalltalk.send($rec, "_renderImplementorsOn_", [html]);smalltalk.send($rec, "_renderSendersOn_", [html]);return smalltalk.send($rec, "_renderReferencedClassesOn_", [html]);})(self);
  1660. return self;}
  1661. }),
  1662. smalltalk.ReferencesBrowser);
  1663. smalltalk.addMethod(
  1664. '_renderInputOn_',
  1665. smalltalk.method({
  1666. selector: 'renderInputOn:',
  1667. fn: function (html){
  1668. var self=this;
  1669. self['@input']=(function($rec){smalltalk.send($rec, "_class_", ["implementors"]);return smalltalk.send($rec, "_yourself", []);})(smalltalk.send(html, "_input", []));
  1670. smalltalk.send(smalltalk.send(self['@input'], "_asJQuery", []), "_val_", [self['@selector']]);
  1671. smalltalk.send(self, "_setInputEvents", []);
  1672. return self;}
  1673. }),
  1674. smalltalk.ReferencesBrowser);
  1675. smalltalk.addMethod(
  1676. '_renderImplementorsOn_',
  1677. smalltalk.method({
  1678. selector: 'renderImplementorsOn:',
  1679. fn: function (html){
  1680. var self=this;
  1681. self['@implementorsList']=smalltalk.send(smalltalk.send(html, "_ul", []), "_class_", ["jt_column implementors"]);
  1682. smalltalk.send(self, "_updateImplementorsList", []);
  1683. return self;}
  1684. }),
  1685. smalltalk.ReferencesBrowser);
  1686. smalltalk.addMethod(
  1687. '_renderSendersOn_',
  1688. smalltalk.method({
  1689. selector: 'renderSendersOn:',
  1690. fn: function (html){
  1691. var self=this;
  1692. self['@sendersList']=smalltalk.send(smalltalk.send(html, "_ul", []), "_class_", ["jt_column senders"]);
  1693. smalltalk.send(self, "_updateSendersList", []);
  1694. return self;}
  1695. }),
  1696. smalltalk.ReferencesBrowser);
  1697. smalltalk.addMethod(
  1698. '_renderReferencedClassesOn_',
  1699. smalltalk.method({
  1700. selector: 'renderReferencedClassesOn:',
  1701. fn: function (html){
  1702. var self=this;
  1703. self['@referencedClassesList']=smalltalk.send(smalltalk.send(html, "_ul", []), "_class_", ["jt_column referenced_classes"]);
  1704. smalltalk.send(self, "_updateReferencedClassesList", []);
  1705. return self;}
  1706. }),
  1707. smalltalk.ReferencesBrowser);
  1708. smalltalk.addMethod(
  1709. '_canBeClosed',
  1710. smalltalk.method({
  1711. selector: 'canBeClosed',
  1712. fn: function (){
  1713. var self=this;
  1714. return true;
  1715. return self;}
  1716. }),
  1717. smalltalk.ReferencesBrowser);
  1718. smalltalk.addMethod(
  1719. '_updateImplementorsList',
  1720. smalltalk.method({
  1721. selector: 'updateImplementorsList',
  1722. fn: function (){
  1723. var self=this;
  1724. smalltalk.send(self['@implementorsList'], "_contents_", [(function(html){(function($rec){smalltalk.send($rec, "_class_", ["column_label"]);smalltalk.send($rec, "_with_", [smalltalk.send(smalltalk.send(unescape("Implementors%20%28"), "__comma", [smalltalk.send(smalltalk.send(smalltalk.send(self, "_implementors", []), "_size", []), "_asString", [])]), "__comma", [unescape("%29")])]);return smalltalk.send($rec, "_style_", [unescape("font-weight%3A%20bold")]);})(smalltalk.send(html, "_li", []));return smalltalk.send(smalltalk.send(self, "_implementors", []), "_do_", [(function(each){var li=nil;
  1725. li=smalltalk.send(html, "_li", []);return (function($rec){smalltalk.send($rec, "_with_", [smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(each, "_methodClass", []), "_asString", []), "__comma", [unescape("%20%3E%3E%20")]), "__comma", [smalltalk.send(self, "_selector", [])])]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_openBrowserOn_", [each]);})]);})(li);})]);})]);
  1726. return self;}
  1727. }),
  1728. smalltalk.ReferencesBrowser);
  1729. smalltalk.addMethod(
  1730. '_updateSendersList',
  1731. smalltalk.method({
  1732. selector: 'updateSendersList',
  1733. fn: function (){
  1734. var self=this;
  1735. smalltalk.send(self['@sendersList'], "_contents_", [(function(html){(function($rec){smalltalk.send($rec, "_class_", ["column_label"]);smalltalk.send($rec, "_with_", [smalltalk.send(smalltalk.send(unescape("Senders%20%28"), "__comma", [smalltalk.send(smalltalk.send(smalltalk.send(self, "_senders", []), "_size", []), "_asString", [])]), "__comma", [unescape("%29")])]);return smalltalk.send($rec, "_style_", [unescape("font-weight%3A%20bold")]);})(smalltalk.send(html, "_li", []));return smalltalk.send(smalltalk.send(self, "_senders", []), "_do_", [(function(each){return (function($rec){smalltalk.send($rec, "_with_", [smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(each, "_methodClass", []), "_asString", []), "__comma", [unescape("%20%3E%3E%20")]), "__comma", [smalltalk.send(each, "_selector", [])])]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_openBrowserOn_", [each]);})]);})(smalltalk.send(html, "_li", []));})]);})]);
  1736. return self;}
  1737. }),
  1738. smalltalk.ReferencesBrowser);
  1739. smalltalk.addMethod(
  1740. '_updateReferencedClassesList',
  1741. smalltalk.method({
  1742. selector: 'updateReferencedClassesList',
  1743. fn: function (){
  1744. var self=this;
  1745. smalltalk.send(self['@referencedClassesList'], "_contents_", [(function(html){(function($rec){smalltalk.send($rec, "_class_", ["column_label"]);smalltalk.send($rec, "_with_", [smalltalk.send(smalltalk.send(unescape("Class%20references%20%28"), "__comma", [smalltalk.send(smalltalk.send(smalltalk.send(self, "_referencedClasses", []), "_size", []), "_asString", [])]), "__comma", [unescape("%29")])]);return smalltalk.send($rec, "_style_", [unescape("font-weight%3A%20bold")]);})(smalltalk.send(html, "_li", []));return smalltalk.send(smalltalk.send(self, "_referencedClasses", []), "_do_", [(function(each){return (function($rec){smalltalk.send($rec, "_with_", [smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(each, "_methodClass", []), "_asString", []), "__comma", [unescape("%20%3E%3E%20")]), "__comma", [smalltalk.send(each, "_selector", [])])]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_openBrowserOn_", [each]);})]);})(smalltalk.send(html, "_li", []));})]);})]);
  1746. return self;}
  1747. }),
  1748. smalltalk.ReferencesBrowser);
  1749. smalltalk.addMethod(
  1750. '_search_',
  1751. smalltalk.method({
  1752. selector: 'search:',
  1753. fn: function (aString){
  1754. var self=this;
  1755. return (function($rec){smalltalk.send($rec, "_searchReferencesFor_", [aString]);return smalltalk.send($rec, "_open", []);})(smalltalk.send(self, "_new", []));
  1756. return self;}
  1757. }),
  1758. smalltalk.ReferencesBrowser.klass);
  1759. smalltalk.addClass('SourceArea', smalltalk.Widget, ['editor', 'div', 'receiver', 'onDoIt'], 'IDE');
  1760. smalltalk.addMethod(
  1761. '_val',
  1762. smalltalk.method({
  1763. selector: 'val',
  1764. fn: function (){
  1765. var self=this;
  1766. return smalltalk.send(self['@editor'], "_getValue", []);
  1767. return self;}
  1768. }),
  1769. smalltalk.SourceArea);
  1770. smalltalk.addMethod(
  1771. '_val_',
  1772. smalltalk.method({
  1773. selector: 'val:',
  1774. fn: function (aString){
  1775. var self=this;
  1776. smalltalk.send(self['@editor'], "_setValue_", [aString]);
  1777. return self;}
  1778. }),
  1779. smalltalk.SourceArea);
  1780. smalltalk.addMethod(
  1781. '_currentLine',
  1782. smalltalk.method({
  1783. selector: 'currentLine',
  1784. fn: function (){
  1785. var self=this;
  1786. return smalltalk.send(self['@editor'], "_getLine_", [smalltalk.send(smalltalk.send(self['@editor'], "_getCursor", []), "_line", [])]);
  1787. return self;}
  1788. }),
  1789. smalltalk.SourceArea);
  1790. smalltalk.addMethod(
  1791. '_selection',
  1792. smalltalk.method({
  1793. selector: 'selection',
  1794. fn: function (){
  1795. var self=this;
  1796. return smalltalk.send(self['@editor'], "_getSelection", []);
  1797. return self;}
  1798. }),
  1799. smalltalk.SourceArea);
  1800. smalltalk.addMethod(
  1801. '_selectionEnd',
  1802. smalltalk.method({
  1803. selector: 'selectionEnd',
  1804. fn: function (){
  1805. var self=this;
  1806. return smalltalk.send(smalltalk.send((typeof textarea == 'undefined' ? nil : textarea), "_element", []), "_selectionEnd", []);
  1807. return self;}
  1808. }),
  1809. smalltalk.SourceArea);
  1810. smalltalk.addMethod(
  1811. '_selectionStart',
  1812. smalltalk.method({
  1813. selector: 'selectionStart',
  1814. fn: function (){
  1815. var self=this;
  1816. return smalltalk.send(smalltalk.send((typeof textarea == 'undefined' ? nil : textarea), "_element", []), "_selectionStart", []);
  1817. return self;}
  1818. }),
  1819. smalltalk.SourceArea);
  1820. smalltalk.addMethod(
  1821. '_selectionStart_',
  1822. smalltalk.method({
  1823. selector: 'selectionStart:',
  1824. fn: function (anInteger){
  1825. var self=this;
  1826. smalltalk.send(smalltalk.send((typeof textarea == 'undefined' ? nil : textarea), "_element", []), "_selectionStart_", [anInteger]);
  1827. return self;}
  1828. }),
  1829. smalltalk.SourceArea);
  1830. smalltalk.addMethod(
  1831. '_selectionEnd_',
  1832. smalltalk.method({
  1833. selector: 'selectionEnd:',
  1834. fn: function (anInteger){
  1835. var self=this;
  1836. smalltalk.send(smalltalk.send((typeof textarea == 'undefined' ? nil : textarea), "_element", []), "_selectionEnd_", [anInteger]);
  1837. return self;}
  1838. }),
  1839. smalltalk.SourceArea);
  1840. smalltalk.addMethod(
  1841. '_setEditorOn_',
  1842. smalltalk.method({
  1843. selector: 'setEditorOn:',
  1844. fn: function (aTextarea){
  1845. var self=this;
  1846. self['@editor'] = CodeMirror.fromTextArea(aTextarea, {
  1847. theme: 'jtalk',
  1848. lineNumbers: true,
  1849. enterMode: 'classic',
  1850. matchBrackets: true,
  1851. electricChars: false,
  1852. });
  1853. return self;}
  1854. }),
  1855. smalltalk.SourceArea);
  1856. smalltalk.addMethod(
  1857. '_editor',
  1858. smalltalk.method({
  1859. selector: 'editor',
  1860. fn: function (){
  1861. var self=this;
  1862. return self['@editor'];
  1863. return self;}
  1864. }),
  1865. smalltalk.SourceArea);
  1866. smalltalk.addMethod(
  1867. '_receiver',
  1868. smalltalk.method({
  1869. selector: 'receiver',
  1870. fn: function (){
  1871. var self=this;
  1872. return (($receiver = self['@receiver']) == nil || $receiver == undefined) ? (function(){return smalltalk.send((smalltalk.DoIt || DoIt), "_new", []);})() : $receiver;
  1873. return self;}
  1874. }),
  1875. smalltalk.SourceArea);
  1876. smalltalk.addMethod(
  1877. '_receiver_',
  1878. smalltalk.method({
  1879. selector: 'receiver:',
  1880. fn: function (anObject){
  1881. var self=this;
  1882. self['@receiver']=anObject;
  1883. return self;}
  1884. }),
  1885. smalltalk.SourceArea);
  1886. smalltalk.addMethod(
  1887. '_onDoIt_',
  1888. smalltalk.method({
  1889. selector: 'onDoIt:',
  1890. fn: function (aBlock){
  1891. var self=this;
  1892. self['@onDoIt']=aBlock;
  1893. return self;}
  1894. }),
  1895. smalltalk.SourceArea);
  1896. smalltalk.addMethod(
  1897. '_onDoIt',
  1898. smalltalk.method({
  1899. selector: 'onDoIt',
  1900. fn: function (){
  1901. var self=this;
  1902. return self['@onDoIt'];
  1903. return self;}
  1904. }),
  1905. smalltalk.SourceArea);
  1906. smalltalk.addMethod(
  1907. '_currentLineOrSelection',
  1908. smalltalk.method({
  1909. selector: 'currentLineOrSelection',
  1910. fn: function (){
  1911. var self=this;
  1912. return (($receiver = smalltalk.send(self['@editor'], "_somethingSelected", [])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return smalltalk.send(self, "_currentLine", []);})() : (function(){return smalltalk.send(self, "_selection", []);})()) : smalltalk.send($receiver, "_ifFalse_ifTrue_", [(function(){return smalltalk.send(self, "_currentLine", []);}), (function(){return smalltalk.send(self, "_selection", []);})]);
  1913. return self;}
  1914. }),
  1915. smalltalk.SourceArea);
  1916. smalltalk.addMethod(
  1917. '_clear',
  1918. smalltalk.method({
  1919. selector: 'clear',
  1920. fn: function (){
  1921. var self=this;
  1922. smalltalk.send(self, "_val_", [""]);
  1923. return self;}
  1924. }),
  1925. smalltalk.SourceArea);
  1926. smalltalk.addMethod(
  1927. '_doIt',
  1928. smalltalk.method({
  1929. selector: 'doIt',
  1930. fn: function (){
  1931. var self=this;
  1932. var result=nil;
  1933. result=smalltalk.send(self, "_eval_", [smalltalk.send(self, "_currentLineOrSelection", [])]);
  1934. (($receiver = smalltalk.send(self, "_onDoIt", [])) != nil && $receiver != undefined) ? (function(){return smalltalk.send(smalltalk.send(self, "_onDoIt", []), "_value", []);})() : nil;
  1935. return result;
  1936. return self;}
  1937. }),
  1938. smalltalk.SourceArea);
  1939. smalltalk.addMethod(
  1940. '_eval_',
  1941. smalltalk.method({
  1942. selector: 'eval:',
  1943. fn: function (aString){
  1944. var self=this;
  1945. try{var compiler=nil;
  1946. compiler=smalltalk.send((smalltalk.Compiler || Compiler), "_new", []);
  1947. smalltalk.send((function(){return smalltalk.send(compiler, "_parseExpression_", [aString]);}), "_on_do_", [(smalltalk.Error || Error), (function(ex){return (function(){throw({name: 'stReturn', selector: '_eval_', fn: function(){return smalltalk.send(self, "_alert_", [smalltalk.send(ex, "_messageText", [])])}})})();})]);
  1948. (function(){throw({name: 'stReturn', selector: '_eval_', fn: function(){return smalltalk.send(smalltalk.send(smalltalk.send(compiler, "_load_forClass_", [smalltalk.send(smalltalk.send(unescape("doIt%20%5E%5B"), "__comma", [aString]), "__comma", [unescape("%5D%20value")]), (smalltalk.DoIt || DoIt)]), "_fn", []), "_applyTo_arguments_", [smalltalk.send(self, "_receiver", []), []])}})})();
  1949. return self;
  1950. } catch(e) {if(e.name === 'stReturn' && e.selector === '_eval_'){return e.fn()} throw(e)}}
  1951. }),
  1952. smalltalk.SourceArea);
  1953. smalltalk.addMethod(
  1954. '_handleKeyDown_',
  1955. smalltalk.method({
  1956. selector: 'handleKeyDown:',
  1957. fn: function (anEvent){
  1958. var self=this;
  1959. if(anEvent.ctrlKey) {
  1960. if(anEvent.keyCode === 80) { //ctrl+p
  1961. self._printIt();
  1962. anEvent.preventDefault();
  1963. return false;
  1964. }
  1965. if(anEvent.keyCode === 68) { //ctrl+d
  1966. self._doIt();
  1967. anEvent.preventDefault();
  1968. return false;
  1969. }
  1970. if(anEvent.keyCode === 73) { //ctrl+i
  1971. self._inspectIt();
  1972. anEvent.preventDefault();
  1973. return false;
  1974. }
  1975. };
  1976. return self;}
  1977. }),
  1978. smalltalk.SourceArea);
  1979. smalltalk.addMethod(
  1980. '_inspectIt',
  1981. smalltalk.method({
  1982. selector: 'inspectIt',
  1983. fn: function (){
  1984. var self=this;
  1985. smalltalk.send(smalltalk.send(self, "_doIt", []), "_inspect", []);
  1986. return self;}
  1987. }),
  1988. smalltalk.SourceArea);
  1989. smalltalk.addMethod(
  1990. '_print_',
  1991. smalltalk.method({
  1992. selector: 'print:',
  1993. fn: function (aString){
  1994. var self=this;
  1995. var start=nil;
  1996. var stop=nil;
  1997. start=smalltalk.send((smalltalk.Dictionary || Dictionary), "_new", []);
  1998. stop=smalltalk.send((smalltalk.Dictionary || Dictionary), "_new", []);
  1999. smalltalk.send(start, "_at_put_", ["line", smalltalk.send(smalltalk.send(self['@editor'], "_getCursor_", [false]), "_line", [])]);
  2000. smalltalk.send(start, "_at_put_", ["ch", smalltalk.send(smalltalk.send(self['@editor'], "_getCursor_", [false]), "_ch", [])]);
  2001. smalltalk.send(stop, "_at_put_", ["line", smalltalk.send(start, "_at_", ["line"])]);
  2002. smalltalk.send(stop, "_at_put_", ["ch", (($receiver = (($receiver = smalltalk.send(start, "_at_", ["ch"])).klass === smalltalk.Number) ? $receiver +smalltalk.send(aString, "_size", []) : smalltalk.send($receiver, "__plus", [smalltalk.send(aString, "_size", [])])).klass === smalltalk.Number) ? $receiver +(2) : smalltalk.send($receiver, "__plus", [(2)])]);
  2003. smalltalk.send(self['@editor'], "_replaceSelection_", [smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(self['@editor'], "_getSelection", []), "__comma", [" "]), "__comma", [aString]), "__comma", [" "])]);
  2004. smalltalk.send(self['@editor'], "_setCursor_", [smalltalk.send(self['@editor'], "_getCursor_", [true])]);
  2005. smalltalk.send(self['@editor'], "_setSelection_end_", [stop, start]);
  2006. return self;}
  2007. }),
  2008. smalltalk.SourceArea);
  2009. smalltalk.addMethod(
  2010. '_printIt',
  2011. smalltalk.method({
  2012. selector: 'printIt',
  2013. fn: function (){
  2014. var self=this;
  2015. smalltalk.send(self, "_print_", [smalltalk.send(smalltalk.send(self, "_doIt", []), "_printString", [])]);
  2016. return self;}
  2017. }),
  2018. smalltalk.SourceArea);
  2019. smalltalk.addMethod(
  2020. '_fileIn',
  2021. smalltalk.method({
  2022. selector: 'fileIn',
  2023. fn: function (){
  2024. var self=this;
  2025. smalltalk.send(smalltalk.send((smalltalk.Importer || Importer), "_new", []), "_import_", [smalltalk.send(smalltalk.send(self, "_currentLineOrSelection", []), "_readStream", [])]);
  2026. return self;}
  2027. }),
  2028. smalltalk.SourceArea);
  2029. smalltalk.addMethod(
  2030. '_onKeyUp_',
  2031. smalltalk.method({
  2032. selector: 'onKeyUp:',
  2033. fn: function (aBlock){
  2034. var self=this;
  2035. smalltalk.send(self['@div'], "_onKeyUp_", [aBlock]);
  2036. return self;}
  2037. }),
  2038. smalltalk.SourceArea);
  2039. smalltalk.addMethod(
  2040. '_onKeyDown_',
  2041. smalltalk.method({
  2042. selector: 'onKeyDown:',
  2043. fn: function (aBlock){
  2044. var self=this;
  2045. smalltalk.send(self['@div'], "_onKeyDown_", [aBlock]);
  2046. return self;}
  2047. }),
  2048. smalltalk.SourceArea);
  2049. smalltalk.addMethod(
  2050. '_renderOn_',
  2051. smalltalk.method({
  2052. selector: 'renderOn:',
  2053. fn: function (html){
  2054. var self=this;
  2055. var textarea=nil;
  2056. self['@div']=smalltalk.send(smalltalk.send(html, "_div", []), "_class_", ["source"]);
  2057. smalltalk.send(self['@div'], "_with_", [(function(){return textarea=smalltalk.send(html, "_textarea", []);})]);
  2058. smalltalk.send(self, "_setEditorOn_", [smalltalk.send(textarea, "_element", [])]);
  2059. smalltalk.send(self['@div'], "_onKeyDown_", [(function(e){return smalltalk.send(self, "_handleKeyDown_", [e]);})]);
  2060. return self;}
  2061. }),
  2062. smalltalk.SourceArea);
  2063. smalltalk.addClass('ClassesList', smalltalk.Widget, ['browser', 'ul', 'nodes'], 'IDE');
  2064. smalltalk.addMethod(
  2065. '_category',
  2066. smalltalk.method({
  2067. selector: 'category',
  2068. fn: function (){
  2069. var self=this;
  2070. return smalltalk.send(smalltalk.send(self, "_browser", []), "_selectedPackage", []);
  2071. return self;}
  2072. }),
  2073. smalltalk.ClassesList);
  2074. smalltalk.addMethod(
  2075. '_nodes',
  2076. smalltalk.method({
  2077. selector: 'nodes',
  2078. fn: function (){
  2079. var self=this;
  2080. (($receiver = self['@nodes']) == nil || $receiver == undefined) ? (function(){return self['@nodes']=smalltalk.send(self, "_getNodes", []);})() : $receiver;
  2081. return self['@nodes'];
  2082. return self;}
  2083. }),
  2084. smalltalk.ClassesList);
  2085. smalltalk.addMethod(
  2086. '_browser',
  2087. smalltalk.method({
  2088. selector: 'browser',
  2089. fn: function (){
  2090. var self=this;
  2091. return self['@browser'];
  2092. return self;}
  2093. }),
  2094. smalltalk.ClassesList);
  2095. smalltalk.addMethod(
  2096. '_browser_',
  2097. smalltalk.method({
  2098. selector: 'browser:',
  2099. fn: function (aBrowser){
  2100. var self=this;
  2101. self['@browser']=aBrowser;
  2102. return self;}
  2103. }),
  2104. smalltalk.ClassesList);
  2105. smalltalk.addMethod(
  2106. '_getNodes',
  2107. smalltalk.method({
  2108. selector: 'getNodes',
  2109. fn: function (){
  2110. var self=this;
  2111. var classes=nil;
  2112. var children=nil;
  2113. var others=nil;
  2114. classes=smalltalk.send(smalltalk.send(self, "_browser", []), "_classes", []);
  2115. children=[];
  2116. others=[];
  2117. smalltalk.send(classes, "_do_", [(function(each){return (($receiver = smalltalk.send(classes, "_includes_", [smalltalk.send(each, "_superclass", [])])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return smalltalk.send(children, "_add_", [each]);})() : (function(){return smalltalk.send(others, "_add_", [each]);})()) : smalltalk.send($receiver, "_ifFalse_ifTrue_", [(function(){return smalltalk.send(children, "_add_", [each]);}), (function(){return smalltalk.send(others, "_add_", [each]);})]);})]);
  2118. return smalltalk.send(children, "_collect_", [(function(each){return smalltalk.send((smalltalk.ClassesListNode || ClassesListNode), "_on_browser_classes_level_", [each, smalltalk.send(self, "_browser", []), others, (0)]);})]);
  2119. return self;}
  2120. }),
  2121. smalltalk.ClassesList);
  2122. smalltalk.addMethod(
  2123. '_resetNodes',
  2124. smalltalk.method({
  2125. selector: 'resetNodes',
  2126. fn: function (){
  2127. var self=this;
  2128. self['@nodes']=nil;
  2129. return self;}
  2130. }),
  2131. smalltalk.ClassesList);
  2132. smalltalk.addMethod(
  2133. '_renderOn_',
  2134. smalltalk.method({
  2135. selector: 'renderOn:',
  2136. fn: function (html){
  2137. var self=this;
  2138. self['@ul']=(function($rec){smalltalk.send($rec, "_class_", ["jt_column browser classes"]);return smalltalk.send($rec, "_yourself", []);})(smalltalk.send(html, "_ul", []));
  2139. smalltalk.send(self, "_updateNodes", []);
  2140. return self;}
  2141. }),
  2142. smalltalk.ClassesList);
  2143. smalltalk.addMethod(
  2144. '_updateNodes',
  2145. smalltalk.method({
  2146. selector: 'updateNodes',
  2147. fn: function (){
  2148. var self=this;
  2149. smalltalk.send(self['@ul'], "_contents_", [(function(html){return smalltalk.send(smalltalk.send(self, "_nodes", []), "_do_", [(function(each){return smalltalk.send(each, "_renderOn_", [html]);})]);})]);
  2150. return self;}
  2151. }),
  2152. smalltalk.ClassesList);
  2153. smalltalk.addMethod(
  2154. '_on_',
  2155. smalltalk.method({
  2156. selector: 'on:',
  2157. fn: function (aBrowser){
  2158. var self=this;
  2159. return (function($rec){smalltalk.send($rec, "_browser_", [aBrowser]);return smalltalk.send($rec, "_yourself", []);})(smalltalk.send(self, "_new", []));
  2160. return self;}
  2161. }),
  2162. smalltalk.ClassesList.klass);
  2163. smalltalk.addClass('ClassesListNode', smalltalk.Widget, ['browser', 'theClass', 'level', 'nodes'], 'IDE');
  2164. smalltalk.addMethod(
  2165. '_renderOn_',
  2166. smalltalk.method({
  2167. selector: 'renderOn:',
  2168. fn: function (html){
  2169. var self=this;
  2170. var li=nil;
  2171. var cssClass=nil;
  2172. cssClass="";
  2173. li=smalltalk.send(smalltalk.send(html, "_li", []), "_onClick_", [(function(){return smalltalk.send(smalltalk.send(self, "_browser", []), "_selectClass_", [smalltalk.send(self, "_theClass", [])]);})]);
  2174. smalltalk.send(smalltalk.send(li, "_asJQuery", []), "_contents_", [smalltalk.send(self, "_label", [])]);
  2175. (($receiver = smalltalk.send(smalltalk.send(smalltalk.send(self, "_browser", []), "_selectedClass", []), "__eq", [smalltalk.send(self, "_theClass", [])])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return cssClass=smalltalk.send(cssClass, "__comma", [" selected"]);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return cssClass=smalltalk.send(cssClass, "__comma", [" selected"]);})]);
  2176. (($receiver = smalltalk.send(smalltalk.send(smalltalk.send(self, "_theClass", []), "_comment", []), "_isEmpty", [])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return cssClass=smalltalk.send(cssClass, "__comma", [" commented"]);})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return cssClass=smalltalk.send(cssClass, "__comma", [" commented"]);})]);
  2177. smalltalk.send(li, "_class_", [cssClass]);
  2178. smalltalk.send(smalltalk.send(self, "_nodes", []), "_do_", [(function(each){return smalltalk.send(each, "_renderOn_", [html]);})]);
  2179. return self;}
  2180. }),
  2181. smalltalk.ClassesListNode);
  2182. smalltalk.addMethod(
  2183. '_nodes',
  2184. smalltalk.method({
  2185. selector: 'nodes',
  2186. fn: function (){
  2187. var self=this;
  2188. return self['@nodes'];
  2189. return self;}
  2190. }),
  2191. smalltalk.ClassesListNode);
  2192. smalltalk.addMethod(
  2193. '_theClass',
  2194. smalltalk.method({
  2195. selector: 'theClass',
  2196. fn: function (){
  2197. var self=this;
  2198. return self['@theClass'];
  2199. return self;}
  2200. }),
  2201. smalltalk.ClassesListNode);
  2202. smalltalk.addMethod(
  2203. '_theClass_',
  2204. smalltalk.method({
  2205. selector: 'theClass:',
  2206. fn: function (aClass){
  2207. var self=this;
  2208. self['@theClass']=aClass;
  2209. return self;}
  2210. }),
  2211. smalltalk.ClassesListNode);
  2212. smalltalk.addMethod(
  2213. '_browser',
  2214. smalltalk.method({
  2215. selector: 'browser',
  2216. fn: function (){
  2217. var self=this;
  2218. return self['@browser'];
  2219. return self;}
  2220. }),
  2221. smalltalk.ClassesListNode);
  2222. smalltalk.addMethod(
  2223. '_browser_',
  2224. smalltalk.method({
  2225. selector: 'browser:',
  2226. fn: function (aBrowser){
  2227. var self=this;
  2228. self['@browser']=aBrowser;
  2229. return self;}
  2230. }),
  2231. smalltalk.ClassesListNode);
  2232. smalltalk.addMethod(
  2233. '_level',
  2234. smalltalk.method({
  2235. selector: 'level',
  2236. fn: function (){
  2237. var self=this;
  2238. return self['@level'];
  2239. return self;}
  2240. }),
  2241. smalltalk.ClassesListNode);
  2242. smalltalk.addMethod(
  2243. '_level_',
  2244. smalltalk.method({
  2245. selector: 'level:',
  2246. fn: function (anInteger){
  2247. var self=this;
  2248. self['@level']=anInteger;
  2249. return self;}
  2250. }),
  2251. smalltalk.ClassesListNode);
  2252. smalltalk.addMethod(
  2253. '_label',
  2254. smalltalk.method({
  2255. selector: 'label',
  2256. fn: function (){
  2257. var self=this;
  2258. var str=nil;
  2259. str=smalltalk.send(smalltalk.send((smalltalk.String || String), "_new", []), "_writeStream", []);
  2260. smalltalk.send(smalltalk.send(self, "_level", []), "_timesRepeat_", [(function(){return smalltalk.send(str, "_nextPutAll_", [unescape("%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B")]);})]);
  2261. smalltalk.send(str, "_nextPutAll_", [smalltalk.send(smalltalk.send(self, "_theClass", []), "_name", [])]);
  2262. return smalltalk.send(str, "_contents", []);
  2263. return self;}
  2264. }),
  2265. smalltalk.ClassesListNode);
  2266. smalltalk.addMethod(
  2267. '_getNodesFrom_',
  2268. smalltalk.method({
  2269. selector: 'getNodesFrom:',
  2270. fn: function (aCollection){
  2271. var self=this;
  2272. var children=nil;
  2273. var others=nil;
  2274. children=[];
  2275. others=[];
  2276. smalltalk.send(aCollection, "_do_", [(function(each){return (($receiver = smalltalk.send(smalltalk.send(each, "_superclass", []), "__eq", [smalltalk.send(self, "_theClass", [])])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(children, "_add_", [each]);})() : (function(){return smalltalk.send(others, "_add_", [each]);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return smalltalk.send(children, "_add_", [each]);}), (function(){return smalltalk.send(others, "_add_", [each]);})]);})]);
  2277. self['@nodes']=smalltalk.send(children, "_collect_", [(function(each){return smalltalk.send((smalltalk.ClassesListNode || ClassesListNode), "_on_browser_classes_level_", [each, smalltalk.send(self, "_browser", []), others, (($receiver = smalltalk.send(self, "_level", [])).klass === smalltalk.Number) ? $receiver +(1) : smalltalk.send($receiver, "__plus", [(1)])]);})]);
  2278. return self;}
  2279. }),
  2280. smalltalk.ClassesListNode);
  2281. smalltalk.addMethod(
  2282. '_on_browser_classes_level_',
  2283. smalltalk.method({
  2284. selector: 'on:browser:classes:level:',
  2285. fn: function (aClass, aBrowser, aCollection, anInteger){
  2286. var self=this;
  2287. return (function($rec){smalltalk.send($rec, "_theClass_", [aClass]);smalltalk.send($rec, "_browser_", [aBrowser]);smalltalk.send($rec, "_level_", [anInteger]);smalltalk.send($rec, "_getNodesFrom_", [aCollection]);return smalltalk.send($rec, "_yourself", []);})(smalltalk.send(self, "_new", []));
  2288. return self;}
  2289. }),
  2290. smalltalk.ClassesListNode.klass);
  2291. smalltalk.addClass('Debugger', smalltalk.TabWidget, ['error', 'selectedContext', 'sourceArea', 'ul', 'ul2', 'inspector', 'saveButton', 'unsavedChanges', 'selectedVariable', 'selectedVariableName', 'inspectButton'], 'IDE');
  2292. smalltalk.addMethod(
  2293. '_error',
  2294. smalltalk.method({
  2295. selector: 'error',
  2296. fn: function (){
  2297. var self=this;
  2298. return self['@error'];
  2299. return self;}
  2300. }),
  2301. smalltalk.Debugger);
  2302. smalltalk.addMethod(
  2303. '_error_',
  2304. smalltalk.method({
  2305. selector: 'error:',
  2306. fn: function (anError){
  2307. var self=this;
  2308. self['@error']=anError;
  2309. return self;}
  2310. }),
  2311. smalltalk.Debugger);
  2312. smalltalk.addMethod(
  2313. '_label',
  2314. smalltalk.method({
  2315. selector: 'label',
  2316. fn: function (){
  2317. var self=this;
  2318. return unescape("%5BDebugger%5D");
  2319. return self;}
  2320. }),
  2321. smalltalk.Debugger);
  2322. smalltalk.addMethod(
  2323. '_source',
  2324. smalltalk.method({
  2325. selector: 'source',
  2326. fn: function (){
  2327. var self=this;
  2328. return (($receiver = smalltalk.send(self, "_method", [])) == nil || $receiver == undefined) ? (function(){return unescape("Method%20doesn%27t%20exist%21");})() : (function(){return smalltalk.send(smalltalk.send(self, "_method", []), "_source", []);})();
  2329. return self;}
  2330. }),
  2331. smalltalk.Debugger);
  2332. smalltalk.addMethod(
  2333. '_method',
  2334. smalltalk.method({
  2335. selector: 'method',
  2336. fn: function (){
  2337. var self=this;
  2338. return smalltalk.send(smalltalk.send(smalltalk.send(self['@selectedContext'], "_receiver", []), "_class", []), "_methodAt_", [smalltalk.send(self['@selectedContext'], "_selector", [])]);
  2339. return self;}
  2340. }),
  2341. smalltalk.Debugger);
  2342. smalltalk.addMethod(
  2343. '_arguments',
  2344. smalltalk.method({
  2345. selector: 'arguments',
  2346. fn: function (){
  2347. var self=this;
  2348. return (($receiver = smalltalk.send(self, "_method", [])) == nil || $receiver == undefined) ? (function(){return smalltalk.send(smalltalk.send(self['@selectedContext'], "_temps", []), "_collect_", [(function(each){return nil;})]);})() : (function(){return smalltalk.send(smalltalk.send(self, "_method", []), "_arguments", []);})();
  2349. return self;}
  2350. }),
  2351. smalltalk.Debugger);
  2352. smalltalk.addMethod(
  2353. '_receiver',
  2354. smalltalk.method({
  2355. selector: 'receiver',
  2356. fn: function (){
  2357. var self=this;
  2358. return smalltalk.send(self['@selectedContext'], "_receiver", []);
  2359. return self;}
  2360. }),
  2361. smalltalk.Debugger);
  2362. smalltalk.addMethod(
  2363. '_selectContext_',
  2364. smalltalk.method({
  2365. selector: 'selectContext:',
  2366. fn: function (aContext){
  2367. var self=this;
  2368. self['@selectedContext']=aContext;
  2369. self['@selectedVariable']=nil;
  2370. self['@selectedVariableName']=nil;
  2371. (function($rec){smalltalk.send($rec, "_updateContextsList", []);smalltalk.send($rec, "_updateSourceArea", []);smalltalk.send($rec, "_updateInspector", []);smalltalk.send($rec, "_updateVariablesList", []);return smalltalk.send($rec, "_updateStatus", []);})(self);
  2372. return self;}
  2373. }),
  2374. smalltalk.Debugger);
  2375. smalltalk.addMethod(
  2376. '_proceed',
  2377. smalltalk.method({
  2378. selector: 'proceed',
  2379. fn: function (){
  2380. var self=this;
  2381. smalltalk.send(self, "_close", []);
  2382. smalltalk.send(smalltalk.send(self['@selectedContext'], "_receiver", []), "_perform_withArguments_", [smalltalk.send(self['@selectedContext'], "_selector", []), smalltalk.send(self['@selectedContext'], "_temps", [])]);
  2383. return self;}
  2384. }),
  2385. smalltalk.Debugger);
  2386. smalltalk.addMethod(
  2387. '_save',
  2388. smalltalk.method({
  2389. selector: 'save',
  2390. fn: function (){
  2391. var self=this;
  2392. var protocol=nil;
  2393. protocol=smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(self['@selectedContext'], "_receiver", []), "_class", []), "_methodDictionary", []), "_at_", [smalltalk.send(self['@selectedContext'], "_selector", [])]), "_category", []);
  2394. smalltalk.send(smalltalk.send(smalltalk.send(self['@selectedContext'], "_receiver", []), "_class", []), "_compile_category_", [smalltalk.send(self['@sourceArea'], "_val", []), protocol]);
  2395. smalltalk.send(self, "_updateStatus", []);
  2396. return self;}
  2397. }),
  2398. smalltalk.Debugger);
  2399. smalltalk.addMethod(
  2400. '_selectVariable_named_',
  2401. smalltalk.method({
  2402. selector: 'selectVariable:named:',
  2403. fn: function (anObject, aString){
  2404. var self=this;
  2405. self['@selectedVariable']=anObject;
  2406. self['@selectedVariableName']=aString;
  2407. smalltalk.send(self['@inspector'], "_contents_", [(function(html){return smalltalk.send(html, "_with_", [smalltalk.send(anObject, "_printString", [])]);})]);
  2408. smalltalk.send(self, "_updateVariablesList", []);
  2409. return self;}
  2410. }),
  2411. smalltalk.Debugger);
  2412. smalltalk.addMethod(
  2413. '_inspectSelectedVariable',
  2414. smalltalk.method({
  2415. selector: 'inspectSelectedVariable',
  2416. fn: function (){
  2417. var self=this;
  2418. smalltalk.send(self['@selectedVariable'], "_inspect", []);
  2419. return self;}
  2420. }),
  2421. smalltalk.Debugger);
  2422. smalltalk.addMethod(
  2423. '_initialize',
  2424. smalltalk.method({
  2425. selector: 'initialize',
  2426. fn: function (){
  2427. var self=this;
  2428. smalltalk.send(self, "_initialize", [], smalltalk.TabWidget);
  2429. smalltalk.send(self['@unsavedChanges'], "__eq", [false]);
  2430. return self;}
  2431. }),
  2432. smalltalk.Debugger);
  2433. smalltalk.addMethod(
  2434. '_renderTopPanelOn_',
  2435. smalltalk.method({
  2436. selector: 'renderTopPanelOn:',
  2437. fn: function (html){
  2438. var self=this;
  2439. self['@selectedContext']=smalltalk.send(smalltalk.send(self, "_error", []), "_context", []);
  2440. (function($rec){smalltalk.send($rec, "_class_", ["top"]);return smalltalk.send($rec, "_with_", [(function(){(function($rec){smalltalk.send($rec, "_class_", ["label"]);return smalltalk.send($rec, "_with_", [smalltalk.send(smalltalk.send(self, "_error", []), "_messageText", [])]);})(smalltalk.send(html, "_div", []));return self['@ul']=(function($rec){smalltalk.send($rec, "_class_", ["jt_column debugger contexts"]);return smalltalk.send($rec, "_with_", [(function(){return smalltalk.send(self, "_renderContext_on_", [smalltalk.send(smalltalk.send(self, "_error", []), "_context", []), html]);})]);})(smalltalk.send(html, "_ul", []));})]);})(smalltalk.send(html, "_div", []));
  2441. return self;}
  2442. }),
  2443. smalltalk.Debugger);
  2444. smalltalk.addMethod(
  2445. '_renderContext_on_',
  2446. smalltalk.method({
  2447. selector: 'renderContext:on:',
  2448. fn: function (aContext, html){
  2449. var self=this;
  2450. var li=nil;
  2451. li=smalltalk.send(html, "_li", []);
  2452. (($receiver = smalltalk.send(self['@selectedContext'], "__eq", [aContext])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(li, "_class_", ["selected"]);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return smalltalk.send(li, "_class_", ["selected"]);})]);
  2453. (function($rec){smalltalk.send($rec, "_with_", [smalltalk.send(aContext, "_asString", [])]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_selectContext_", [aContext]);})]);})(li);
  2454. (($receiver = smalltalk.send(aContext, "_home", [])) != nil && $receiver != undefined) ? (function(){return smalltalk.send(self, "_renderContext_on_", [smalltalk.send(aContext, "_home", []), html]);})() : nil;
  2455. return self;}
  2456. }),
  2457. smalltalk.Debugger);
  2458. smalltalk.addMethod(
  2459. '_renderBottomPanelOn_',
  2460. smalltalk.method({
  2461. selector: 'renderBottomPanelOn:',
  2462. fn: function (html){
  2463. var self=this;
  2464. (function($rec){smalltalk.send($rec, "_class_", ["jt_sourceCode debugger"]);return smalltalk.send($rec, "_with_", [(function(){self['@sourceArea']=smalltalk.send((smalltalk.SourceArea || SourceArea), "_new", []);return smalltalk.send(self['@sourceArea'], "_renderOn_", [html]);})]);})(smalltalk.send(html, "_div", []));
  2465. self['@ul2']=smalltalk.send(smalltalk.send(html, "_ul", []), "_class_", ["jt_column debugger variables"]);
  2466. self['@inspector']=smalltalk.send(smalltalk.send(html, "_div", []), "_class_", ["jt_column debugger inspector"]);
  2467. smalltalk.send(self['@sourceArea'], "_onKeyUp_", [(function(){return smalltalk.send(self, "_updateStatus", []);})]);
  2468. return self;}
  2469. }),
  2470. smalltalk.Debugger);
  2471. smalltalk.addMethod(
  2472. '_renderButtonsOn_',
  2473. smalltalk.method({
  2474. selector: 'renderButtonsOn:',
  2475. fn: function (html){
  2476. var self=this;
  2477. self['@saveButton']=(function($rec){smalltalk.send($rec, "_with_", ["Save"]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_save", []);})]);})(smalltalk.send(html, "_button", []));
  2478. (function($rec){smalltalk.send($rec, "_with_", ["DoIt"]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self['@sourceArea'], "_doIt", []);})]);})(smalltalk.send(html, "_button", []));
  2479. (function($rec){smalltalk.send($rec, "_with_", ["PrintIt"]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self['@sourceArea'], "_printIt", []);})]);})(smalltalk.send(html, "_button", []));
  2480. (function($rec){smalltalk.send($rec, "_with_", ["InspectIt"]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self['@sourceArea'], "_inspectIt", []);})]);})(smalltalk.send(html, "_button", []));
  2481. (function($rec){smalltalk.send($rec, "_with_", ["Proceed"]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_proceed", []);})]);})(smalltalk.send(html, "_button", []));
  2482. (function($rec){smalltalk.send($rec, "_with_", ["Abandon"]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_close", []);})]);})(smalltalk.send(html, "_button", []));
  2483. self['@inspectButton']=(function($rec){smalltalk.send($rec, "_class_", ["jt_button debugger inspect"]);smalltalk.send($rec, "_with_", ["Inspect"]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_inspectSelectedVariable", []);})]);})(smalltalk.send(html, "_button", []));
  2484. (function($rec){smalltalk.send($rec, "_updateSourceArea", []);smalltalk.send($rec, "_updateStatus", []);smalltalk.send($rec, "_updateVariablesList", []);return smalltalk.send($rec, "_updateInspector", []);})(self);
  2485. return self;}
  2486. }),
  2487. smalltalk.Debugger);
  2488. smalltalk.addMethod(
  2489. '_renderBoxOn_',
  2490. smalltalk.method({
  2491. selector: 'renderBoxOn:',
  2492. fn: function (html){
  2493. var self=this;
  2494. (function($rec){smalltalk.send($rec, "_renderTopPanelOn_", [html]);return smalltalk.send($rec, "_renderBottomPanelOn_", [html]);})(self);
  2495. return self;}
  2496. }),
  2497. smalltalk.Debugger);
  2498. smalltalk.addMethod(
  2499. '_canBeClosed',
  2500. smalltalk.method({
  2501. selector: 'canBeClosed',
  2502. fn: function (){
  2503. var self=this;
  2504. return true;
  2505. return self;}
  2506. }),
  2507. smalltalk.Debugger);
  2508. smalltalk.addMethod(
  2509. '_updateContextsList',
  2510. smalltalk.method({
  2511. selector: 'updateContextsList',
  2512. fn: function (){
  2513. var self=this;
  2514. smalltalk.send(self['@ul'], "_contents_", [(function(html){return smalltalk.send(self, "_renderContext_on_", [smalltalk.send(smalltalk.send(self, "_error", []), "_context", []), html]);})]);
  2515. return self;}
  2516. }),
  2517. smalltalk.Debugger);
  2518. smalltalk.addMethod(
  2519. '_updateSourceArea',
  2520. smalltalk.method({
  2521. selector: 'updateSourceArea',
  2522. fn: function (){
  2523. var self=this;
  2524. smalltalk.send(self['@sourceArea'], "_val_", [smalltalk.send(self, "_source", [])]);
  2525. return self;}
  2526. }),
  2527. smalltalk.Debugger);
  2528. smalltalk.addMethod(
  2529. '_updateStatus',
  2530. smalltalk.method({
  2531. selector: 'updateStatus',
  2532. fn: function (){
  2533. var self=this;
  2534. (($receiver = smalltalk.send(smalltalk.send(self['@sourceArea'], "_val", []), "__eq", [smalltalk.send(self, "_source", [])])).klass === smalltalk.Boolean) ? ($receiver ? (function(){(($receiver = self['@saveButton']) != nil && $receiver != undefined) ? (function(){return smalltalk.send(self['@saveButton'], "_at_put_", ["disabled", true]);})() : nil;return self['@unsavedChanges']=false;})() : (function(){(($receiver = self['@saveButton']) != nil && $receiver != undefined) ? (function(){return smalltalk.send(self['@saveButton'], "_removeAt_", ["disabled"]);})() : nil;return self['@unsavedChanges']=true;})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){(($receiver = self['@saveButton']) != nil && $receiver != undefined) ? (function(){return smalltalk.send(self['@saveButton'], "_at_put_", ["disabled", true]);})() : nil;return self['@unsavedChanges']=false;}), (function(){(($receiver = self['@saveButton']) != nil && $receiver != undefined) ? (function(){return smalltalk.send(self['@saveButton'], "_removeAt_", ["disabled"]);})() : nil;return self['@unsavedChanges']=true;})]);
  2535. return self;}
  2536. }),
  2537. smalltalk.Debugger);
  2538. smalltalk.addMethod(
  2539. '_updateInspector',
  2540. smalltalk.method({
  2541. selector: 'updateInspector',
  2542. fn: function (){
  2543. var self=this;
  2544. smalltalk.send(self['@inspector'], "_contents_", [(function(html){return nil;})]);
  2545. return self;}
  2546. }),
  2547. smalltalk.Debugger);
  2548. smalltalk.addMethod(
  2549. '_updateVariablesList',
  2550. smalltalk.method({
  2551. selector: 'updateVariablesList',
  2552. fn: function (){
  2553. var self=this;
  2554. smalltalk.send(self['@ul2'], "_contents_", [(function(html){var li=nil;
  2555. li=(function($rec){smalltalk.send($rec, "_with_", ["self"]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_selectVariable_named_", [smalltalk.send(self, "_receiver", []), "self"]);})]);})(smalltalk.send(html, "_li", []));(($receiver = smalltalk.send(self['@selectedVariableName'], "__eq", ["self"])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(li, "_class_", ["selected"]);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return smalltalk.send(li, "_class_", ["selected"]);})]);smalltalk.send(smalltalk.send(self, "_arguments", []), "_withIndexDo_", [(function(each, index){var param=nil;
  2556. param=smalltalk.send(smalltalk.send(self['@selectedContext'], "_temps", []), "_at_", [index]);li=(function($rec){smalltalk.send($rec, "_with_", [each]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_selectVariable_named_", [param, each]);})]);})(smalltalk.send(html, "_li", []));return (($receiver = smalltalk.send(self['@selectedVariableName'], "__eq", [each])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(li, "_class_", ["selected"]);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return smalltalk.send(li, "_class_", ["selected"]);})]);})]);return smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(self, "_receiver", []), "_class", []), "_allInstanceVariableNames", []), "_do_", [(function(each){var ivar=nil;
  2557. ivar=smalltalk.send(smalltalk.send(self, "_receiver", []), "_instVarAt_", [each]);li=(function($rec){smalltalk.send($rec, "_with_", [each]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_selectVariable_named_", [ivar, each]);})]);})(smalltalk.send(html, "_li", []));return (($receiver = smalltalk.send(self['@selectedVariableName'], "__eq", [each])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(li, "_class_", ["selected"]);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return smalltalk.send(li, "_class_", ["selected"]);})]);})]);})]);
  2558. (($receiver = self['@selectedVariable']) == nil || $receiver == undefined) ? (function(){return smalltalk.send(self['@inspectButton'], "_at_put_", ["disabled", true]);})() : (function(){return smalltalk.send(self['@inspectButton'], "_removeAt_", ["disabled"]);})();
  2559. return self;}
  2560. }),
  2561. smalltalk.Debugger);
  2562. smalltalk.addClass('DebugErrorHandler', smalltalk.ErrorHandler, [], 'IDE');
  2563. smalltalk.addMethod(
  2564. '_handleError_',
  2565. smalltalk.method({
  2566. selector: 'handleError:',
  2567. fn: function (anError){
  2568. var self=this;
  2569. smalltalk.send((function(){return (function($rec){smalltalk.send($rec, "_error_", [anError]);return smalltalk.send($rec, "_open", []);})(smalltalk.send((smalltalk.Debugger || Debugger), "_new", []));}), "_on_do_", [(smalltalk.Error || Error), (function(error){return smalltalk.send(smalltalk.send((smalltalk.ErrorHandler || ErrorHandler), "_new", []), "_handleError_", [error]);})]);
  2570. return self;}
  2571. }),
  2572. smalltalk.DebugErrorHandler);
  2573. smalltalk.addMethod(
  2574. '_initialize',
  2575. smalltalk.method({
  2576. selector: 'initialize',
  2577. fn: function (){
  2578. var self=this;
  2579. smalltalk.send(self, "_register", []);
  2580. return self;}
  2581. }),
  2582. smalltalk.DebugErrorHandler.klass);
  2583. smalltalk.addClass('ProgressBar', smalltalk.TabWidget, ['percent', 'progressDiv', 'div'], 'IDE');
  2584. smalltalk.addMethod(
  2585. '_percent',
  2586. smalltalk.method({
  2587. selector: 'percent',
  2588. fn: function (){
  2589. var self=this;
  2590. return (($receiver = self['@percent']) == nil || $receiver == undefined) ? (function(){return (0);})() : $receiver;
  2591. return self;}
  2592. }),
  2593. smalltalk.ProgressBar);
  2594. smalltalk.addMethod(
  2595. '_percent_',
  2596. smalltalk.method({
  2597. selector: 'percent:',
  2598. fn: function (aNumber){
  2599. var self=this;
  2600. self['@percent']=aNumber;
  2601. return self;}
  2602. }),
  2603. smalltalk.ProgressBar);
  2604. smalltalk.addMethod(
  2605. '_renderOn_',
  2606. smalltalk.method({
  2607. selector: 'renderOn:',
  2608. fn: function (html){
  2609. var self=this;
  2610. self['@div']=(function($rec){smalltalk.send($rec, "_class_", ["progress_bar"]);return smalltalk.send($rec, "_yourself", []);})(smalltalk.send(html, "_div", []));
  2611. smalltalk.send(self, "_renderProgressBar", []);
  2612. return self;}
  2613. }),
  2614. smalltalk.ProgressBar);
  2615. smalltalk.addMethod(
  2616. '_renderProgressBar',
  2617. smalltalk.method({
  2618. selector: 'renderProgressBar',
  2619. fn: function (){
  2620. var self=this;
  2621. smalltalk.send(self['@div'], "_contents_", [(function(html){return (function($rec){smalltalk.send($rec, "_class_", ["progress"]);return smalltalk.send($rec, "_style_", [smalltalk.send(smalltalk.send("width:", "__comma", [smalltalk.send(smalltalk.send(self, "_percent", []), "_asString", [])]), "__comma", [unescape("%25")])]);})(smalltalk.send(html, "_div", []));})]);
  2622. return self;}
  2623. }),
  2624. smalltalk.ProgressBar);
  2625. smalltalk.addMethod(
  2626. '_updatePercent_',
  2627. smalltalk.method({
  2628. selector: 'updatePercent:',
  2629. fn: function (aNumber){
  2630. var self=this;
  2631. smalltalk.send(self, "_percent_", [aNumber]);
  2632. smalltalk.send(self, "_renderProgressBar", []);
  2633. return self;}
  2634. }),
  2635. smalltalk.ProgressBar);
  2636. smalltalk.addClass('TestRunner', smalltalk.TabWidget, ['selectedCategories', 'packagesList', 'selectedClasses', 'classesList', 'selectedMethods', 'progressBar', 'methodsList', 'result', 'statusDiv'], 'IDE');
  2637. smalltalk.addMethod(
  2638. '_label',
  2639. smalltalk.method({
  2640. selector: 'label',
  2641. fn: function (){
  2642. var self=this;
  2643. return "SUnit";
  2644. return self;}
  2645. }),
  2646. smalltalk.TestRunner);
  2647. smalltalk.addMethod(
  2648. '_packages',
  2649. smalltalk.method({
  2650. selector: 'packages',
  2651. fn: function (){
  2652. var self=this;
  2653. var packages=nil;
  2654. packages=smalltalk.send((smalltalk.Array || Array), "_new", []);
  2655. smalltalk.send(smalltalk.send(self, "_allClasses", []), "_do_", [(function(each){return (($receiver = smalltalk.send(packages, "_includes_", [smalltalk.send(each, "_category", [])])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return smalltalk.send(packages, "_add_", [smalltalk.send(each, "_category", [])]);})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return smalltalk.send(packages, "_add_", [smalltalk.send(each, "_category", [])]);})]);})]);
  2656. return smalltalk.send(packages, "_sort", []);
  2657. return self;}
  2658. }),
  2659. smalltalk.TestRunner);
  2660. smalltalk.addMethod(
  2661. '_classes',
  2662. smalltalk.method({
  2663. selector: 'classes',
  2664. fn: function (){
  2665. var self=this;
  2666. return smalltalk.send(smalltalk.send(smalltalk.send(self, "_allClasses", []), "_select_", [(function(each){return smalltalk.send(smalltalk.send(self, "_selectedCategories", []), "_includes_", [smalltalk.send(each, "_category", [])]);})]), "_sort_", [(function(a, b){return (($receiver = smalltalk.send(a, "_name", [])).klass === smalltalk.Number) ? $receiver >smalltalk.send(b, "_name", []) : smalltalk.send($receiver, "__gt", [smalltalk.send(b, "_name", [])]);})]);
  2667. return self;}
  2668. }),
  2669. smalltalk.TestRunner);
  2670. smalltalk.addMethod(
  2671. '_selectedCategories',
  2672. smalltalk.method({
  2673. selector: 'selectedCategories',
  2674. fn: function (){
  2675. var self=this;
  2676. return (($receiver = self['@selectedCategories']) == nil || $receiver == undefined) ? (function(){return self['@selectedCategories']=smalltalk.send((smalltalk.Array || Array), "_new", []);})() : $receiver;
  2677. return self;}
  2678. }),
  2679. smalltalk.TestRunner);
  2680. smalltalk.addMethod(
  2681. '_allClasses',
  2682. smalltalk.method({
  2683. selector: 'allClasses',
  2684. fn: function (){
  2685. var self=this;
  2686. return smalltalk.send((smalltalk.TestCase || TestCase), "_allSubclasses", []);
  2687. return self;}
  2688. }),
  2689. smalltalk.TestRunner);
  2690. smalltalk.addMethod(
  2691. '_selectedClasses',
  2692. smalltalk.method({
  2693. selector: 'selectedClasses',
  2694. fn: function (){
  2695. var self=this;
  2696. return (($receiver = self['@selectedClasses']) == nil || $receiver == undefined) ? (function(){return self['@selectedClasses']=smalltalk.send((smalltalk.Array || Array), "_new", []);})() : $receiver;
  2697. return self;}
  2698. }),
  2699. smalltalk.TestRunner);
  2700. smalltalk.addMethod(
  2701. '_progressBar',
  2702. smalltalk.method({
  2703. selector: 'progressBar',
  2704. fn: function (){
  2705. var self=this;
  2706. return (($receiver = self['@progressBar']) == nil || $receiver == undefined) ? (function(){return self['@progressBar']=smalltalk.send((smalltalk.ProgressBar || ProgressBar), "_new", []);})() : $receiver;
  2707. return self;}
  2708. }),
  2709. smalltalk.TestRunner);
  2710. smalltalk.addMethod(
  2711. '_statusInfo',
  2712. smalltalk.method({
  2713. selector: 'statusInfo',
  2714. fn: function (){
  2715. var self=this;
  2716. return smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(self, "_printTotal", []), "__comma", [smalltalk.send(self, "_printPasses", [])]), "__comma", [smalltalk.send(self, "_printErrors", [])]), "__comma", [smalltalk.send(self, "_printFailures", [])]);
  2717. return self;}
  2718. }),
  2719. smalltalk.TestRunner);
  2720. smalltalk.addMethod(
  2721. '_result',
  2722. smalltalk.method({
  2723. selector: 'result',
  2724. fn: function (){
  2725. var self=this;
  2726. return self['@result'];
  2727. return self;}
  2728. }),
  2729. smalltalk.TestRunner);
  2730. smalltalk.addMethod(
  2731. '_testCases',
  2732. smalltalk.method({
  2733. selector: 'testCases',
  2734. fn: function (){
  2735. var self=this;
  2736. var testCases=nil;
  2737. testCases=[];
  2738. smalltalk.send(smalltalk.send(self, "_selectedClasses", []), "_do_", [(function(each){return smalltalk.send(testCases, "_addAll_", [smalltalk.send(each, "_buildSuite", [])]);})]);
  2739. return testCases;
  2740. return self;}
  2741. }),
  2742. smalltalk.TestRunner);
  2743. smalltalk.addMethod(
  2744. '_selectAllCategories',
  2745. smalltalk.method({
  2746. selector: 'selectAllCategories',
  2747. fn: function (){
  2748. var self=this;
  2749. smalltalk.send(smalltalk.send(self, "_packages", []), "_do_", [(function(each){return (($receiver = smalltalk.send(self['@selectedCategories'], "_includes_", [each])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return smalltalk.send(smalltalk.send(self, "_selectedCategories", []), "_add_", [each]);})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return smalltalk.send(smalltalk.send(self, "_selectedCategories", []), "_add_", [each]);})]);})]);
  2750. (function($rec){smalltalk.send($rec, "_updateCategoriesList", []);return smalltalk.send($rec, "_updateClassesList", []);})(self);
  2751. return self;}
  2752. }),
  2753. smalltalk.TestRunner);
  2754. smalltalk.addMethod(
  2755. '_toggleCategory_',
  2756. smalltalk.method({
  2757. selector: 'toggleCategory:',
  2758. fn: function (aCategory){
  2759. var self=this;
  2760. (($receiver = smalltalk.send(self, "_isSelectedCategory_", [aCategory])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return smalltalk.send(self['@selectedCategories'], "_add_", [aCategory]);})() : (function(){return smalltalk.send(self['@selectedCategories'], "_remove_", [aCategory]);})()) : smalltalk.send($receiver, "_ifFalse_ifTrue_", [(function(){return smalltalk.send(self['@selectedCategories'], "_add_", [aCategory]);}), (function(){return smalltalk.send(self['@selectedCategories'], "_remove_", [aCategory]);})]);
  2761. (function($rec){smalltalk.send($rec, "_updateCategoriesList", []);return smalltalk.send($rec, "_updateClassesList", []);})(self);
  2762. return self;}
  2763. }),
  2764. smalltalk.TestRunner);
  2765. smalltalk.addMethod(
  2766. '_toggleClass_',
  2767. smalltalk.method({
  2768. selector: 'toggleClass:',
  2769. fn: function (aClass){
  2770. var self=this;
  2771. (($receiver = smalltalk.send(self, "_isSelectedClass_", [aClass])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return smalltalk.send(self['@selectedClasses'], "_add_", [aClass]);})() : (function(){return smalltalk.send(self['@selectedClasses'], "_remove_", [aClass]);})()) : smalltalk.send($receiver, "_ifFalse_ifTrue_", [(function(){return smalltalk.send(self['@selectedClasses'], "_add_", [aClass]);}), (function(){return smalltalk.send(self['@selectedClasses'], "_remove_", [aClass]);})]);
  2772. smalltalk.send(self, "_updateClassesList", []);
  2773. return self;}
  2774. }),
  2775. smalltalk.TestRunner);
  2776. smalltalk.addMethod(
  2777. '_selectAllClasses',
  2778. smalltalk.method({
  2779. selector: 'selectAllClasses',
  2780. fn: function (){
  2781. var self=this;
  2782. smalltalk.send(smalltalk.send(self, "_classes", []), "_do_", [(function(each){return (($receiver = smalltalk.send(self['@selectedClasses'], "_includes_", [each])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return smalltalk.send(smalltalk.send(self, "_selectedClasses", []), "_add_", [each]);})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return smalltalk.send(smalltalk.send(self, "_selectedClasses", []), "_add_", [each]);})]);})]);
  2783. (function($rec){smalltalk.send($rec, "_updateCategoriesList", []);return smalltalk.send($rec, "_updateClassesList", []);})(self);
  2784. return self;}
  2785. }),
  2786. smalltalk.TestRunner);
  2787. smalltalk.addMethod(
  2788. '_run_',
  2789. smalltalk.method({
  2790. selector: 'run:',
  2791. fn: function (aCollection){
  2792. var self=this;
  2793. self['@result']=smalltalk.send((smalltalk.TestResult || TestResult), "_new", []);
  2794. (function($rec){smalltalk.send($rec, "_updateStatusDiv", []);return smalltalk.send($rec, "_updateMethodsList", []);})(self);
  2795. smalltalk.send(smalltalk.send(self, "_progressBar", []), "_updatePercent_", [(0)]);
  2796. smalltalk.send(self['@result'], "_total_", [smalltalk.send(aCollection, "_size", [])]);
  2797. smalltalk.send(aCollection, "_do_", [(function(each){return smalltalk.send((function(){smalltalk.send(each, "_runCaseFor_", [self['@result']]);smalltalk.send(smalltalk.send(self, "_progressBar", []), "_updatePercent_", [(($receiver = (($receiver = smalltalk.send(self['@result'], "_runs", [])).klass === smalltalk.Number) ? $receiver /smalltalk.send(self['@result'], "_total", []) : smalltalk.send($receiver, "__slash", [smalltalk.send(self['@result'], "_total", [])])).klass === smalltalk.Number) ? $receiver *(100) : smalltalk.send($receiver, "__star", [(100)])]);smalltalk.send(self, "_updateStatusDiv", []);return smalltalk.send(self, "_updateMethodsList", []);}), "_valueWithTimeout_", [(100)]);})]);
  2798. return self;}
  2799. }),
  2800. smalltalk.TestRunner);
  2801. smalltalk.addMethod(
  2802. '_performFailure_',
  2803. smalltalk.method({
  2804. selector: 'performFailure:',
  2805. fn: function (aTestCase){
  2806. var self=this;
  2807. smalltalk.send(aTestCase, "_perform_", [smalltalk.send(aTestCase, "_selector", [])]);
  2808. return self;}
  2809. }),
  2810. smalltalk.TestRunner);
  2811. smalltalk.addMethod(
  2812. '_initialize',
  2813. smalltalk.method({
  2814. selector: 'initialize',
  2815. fn: function (){
  2816. var self=this;
  2817. smalltalk.send(self, "_initialize", [], smalltalk.TabWidget);
  2818. self['@result']=smalltalk.send((smalltalk.TestResult || TestResult), "_new", []);
  2819. return self;}
  2820. }),
  2821. smalltalk.TestRunner);
  2822. smalltalk.addMethod(
  2823. '_printErrors',
  2824. smalltalk.method({
  2825. selector: 'printErrors',
  2826. fn: function (){
  2827. var self=this;
  2828. return smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(self, "_result", []), "_errors", []), "_size", []), "_asString", []), "__comma", [unescape("%20errors%2C%20")]);
  2829. return self;}
  2830. }),
  2831. smalltalk.TestRunner);
  2832. smalltalk.addMethod(
  2833. '_printFailures',
  2834. smalltalk.method({
  2835. selector: 'printFailures',
  2836. fn: function (){
  2837. var self=this;
  2838. return smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(self, "_result", []), "_failures", []), "_size", []), "_asString", []), "__comma", [" failures"]);
  2839. return self;}
  2840. }),
  2841. smalltalk.TestRunner);
  2842. smalltalk.addMethod(
  2843. '_printPasses',
  2844. smalltalk.method({
  2845. selector: 'printPasses',
  2846. fn: function (){
  2847. var self=this;
  2848. return smalltalk.send(smalltalk.send((($receiver = (($receiver = smalltalk.send(smalltalk.send(self, "_result", []), "_total", [])).klass === smalltalk.Number) ? $receiver -smalltalk.send(smalltalk.send(smalltalk.send(self, "_result", []), "_errors", []), "_size", []) : smalltalk.send($receiver, "__minus", [smalltalk.send(smalltalk.send(smalltalk.send(self, "_result", []), "_errors", []), "_size", [])])).klass === smalltalk.Number) ? $receiver -smalltalk.send(smalltalk.send(smalltalk.send(self, "_result", []), "_failures", []), "_size", []) : smalltalk.send($receiver, "__minus", [smalltalk.send(smalltalk.send(smalltalk.send(self, "_result", []), "_failures", []), "_size", [])]), "_asString", []), "__comma", [unescape("%20passes%2C%20")]);
  2849. return self;}
  2850. }),
  2851. smalltalk.TestRunner);
  2852. smalltalk.addMethod(
  2853. '_printTotal',
  2854. smalltalk.method({
  2855. selector: 'printTotal',
  2856. fn: function (){
  2857. var self=this;
  2858. return smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(self, "_result", []), "_total", []), "_asString", []), "__comma", [unescape("%20runs%2C%20")]);
  2859. return self;}
  2860. }),
  2861. smalltalk.TestRunner);
  2862. smalltalk.addMethod(
  2863. '_renderBoxOn_',
  2864. smalltalk.method({
  2865. selector: 'renderBoxOn:',
  2866. fn: function (html){
  2867. var self=this;
  2868. (function($rec){smalltalk.send($rec, "_renderCategoriesOn_", [html]);smalltalk.send($rec, "_renderClassesOn_", [html]);return smalltalk.send($rec, "_renderResultsOn_", [html]);})(self);
  2869. return self;}
  2870. }),
  2871. smalltalk.TestRunner);
  2872. smalltalk.addMethod(
  2873. '_renderButtonsOn_',
  2874. smalltalk.method({
  2875. selector: 'renderButtonsOn:',
  2876. fn: function (html){
  2877. var self=this;
  2878. (function($rec){smalltalk.send($rec, "_with_", ["Run selected"]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_run_", [smalltalk.send(self, "_testCases", [])]);})]);})(smalltalk.send(html, "_button", []));
  2879. return self;}
  2880. }),
  2881. smalltalk.TestRunner);
  2882. smalltalk.addMethod(
  2883. '_renderCategoriesOn_',
  2884. smalltalk.method({
  2885. selector: 'renderCategoriesOn:',
  2886. fn: function (html){
  2887. var self=this;
  2888. self['@packagesList']=smalltalk.send(smalltalk.send(html, "_ul", []), "_class_", ["jt_column sunit packages"]);
  2889. smalltalk.send(self, "_updateCategoriesList", []);
  2890. return self;}
  2891. }),
  2892. smalltalk.TestRunner);
  2893. smalltalk.addMethod(
  2894. '_renderClassesOn_',
  2895. smalltalk.method({
  2896. selector: 'renderClassesOn:',
  2897. fn: function (html){
  2898. var self=this;
  2899. self['@classesList']=smalltalk.send(smalltalk.send(html, "_ul", []), "_class_", ["jt_column sunit classes"]);
  2900. smalltalk.send(self, "_updateClassesList", []);
  2901. return self;}
  2902. }),
  2903. smalltalk.TestRunner);
  2904. smalltalk.addMethod(
  2905. '_renderResultsOn_',
  2906. smalltalk.method({
  2907. selector: 'renderResultsOn:',
  2908. fn: function (html){
  2909. var self=this;
  2910. self['@statusDiv']=smalltalk.send(html, "_div", []);
  2911. smalltalk.send(html, "_with_", [smalltalk.send(self, "_progressBar", [])]);
  2912. self['@methodsList']=smalltalk.send(smalltalk.send(html, "_ul", []), "_class_", ["jt_column sunit results"]);
  2913. smalltalk.send(self, "_updateMethodsList", []);
  2914. smalltalk.send(self, "_updateStatusDiv", []);
  2915. return self;}
  2916. }),
  2917. smalltalk.TestRunner);
  2918. smalltalk.addMethod(
  2919. '_renderFailuresOn_',
  2920. smalltalk.method({
  2921. selector: 'renderFailuresOn:',
  2922. fn: function (html){
  2923. var self=this;
  2924. smalltalk.send(smalltalk.send(smalltalk.send(self, "_result", []), "_failures", []), "_do_", [(function(each){return (function($rec){smalltalk.send($rec, "_class_", ["failures"]);smalltalk.send($rec, "_with_", [smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(each, "_class", []), "_name", []), "__comma", [unescape("%20%3E%3E%20")]), "__comma", [smalltalk.send(each, "_selector", [])])]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_performFailure_", [each]);})]);})(smalltalk.send(html, "_li", []));})]);
  2925. return self;}
  2926. }),
  2927. smalltalk.TestRunner);
  2928. smalltalk.addMethod(
  2929. '_renderErrorsOn_',
  2930. smalltalk.method({
  2931. selector: 'renderErrorsOn:',
  2932. fn: function (html){
  2933. var self=this;
  2934. smalltalk.send(smalltalk.send(smalltalk.send(self, "_result", []), "_errors", []), "_do_", [(function(each){return (function($rec){smalltalk.send($rec, "_class_", ["errors"]);smalltalk.send($rec, "_with_", [smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(each, "_class", []), "_name", []), "__comma", [unescape("%20%3E%3E%20")]), "__comma", [smalltalk.send(each, "_selector", [])])]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_performFailure_", [each]);})]);})(smalltalk.send(html, "_li", []));})]);
  2935. return self;}
  2936. }),
  2937. smalltalk.TestRunner);
  2938. smalltalk.addMethod(
  2939. '_isSelectedClass_',
  2940. smalltalk.method({
  2941. selector: 'isSelectedClass:',
  2942. fn: function (aClass){
  2943. var self=this;
  2944. return smalltalk.send(smalltalk.send(self, "_selectedClasses", []), "_includes_", [aClass]);
  2945. return self;}
  2946. }),
  2947. smalltalk.TestRunner);
  2948. smalltalk.addMethod(
  2949. '_isSelectedCategory_',
  2950. smalltalk.method({
  2951. selector: 'isSelectedCategory:',
  2952. fn: function (aCategory){
  2953. var self=this;
  2954. return smalltalk.send(smalltalk.send(self, "_selectedCategories", []), "_includes_", [aCategory]);
  2955. return self;}
  2956. }),
  2957. smalltalk.TestRunner);
  2958. smalltalk.addMethod(
  2959. '_updateCategoriesList',
  2960. smalltalk.method({
  2961. selector: 'updateCategoriesList',
  2962. fn: function (){
  2963. var self=this;
  2964. smalltalk.send(self['@packagesList'], "_contents_", [(function(html){(function($rec){smalltalk.send($rec, "_class_", ["all"]);smalltalk.send($rec, "_with_", ["All"]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_selectAllCategories", []);})]);})(smalltalk.send(html, "_li", []));return smalltalk.send(smalltalk.send(self, "_packages", []), "_do_", [(function(each){var li=nil;
  2965. li=smalltalk.send(html, "_li", []);(($receiver = smalltalk.send(smalltalk.send(self, "_selectedCategories", []), "_includes_", [each])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(li, "_class_", ["selected"]);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return smalltalk.send(li, "_class_", ["selected"]);})]);return (function($rec){smalltalk.send($rec, "_with_", [each]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_toggleCategory_", [each]);})]);})(li);})]);})]);
  2966. return self;}
  2967. }),
  2968. smalltalk.TestRunner);
  2969. smalltalk.addMethod(
  2970. '_updateClassesList',
  2971. smalltalk.method({
  2972. selector: 'updateClassesList',
  2973. fn: function (){
  2974. var self=this;
  2975. smalltalk.send(self['@classesList'], "_contents_", [(function(html){(($receiver = smalltalk.send(smalltalk.send(self, "_selectedCategories", []), "_isEmpty", [])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return (function($rec){smalltalk.send($rec, "_class_", ["all"]);smalltalk.send($rec, "_with_", ["All"]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_selectAllClasses", []);})]);})(smalltalk.send(html, "_li", []));})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return (function($rec){smalltalk.send($rec, "_class_", ["all"]);smalltalk.send($rec, "_with_", ["All"]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_selectAllClasses", []);})]);})(smalltalk.send(html, "_li", []));})]);return smalltalk.send(smalltalk.send(self, "_classes", []), "_do_", [(function(each){var li=nil;
  2976. li=smalltalk.send(html, "_li", []);(($receiver = smalltalk.send(smalltalk.send(self, "_selectedClasses", []), "_includes_", [each])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(li, "_class_", ["selected"]);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return smalltalk.send(li, "_class_", ["selected"]);})]);return (function($rec){smalltalk.send($rec, "_with_", [smalltalk.send(each, "_name", [])]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_toggleClass_", [each]);})]);})(li);})]);})]);
  2977. return self;}
  2978. }),
  2979. smalltalk.TestRunner);
  2980. smalltalk.addMethod(
  2981. '_updateMethodsList',
  2982. smalltalk.method({
  2983. selector: 'updateMethodsList',
  2984. fn: function (){
  2985. var self=this;
  2986. smalltalk.send(self['@methodsList'], "_contents_", [(function(html){smalltalk.send(self, "_renderErrorsOn_", [html]);return smalltalk.send(self, "_renderFailuresOn_", [html]);})]);
  2987. return self;}
  2988. }),
  2989. smalltalk.TestRunner);
  2990. smalltalk.addMethod(
  2991. '_updateStatusDiv',
  2992. smalltalk.method({
  2993. selector: 'updateStatusDiv',
  2994. fn: function (){
  2995. var self=this;
  2996. smalltalk.send(self['@statusDiv'], "_class_", [smalltalk.send("sunit status ", "__comma", [smalltalk.send(self['@result'], "_status", [])])]);
  2997. smalltalk.send(self['@statusDiv'], "_contents_", [(function(html){return smalltalk.send(smalltalk.send(html, "_span", []), "_with_", [smalltalk.send(self, "_statusInfo", [])]);})]);
  2998. return self;}
  2999. }),
  3000. smalltalk.TestRunner);
  3001. smalltalk.addMethod(
  3002. '_inspect',
  3003. smalltalk.method({
  3004. selector: 'inspect',
  3005. fn: function (){
  3006. var self=this;
  3007. (function($rec){smalltalk.send($rec, "_inspect_", [self]);return smalltalk.send($rec, "_open", []);})(smalltalk.send((smalltalk.Inspector || Inspector), "_new", []));
  3008. return self;}
  3009. }),
  3010. smalltalk.Object);
  3011. smalltalk.addMethod(
  3012. '_inspectOn_',
  3013. smalltalk.method({
  3014. selector: 'inspectOn:',
  3015. fn: function (anInspector){
  3016. var self=this;
  3017. var variables=nil;
  3018. variables=smalltalk.send((smalltalk.Dictionary || Dictionary), "_new", []);
  3019. smalltalk.send(variables, "_at_put_", [unescape("%23self"), self]);
  3020. smalltalk.send(smalltalk.send(smalltalk.send(self, "_class", []), "_allInstanceVariableNames", []), "_do_", [(function(each){return smalltalk.send(variables, "_at_put_", [each, smalltalk.send(self, "_instVarAt_", [each])]);})]);
  3021. (function($rec){smalltalk.send($rec, "_setLabel_", [smalltalk.send(self, "_printString", [])]);return smalltalk.send($rec, "_setVariables_", [variables]);})(anInspector);
  3022. return self;}
  3023. }),
  3024. smalltalk.Object);
  3025. smalltalk.addMethod(
  3026. '_inspectOn_',
  3027. smalltalk.method({
  3028. selector: 'inspectOn:',
  3029. fn: function (anInspector){
  3030. var self=this;
  3031. var variables=nil;
  3032. variables=smalltalk.send((smalltalk.Dictionary || Dictionary), "_new", []);
  3033. smalltalk.send(variables, "_at_put_", [unescape("%23self"), self]);
  3034. smalltalk.send(variables, "_at_put_", [unescape("%23year"), smalltalk.send(self, "_year", [])]);
  3035. smalltalk.send(variables, "_at_put_", [unescape("%23month"), smalltalk.send(self, "_month", [])]);
  3036. smalltalk.send(variables, "_at_put_", [unescape("%23day"), smalltalk.send(self, "_day", [])]);
  3037. smalltalk.send(variables, "_at_put_", [unescape("%23hours"), smalltalk.send(self, "_hours", [])]);
  3038. smalltalk.send(variables, "_at_put_", [unescape("%23minutes"), smalltalk.send(self, "_minutes", [])]);
  3039. smalltalk.send(variables, "_at_put_", [unescape("%23seconds"), smalltalk.send(self, "_seconds", [])]);
  3040. smalltalk.send(variables, "_at_put_", [unescape("%23milliseconds"), smalltalk.send(self, "_milliseconds", [])]);
  3041. (function($rec){smalltalk.send($rec, "_setLabel_", [smalltalk.send(self, "_printString", [])]);return smalltalk.send($rec, "_setVariables_", [variables]);})(anInspector);
  3042. return self;}
  3043. }),
  3044. smalltalk.Date);
  3045. smalltalk.addMethod(
  3046. '_inspectOn_',
  3047. smalltalk.method({
  3048. selector: 'inspectOn:',
  3049. fn: function (anInspector){
  3050. var self=this;
  3051. var variables=nil;
  3052. variables=smalltalk.send((smalltalk.Dictionary || Dictionary), "_new", []);
  3053. smalltalk.send(variables, "_at_put_", [unescape("%23self"), self]);
  3054. smalltalk.send(self, "_withIndexDo_", [(function(each, i){return smalltalk.send(variables, "_at_put_", [i, each]);})]);
  3055. (function($rec){smalltalk.send($rec, "_setLabel_", [smalltalk.send(self, "_printString", [])]);return smalltalk.send($rec, "_setVariables_", [variables]);})(anInspector);
  3056. return self;}
  3057. }),
  3058. smalltalk.Collection);
  3059. smalltalk.addMethod(
  3060. '_inspectOn_',
  3061. smalltalk.method({
  3062. selector: 'inspectOn:',
  3063. fn: function (anInspector){
  3064. var self=this;
  3065. var label=nil;
  3066. smalltalk.send(self, "_inspectOn_", [anInspector], smalltalk.SequenceableCollection);
  3067. (($receiver = (($receiver = smalltalk.send(smalltalk.send(self, "_printString", []), "_size", [])).klass === smalltalk.Number) ? $receiver >(30) : smalltalk.send($receiver, "__gt", [(30)])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return label=smalltalk.send(smalltalk.send(smalltalk.send(self, "_printString", []), "_copyFrom_to_", [(1), (30)]), "__comma", [unescape("...%27")]);})() : (function(){return label=smalltalk.send(self, "_printString", []);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return label=smalltalk.send(smalltalk.send(smalltalk.send(self, "_printString", []), "_copyFrom_to_", [(1), (30)]), "__comma", [unescape("...%27")]);}), (function(){return label=smalltalk.send(self, "_printString", []);})]);
  3068. smalltalk.send(anInspector, "_setLabel_", [label]);
  3069. return self;}
  3070. }),
  3071. smalltalk.String);
  3072. smalltalk.addMethod(
  3073. '_inspectOn_',
  3074. smalltalk.method({
  3075. selector: 'inspectOn:',
  3076. fn: function (anInspector){
  3077. var self=this;
  3078. var variables=nil;
  3079. variables=smalltalk.send((smalltalk.Dictionary || Dictionary), "_new", []);
  3080. smalltalk.send(variables, "_at_put_", [unescape("%23self"), self]);
  3081. smalltalk.send(variables, "_at_put_", [unescape("%23home"), smalltalk.send(self, "_home", [])]);
  3082. smalltalk.send(variables, "_at_put_", [unescape("%23receiver"), smalltalk.send(self, "_receiver", [])]);
  3083. smalltalk.send(variables, "_at_put_", [unescape("%23selector"), smalltalk.send(self, "_selector", [])]);
  3084. smalltalk.send(variables, "_at_put_", [unescape("%23temps"), smalltalk.send(self, "_temps", [])]);
  3085. smalltalk.send(smalltalk.send(smalltalk.send(self, "_class", []), "_instanceVariableNames", []), "_do_", [(function(each){return smalltalk.send(variables, "_at_put_", [each, smalltalk.send(self, "_instVarAt_", [each])]);})]);
  3086. (function($rec){smalltalk.send($rec, "_setLabel_", [smalltalk.send(self, "_printString", [])]);return smalltalk.send($rec, "_setVariables_", [variables]);})(anInspector);
  3087. return self;}
  3088. }),
  3089. smalltalk.MethodContext);
  3090. smalltalk.addMethod(
  3091. '_inspectOn_',
  3092. smalltalk.method({
  3093. selector: 'inspectOn:',
  3094. fn: function (anInspector){
  3095. var self=this;
  3096. var variables=nil;
  3097. variables=smalltalk.send((smalltalk.Dictionary || Dictionary), "_new", []);
  3098. smalltalk.send(variables, "_at_put_", [unescape("%23self"), self]);
  3099. smalltalk.send(variables, "_at_put_", [unescape("%23keys"), smalltalk.send(self, "_keys", [])]);
  3100. smalltalk.send(self, "_keysAndValuesDo_", [(function(key, value){return smalltalk.send(variables, "_at_put_", [key, value]);})]);
  3101. (function($rec){smalltalk.send($rec, "_setLabel_", [smalltalk.send(self, "_printString", [])]);return smalltalk.send($rec, "_setVariables_", [variables]);})(anInspector);
  3102. return self;}
  3103. }),
  3104. smalltalk.Dictionary);