1
0

IDE.js 152 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537253825392540254125422543254425452546254725482549255025512552255325542555255625572558255925602561256225632564256525662567256825692570257125722573257425752576257725782579258025812582258325842585258625872588258925902591259225932594259525962597259825992600260126022603260426052606260726082609261026112612261326142615261626172618261926202621262226232624262526262627262826292630263126322633263426352636263726382639264026412642264326442645264626472648264926502651265226532654265526562657265826592660266126622663266426652666266726682669267026712672267326742675267626772678267926802681268226832684268526862687268826892690269126922693269426952696269726982699270027012702270327042705270627072708270927102711271227132714
  1. smalltalk.addClass('TabManager', smalltalk.Widget, ['selectedTab', 'tabs', 'opened', 'ul'], 'IDE');
  2. smalltalk.addMethod(
  3. '_tabs',
  4. smalltalk.method({
  5. selector: 'tabs',
  6. category: 'accessing',
  7. fn: function (){
  8. var self=this;
  9. return smalltalk.send(self['@tabs'], "_ifNil_", [(function(){return self['@tabs']=smalltalk.send(smalltalk.Array, "_new", []);})]);
  10. return self;},
  11. source: unescape('tabs%0A%20%20%20%20%5Etabs%20ifNil%3A%20%5Btabs%20%3A%3D%20Array%20new%5D'),
  12. messageSends: ["ifNil:", "new"],
  13. referencedClasses: [smalltalk.Array]
  14. }),
  15. smalltalk.TabManager);
  16. smalltalk.addMethod(
  17. '_updateBodyMargin',
  18. smalltalk.method({
  19. selector: 'updateBodyMargin',
  20. category: 'actions',
  21. fn: function (){
  22. var self=this;
  23. smalltalk.send(self, "_setBodyMargin_", [smalltalk.send(smalltalk.send(smalltalk.send(unescape("%23jtalk"), "_asJQuery", []), "_height", []), "__plus", [(27)])]);
  24. return self;},
  25. source: unescape('updateBodyMargin%0A%20%20%20%20self%20setBodyMargin%3A%20%27%23jtalk%27%20asJQuery%20height%20+%2027'),
  26. messageSends: ["setBodyMargin:", unescape("+"), "height", "asJQuery"],
  27. referencedClasses: []
  28. }),
  29. smalltalk.TabManager);
  30. smalltalk.addMethod(
  31. '_updatePosition',
  32. smalltalk.method({
  33. selector: 'updatePosition',
  34. category: 'actions',
  35. fn: function (){
  36. var self=this;
  37. jQuery('#jtalk').css('top', '').css('bottom', '27px');
  38. return self;},
  39. source: unescape('updatePosition%0A%20%20%20%20%3CjQuery%28%27%23jtalk%27%29.css%28%27top%27%2C%20%27%27%29.css%28%27bottom%27%2C%20%2727px%27%29%3E'),
  40. messageSends: [],
  41. referencedClasses: []
  42. }),
  43. smalltalk.TabManager);
  44. smalltalk.addMethod(
  45. '_removeBodyMargin',
  46. smalltalk.method({
  47. selector: 'removeBodyMargin',
  48. category: 'actions',
  49. fn: function (){
  50. var self=this;
  51. smalltalk.send(self, "_setBodyMargin_", [(0)]);
  52. return self;},
  53. source: unescape('removeBodyMargin%0A%20%20%20%20self%20setBodyMargin%3A%200'),
  54. messageSends: ["setBodyMargin:"],
  55. referencedClasses: []
  56. }),
  57. smalltalk.TabManager);
  58. smalltalk.addMethod(
  59. '_setBodyMargin_',
  60. smalltalk.method({
  61. selector: 'setBodyMargin:',
  62. category: 'actions',
  63. fn: function (anInteger){
  64. var self=this;
  65. smalltalk.send(smalltalk.send(".jtalkBody", "_asJQuery", []), "_cssAt_put_", [unescape("margin-bottom"), smalltalk.send(smalltalk.send(anInteger, "_asString", []), "__comma", ["px"])]);
  66. return self;},
  67. source: unescape('setBodyMargin%3A%20anInteger%0A%20%20%20%20%27.jtalkBody%27%20asJQuery%20cssAt%3A%20%27margin-bottom%27%20put%3A%20anInteger%20asString%2C%20%27px%27'),
  68. messageSends: ["cssAt:put:", "asJQuery", unescape("%2C"), "asString"],
  69. referencedClasses: []
  70. }),
  71. smalltalk.TabManager);
  72. smalltalk.addMethod(
  73. '_onResize_',
  74. smalltalk.method({
  75. selector: 'onResize:',
  76. category: 'actions',
  77. fn: function (aBlock){
  78. var self=this;
  79. jQuery('#jtalk').resizable({
  80. handles: 'n',
  81. resize: aBlock,
  82. minHeight: 230
  83. });
  84. return self;},
  85. source: unescape('onResize%3A%20aBlock%0A%20%20%20%20%3CjQuery%28%27%23jtalk%27%29.resizable%28%7B%0A%09handles%3A%20%27n%27%2C%20%0A%09resize%3A%20aBlock%2C%0A%09minHeight%3A%20230%0A%7D%29%3E'),
  86. messageSends: [],
  87. referencedClasses: []
  88. }),
  89. smalltalk.TabManager);
  90. smalltalk.addMethod(
  91. '_onWindowResize_',
  92. smalltalk.method({
  93. selector: 'onWindowResize:',
  94. category: 'actions',
  95. fn: function (aBlock){
  96. var self=this;
  97. jQuery(window).resize(aBlock);
  98. return self;},
  99. source: unescape('onWindowResize%3A%20aBlock%0A%20%20%20%20%3CjQuery%28window%29.resize%28aBlock%29%3E'),
  100. messageSends: [],
  101. referencedClasses: []
  102. }),
  103. smalltalk.TabManager);
  104. smalltalk.addMethod(
  105. '_open',
  106. smalltalk.method({
  107. selector: 'open',
  108. category: 'actions',
  109. fn: function (){
  110. var self=this;
  111. smalltalk.send(self['@opened'], "_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;})]);
  112. return self;},
  113. source: unescape('open%0A%20%20%20%20opened%20ifFalse%3A%20%5B%0A%09%27body%27%20asJQuery%20addClass%3A%20%27jtalkBody%27.%0A%09%27%23jtalk%27%20asJQuery%20show.%0A%09ul%20asJQuery%20show.%0A%09self%20updateBodyMargin.%0A%09selectedTab%20show.%0A%09opened%20%3A%3D%20true%5D'),
  114. messageSends: ["ifFalse:", "addClass:", "asJQuery", "show", "updateBodyMargin"],
  115. referencedClasses: []
  116. }),
  117. smalltalk.TabManager);
  118. smalltalk.addMethod(
  119. '_close',
  120. smalltalk.method({
  121. selector: 'close',
  122. category: 'actions',
  123. fn: function (){
  124. var self=this;
  125. smalltalk.send(self['@opened'], "_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;})]);
  126. return self;},
  127. source: unescape('close%0A%20%20%20%20opened%20ifTrue%3A%20%5B%0A%09%27%23jtalk%27%20asJQuery%20hide.%0A%09ul%20asJQuery%20hide.%0A%09selectedTab%20hide.%0A%09self%20removeBodyMargin.%0A%09%27body%27%20asJQuery%20removeClass%3A%20%27jtalkBody%27.%0A%09opened%20%3A%3D%20false%5D'),
  128. messageSends: ["ifTrue:", "hide", "asJQuery", "removeBodyMargin", "removeClass:"],
  129. referencedClasses: []
  130. }),
  131. smalltalk.TabManager);
  132. smalltalk.addMethod(
  133. '_newBrowserTab',
  134. smalltalk.method({
  135. selector: 'newBrowserTab',
  136. category: 'actions',
  137. fn: function (){
  138. var self=this;
  139. smalltalk.send(smalltalk.Browser, "_open", []);
  140. return self;},
  141. source: unescape('newBrowserTab%0A%20%20%20%20Browser%20open'),
  142. messageSends: ["open"],
  143. referencedClasses: [smalltalk.nil]
  144. }),
  145. smalltalk.TabManager);
  146. smalltalk.addMethod(
  147. '_selectTab_',
  148. smalltalk.method({
  149. selector: 'selectTab:',
  150. category: 'actions',
  151. fn: function (aWidget){
  152. var self=this;
  153. smalltalk.send(self, "_open", []);
  154. self['@selectedTab']=aWidget;
  155. smalltalk.send(smalltalk.send(self, "_tabs", []), "_do_", [(function(each){return smalltalk.send(each, "_hide", []);})]);
  156. smalltalk.send(aWidget, "_show", []);
  157. smalltalk.send(self, "_update", []);
  158. return self;},
  159. source: unescape('selectTab%3A%20aWidget%0A%20%20%20%20self%20open.%0A%20%20%20%20selectedTab%20%3A%3D%20aWidget.%0A%20%20%20%20self%20tabs%20do%3A%20%5B%3Aeach%20%7C%0A%09each%20hide%5D.%0A%20%20%20%20aWidget%20show.%0A%09%0A%20%20%20%20self%20update'),
  160. messageSends: ["open", "do:", "tabs", "hide", "show", "update"],
  161. referencedClasses: []
  162. }),
  163. smalltalk.TabManager);
  164. smalltalk.addMethod(
  165. '_closeTab_',
  166. smalltalk.method({
  167. selector: 'closeTab:',
  168. category: 'actions',
  169. fn: function (aWidget){
  170. var self=this;
  171. smalltalk.send(self, "_removeTab_", [aWidget]);
  172. smalltalk.send(self, "_selectTab_", [smalltalk.send(smalltalk.send(self, "_tabs", []), "_last", [])]);
  173. smalltalk.send(aWidget, "_remove", []);
  174. smalltalk.send(self, "_update", []);
  175. return self;},
  176. source: unescape('closeTab%3A%20aWidget%0A%20%20%20%20self%20removeTab%3A%20aWidget.%0A%20%20%20%20self%20selectTab%3A%20self%20tabs%20last.%0A%20%20%20%20aWidget%20remove.%0A%20%20%20%20self%20update'),
  177. messageSends: ["removeTab:", "selectTab:", "last", "tabs", "remove", "update"],
  178. referencedClasses: []
  179. }),
  180. smalltalk.TabManager);
  181. smalltalk.addMethod(
  182. '_addTab_',
  183. smalltalk.method({
  184. selector: 'addTab:',
  185. category: 'adding/Removing',
  186. fn: function (aWidget){
  187. var self=this;
  188. smalltalk.send(smalltalk.send(self, "_tabs", []), "_add_", [aWidget]);
  189. smalltalk.send(smalltalk.send(unescape("%23jtalk"), "_asJQuery", []), "_append_", [aWidget]);
  190. smalltalk.send(aWidget, "_hide", []);
  191. return self;},
  192. source: unescape('addTab%3A%20aWidget%0A%20%20%20%20self%20tabs%20add%3A%20aWidget.%0A%20%20%20%20%27%23jtalk%27%20asJQuery%20append%3A%20aWidget.%0A%20%20%20%20aWidget%20hide'),
  193. messageSends: ["add:", "tabs", "append:", "asJQuery", "hide"],
  194. referencedClasses: []
  195. }),
  196. smalltalk.TabManager);
  197. smalltalk.addMethod(
  198. '_removeTab_',
  199. smalltalk.method({
  200. selector: 'removeTab:',
  201. category: 'adding/Removing',
  202. fn: function (aWidget){
  203. var self=this;
  204. smalltalk.send(smalltalk.send(self, "_tabs", []), "_remove_", [aWidget]);
  205. smalltalk.send(self, "_update", []);
  206. return self;},
  207. source: unescape('removeTab%3A%20aWidget%0A%20%20%20%20self%20tabs%20remove%3A%20aWidget.%0A%20%20%20%20self%20update'),
  208. messageSends: ["remove:", "tabs", "update"],
  209. referencedClasses: []
  210. }),
  211. smalltalk.TabManager);
  212. smalltalk.addMethod(
  213. '_initialize',
  214. smalltalk.method({
  215. selector: 'initialize',
  216. category: 'initialization',
  217. fn: function (){
  218. var self=this;
  219. smalltalk.send(self, "_initialize", [], smalltalk.Widget);
  220. self['@opened']=true;
  221. (function($rec){smalltalk.send($rec, "_append_", [self]);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", []));
  222. (function($rec){smalltalk.send($rec, "_addTab_", [smalltalk.send(smalltalk.Transcript, "_current", [])]);return smalltalk.send($rec, "_addTab_", [smalltalk.send(smalltalk.Workspace, "_new", [])]);})(self);
  223. smalltalk.send(self, "_selectTab_", [smalltalk.send(smalltalk.send(self, "_tabs", []), "_last", [])]);
  224. (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);
  225. return self;},
  226. source: unescape('initialize%0A%20%20%20%20super%20initialize.%0A%20%20%20%20opened%20%3A%3D%20true.%0A%20%20%20%20%27body%27%20asJQuery%20%0A%09append%3A%20self%3B%0A%09append%3A%20%5B%3Ahtml%20%7C%20html%20div%20id%3A%20%27jtalk%27%5D%3B%0A%09addClass%3A%20%27jtalkBody%27.%0A%20%20%20%20self%20%0A%09addTab%3A%20Transcript%20current%3B%0A%09addTab%3A%20Workspace%20new.%0A%20%20%20%20self%20selectTab%3A%20self%20tabs%20last.%0A%20%20%20%20self%20%0A%09onResize%3A%20%5Bself%20updateBodyMargin%3B%20updatePosition%5D%3B%0A%09onWindowResize%3A%20%5Bself%20updatePosition%5D'),
  227. messageSends: ["initialize", "append:", "id:", "div", "addClass:", "asJQuery", "addTab:", "current", "new", "selectTab:", "last", "tabs", "onResize:", "updateBodyMargin", "updatePosition", "onWindowResize:"],
  228. referencedClasses: [smalltalk.nil,smalltalk.nil]
  229. }),
  230. smalltalk.TabManager);
  231. smalltalk.addMethod(
  232. '_renderOn_',
  233. smalltalk.method({
  234. selector: 'renderOn:',
  235. category: 'rendering',
  236. fn: function (html){
  237. var self=this;
  238. self['@ul']=(function($rec){smalltalk.send($rec, "_id_", ["jtalkTabs"]);return smalltalk.send($rec, "_yourself", []);})(smalltalk.send(html, "_ul", []));
  239. smalltalk.send(self, "_renderTabs", []);
  240. return self;},
  241. source: unescape('renderOn%3A%20html%0A%09ul%20%3A%3D%20html%20ul%0A%09%09id%3A%20%27jtalkTabs%27%3B%0A%09%09yourself.%0A%09self%20renderTabs'),
  242. messageSends: ["id:", "yourself", "ul", "renderTabs"],
  243. referencedClasses: []
  244. }),
  245. smalltalk.TabManager);
  246. smalltalk.addMethod(
  247. '_renderTabFor_on_',
  248. smalltalk.method({
  249. selector: 'renderTabFor:on:',
  250. category: 'rendering',
  251. fn: function (aWidget, html){
  252. var self=this;
  253. var li=nil;
  254. li=smalltalk.send(html, "_li", []);
  255. smalltalk.send(smalltalk.send(self['@selectedTab'], "__eq", [aWidget]), "_ifTrue_", [(function(){return smalltalk.send(li, "_class_", ["selected"]);})]);
  256. smalltalk.send(li, "_with_", [(function(){(function($rec){smalltalk.send($rec, "_with_", [smalltalk.send(aWidget, "_label", [])]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_selectTab_", [aWidget]);})]);})(smalltalk.send(html, "_span", []));return smalltalk.send(smalltalk.send(aWidget, "_canBeClosed", []), "_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", []));})]);})]);
  257. return self;},
  258. source: unescape('renderTabFor%3A%20aWidget%20on%3A%20html%0A%20%20%20%20%7C%20li%20%7C%0A%20%20%20%20li%20%3A%3D%20html%20li.%0A%20%20%20%20selectedTab%20%3D%20aWidget%20ifTrue%3A%20%5B%0A%09li%20class%3A%20%27selected%27%5D.%0A%20%20%20%20li%20with%3A%20%5B%0A%09html%20span%0A%09%20%20%20%20with%3A%20aWidget%20label%3B%0A%09%20%20%20%20onClick%3A%20%5Bself%20selectTab%3A%20aWidget%5D.%0A%09aWidget%20canBeClosed%20ifTrue%3A%20%5B%0A%09%20%20%20%20html%20span%20%0A%09%09class%3A%20%27close%27%3B%0A%09%09with%3A%20%27x%27%3B%0A%09%09onClick%3A%20%5Bself%20closeTab%3A%20aWidget%5D%5D%5D'),
  259. messageSends: ["li", "ifTrue:", unescape("%3D"), "class:", "with:", "label", "onClick:", "selectTab:", "span", "canBeClosed", "closeTab:"],
  260. referencedClasses: []
  261. }),
  262. smalltalk.TabManager);
  263. smalltalk.addMethod(
  264. '_renderTabs',
  265. smalltalk.method({
  266. selector: 'renderTabs',
  267. category: 'rendering',
  268. fn: function (){
  269. var self=this;
  270. smalltalk.send(self['@ul'], "_contents_", [(function(html){(function($rec){smalltalk.send($rec, "_class_", ["closeAll"]);smalltalk.send($rec, "_with_", ["x"]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_close", []);})]);})(smalltalk.send(html, "_li", []));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_", [unescape("%20+%20")]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_newBrowserTab", []);})]);})(smalltalk.send(html, "_li", []));})]);
  271. return self;},
  272. source: unescape('renderTabs%0A%09ul%20contents%3A%20%5B%3Ahtml%20%7C%0A%09%20%20%20%20html%20li%20%0A%09%09class%3A%20%27closeAll%27%3B%0A%09%09with%3A%20%27x%27%3B%0A%09%09onClick%3A%20%5Bself%20close%5D.%0A%09%20%20%20%20self%20tabs%20do%3A%20%5B%3Aeach%20%7C%0A%09%09self%20renderTabFor%3A%20each%20on%3A%20html%5D.%0A%09%20%20%20%20html%20li%0A%09%09class%3A%20%27newtab%27%3B%0A%09%09with%3A%20%27%20+%20%27%3B%0A%09%09onClick%3A%20%5Bself%20newBrowserTab%5D%5D'),
  273. messageSends: ["contents:", "class:", "with:", "onClick:", "close", "li", "do:", "tabs", "renderTabFor:on:", "newBrowserTab"],
  274. referencedClasses: []
  275. }),
  276. smalltalk.TabManager);
  277. smalltalk.addMethod(
  278. '_update',
  279. smalltalk.method({
  280. selector: 'update',
  281. category: 'updating',
  282. fn: function (){
  283. var self=this;
  284. smalltalk.send(self, "_renderTabs", []);
  285. return self;},
  286. source: unescape('update%0A%09self%20renderTabs'),
  287. messageSends: ["renderTabs"],
  288. referencedClasses: []
  289. }),
  290. smalltalk.TabManager);
  291. smalltalk.TabManager.klass.iVarNames = ['current'];
  292. smalltalk.addMethod(
  293. '_current',
  294. smalltalk.method({
  295. selector: 'current',
  296. category: 'instance creation',
  297. fn: function (){
  298. var self=this;
  299. return smalltalk.send(self['@current'], "_ifNil_", [(function(){return self['@current']=smalltalk.send(self, "_new", [], smalltalk.Widget.klass);})]);
  300. return self;},
  301. source: unescape('current%0A%20%20%20%20%5Ecurrent%20ifNil%3A%20%5Bcurrent%20%3A%3D%20super%20new%5D'),
  302. messageSends: ["ifNil:", "new"],
  303. referencedClasses: []
  304. }),
  305. smalltalk.TabManager.klass);
  306. smalltalk.addMethod(
  307. '_new',
  308. smalltalk.method({
  309. selector: 'new',
  310. category: 'instance creation',
  311. fn: function (){
  312. var self=this;
  313. smalltalk.send(self, "_shouldNotImplement", []);
  314. return self;},
  315. source: unescape('new%0A%20%20%20%20self%20shouldNotImplement'),
  316. messageSends: ["shouldNotImplement"],
  317. referencedClasses: []
  318. }),
  319. smalltalk.TabManager.klass);
  320. smalltalk.addClass('TabWidget', smalltalk.Widget, ['div'], 'IDE');
  321. smalltalk.addMethod(
  322. '_label',
  323. smalltalk.method({
  324. selector: 'label',
  325. category: 'accessing',
  326. fn: function (){
  327. var self=this;
  328. smalltalk.send(self, "_subclassResponsibility", []);
  329. return self;},
  330. source: unescape('label%0A%20%20%20%20self%20subclassResponsibility'),
  331. messageSends: ["subclassResponsibility"],
  332. referencedClasses: []
  333. }),
  334. smalltalk.TabWidget);
  335. smalltalk.addMethod(
  336. '_open',
  337. smalltalk.method({
  338. selector: 'open',
  339. category: 'actions',
  340. fn: function (){
  341. var self=this;
  342. smalltalk.send(smalltalk.send(smalltalk.TabManager, "_current", []), "_addTab_", [self]);
  343. smalltalk.send(smalltalk.send(smalltalk.TabManager, "_current", []), "_selectTab_", [self]);
  344. return self;},
  345. source: unescape('open%0A%20%20%20%20TabManager%20current%20addTab%3A%20self.%0A%20%20%20%20TabManager%20current%20selectTab%3A%20self'),
  346. messageSends: ["addTab:", "current", "selectTab:"],
  347. referencedClasses: [smalltalk.TabManager]
  348. }),
  349. smalltalk.TabWidget);
  350. smalltalk.addMethod(
  351. '_renderOn_',
  352. smalltalk.method({
  353. selector: 'renderOn:',
  354. category: 'rendering',
  355. fn: function (html){
  356. var self=this;
  357. self['@div']=(function($rec){smalltalk.send($rec, "_class_", ["jtalkTool"]);return smalltalk.send($rec, "_yourself", []);})(smalltalk.send(html, "_div", []));
  358. smalltalk.send(self, "_renderTab", []);
  359. return self;},
  360. source: unescape('renderOn%3A%20html%0A%09div%20%3A%3D%20html%20div%0A%09%09class%3A%20%27jtalkTool%27%3B%0A%09%09yourself.%0A%09self%20renderTab'),
  361. messageSends: ["class:", "yourself", "div", "renderTab"],
  362. referencedClasses: []
  363. }),
  364. smalltalk.TabWidget);
  365. smalltalk.addMethod(
  366. '_renderBoxOn_',
  367. smalltalk.method({
  368. selector: 'renderBoxOn:',
  369. category: 'rendering',
  370. fn: function (html){
  371. var self=this;
  372. return self;},
  373. source: unescape('renderBoxOn%3A%20html'),
  374. messageSends: [],
  375. referencedClasses: []
  376. }),
  377. smalltalk.TabWidget);
  378. smalltalk.addMethod(
  379. '_renderButtonsOn_',
  380. smalltalk.method({
  381. selector: 'renderButtonsOn:',
  382. category: 'rendering',
  383. fn: function (html){
  384. var self=this;
  385. return self;},
  386. source: unescape('renderButtonsOn%3A%20html'),
  387. messageSends: [],
  388. referencedClasses: []
  389. }),
  390. smalltalk.TabWidget);
  391. smalltalk.addMethod(
  392. '_canBeClosed',
  393. smalltalk.method({
  394. selector: 'canBeClosed',
  395. category: 'testing',
  396. fn: function (){
  397. var self=this;
  398. return false;
  399. return self;},
  400. source: unescape('canBeClosed%0A%20%20%20%20%5Efalse'),
  401. messageSends: [],
  402. referencedClasses: []
  403. }),
  404. smalltalk.TabWidget);
  405. smalltalk.addMethod(
  406. '_show',
  407. smalltalk.method({
  408. selector: 'show',
  409. category: 'actions',
  410. fn: function (){
  411. var self=this;
  412. smalltalk.send(smalltalk.send(self['@div'], "_asJQuery", []), "_show", []);
  413. return self;},
  414. source: unescape('show%0A%09div%20asJQuery%20show'),
  415. messageSends: ["show", "asJQuery"],
  416. referencedClasses: []
  417. }),
  418. smalltalk.TabWidget);
  419. smalltalk.addMethod(
  420. '_hide',
  421. smalltalk.method({
  422. selector: 'hide',
  423. category: 'actions',
  424. fn: function (){
  425. var self=this;
  426. smalltalk.send(smalltalk.send(self['@div'], "_asJQuery", []), "_hide", []);
  427. return self;},
  428. source: unescape('hide%0A%09div%20asJQuery%20hide'),
  429. messageSends: ["hide", "asJQuery"],
  430. referencedClasses: []
  431. }),
  432. smalltalk.TabWidget);
  433. smalltalk.addMethod(
  434. '_update',
  435. smalltalk.method({
  436. selector: 'update',
  437. category: 'rendering',
  438. fn: function (){
  439. var self=this;
  440. smalltalk.send(self, "_renderTab", []);
  441. return self;},
  442. source: unescape('update%0A%09self%20renderTab'),
  443. messageSends: ["renderTab"],
  444. referencedClasses: []
  445. }),
  446. smalltalk.TabWidget);
  447. smalltalk.addMethod(
  448. '_remove',
  449. smalltalk.method({
  450. selector: 'remove',
  451. category: 'actions',
  452. fn: function (){
  453. var self=this;
  454. smalltalk.send(smalltalk.send(self['@div'], "_asJQuery", []), "_remove", []);
  455. return self;},
  456. source: unescape('remove%0A%09div%20asJQuery%20remove'),
  457. messageSends: ["remove", "asJQuery"],
  458. referencedClasses: []
  459. }),
  460. smalltalk.TabWidget);
  461. smalltalk.addMethod(
  462. '_renderTab',
  463. smalltalk.method({
  464. selector: 'renderTab',
  465. category: 'rendering',
  466. fn: function (){
  467. var self=this;
  468. 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", []));})]);
  469. return self;},
  470. source: unescape('renderTab%0A%09div%20contents%3A%20%5B%3Ahtml%20%7C%0A%09%20%20%20%20html%20div%0A%09%09class%3A%20%27jt_box%27%3B%0A%09%09with%3A%20%5Bself%20renderBoxOn%3A%20html%5D.%0A%09%20%20%20%20html%20div%0A%09%09class%3A%20%27jt_buttons%27%3B%0A%09%09with%3A%20%5Bself%20renderButtonsOn%3A%20html%5D%5D'),
  471. messageSends: ["contents:", "class:", "with:", "renderBoxOn:", "div", "renderButtonsOn:"],
  472. referencedClasses: []
  473. }),
  474. smalltalk.TabWidget);
  475. smalltalk.addMethod(
  476. '_open',
  477. smalltalk.method({
  478. selector: 'open',
  479. category: 'instance creation',
  480. fn: function (){
  481. var self=this;
  482. return smalltalk.send(smalltalk.send(self, "_new", []), "_open", []);
  483. return self;},
  484. source: unescape('open%0A%20%20%20%20%5Eself%20new%20open'),
  485. messageSends: ["open", "new"],
  486. referencedClasses: []
  487. }),
  488. smalltalk.TabWidget.klass);
  489. smalltalk.addClass('Workspace', smalltalk.TabWidget, ['textarea'], 'IDE');
  490. smalltalk.addMethod(
  491. '_label',
  492. smalltalk.method({
  493. selector: 'label',
  494. category: 'accessing',
  495. fn: function (){
  496. var self=this;
  497. return unescape("%5BWorkspace%5D");
  498. return self;},
  499. source: unescape('label%0A%20%20%20%20%5E%27%5BWorkspace%5D%27'),
  500. messageSends: [],
  501. referencedClasses: []
  502. }),
  503. smalltalk.Workspace);
  504. smalltalk.addMethod(
  505. '_selection',
  506. smalltalk.method({
  507. selector: 'selection',
  508. category: 'accessing',
  509. fn: function (){
  510. var self=this;
  511. return document.selection;
  512. return self;},
  513. source: unescape('selection%0A%20%20%20%20%3Creturn%20document.selection%3E'),
  514. messageSends: [],
  515. referencedClasses: []
  516. }),
  517. smalltalk.Workspace);
  518. smalltalk.addMethod(
  519. '_selectionStart',
  520. smalltalk.method({
  521. selector: 'selectionStart',
  522. category: 'accessing',
  523. fn: function (){
  524. var self=this;
  525. return jQuery('.jt_workspace')[0].selectionStart;
  526. return self;},
  527. source: unescape('selectionStart%0A%20%20%20%20%3Creturn%20jQuery%28%27.jt_workspace%27%29%5B0%5D.selectionStart%3E'),
  528. messageSends: [],
  529. referencedClasses: []
  530. }),
  531. smalltalk.Workspace);
  532. smalltalk.addMethod(
  533. '_selectionEnd',
  534. smalltalk.method({
  535. selector: 'selectionEnd',
  536. category: 'accessing',
  537. fn: function (){
  538. var self=this;
  539. return jQuery('.jt_workspace')[0].selectionEnd;
  540. return self;},
  541. source: unescape('selectionEnd%0A%20%20%20%20%3Creturn%20jQuery%28%27.jt_workspace%27%29%5B0%5D.selectionEnd%3E'),
  542. messageSends: [],
  543. referencedClasses: []
  544. }),
  545. smalltalk.Workspace);
  546. smalltalk.addMethod(
  547. '_selectionStart_',
  548. smalltalk.method({
  549. selector: 'selectionStart:',
  550. category: 'accessing',
  551. fn: function (anInteger){
  552. var self=this;
  553. jQuery('.jt_workspace')[0].selectionStart = anInteger;
  554. return self;},
  555. source: unescape('selectionStart%3A%20anInteger%0A%20%20%20%20%3CjQuery%28%27.jt_workspace%27%29%5B0%5D.selectionStart%20%3D%20anInteger%3E'),
  556. messageSends: [],
  557. referencedClasses: []
  558. }),
  559. smalltalk.Workspace);
  560. smalltalk.addMethod(
  561. '_selectionEnd_',
  562. smalltalk.method({
  563. selector: 'selectionEnd:',
  564. category: 'accessing',
  565. fn: function (anInteger){
  566. var self=this;
  567. jQuery('.jt_workspace')[0].selectionEnd = anInteger;
  568. return self;},
  569. source: unescape('selectionEnd%3A%20anInteger%0A%20%20%20%20%3CjQuery%28%27.jt_workspace%27%29%5B0%5D.selectionEnd%20%3D%20anInteger%3E'),
  570. messageSends: [],
  571. referencedClasses: []
  572. }),
  573. smalltalk.Workspace);
  574. smalltalk.addMethod(
  575. '_currentLine',
  576. smalltalk.method({
  577. selector: 'currentLine',
  578. category: 'accessing',
  579. fn: function (){
  580. var self=this;
  581. try{var lines=nil;
  582. var startLine=nil;
  583. var endLine=nil;
  584. lines=smalltalk.send(smalltalk.send(smalltalk.send(self['@textarea'], "_asJQuery", []), "_val", []), "_tokenize_", [smalltalk.send(smalltalk.String, "_lf", [])]);
  585. startLine=endLine=(0);
  586. smalltalk.send(lines, "_do_", [(function(each){endLine=smalltalk.send(startLine, "__plus", [smalltalk.send(each, "_size", [])]);startLine=smalltalk.send(endLine, "__plus", [(1)]);return smalltalk.send(smalltalk.send(endLine, "__gt_eq", [smalltalk.send(self, "_selectionStart", [])]), "_ifTrue_", [(function(){smalltalk.send(self, "_selectionEnd_", [endLine]);return (function(){throw({name: 'stReturn', selector: '_currentLine', fn: function(){return each}})})();})]);})]);
  587. return self;
  588. } catch(e) {if(e.name === 'stReturn' && e.selector === '_currentLine'){return e.fn()} throw(e)}},
  589. source: unescape('currentLine%0A%20%20%20%20%7C%20lines%20startLine%20endLine%7C%0A%20%20%20%20lines%20%3A%3D%20textarea%20asJQuery%20val%20tokenize%3A%20String%20lf.%0A%20%20%20%20startLine%20%3A%3D%20endLine%20%3A%3D%200.%0A%20%20%20%20lines%20do%3A%20%5B%3Aeach%20%7C%0A%09endLine%20%3A%3D%20startLine%20+%20each%20size.%0A%09startLine%20%3A%3D%20endLine%20+%201.%0A%09endLine%20%3E%3D%20self%20selectionStart%20ifTrue%3A%20%5B%0A%09%20%20%20%20self%20selectionEnd%3A%20endLine.%0A%09%20%20%20%20%5Eeach%5D%5D'),
  590. messageSends: ["tokenize:", "val", "asJQuery", "lf", "do:", unescape("+"), "size", "ifTrue:", unescape("%3E%3D"), "selectionStart", "selectionEnd:"],
  591. referencedClasses: [smalltalk.String]
  592. }),
  593. smalltalk.Workspace);
  594. smalltalk.addMethod(
  595. '_handleKeyDown_',
  596. smalltalk.method({
  597. selector: 'handleKeyDown:',
  598. category: 'actions',
  599. fn: function (anEvent){
  600. var self=this;
  601. if(anEvent.ctrlKey) {
  602. if(anEvent.keyCode === 80) { //ctrl+p
  603. self._printIt();
  604. anEvent.preventDefault();
  605. return false;
  606. }
  607. if(anEvent.keyCode === 68) { //ctrl+d
  608. self._doIt();
  609. anEvent.preventDefault();
  610. return false;
  611. }
  612. if(anEvent.keyCode === 73) { //ctrl+i
  613. self._inspectIt();
  614. anEvent.preventDefault();
  615. return false;
  616. }
  617. };
  618. return self;},
  619. source: unescape('handleKeyDown%3A%20anEvent%0A%20%20%20%20%3Cif%28anEvent.ctrlKey%29%20%7B%0A%09%09if%28anEvent.keyCode%20%3D%3D%3D%2080%29%20%7B%20//ctrl+p%0A%09%09%09self._printIt%28%29%3B%0A%09%09%09anEvent.preventDefault%28%29%3B%0A%09%09%09return%20false%3B%0A%09%09%7D%0A%09%09if%28anEvent.keyCode%20%3D%3D%3D%2068%29%20%7B%20//ctrl+d%0A%09%09%09self._doIt%28%29%3B%0A%09%09%09anEvent.preventDefault%28%29%3B%0A%09%09%09return%20false%3B%0A%09%09%7D%0A%09%09if%28anEvent.keyCode%20%3D%3D%3D%2073%29%20%7B%20//ctrl+i%0A%09%09%09self._inspectIt%28%29%3B%0A%09%09%09anEvent.preventDefault%28%29%3B%0A%09%09%09return%20false%3B%0A%09%09%7D%0A%09%7D%3E'),
  620. messageSends: [],
  621. referencedClasses: []
  622. }),
  623. smalltalk.Workspace);
  624. smalltalk.addMethod(
  625. '_clearWorkspace',
  626. smalltalk.method({
  627. selector: 'clearWorkspace',
  628. category: 'actions',
  629. fn: function (){
  630. var self=this;
  631. smalltalk.send(smalltalk.send(self['@textarea'], "_asJQuery", []), "_val_", [""]);
  632. return self;},
  633. source: unescape('clearWorkspace%0A%20%20%20%20textarea%20asJQuery%20val%3A%20%27%27'),
  634. messageSends: ["val:", "asJQuery"],
  635. referencedClasses: []
  636. }),
  637. smalltalk.Workspace);
  638. smalltalk.addMethod(
  639. '_doIt',
  640. smalltalk.method({
  641. selector: 'doIt',
  642. category: 'actions',
  643. fn: function (){
  644. var self=this;
  645. var selection=nil;
  646. smalltalk.send(smalltalk.send(self['@textarea'], "_asJQuery", []), "_focus", []);
  647. smalltalk.send(smalltalk.send(smalltalk.send(self, "_selectionStart", []), "__eq", [smalltalk.send(self, "_selectionEnd", [])]), "_ifTrue_ifFalse_", [(function(){return selection=smalltalk.send(self, "_currentLine", []);}), (function(){return selection=smalltalk.send(smalltalk.send(smalltalk.send(self['@textarea'], "_asJQuery", []), "_val", []), "_copyFrom_to_", [smalltalk.send(smalltalk.send(self, "_selectionStart", []), "__plus", [(1)]), smalltalk.send(smalltalk.send(self, "_selectionEnd", []), "__plus", [(1)])]);})]);
  648. return smalltalk.send(self, "_eval_", [selection]);
  649. return self;},
  650. source: unescape('doIt%0A%20%20%20%20%7C%20selection%20%7C%0A%20%20%20%20textarea%20asJQuery%20focus.%0A%20%20%20%20self%20selectionStart%20%3D%20self%20selectionEnd%0A%09ifTrue%3A%20%5Bselection%20%3A%3D%20self%20currentLine%5D%0A%09ifFalse%3A%20%5B%0A%09%20%20%20%20selection%20%3A%3D%20textarea%20asJQuery%20val%20copyFrom%3A%20self%20selectionStart%20+%201%20to%3A%20self%20selectionEnd%20+%201%5D.%0A%20%20%20%20%5Eself%20eval%3A%20selection'),
  651. messageSends: ["focus", "asJQuery", "ifTrue:ifFalse:", unescape("%3D"), "selectionStart", "selectionEnd", "currentLine", "copyFrom:to:", "val", unescape("+"), "eval:"],
  652. referencedClasses: []
  653. }),
  654. smalltalk.Workspace);
  655. smalltalk.addMethod(
  656. '_printIt',
  657. smalltalk.method({
  658. selector: 'printIt',
  659. category: 'actions',
  660. fn: function (){
  661. var self=this;
  662. smalltalk.send(self, "_print_", [smalltalk.send(smalltalk.send(self, "_doIt", []), "_printString", [])]);
  663. return self;},
  664. source: unescape('printIt%0A%20%20%20%20self%20print%3A%20self%20doIt%20printString'),
  665. messageSends: ["print:", "printString", "doIt"],
  666. referencedClasses: []
  667. }),
  668. smalltalk.Workspace);
  669. smalltalk.addMethod(
  670. '_print_',
  671. smalltalk.method({
  672. selector: 'print:',
  673. category: 'actions',
  674. fn: function (aString){
  675. var self=this;
  676. var start=nil;
  677. start=smalltalk.send(self, "_selectionEnd", []);
  678. smalltalk.send(smalltalk.send(self['@textarea'], "_asJQuery", []), "_val_", [smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(self['@textarea'], "_asJQuery", []), "_val", []), "_copyFrom_to_", [(1), start]), "__comma", [" "]), "__comma", [aString]), "__comma", [" "]), "__comma", [smalltalk.send(smalltalk.send(smalltalk.send(self['@textarea'], "_asJQuery", []), "_val", []), "_copyFrom_to_", [smalltalk.send(start, "__plus", [(1)]), smalltalk.send(smalltalk.send(smalltalk.send(self['@textarea'], "_asJQuery", []), "_val", []), "_size", [])])])]);
  679. smalltalk.send(self, "_selectionStart_", [start]);
  680. smalltalk.send(self, "_selectionEnd_", [smalltalk.send(smalltalk.send(start, "__plus", [smalltalk.send(aString, "_size", [])]), "__plus", [(2)])]);
  681. return self;},
  682. source: unescape('print%3A%20aString%0A%20%20%20%20%7C%20start%20%7C%0A%20%20%20%20start%20%3A%3D%20self%20selectionEnd.%0A%20%20%20%20textarea%20asJQuery%20val%3A%20%28%0A%09%28textarea%20asJQuery%20val%20copyFrom%3A%201%20to%3A%20start%29%2C%0A%09%27%20%27%2C%20aString%2C%20%27%20%27%2C%0A%09%28textarea%20asJQuery%20val%20copyFrom%3A%20start%20+%201%20to%3A%20textarea%20asJQuery%20val%20size%29%29.%0A%20%20%20%20self%20selectionStart%3A%20start.%0A%20%20%20%20self%20selectionEnd%3A%20start%20+%20aString%20size%20+%202'),
  683. messageSends: ["selectionEnd", "val:", "asJQuery", unescape("%2C"), "copyFrom:to:", "val", unescape("+"), "size", "selectionStart:", "selectionEnd:"],
  684. referencedClasses: []
  685. }),
  686. smalltalk.Workspace);
  687. smalltalk.addMethod(
  688. '_eval_',
  689. smalltalk.method({
  690. selector: 'eval:',
  691. category: 'actions',
  692. fn: function (aString){
  693. var self=this;
  694. try{var compiler=nil;
  695. var node=nil;
  696. compiler=smalltalk.send(smalltalk.Compiler, "_new", []);
  697. node=smalltalk.send(compiler, "_parseExpression_", [aString]);
  698. smalltalk.send(smalltalk.send(node, "_isParseFailure", []), "_ifTrue_", [(function(){return (function(){throw({name: 'stReturn', selector: '_eval_', fn: function(){return smalltalk.send(self, "_alert_", [smalltalk.send(smalltalk.send(smalltalk.send(node, "_reason", []), "__comma", [unescape("%2C%20position%3A%20")]), "__comma", [smalltalk.send(node, "_position", [])])])}})})();})]);
  699. (function(){throw({name: 'stReturn', selector: '_eval_', fn: function(){return smalltalk.send(compiler, "_loadExpression_", [aString])}})})();
  700. return self;
  701. } catch(e) {if(e.name === 'stReturn' && e.selector === '_eval_'){return e.fn()} throw(e)}},
  702. source: unescape('eval%3A%20aString%0A%20%20%20%20%7C%20compiler%20node%20%7C%0A%20%20%20%20compiler%20%3A%3D%20Compiler%20new.%0A%20%20%20%20node%20%3A%3D%20compiler%20parseExpression%3A%20aString.%0A%20%20%20%20node%20isParseFailure%20ifTrue%3A%20%5B%0A%09%5Eself%20alert%3A%20node%20reason%2C%20%27%2C%20position%3A%20%27%2C%20node%20position%5D.%0A%20%20%20%20%5Ecompiler%20loadExpression%3A%20aString'),
  703. messageSends: ["new", "parseExpression:", "ifTrue:", "isParseFailure", "alert:", unescape("%2C"), "reason", "position", "loadExpression:"],
  704. referencedClasses: [smalltalk.Compiler]
  705. }),
  706. smalltalk.Workspace);
  707. smalltalk.addMethod(
  708. '_inspectIt',
  709. smalltalk.method({
  710. selector: 'inspectIt',
  711. category: 'actions',
  712. fn: function (){
  713. var self=this;
  714. smalltalk.send(smalltalk.send(self, "_doIt", []), "_inspect", []);
  715. return self;},
  716. source: unescape('inspectIt%0A%20%20%20%20self%20doIt%20inspect'),
  717. messageSends: ["inspect", "doIt"],
  718. referencedClasses: []
  719. }),
  720. smalltalk.Workspace);
  721. smalltalk.addMethod(
  722. '_renderBoxOn_',
  723. smalltalk.method({
  724. selector: 'renderBoxOn:',
  725. category: 'rendering',
  726. fn: function (html){
  727. var self=this;
  728. self['@textarea']=smalltalk.send(html, "_textarea", []);
  729. smalltalk.send(smalltalk.send(self['@textarea'], "_asJQuery", []), "_call_", ["tabby"]);
  730. smalltalk.send(self['@textarea'], "_onKeyDown_", [(function(e){return smalltalk.send(self, "_handleKeyDown_", [e]);})]);
  731. (function($rec){smalltalk.send($rec, "_class_", ["jt_workspace"]);return smalltalk.send($rec, "_at_put_", ["spellcheck", "false"]);})(self['@textarea']);
  732. return self;},
  733. source: unescape('renderBoxOn%3A%20html%0A%20%20%20%20textarea%20%3A%3D%20html%20textarea.%0A%20%20%20%20textarea%20asJQuery%20call%3A%20%27tabby%27.%0A%20%20%20%20textarea%20onKeyDown%3A%20%5B%3Ae%20%7C%20self%20handleKeyDown%3A%20e%5D.%0A%20%20%20%20textarea%20%0A%09class%3A%20%27jt_workspace%27%3B%0A%09at%3A%20%27spellcheck%27%20put%3A%20%27false%27'),
  734. messageSends: ["textarea", "call:", "asJQuery", "onKeyDown:", "handleKeyDown:", "class:", "at:put:"],
  735. referencedClasses: []
  736. }),
  737. smalltalk.Workspace);
  738. smalltalk.addMethod(
  739. '_renderButtonsOn_',
  740. smalltalk.method({
  741. selector: 'renderButtonsOn:',
  742. category: 'rendering',
  743. fn: function (html){
  744. var self=this;
  745. (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", []));
  746. (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", []));
  747. (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", []));
  748. (function($rec){smalltalk.send($rec, "_with_", ["Clear workspace"]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_clearWorkspace", []);})]);})(smalltalk.send(html, "_button", []));
  749. return self;},
  750. source: unescape('renderButtonsOn%3A%20html%0A%20%20%20%20html%20button%0A%09with%3A%20%27DoIt%27%3B%0A%09title%3A%20%27ctrl+d%27%3B%0A%09onClick%3A%20%5Bself%20doIt%5D.%0A%20%20%20%20html%20button%0A%09with%3A%20%27PrintIt%27%3B%0A%09title%3A%20%27ctrl+p%27%3B%0A%09onClick%3A%20%5Bself%20printIt%5D.%0A%20%20%20%20html%20button%0A%09with%3A%20%27InspectIt%27%3B%0A%09title%3A%20%27ctrl+i%27%3B%0A%09onClick%3A%20%5Bself%20inspectIt%5D.%0A%20%20%20%20html%20button%0A%09with%3A%20%27Clear%20workspace%27%3B%0A%09onClick%3A%20%5Bself%20clearWorkspace%5D'),
  751. messageSends: ["with:", "title:", "onClick:", "doIt", "button", "printIt", "inspectIt", "clearWorkspace"],
  752. referencedClasses: []
  753. }),
  754. smalltalk.Workspace);
  755. smalltalk.addClass('Transcript', smalltalk.TabWidget, ['textarea'], 'IDE');
  756. smalltalk.addMethod(
  757. '_label',
  758. smalltalk.method({
  759. selector: 'label',
  760. category: 'accessing',
  761. fn: function (){
  762. var self=this;
  763. return unescape("%5BTranscript%5D");
  764. return self;},
  765. source: unescape('label%0A%20%20%20%20%5E%27%5BTranscript%5D%27'),
  766. messageSends: [],
  767. referencedClasses: []
  768. }),
  769. smalltalk.Transcript);
  770. smalltalk.addMethod(
  771. '_show_',
  772. smalltalk.method({
  773. selector: 'show:',
  774. category: 'actions',
  775. fn: function (anObject){
  776. var self=this;
  777. smalltalk.send(smalltalk.send(self['@textarea'], "_asJQuery", []), "_val_", [smalltalk.send(smalltalk.send(smalltalk.send(self['@textarea'], "_asJQuery", []), "_val", []), "__comma", [smalltalk.send(anObject, "_asString", [])])]);
  778. return self;},
  779. source: unescape('show%3A%20anObject%0A%20%20%20%20textarea%20asJQuery%20val%3A%20textarea%20asJQuery%20val%2C%20anObject%20asString.'),
  780. messageSends: ["val:", "asJQuery", unescape("%2C"), "val", "asString"],
  781. referencedClasses: []
  782. }),
  783. smalltalk.Transcript);
  784. smalltalk.addMethod(
  785. '_cr',
  786. smalltalk.method({
  787. selector: 'cr',
  788. category: 'actions',
  789. fn: function (){
  790. var self=this;
  791. smalltalk.send(smalltalk.send(self['@textarea'], "_asJQuery", []), "_val_", [smalltalk.send(smalltalk.send(smalltalk.send(self['@textarea'], "_asJQuery", []), "_val", []), "__comma", [smalltalk.send(smalltalk.String, "_cr", [])])]);
  792. return self;},
  793. source: unescape('cr%0A%20%20%20%20textarea%20asJQuery%20val%3A%20textarea%20asJQuery%20val%2C%20String%20cr.'),
  794. messageSends: ["val:", "asJQuery", unescape("%2C"), "val", "cr"],
  795. referencedClasses: [smalltalk.String]
  796. }),
  797. smalltalk.Transcript);
  798. smalltalk.addMethod(
  799. '_clear',
  800. smalltalk.method({
  801. selector: 'clear',
  802. category: 'actions',
  803. fn: function (){
  804. var self=this;
  805. smalltalk.send(smalltalk.send(self['@textarea'], "_asJQuery", []), "_val_", [""]);
  806. return self;},
  807. source: unescape('clear%0A%20%20%20%20textarea%20asJQuery%20val%3A%20%27%27'),
  808. messageSends: ["val:", "asJQuery"],
  809. referencedClasses: []
  810. }),
  811. smalltalk.Transcript);
  812. smalltalk.addMethod(
  813. '_renderBoxOn_',
  814. smalltalk.method({
  815. selector: 'renderBoxOn:',
  816. category: 'rendering',
  817. fn: function (html){
  818. var self=this;
  819. self['@textarea']=smalltalk.send(html, "_textarea", []);
  820. smalltalk.send(smalltalk.send(self['@textarea'], "_asJQuery", []), "_call_", ["tabby"]);
  821. (function($rec){smalltalk.send($rec, "_class_", ["jt_transcript"]);return smalltalk.send($rec, "_at_put_", ["spellcheck", "false"]);})(self['@textarea']);
  822. return self;},
  823. source: unescape('renderBoxOn%3A%20html%0A%20%20%20%20textarea%20%3A%3D%20html%20textarea.%0A%20%20%20%20textarea%20asJQuery%20call%3A%20%27tabby%27.%0A%20%20%20%20textarea%20%0A%09class%3A%20%27jt_transcript%27%3B%0A%09at%3A%20%27spellcheck%27%20put%3A%20%27false%27'),
  824. messageSends: ["textarea", "call:", "asJQuery", "class:", "at:put:"],
  825. referencedClasses: []
  826. }),
  827. smalltalk.Transcript);
  828. smalltalk.addMethod(
  829. '_renderButtonsOn_',
  830. smalltalk.method({
  831. selector: 'renderButtonsOn:',
  832. category: 'rendering',
  833. fn: function (html){
  834. var self=this;
  835. (function($rec){smalltalk.send($rec, "_with_", ["Clear transcript"]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_clear", []);})]);})(smalltalk.send(html, "_button", []));
  836. return self;},
  837. source: unescape('renderButtonsOn%3A%20html%0A%20%20%20%20html%20button%0A%09with%3A%20%27Clear%20transcript%27%3B%0A%09onClick%3A%20%5Bself%20clear%5D'),
  838. messageSends: ["with:", "onClick:", "clear", "button"],
  839. referencedClasses: []
  840. }),
  841. smalltalk.Transcript);
  842. smalltalk.Transcript.klass.iVarNames = ['current'];
  843. smalltalk.addMethod(
  844. '_open',
  845. smalltalk.method({
  846. selector: 'open',
  847. category: 'instance creation',
  848. fn: function (){
  849. var self=this;
  850. smalltalk.send(smalltalk.send(self, "_current", []), "_open", []);
  851. return self;},
  852. source: unescape('open%0A%20%20%20%20self%20current%20open'),
  853. messageSends: ["open", "current"],
  854. referencedClasses: []
  855. }),
  856. smalltalk.Transcript.klass);
  857. smalltalk.addMethod(
  858. '_new',
  859. smalltalk.method({
  860. selector: 'new',
  861. category: 'instance creation',
  862. fn: function (){
  863. var self=this;
  864. smalltalk.send(self, "_shouldNotImplement", []);
  865. return self;},
  866. source: unescape('new%0A%20%20%20%20self%20shouldNotImplement'),
  867. messageSends: ["shouldNotImplement"],
  868. referencedClasses: []
  869. }),
  870. smalltalk.Transcript.klass);
  871. smalltalk.addMethod(
  872. '_current',
  873. smalltalk.method({
  874. selector: 'current',
  875. category: 'instance creation',
  876. fn: function (){
  877. var self=this;
  878. return smalltalk.send(self['@current'], "_ifNil_", [(function(){return self['@current']=smalltalk.send(self, "_new", [], smalltalk.TabWidget.klass);})]);
  879. return self;},
  880. source: unescape('current%0A%20%20%20%20%5Ecurrent%20ifNil%3A%20%5Bcurrent%20%3A%3D%20super%20new%5D'),
  881. messageSends: ["ifNil:", "new"],
  882. referencedClasses: []
  883. }),
  884. smalltalk.Transcript.klass);
  885. smalltalk.addMethod(
  886. '_show_',
  887. smalltalk.method({
  888. selector: 'show:',
  889. category: 'printing',
  890. fn: function (anObject){
  891. var self=this;
  892. smalltalk.send(smalltalk.send(self, "_current", []), "_show_", [anObject]);
  893. return self;},
  894. source: unescape('show%3A%20anObject%0A%20%20%20%20self%20current%20show%3A%20anObject'),
  895. messageSends: ["show:", "current"],
  896. referencedClasses: []
  897. }),
  898. smalltalk.Transcript.klass);
  899. smalltalk.addMethod(
  900. '_cr',
  901. smalltalk.method({
  902. selector: 'cr',
  903. category: 'printing',
  904. fn: function (){
  905. var self=this;
  906. smalltalk.send(smalltalk.send(self, "_current", []), "_show_", [smalltalk.send(smalltalk.String, "_cr", [])]);
  907. return self;},
  908. source: unescape('cr%0A%20%20%20%20self%20current%20show%3A%20String%20cr'),
  909. messageSends: ["show:", "current", "cr"],
  910. referencedClasses: [smalltalk.String]
  911. }),
  912. smalltalk.Transcript.klass);
  913. smalltalk.addMethod(
  914. '_clear',
  915. smalltalk.method({
  916. selector: 'clear',
  917. category: 'printing',
  918. fn: function (){
  919. var self=this;
  920. smalltalk.send(smalltalk.send(self, "_current", []), "_clear", []);
  921. return self;},
  922. source: unescape('clear%0A%20%20%20%20self%20current%20clear'),
  923. messageSends: ["clear", "current"],
  924. referencedClasses: []
  925. }),
  926. smalltalk.Transcript.klass);
  927. smalltalk.addClass('Browser', smalltalk.TabWidget, ['selectedCategory', 'selectedClass', 'selectedProtocol', 'selectedMethod', 'commitButton', 'categoriesList', 'classesList', 'protocolsList', 'methodsList', 'sourceTextarea', 'tabsList', 'selectedTab', 'saveButton', 'classButtons', 'methodButtons', 'unsavedChanges', 'input'], 'IDE');
  928. smalltalk.addMethod(
  929. '_label',
  930. smalltalk.method({
  931. selector: 'label',
  932. category: 'accessing',
  933. fn: function (){
  934. var self=this;
  935. return smalltalk.send(self['@selectedClass'], "_ifNil_ifNotNil_", [(function(){return unescape("Browser%20%28nil%29");}), (function(){return smalltalk.send(self['@selectedClass'], "_name", []);})]);
  936. return self;},
  937. source: unescape('label%0A%20%20%20%20%5EselectedClass%20%0A%09ifNil%3A%20%5B%27Browser%20%28nil%29%27%5D%0A%09ifNotNil%3A%20%5BselectedClass%20name%5D'),
  938. messageSends: ["ifNil:ifNotNil:", "name"],
  939. referencedClasses: []
  940. }),
  941. smalltalk.Browser);
  942. smalltalk.addMethod(
  943. '_categories',
  944. smalltalk.method({
  945. selector: 'categories',
  946. category: 'accessing',
  947. fn: function (){
  948. var self=this;
  949. var categories=nil;
  950. categories=smalltalk.send(smalltalk.Array, "_new", []);
  951. smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.Smalltalk, "_current", []), "_classes", []), "_do_", [(function(each){return smalltalk.send(smalltalk.send(categories, "_includes_", [smalltalk.send(each, "_category", [])]), "_ifFalse_", [(function(){return smalltalk.send(categories, "_add_", [smalltalk.send(each, "_category", [])]);})]);})]);
  952. return smalltalk.send(categories, "_sort", []);
  953. return self;},
  954. source: unescape('categories%0A%20%20%20%20%7C%20categories%20%7C%0A%20%20%20%20categories%20%3A%3D%20Array%20new.%0A%20%20%20%20Smalltalk%20current%20classes%20do%3A%20%5B%3Aeach%20%7C%0A%09%28categories%20includes%3A%20each%20category%29%20ifFalse%3A%20%5B%0A%09%20%20%20%20categories%20add%3A%20each%20category%5D%5D.%0A%20%20%20%20%5Ecategories%20sort'),
  955. messageSends: ["new", "do:", "classes", "current", "ifFalse:", "includes:", "category", "add:", "sort"],
  956. referencedClasses: [smalltalk.Array,smalltalk.Smalltalk]
  957. }),
  958. smalltalk.Browser);
  959. smalltalk.addMethod(
  960. '_classes',
  961. smalltalk.method({
  962. selector: 'classes',
  963. category: 'accessing',
  964. fn: function (){
  965. var self=this;
  966. return smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.Smalltalk, "_current", []), "_classes", []), "_select_", [(function(each){return smalltalk.send(smalltalk.send(each, "_category", []), "__eq", [self['@selectedCategory']]);})]), "_sort_", [(function(a, b){return smalltalk.send(smalltalk.send(a, "_name", []), "__gt", [smalltalk.send(b, "_name", [])]);})]);
  967. return self;},
  968. source: unescape('classes%0A%20%20%20%20%5E%28Smalltalk%20current%20classes%20%0A%09select%3A%20%5B%3Aeach%20%7C%20each%20category%20%3D%20selectedCategory%5D%29%0A%09sort%3A%20%5B%3Aa%20%3Ab%20%7C%20a%20name%20%3E%20b%20name%5D'),
  969. messageSends: ["sort:", "select:", "classes", "current", unescape("%3D"), "category", unescape("%3E"), "name"],
  970. referencedClasses: [smalltalk.Smalltalk]
  971. }),
  972. smalltalk.Browser);
  973. smalltalk.addMethod(
  974. '_protocols',
  975. smalltalk.method({
  976. selector: 'protocols',
  977. category: 'accessing',
  978. fn: function (){
  979. var self=this;
  980. try{var klass=nil;
  981. smalltalk.send(self['@selectedClass'], "_ifNotNil_", [(function(){smalltalk.send(smalltalk.send(self['@selectedTab'], "__eq", ["comment"]), "_ifTrue_", [(function(){return (function(){throw({name: 'stReturn', selector: '_protocols', fn: function(){return []}})})();})]);klass=smalltalk.send(smalltalk.send(self['@selectedTab'], "__eq", ["instance"]), "_ifTrue_ifFalse_", [(function(){return self['@selectedClass'];}), (function(){return smalltalk.send(self['@selectedClass'], "_class", []);})]);smalltalk.send(smalltalk.send(smalltalk.send(klass, "_methodDictionary", []), "_isEmpty", []), "_ifTrue_", [(function(){return (function(){throw({name: 'stReturn', selector: '_protocols', fn: function(){return smalltalk.send(smalltalk.Array, "_with_", ["not yet classified"])}})})();})]);return (function(){throw({name: 'stReturn', selector: '_protocols', fn: function(){return smalltalk.send(klass, "_protocols", [])}})})();})]);
  982. (function(){throw({name: 'stReturn', selector: '_protocols', fn: function(){return smalltalk.send(smalltalk.Array, "_new", [])}})})();
  983. return self;
  984. } catch(e) {if(e.name === 'stReturn' && e.selector === '_protocols'){return e.fn()} throw(e)}},
  985. source: unescape('protocols%0A%20%20%20%20%7C%20klass%20%7C%0A%20%20%20%20selectedClass%20ifNotNil%3A%20%5B%0A%09selectedTab%20%3D%20%23comment%20ifTrue%3A%20%5B%5E%23%28%29%5D.%0A%09klass%20%3A%3D%20selectedTab%20%3D%20%23instance%0A%09%20%20%20%20ifTrue%3A%20%5BselectedClass%5D%0A%09%20%20%20%20ifFalse%3A%20%5BselectedClass%20class%5D.%0A%09klass%20methodDictionary%20isEmpty%20ifTrue%3A%20%5B%0A%09%20%20%20%20%5EArray%20with%3A%20%27not%20yet%20classified%27%5D.%0A%09%5Eklass%20protocols%5D.%0A%20%20%20%20%5EArray%20new'),
  986. messageSends: ["ifNotNil:", "ifTrue:", unescape("%3D"), "ifTrue:ifFalse:", "class", "isEmpty", "methodDictionary", "with:", "protocols", "new"],
  987. referencedClasses: [smalltalk.Array]
  988. }),
  989. smalltalk.Browser);
  990. smalltalk.addMethod(
  991. '_methods',
  992. smalltalk.method({
  993. selector: 'methods',
  994. category: 'accessing',
  995. fn: function (){
  996. var self=this;
  997. try{var klass=nil;
  998. smalltalk.send(smalltalk.send(self['@selectedTab'], "__eq", ["comment"]), "_ifTrue_", [(function(){return (function(){throw({name: 'stReturn', selector: '_methods', fn: function(){return []}})})();})]);
  999. smalltalk.send(self['@selectedClass'], "_ifNotNil_", [(function(){return klass=smalltalk.send(smalltalk.send(self['@selectedTab'], "__eq", ["instance"]), "_ifTrue_ifFalse_", [(function(){return self['@selectedClass'];}), (function(){return smalltalk.send(self['@selectedClass'], "_class", []);})]);})]);
  1000. (function(){throw({name: 'stReturn', selector: '_methods', fn: function(){return smalltalk.send(smalltalk.send(self['@selectedProtocol'], "_ifNil_ifNotNil_", [(function(){return smalltalk.send(klass, "_ifNil_ifNotNil_", [(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 smalltalk.send(smalltalk.send(a, "_selector", []), "__gt", [smalltalk.send(b, "_selector", [])]);})])}})})();
  1001. return self;
  1002. } catch(e) {if(e.name === 'stReturn' && e.selector === '_methods'){return e.fn()} throw(e)}},
  1003. source: unescape('methods%0A%20%20%20%20%7C%20klass%20%7C%0A%20%20%20%20selectedTab%20%3D%20%23comment%20ifTrue%3A%20%5B%5E%23%28%29%5D.%0A%20%20%20%20selectedClass%20ifNotNil%3A%20%5B%0A%09klass%20%3A%3D%20selectedTab%20%3D%20%23instance%0A%09%20%20%20%20ifTrue%3A%20%5BselectedClass%5D%0A%09%20%20%20%20ifFalse%3A%20%5BselectedClass%20class%5D%5D.%0A%20%20%20%20%5E%28selectedProtocol%20%0A%09ifNil%3A%20%5B%0A%09%20%20%20%20klass%20%0A%09%09ifNil%3A%20%5B%23%28%29%5D%20%0A%09%09ifNotNil%3A%20%5Bklass%20methodDictionary%20values%5D%5D%0A%09ifNotNil%3A%20%5B%0A%09%20%20%20%20klass%20methodDictionary%20values%20select%3A%20%5B%3Aeach%20%7C%0A%09%09each%20category%20%3D%20selectedProtocol%5D%5D%29%20sort%3A%20%5B%3Aa%20%3Ab%20%7C%20a%20selector%20%3E%20b%20selector%5D'),
  1004. messageSends: ["ifTrue:", unescape("%3D"), "ifNotNil:", "ifTrue:ifFalse:", "class", "sort:", "ifNil:ifNotNil:", "values", "methodDictionary", "select:", "category", unescape("%3E"), "selector"],
  1005. referencedClasses: []
  1006. }),
  1007. smalltalk.Browser);
  1008. smalltalk.addMethod(
  1009. '_source',
  1010. smalltalk.method({
  1011. selector: 'source',
  1012. category: 'accessing',
  1013. fn: function (){
  1014. var self=this;
  1015. try{smalltalk.send(smalltalk.send(self['@selectedTab'], "__eq", ["comment"]), "_ifFalse_", [(function(){return (function(){throw({name: 'stReturn', selector: '_source', fn: function(){return smalltalk.send(smalltalk.send(smalltalk.send(self['@selectedProtocol'], "_notNil", []), "_or_", [(function(){return smalltalk.send(self['@selectedMethod'], "_notNil", []);})]), "_ifFalse_ifTrue_", [(function(){return smalltalk.send(self, "_declarationSource", []);}), (function(){return smalltalk.send(self, "_methodSource", []);})])}})})();})]);
  1016. (function(){throw({name: 'stReturn', selector: '_source', fn: function(){return smalltalk.send(self['@selectedClass'], "_ifNil_ifNotNil_", [(function(){return "";}), (function(){return smalltalk.send(self, "_classCommentSource", []);})])}})})();
  1017. return self;
  1018. } catch(e) {if(e.name === 'stReturn' && e.selector === '_source'){return e.fn()} throw(e)}},
  1019. source: unescape('source%0A%20%20%20%20selectedTab%20%3D%20%23comment%20ifFalse%3A%20%5B%0A%09%5E%28selectedProtocol%20notNil%20or%3A%20%5BselectedMethod%20notNil%5D%29%0A%09%20%20%20%20ifFalse%3A%20%5Bself%20declarationSource%5D%0A%09%20%20%20%20ifTrue%3A%20%5Bself%20methodSource%5D%5D.%0A%20%20%20%20%5EselectedClass%0A%09ifNil%3A%20%5B%27%27%5D%0A%09ifNotNil%3A%20%5Bself%20classCommentSource%5D'),
  1020. messageSends: ["ifFalse:", unescape("%3D"), "ifFalse:ifTrue:", "or:", "notNil", "declarationSource", "methodSource", "ifNil:ifNotNil:", "classCommentSource"],
  1021. referencedClasses: []
  1022. }),
  1023. smalltalk.Browser);
  1024. smalltalk.addMethod(
  1025. '_methodSource',
  1026. smalltalk.method({
  1027. selector: 'methodSource',
  1028. category: 'accessing',
  1029. fn: function (){
  1030. var self=this;
  1031. return smalltalk.send(self['@selectedMethod'], "_ifNil_ifNotNil_", [(function(){return smalltalk.send(self, "_dummyMethodSource", []);}), (function(){return smalltalk.send(self['@selectedMethod'], "_source", []);})]);
  1032. return self;},
  1033. source: unescape('methodSource%0A%20%20%20%20%5EselectedMethod%0A%09ifNil%3A%20%5Bself%20dummyMethodSource%5D%0A%09ifNotNil%3A%20%5BselectedMethod%20source%5D'),
  1034. messageSends: ["ifNil:ifNotNil:", "dummyMethodSource", "source"],
  1035. referencedClasses: []
  1036. }),
  1037. smalltalk.Browser);
  1038. smalltalk.addMethod(
  1039. '_dummyMethodSource',
  1040. smalltalk.method({
  1041. selector: 'dummyMethodSource',
  1042. category: 'accessing',
  1043. fn: function (){
  1044. var self=this;
  1045. return unescape("messageSelectorAndArgumentNames%0A%09%22comment%20stating%20purpose%20of%20message%22%0A%0A%09%7C%20temporary%20variable%20names%20%7C%0A%09statements");
  1046. return self;},
  1047. source: unescape('dummyMethodSource%0A%20%20%20%20%5E%27messageSelectorAndArgumentNames%0A%09%22comment%20stating%20purpose%20of%20message%22%0A%0A%09%7C%20temporary%20variable%20names%20%7C%0A%09statements%27'),
  1048. messageSends: [],
  1049. referencedClasses: []
  1050. }),
  1051. smalltalk.Browser);
  1052. smalltalk.addMethod(
  1053. '_declarationSource',
  1054. smalltalk.method({
  1055. selector: 'declarationSource',
  1056. category: 'accessing',
  1057. fn: function (){
  1058. var self=this;
  1059. return smalltalk.send(smalltalk.send(self['@selectedTab'], "__eq", ["instance"]), "_ifTrue_ifFalse_", [(function(){return smalltalk.send(self, "_classDeclarationSource", []);}), (function(){return smalltalk.send(self, "_metaclassDeclarationSource", []);})]);
  1060. return self;},
  1061. source: unescape('declarationSource%0A%20%20%20%20%5EselectedTab%20%3D%20%23instance%0A%09ifTrue%3A%20%5Bself%20classDeclarationSource%5D%0A%09ifFalse%3A%20%5Bself%20metaclassDeclarationSource%5D'),
  1062. messageSends: ["ifTrue:ifFalse:", unescape("%3D"), "classDeclarationSource", "metaclassDeclarationSource"],
  1063. referencedClasses: []
  1064. }),
  1065. smalltalk.Browser);
  1066. smalltalk.addMethod(
  1067. '_classDeclarationSource',
  1068. smalltalk.method({
  1069. selector: 'classDeclarationSource',
  1070. category: 'accessing',
  1071. fn: function (){
  1072. var self=this;
  1073. var stream=nil;
  1074. stream=smalltalk.send("", "_writeStream", []);
  1075. smalltalk.send(self['@selectedClass'], "_ifNotNil_", [(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, "_lf", []), "__comma", [smalltalk.send(smalltalk.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, "_lf", [])]), "__comma", [smalltalk.send(smalltalk.String, "_tab", [])])]);smalltalk.send($rec, "_nextPutAll_", [unescape("category%3A%20%27")]);smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(self['@selectedClass'], "_category", [])]);return smalltalk.send($rec, "_nextPutAll_", [unescape("%27")]);})(stream);})]);
  1076. return smalltalk.send(stream, "_contents", []);
  1077. return self;},
  1078. source: unescape('classDeclarationSource%0A%20%20%20%20%7C%20stream%20%7C%0A%20%20%20%20stream%20%3A%3D%20%27%27%20writeStream.%0A%20%20%20%20selectedClass%20ifNotNil%3A%20%5B%0A%09stream%20%0A%09%20%20%20%20nextPutAll%3A%20selectedClass%20superclass%20asString%3B%0A%09%20%20%20%20nextPutAll%3A%20%27%20subclass%3A%20%23%27%3B%0A%09%20%20%20%20nextPutAll%3A%20selectedClass%20name%3B%0A%09%20%20%20%20nextPutAll%3A%20String%20lf%2C%20String%20tab%3B%0A%09%20%20%20%20nextPutAll%3A%20%27instanceVariableNames%3A%20%27%27%27.%0A%09selectedClass%20instanceVariableNames%20%0A%09%20%20%20%20do%3A%20%5B%3Aeach%20%7C%20stream%20nextPutAll%3A%20each%5D%20%0A%09%20%20%20%20separatedBy%3A%20%5Bstream%20nextPutAll%3A%20%27%20%27%5D.%0A%09stream%0A%09%20%20%20%20nextPutAll%3A%20%27%27%27%27%2C%20String%20lf%2C%20String%20tab%3B%0A%09%20%20%20%20nextPutAll%3A%20%27category%3A%20%27%27%27%3B%0A%09%20%20%20%20nextPutAll%3A%20selectedClass%20category%3B%0A%09%20%20%20%20nextPutAll%3A%20%27%27%27%27%5D.%0A%20%20%20%20%5Estream%20contents'),
  1079. messageSends: ["writeStream", "ifNotNil:", "nextPutAll:", "asString", "superclass", "name", unescape("%2C"), "lf", "tab", "do:separatedBy:", "instanceVariableNames", "category", "contents"],
  1080. referencedClasses: [smalltalk.String]
  1081. }),
  1082. smalltalk.Browser);
  1083. smalltalk.addMethod(
  1084. '_metaclassDeclarationSource',
  1085. smalltalk.method({
  1086. selector: 'metaclassDeclarationSource',
  1087. category: 'accessing',
  1088. fn: function (){
  1089. var self=this;
  1090. var stream=nil;
  1091. stream=smalltalk.send("", "_writeStream", []);
  1092. smalltalk.send(self['@selectedClass'], "_ifNotNil_", [(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")]);})]);
  1093. return smalltalk.send(stream, "_contents", []);
  1094. return self;},
  1095. source: unescape('metaclassDeclarationSource%0A%20%20%20%20%7C%20stream%20%7C%0A%20%20%20%20stream%20%3A%3D%20%27%27%20writeStream.%0A%20%20%20%20selectedClass%20ifNotNil%3A%20%5B%0A%09stream%20%0A%09%20%20%20%20nextPutAll%3A%20selectedClass%20asString%3B%0A%09%20%20%20%20nextPutAll%3A%20%27%20class%20%27%3B%0A%09%20%20%20%20nextPutAll%3A%20%27instanceVariableNames%3A%20%27%27%27.%0A%09selectedClass%20class%20instanceVariableNames%0A%09%20%20%20%20do%3A%20%5B%3Aeach%20%7C%20stream%20nextPutAll%3A%20each%5D%0A%09%20%20%20%20separatedBy%3A%20%5Bstream%20nextPutAll%3A%20%27%20%27%5D.%0A%09stream%20nextPutAll%3A%20%27%27%27%27%5D.%0A%20%20%20%20%5Estream%20contents'),
  1096. messageSends: ["writeStream", "ifNotNil:", "nextPutAll:", "asString", "do:separatedBy:", "instanceVariableNames", "class", "contents"],
  1097. referencedClasses: []
  1098. }),
  1099. smalltalk.Browser);
  1100. smalltalk.addMethod(
  1101. '_classCommentSource',
  1102. smalltalk.method({
  1103. selector: 'classCommentSource',
  1104. category: 'accessing',
  1105. fn: function (){
  1106. var self=this;
  1107. return smalltalk.send(self['@selectedClass'], "_comment", []);
  1108. return self;},
  1109. source: unescape('classCommentSource%0A%20%20%20%20%5EselectedClass%20comment'),
  1110. messageSends: ["comment"],
  1111. referencedClasses: []
  1112. }),
  1113. smalltalk.Browser);
  1114. smalltalk.addMethod(
  1115. '_enableSaveButton',
  1116. smalltalk.method({
  1117. selector: 'enableSaveButton',
  1118. category: 'actions',
  1119. fn: function (){
  1120. var self=this;
  1121. smalltalk.send(self['@saveButton'], "_removeAt_", ["disabled"]);
  1122. self['@unsavedChanges']=true;
  1123. return self;},
  1124. source: unescape('enableSaveButton%0A%20%20%20%20saveButton%20removeAt%3A%20%27disabled%27.%0A%20%20%20%20unsavedChanges%20%3A%3D%20true'),
  1125. messageSends: ["removeAt:"],
  1126. referencedClasses: []
  1127. }),
  1128. smalltalk.Browser);
  1129. smalltalk.addMethod(
  1130. '_disableSaveButton',
  1131. smalltalk.method({
  1132. selector: 'disableSaveButton',
  1133. category: 'actions',
  1134. fn: function (){
  1135. var self=this;
  1136. smalltalk.send(self['@saveButton'], "_ifNotNil_", [(function(){return smalltalk.send(self['@saveButton'], "_at_put_", ["disabled", true]);})]);
  1137. self['@unsavedChanges']=false;
  1138. return self;},
  1139. source: unescape('disableSaveButton%0A%20%20%20%20saveButton%20ifNotNil%3A%20%5B%0A%09saveButton%20at%3A%20%27disabled%27%20put%3A%20true%5D.%0A%20%20%20%20unsavedChanges%20%3A%3D%20false'),
  1140. messageSends: ["ifNotNil:", "at:put:"],
  1141. referencedClasses: []
  1142. }),
  1143. smalltalk.Browser);
  1144. smalltalk.addMethod(
  1145. '_hideClassButtons',
  1146. smalltalk.method({
  1147. selector: 'hideClassButtons',
  1148. category: 'actions',
  1149. fn: function (){
  1150. var self=this;
  1151. smalltalk.send(smalltalk.send(self['@classButtons'], "_asJQuery", []), "_hide", []);
  1152. return self;},
  1153. source: unescape('hideClassButtons%0A%20%20%20%20classButtons%20asJQuery%20hide'),
  1154. messageSends: ["hide", "asJQuery"],
  1155. referencedClasses: []
  1156. }),
  1157. smalltalk.Browser);
  1158. smalltalk.addMethod(
  1159. '_showClassButtons',
  1160. smalltalk.method({
  1161. selector: 'showClassButtons',
  1162. category: 'actions',
  1163. fn: function (){
  1164. var self=this;
  1165. smalltalk.send(smalltalk.send(self['@classButtons'], "_asJQuery", []), "_show", []);
  1166. return self;},
  1167. source: unescape('showClassButtons%0A%20%20%20%20classButtons%20asJQuery%20show'),
  1168. messageSends: ["show", "asJQuery"],
  1169. referencedClasses: []
  1170. }),
  1171. smalltalk.Browser);
  1172. smalltalk.addMethod(
  1173. '_hideMethodButtons',
  1174. smalltalk.method({
  1175. selector: 'hideMethodButtons',
  1176. category: 'actions',
  1177. fn: function (){
  1178. var self=this;
  1179. smalltalk.send(smalltalk.send(self['@methodButtons'], "_asJQuery", []), "_hide", []);
  1180. return self;},
  1181. source: unescape('hideMethodButtons%0A%20%20%20%20methodButtons%20asJQuery%20hide'),
  1182. messageSends: ["hide", "asJQuery"],
  1183. referencedClasses: []
  1184. }),
  1185. smalltalk.Browser);
  1186. smalltalk.addMethod(
  1187. '_showMethodButtons',
  1188. smalltalk.method({
  1189. selector: 'showMethodButtons',
  1190. category: 'actions',
  1191. fn: function (){
  1192. var self=this;
  1193. smalltalk.send(smalltalk.send(self['@methodButtons'], "_asJQuery", []), "_show", []);
  1194. return self;},
  1195. source: unescape('showMethodButtons%0A%20%20%20%20methodButtons%20asJQuery%20show'),
  1196. messageSends: ["show", "asJQuery"],
  1197. referencedClasses: []
  1198. }),
  1199. smalltalk.Browser);
  1200. smalltalk.addMethod(
  1201. '_compile',
  1202. smalltalk.method({
  1203. selector: 'compile',
  1204. category: 'actions',
  1205. fn: function (){
  1206. var self=this;
  1207. smalltalk.send(self, "_disableSaveButton", []);
  1208. smalltalk.send(smalltalk.send(self['@selectedTab'], "__eq", ["comment"]), "_ifTrue_", [(function(){return smalltalk.send(self['@selectedClass'], "_ifNotNil_", [(function(){return smalltalk.send(self, "_compileClassComment", []);})]);})]);
  1209. smalltalk.send(smalltalk.send(smalltalk.send(self['@selectedProtocol'], "_notNil", []), "_or_", [(function(){return smalltalk.send(self['@selectedMethod'], "_notNil", []);})]), "_ifFalse_ifTrue_", [(function(){return smalltalk.send(self, "_compileDefinition", []);}), (function(){return smalltalk.send(self, "_compileMethodDefinition", []);})]);
  1210. return self;},
  1211. source: unescape('compile%0A%20%20%20%20self%20disableSaveButton.%0A%20%20%20%20selectedTab%20%3D%20%23comment%20ifTrue%3A%20%5B%0A%09selectedClass%20ifNotNil%3A%20%5B%0A%09%20%20%20%20self%20compileClassComment%5D%5D.%0A%20%20%20%20%28selectedProtocol%20notNil%20or%3A%20%5BselectedMethod%20notNil%5D%29%0A%09ifFalse%3A%20%5Bself%20compileDefinition%5D%0A%09ifTrue%3A%20%5Bself%20compileMethodDefinition%5D'),
  1212. messageSends: ["disableSaveButton", "ifTrue:", unescape("%3D"), "ifNotNil:", "compileClassComment", "ifFalse:ifTrue:", "or:", "notNil", "compileDefinition", "compileMethodDefinition"],
  1213. referencedClasses: []
  1214. }),
  1215. smalltalk.Browser);
  1216. smalltalk.addMethod(
  1217. '_compileClassComment',
  1218. smalltalk.method({
  1219. selector: 'compileClassComment',
  1220. category: 'actions',
  1221. fn: function (){
  1222. var self=this;
  1223. smalltalk.send(self['@selectedClass'], "_comment_", [smalltalk.send(smalltalk.send(self['@sourceTextarea'], "_asJQuery", []), "_val", [])]);
  1224. return self;},
  1225. source: unescape('compileClassComment%0A%20%20%20%20selectedClass%20comment%3A%20sourceTextarea%20asJQuery%20val'),
  1226. messageSends: ["comment:", "val", "asJQuery"],
  1227. referencedClasses: []
  1228. }),
  1229. smalltalk.Browser);
  1230. smalltalk.addMethod(
  1231. '_compileMethodDefinition',
  1232. smalltalk.method({
  1233. selector: 'compileMethodDefinition',
  1234. category: 'actions',
  1235. fn: function (){
  1236. var self=this;
  1237. smalltalk.send(smalltalk.send(self['@selectedTab'], "__eq", ["instance"]), "_ifTrue_ifFalse_", [(function(){return smalltalk.send(self, "_compileMethodDefinitionFor_", [self['@selectedClass']]);}), (function(){return smalltalk.send(self, "_compileMethodDefinitionFor_", [smalltalk.send(self['@selectedClass'], "_class", [])]);})]);
  1238. return self;},
  1239. source: unescape('compileMethodDefinition%0A%20%20%20%20selectedTab%20%3D%20%23instance%0A%09ifTrue%3A%20%5Bself%20compileMethodDefinitionFor%3A%20selectedClass%5D%0A%09ifFalse%3A%20%5Bself%20compileMethodDefinitionFor%3A%20selectedClass%20class%5D'),
  1240. messageSends: ["ifTrue:ifFalse:", unescape("%3D"), "compileMethodDefinitionFor:", "class"],
  1241. referencedClasses: []
  1242. }),
  1243. smalltalk.Browser);
  1244. smalltalk.addMethod(
  1245. '_compileMethodDefinitionFor_',
  1246. smalltalk.method({
  1247. selector: 'compileMethodDefinitionFor:',
  1248. category: 'actions',
  1249. fn: function (aClass){
  1250. var self=this;
  1251. try{var compiler=nil;
  1252. var method=nil;
  1253. var source=nil;
  1254. var node=nil;
  1255. source=smalltalk.send(smalltalk.send(self['@sourceTextarea'], "_asJQuery", []), "_val", []);
  1256. smalltalk.send(self['@selectedProtocol'], "_ifNil_", [(function(){return self['@selectedProtocol']=smalltalk.send(self['@selectedMethod'], "_category", []);})]);
  1257. compiler=smalltalk.send(smalltalk.Compiler, "_new", []);
  1258. node=smalltalk.send(compiler, "_parse_", [source]);
  1259. smalltalk.send(smalltalk.send(node, "_isParseFailure", []), "_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", [])])])}})})();})]);
  1260. smalltalk.send(compiler, "_currentClass_", [aClass]);
  1261. method=smalltalk.send(compiler, "_eval_", [smalltalk.send(compiler, "_compileNode_", [node])]);
  1262. smalltalk.send(method, "_category_", [self['@selectedProtocol']]);
  1263. smalltalk.send(smalltalk.send(compiler, "_unknownVariables", []), "_do_", [(function(each){return smalltalk.send(smalltalk.send(self, "_confirm_", [smalltalk.send(smalltalk.send(unescape("Declare%20%27"), "__comma", [each]), "__comma", [unescape("%27%20as%20instance%20variable%3F")])]), "_ifTrue_", [(function(){smalltalk.send(self, "_addInstanceVariableNamed_toClass_", [each, aClass]);return (function(){throw({name: 'stReturn', selector: '_compileMethodDefinitionFor_', fn: function(){return smalltalk.send(self, "_compileMethodDefinitionFor_", [aClass])}})})();})]);})]);
  1264. smalltalk.send(aClass, "_addCompiledMethod_", [method]);
  1265. smalltalk.send(compiler, "_setupClass_", [aClass]);
  1266. smalltalk.send(self, "_updateMethodsList", []);
  1267. smalltalk.send(self, "_selectMethod_", [method]);
  1268. return self;
  1269. } catch(e) {if(e.name === 'stReturn' && e.selector === '_compileMethodDefinitionFor_'){return e.fn()} throw(e)}},
  1270. source: unescape('compileMethodDefinitionFor%3A%20aClass%0A%20%20%20%20%7C%20compiler%20method%20source%20node%20%7C%0A%20%20%20%20source%20%3A%3D%20sourceTextarea%20asJQuery%20val.%0A%20%20%20%20selectedProtocol%20ifNil%3A%20%5BselectedProtocol%20%3A%3D%20selectedMethod%20category%5D.%0A%20%20%20%20compiler%20%3A%3D%20Compiler%20new.%0A%20%20%20%20node%20%3A%3D%20compiler%20parse%3A%20source.%0A%20%20%20%20node%20isParseFailure%20ifTrue%3A%20%5B%0A%09%5Eself%20alert%3A%20%27PARSE%20ERROR%3A%20%27%2C%20node%20reason%2C%20%27%2C%20position%3A%20%27%2C%20node%20position%20asString%5D.%0A%20%20%20%20compiler%20currentClass%3A%20aClass.%0A%20%20%20%20method%20%3A%3D%20compiler%20eval%3A%20%28compiler%20compileNode%3A%20node%29.%0A%20%20%20%20method%20category%3A%20selectedProtocol.%0A%20%20%20%20compiler%20unknownVariables%20do%3A%20%5B%3Aeach%20%7C%0A%09%28self%20confirm%3A%20%27Declare%20%27%27%27%2C%20each%2C%20%27%27%27%20as%20instance%20variable%3F%27%29%20ifTrue%3A%20%5B%0A%09%09self%20addInstanceVariableNamed%3A%20each%20toClass%3A%20aClass.%0A%09%09%5Eself%20compileMethodDefinitionFor%3A%20aClass%5D%5D.%0A%20%20%20%20aClass%20addCompiledMethod%3A%20method.%0A%20%20%20%20compiler%20setupClass%3A%20aClass.%0A%20%20%20%20self%20updateMethodsList.%0A%20%20%20%20self%20selectMethod%3A%20method'),
  1271. messageSends: ["val", "asJQuery", "ifNil:", "category", "new", "parse:", "ifTrue:", "isParseFailure", "alert:", unescape("%2C"), "reason", "asString", "position", "currentClass:", "eval:", "compileNode:", "category:", "do:", "unknownVariables", "confirm:", "addInstanceVariableNamed:toClass:", "compileMethodDefinitionFor:", "addCompiledMethod:", "setupClass:", "updateMethodsList", "selectMethod:"],
  1272. referencedClasses: [smalltalk.Compiler]
  1273. }),
  1274. smalltalk.Browser);
  1275. smalltalk.addMethod(
  1276. '_compileDefinition',
  1277. smalltalk.method({
  1278. selector: 'compileDefinition',
  1279. category: 'actions',
  1280. fn: function (){
  1281. var self=this;
  1282. var newClass=nil;
  1283. newClass=smalltalk.send(smalltalk.send(smalltalk.Compiler, "_new", []), "_loadExpression_", [smalltalk.send(smalltalk.send(self['@sourceTextarea'], "_asJQuery", []), "_val", [])]);
  1284. (function($rec){smalltalk.send($rec, "_updateCategoriesList", []);return smalltalk.send($rec, "_updateClassesList", []);})(self);
  1285. return self;},
  1286. source: unescape('compileDefinition%0A%20%20%20%20%7C%20newClass%20%7C%0A%20%20%20%20newClass%20%3A%3D%20Compiler%20new%20loadExpression%3A%20sourceTextarea%20asJQuery%20val.%0A%20%20%20%20self%20%0A%09updateCategoriesList%3B%0A%09updateClassesList'),
  1287. messageSends: ["loadExpression:", "new", "val", "asJQuery", "updateCategoriesList", "updateClassesList"],
  1288. referencedClasses: [smalltalk.Compiler]
  1289. }),
  1290. smalltalk.Browser);
  1291. smalltalk.addMethod(
  1292. '_commitCategory',
  1293. smalltalk.method({
  1294. selector: 'commitCategory',
  1295. category: 'actions',
  1296. fn: function (){
  1297. var self=this;
  1298. smalltalk.send(self['@selectedCategory'], "_ifNotNil_", [(function(){(function($rec){smalltalk.send($rec, "_at_put_", ["type", "PUT"]);smalltalk.send($rec, "_at_put_", ["data", smalltalk.send(smalltalk.send(smalltalk.Exporter, "_new", []), "_exportCategory_", [self['@selectedCategory']])]);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, "_url_", [smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(self, "_class", []), "_commitPathJs", []), "__comma", [unescape("/")]), "__comma", [self['@selectedCategory']]), "__comma", [".js"])]));return (function($rec){smalltalk.send($rec, "_at_put_", ["type", "PUT"]);smalltalk.send($rec, "_at_put_", ["data", smalltalk.send(smalltalk.send(smalltalk.ChunkExporter, "_new", []), "_exportCategory_", [self['@selectedCategory']])]);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, "_url_", [smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(self, "_class", []), "_commitPathSt", []), "__comma", [unescape("/")]), "__comma", [self['@selectedCategory']]), "__comma", [".st"])]));})]);
  1299. return self;},
  1300. source: unescape('commitCategory%0A%20%20%20%20selectedCategory%20ifNotNil%3A%20%5B%0A%09%28Ajax%20url%3A%20self%20class%20commitPathJs%2C%20%27/%27%2C%20selectedCategory%2C%20%27.js%27%29%0A%09%20%20%20%20at%3A%20%27type%27%20put%3A%20%27PUT%27%3B%0A%09%20%20%20%20at%3A%20%27data%27%20put%3A%20%28Exporter%20new%20exportCategory%3A%20selectedCategory%29%3B%0A%09%20%20%20%20at%3A%20%27error%27%20put%3A%20%5Bself%20alert%3A%20%27Commit%20failed%21%27%5D%3B%0A%09%20%20%20%20send.%0A%09%28Ajax%20url%3A%20self%20class%20commitPathSt%2C%20%27/%27%2C%20selectedCategory%2C%20%27.st%27%29%0A%09%20%20%20%20at%3A%20%27type%27%20put%3A%20%27PUT%27%3B%0A%09%20%20%20%20at%3A%20%27data%27%20put%3A%20%28ChunkExporter%20new%20exportCategory%3A%20selectedCategory%29%3B%0A%09%20%20%20%20at%3A%20%27error%27%20put%3A%20%5Bself%20alert%3A%20%27Commit%20failed%21%27%5D%3B%0A%09%20%20%20%20send%5D'),
  1301. messageSends: ["ifNotNil:", "at:put:", "exportCategory:", "new", "alert:", "send", "url:", unescape("%2C"), "commitPathJs", "class", "commitPathSt"],
  1302. referencedClasses: [smalltalk.Exporter,smalltalk.Ajax,smalltalk.ChunkExporter]
  1303. }),
  1304. smalltalk.Browser);
  1305. smalltalk.addMethod(
  1306. '_cancelChanges',
  1307. smalltalk.method({
  1308. selector: 'cancelChanges',
  1309. category: 'actions',
  1310. fn: function (){
  1311. var self=this;
  1312. return smalltalk.send(self['@unsavedChanges'], "_ifTrue_ifFalse_", [(function(){return smalltalk.send(self, "_confirm_", [unescape("Cancel%20changes%3F")]);}), (function(){return true;})]);
  1313. return self;},
  1314. source: unescape('cancelChanges%0A%20%20%20%20%5EunsavedChanges%20%0A%09ifTrue%3A%20%5Bself%20confirm%3A%20%27Cancel%20changes%3F%27%5D%0A%09ifFalse%3A%20%5Btrue%5D'),
  1315. messageSends: ["ifTrue:ifFalse:", "confirm:"],
  1316. referencedClasses: []
  1317. }),
  1318. smalltalk.Browser);
  1319. smalltalk.addMethod(
  1320. '_removeClass',
  1321. smalltalk.method({
  1322. selector: 'removeClass',
  1323. category: 'actions',
  1324. fn: function (){
  1325. var self=this;
  1326. smalltalk.send(smalltalk.send(self, "_confirm_", [smalltalk.send(smalltalk.send("Do you really want to remove ", "__comma", [smalltalk.send(self['@selectedClass'], "_name", [])]), "__comma", [unescape("%3F")])]), "_ifTrue_", [(function(){smalltalk.send(smalltalk.send(smalltalk.Smalltalk, "_current", []), "_basicDelete_", [smalltalk.send(self['@selectedClass'], "_name", [])]);return smalltalk.send(self, "_selectClass_", [nil]);})]);
  1327. return self;},
  1328. source: unescape('removeClass%0A%20%20%20%20%28self%20confirm%3A%20%27Do%20you%20really%20want%20to%20remove%20%27%2C%20selectedClass%20name%2C%20%27%3F%27%29%0A%09ifTrue%3A%20%5B%0A%09%20%20%20%20Smalltalk%20current%20basicDelete%3A%20selectedClass%20name.%0A%09%20%20%20%20self%20selectClass%3A%20nil%5D'),
  1329. messageSends: ["ifTrue:", "confirm:", unescape("%2C"), "name", "basicDelete:", "current", "selectClass:"],
  1330. referencedClasses: [smalltalk.Smalltalk]
  1331. }),
  1332. smalltalk.Browser);
  1333. smalltalk.addMethod(
  1334. '_removeMethod',
  1335. smalltalk.method({
  1336. selector: 'removeMethod',
  1337. category: 'actions',
  1338. fn: function (){
  1339. var self=this;
  1340. smalltalk.send(smalltalk.send(self, "_cancelChanges", []), "_ifTrue_", [(function(){return smalltalk.send(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")])]), "_ifTrue_", [(function(){smalltalk.send(smalltalk.send(self['@selectedTab'], "__eq", ["instance"]), "_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]);})]);})]);
  1341. return self;},
  1342. source: unescape('removeMethod%0A%20%20%20%20self%20cancelChanges%20ifTrue%3A%20%5B%0A%09%28self%20confirm%3A%20%27Do%20you%20really%20want%20to%20remove%20%23%27%2C%20selectedMethod%20selector%2C%20%27%3F%27%29%0A%09%20%20%20%20ifTrue%3A%20%5B%0A%09%09selectedTab%20%3D%20%23instance%20%0A%09%09%09ifTrue%3A%20%5BselectedClass%20removeCompiledMethod%3A%20selectedMethod%5D%0A%09%09%09ifFalse%3A%20%5BselectedClass%20class%20removeCompiledMethod%3A%20selectedMethod%5D.%0A%09%09self%20selectMethod%3A%20nil%5D%5D'),
  1343. messageSends: ["ifTrue:", "cancelChanges", "confirm:", unescape("%2C"), "selector", "ifTrue:ifFalse:", unescape("%3D"), "removeCompiledMethod:", "class", "selectMethod:"],
  1344. referencedClasses: []
  1345. }),
  1346. smalltalk.Browser);
  1347. smalltalk.addMethod(
  1348. '_setMethodProtocol_',
  1349. smalltalk.method({
  1350. selector: 'setMethodProtocol:',
  1351. category: 'actions',
  1352. fn: function (aString){
  1353. var self=this;
  1354. smalltalk.send(smalltalk.send(self, "_cancelChanges", []), "_ifTrue_", [(function(){return smalltalk.send(smalltalk.send(smalltalk.send(self, "_protocols", []), "_includes_", [aString]), "_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);})]);})]);
  1355. return self;},
  1356. source: unescape('setMethodProtocol%3A%20aString%0A%20%20%20%20self%20cancelChanges%20ifTrue%3A%20%5B%0A%09%28self%20protocols%20includes%3A%20aString%29%0A%09%20%20%20%20ifFalse%3A%20%5Bself%20addNewProtocol%5D%0A%09%20%20%20%20ifTrue%3A%20%5B%0A%09%09selectedMethod%20category%3A%20aString.%0A%09%09selectedProtocol%20%3A%3D%20aString.%0A%09%09selectedMethod%20%3A%3D%20selectedMethod.%0A%09%09self%20%0A%09%09%20%20%20%20updateProtocolsList%3B%0A%09%09%20%20%20%20updateMethodsList%3B%0A%09%09%20%20%20%20updateSourceAndButtons%5D%5D'),
  1357. messageSends: ["ifTrue:", "cancelChanges", "ifFalse:ifTrue:", "includes:", "protocols", "addNewProtocol", "category:", "updateProtocolsList", "updateMethodsList", "updateSourceAndButtons"],
  1358. referencedClasses: []
  1359. }),
  1360. smalltalk.Browser);
  1361. smalltalk.addMethod(
  1362. '_addNewProtocol',
  1363. smalltalk.method({
  1364. selector: 'addNewProtocol',
  1365. category: 'actions',
  1366. fn: function (){
  1367. var self=this;
  1368. var newProtocol=nil;
  1369. newProtocol=smalltalk.send(self, "_prompt_", ["New method protocol"]);
  1370. smalltalk.send(smalltalk.send(newProtocol, "_notEmpty", []), "_ifTrue_", [(function(){smalltalk.send(self['@selectedMethod'], "_category_", [newProtocol]);return smalltalk.send(self, "_setMethodProtocol_", [newProtocol]);})]);
  1371. return self;},
  1372. source: unescape('addNewProtocol%0A%20%20%20%20%7C%20newProtocol%20%7C%0A%20%20%20%20newProtocol%20%3A%3D%20self%20prompt%3A%20%27New%20method%20protocol%27.%0A%20%20%20%20newProtocol%20notEmpty%20ifTrue%3A%20%5B%0A%09selectedMethod%20category%3A%20newProtocol.%0A%09self%20setMethodProtocol%3A%20newProtocol%5D'),
  1373. messageSends: ["prompt:", "ifTrue:", "notEmpty", "category:", "setMethodProtocol:"],
  1374. referencedClasses: []
  1375. }),
  1376. smalltalk.Browser);
  1377. smalltalk.addMethod(
  1378. '_selectCategory_',
  1379. smalltalk.method({
  1380. selector: 'selectCategory:',
  1381. category: 'actions',
  1382. fn: function (aCategory){
  1383. var self=this;
  1384. smalltalk.send(smalltalk.send(self, "_cancelChanges", []), "_ifTrue_", [(function(){self['@selectedCategory']=aCategory;self['@selectedClass']=self['@selectedProtocol']=self['@selectedMethod']=nil;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);})]);
  1385. return self;},
  1386. source: unescape('selectCategory%3A%20aCategory%0A%20%20%20%20self%20cancelChanges%20ifTrue%3A%20%5B%0A%09selectedCategory%20%3A%3D%20aCategory.%0A%09selectedClass%20%3A%3D%20selectedProtocol%20%3A%3D%20selectedMethod%20%3A%3D%20%20nil.%0A%09self%20%0A%09%20%20%20%20updateCategoriesList%3B%0A%09%20%20%20%20updateClassesList%3B%0A%09%20%20%20%20updateProtocolsList%3B%0A%09%20%20%20%20updateMethodsList%3B%0A%09%20%20%20%20updateSourceAndButtons%5D'),
  1387. messageSends: ["ifTrue:", "cancelChanges", "updateCategoriesList", "updateClassesList", "updateProtocolsList", "updateMethodsList", "updateSourceAndButtons"],
  1388. referencedClasses: []
  1389. }),
  1390. smalltalk.Browser);
  1391. smalltalk.addMethod(
  1392. '_selectClass_',
  1393. smalltalk.method({
  1394. selector: 'selectClass:',
  1395. category: 'actions',
  1396. fn: function (aClass){
  1397. var self=this;
  1398. smalltalk.send(smalltalk.send(self, "_cancelChanges", []), "_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);})]);
  1399. return self;},
  1400. source: unescape('selectClass%3A%20aClass%0A%20%20%20%20self%20cancelChanges%20ifTrue%3A%20%5B%0A%09selectedClass%20%3A%3D%20aClass.%0A%09selectedProtocol%20%3A%3D%20selectedMethod%20%3A%3D%20nil.%0A%09self%20%0A%09%20%20%20%20updateClassesList%3B%0A%09%20%20%20%20updateProtocolsList%3B%0A%09%20%20%20%20updateMethodsList%3B%0A%09%20%20%20%20updateSourceAndButtons%5D'),
  1401. messageSends: ["ifTrue:", "cancelChanges", "updateClassesList", "updateProtocolsList", "updateMethodsList", "updateSourceAndButtons"],
  1402. referencedClasses: []
  1403. }),
  1404. smalltalk.Browser);
  1405. smalltalk.addMethod(
  1406. '_selectProtocol_',
  1407. smalltalk.method({
  1408. selector: 'selectProtocol:',
  1409. category: 'actions',
  1410. fn: function (aString){
  1411. var self=this;
  1412. smalltalk.send(smalltalk.send(self, "_cancelChanges", []), "_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);})]);
  1413. return self;},
  1414. source: unescape('selectProtocol%3A%20aString%0A%20%20%20%20self%20cancelChanges%20ifTrue%3A%20%5B%0A%09selectedProtocol%20%3A%3D%20aString.%0A%09selectedMethod%20%3A%3D%20nil.%0A%09self%20%0A%09%20%20%20%20updateProtocolsList%3B%0A%09%20%20%20%20updateMethodsList%3B%0A%09%20%20%20%20updateSourceAndButtons%5D'),
  1415. messageSends: ["ifTrue:", "cancelChanges", "updateProtocolsList", "updateMethodsList", "updateSourceAndButtons"],
  1416. referencedClasses: []
  1417. }),
  1418. smalltalk.Browser);
  1419. smalltalk.addMethod(
  1420. '_selectMethod_',
  1421. smalltalk.method({
  1422. selector: 'selectMethod:',
  1423. category: 'actions',
  1424. fn: function (aMethod){
  1425. var self=this;
  1426. smalltalk.send(smalltalk.send(self, "_cancelChanges", []), "_ifTrue_", [(function(){self['@selectedMethod']=aMethod;return (function($rec){smalltalk.send($rec, "_updateProtocolsList", []);smalltalk.send($rec, "_updateMethodsList", []);return smalltalk.send($rec, "_updateSourceAndButtons", []);})(self);})]);
  1427. return self;},
  1428. source: unescape('selectMethod%3A%20aMethod%0A%20%20%20%20self%20cancelChanges%20ifTrue%3A%20%5B%0A%09selectedMethod%20%3A%3D%20aMethod.%0A%09self%20%0A%09%20%20%20%20updateProtocolsList%3B%0A%09%20%20%20%20updateMethodsList%3B%0A%09%20%20%20%20updateSourceAndButtons%5D'),
  1429. messageSends: ["ifTrue:", "cancelChanges", "updateProtocolsList", "updateMethodsList", "updateSourceAndButtons"],
  1430. referencedClasses: []
  1431. }),
  1432. smalltalk.Browser);
  1433. smalltalk.addMethod(
  1434. '_selectTab_',
  1435. smalltalk.method({
  1436. selector: 'selectTab:',
  1437. category: 'actions',
  1438. fn: function (aString){
  1439. var self=this;
  1440. smalltalk.send(smalltalk.send(self, "_cancelChanges", []), "_ifTrue_", [(function(){self['@selectedTab']=aString;smalltalk.send(self, "_selectProtocol_", [nil]);return smalltalk.send(self, "_updateTabsList", []);})]);
  1441. return self;},
  1442. source: unescape('selectTab%3A%20aString%0A%20%20%20%20self%20cancelChanges%20ifTrue%3A%20%5B%0A%09selectedTab%20%3A%3D%20aString.%0A%09self%20selectProtocol%3A%20nil.%0A%09self%20updateTabsList%5D'),
  1443. messageSends: ["ifTrue:", "cancelChanges", "selectProtocol:", "updateTabsList"],
  1444. referencedClasses: []
  1445. }),
  1446. smalltalk.Browser);
  1447. smalltalk.addMethod(
  1448. '_renameClass',
  1449. smalltalk.method({
  1450. selector: 'renameClass',
  1451. category: 'actions',
  1452. fn: function (){
  1453. var self=this;
  1454. var newName=nil;
  1455. newName=smalltalk.send(self, "_prompt_", [smalltalk.send("Rename class ", "__comma", [smalltalk.send(self['@selectedClass'], "_name", [])])]);
  1456. smalltalk.send(smalltalk.send(newName, "_notEmpty", []), "_ifTrue_", [(function(){smalltalk.send(self['@selectedClass'], "_rename_", [newName]);return (function($rec){smalltalk.send($rec, "_updateClassesList", []);return smalltalk.send($rec, "_updateSourceAndButtons", []);})(self);})]);
  1457. return self;},
  1458. source: unescape('renameClass%0A%20%20%20%20%7C%20newName%20%7C%0A%20%20%20%20newName%20%3A%3D%20self%20prompt%3A%20%27Rename%20class%20%27%2C%20selectedClass%20name.%0A%20%20%20%20newName%20notEmpty%20ifTrue%3A%20%5B%0A%09selectedClass%20rename%3A%20newName.%0A%09self%20%0A%09%09updateClassesList%3B%0A%09%09updateSourceAndButtons%5D'),
  1459. messageSends: ["prompt:", unescape("%2C"), "name", "ifTrue:", "notEmpty", "rename:", "updateClassesList", "updateSourceAndButtons"],
  1460. referencedClasses: []
  1461. }),
  1462. smalltalk.Browser);
  1463. smalltalk.addMethod(
  1464. '_addInstanceVariableNamed_toClass_',
  1465. smalltalk.method({
  1466. selector: 'addInstanceVariableNamed:toClass:',
  1467. category: 'actions',
  1468. fn: function (aString, aClass){
  1469. var self=this;
  1470. smalltalk.send(smalltalk.send(smalltalk.ClassBuilder, "_new", []), "_addSubclassOf_named_instanceVariableNames_", [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", []))]);
  1471. return self;},
  1472. source: unescape('addInstanceVariableNamed%3A%20aString%20toClass%3A%20aClass%0A%09ClassBuilder%20new%0A%09%09addSubclassOf%3A%20aClass%20superclass%20named%3A%20aClass%20name%20instanceVariableNames%3A%20%28aClass%20instanceVariableNames%20copy%20add%3A%20aString%3B%20yourself%29'),
  1473. messageSends: ["addSubclassOf:named:instanceVariableNames:", "new", "superclass", "name", "add:", "yourself", "copy", "instanceVariableNames"],
  1474. referencedClasses: [smalltalk.ClassBuilder]
  1475. }),
  1476. smalltalk.Browser);
  1477. smalltalk.addMethod(
  1478. '_searchReferencesOf_',
  1479. smalltalk.method({
  1480. selector: 'searchReferencesOf:',
  1481. category: 'actions',
  1482. fn: function (aString){
  1483. var self=this;
  1484. smalltalk.send(smalltalk.ReferencesBrowser, "_search_", [aString]);
  1485. return self;},
  1486. source: unescape('searchReferencesOf%3A%20aString%0A%09ReferencesBrowser%20search%3A%20aString'),
  1487. messageSends: ["search:"],
  1488. referencedClasses: [smalltalk.nil]
  1489. }),
  1490. smalltalk.Browser);
  1491. smalltalk.addMethod(
  1492. '_searchClassReferences',
  1493. smalltalk.method({
  1494. selector: 'searchClassReferences',
  1495. category: 'actions',
  1496. fn: function (){
  1497. var self=this;
  1498. smalltalk.send(smalltalk.ReferencesBrowser, "_search_", [smalltalk.send(self['@selectedClass'], "_name", [])]);
  1499. return self;},
  1500. source: unescape('searchClassReferences%0A%09ReferencesBrowser%20search%3A%20selectedClass%20name'),
  1501. messageSends: ["search:", "name"],
  1502. referencedClasses: [smalltalk.nil]
  1503. }),
  1504. smalltalk.Browser);
  1505. smalltalk.addMethod(
  1506. '_initialize',
  1507. smalltalk.method({
  1508. selector: 'initialize',
  1509. category: 'initialization',
  1510. fn: function (){
  1511. var self=this;
  1512. smalltalk.send(self, "_initialize", [], smalltalk.TabWidget);
  1513. self['@selectedTab']="instance";
  1514. self['@unsavedChanges']=false;
  1515. return self;},
  1516. source: unescape('initialize%0A%20%20%20%20super%20initialize.%0A%20%20%20%20selectedTab%20%3A%3D%20%23instance.%0A%20%20%20%20unsavedChanges%20%3A%3D%20false'),
  1517. messageSends: ["initialize"],
  1518. referencedClasses: []
  1519. }),
  1520. smalltalk.Browser);
  1521. smalltalk.addMethod(
  1522. '_renderBoxOn_',
  1523. smalltalk.method({
  1524. selector: 'renderBoxOn:',
  1525. category: 'rendering',
  1526. fn: function (html){
  1527. var self=this;
  1528. (function($rec){smalltalk.send($rec, "_renderTopPanelOn_", [html]);smalltalk.send($rec, "_renderTabsOn_", [html]);return smalltalk.send($rec, "_renderBottomPanelOn_", [html]);})(self);
  1529. return self;},
  1530. source: unescape('renderBoxOn%3A%20html%0A%20%20%20%20self%20%0A%09renderTopPanelOn%3A%20html%3B%0A%09renderTabsOn%3A%20html%3B%0A%09renderBottomPanelOn%3A%20html'),
  1531. messageSends: ["renderTopPanelOn:", "renderTabsOn:", "renderBottomPanelOn:"],
  1532. referencedClasses: []
  1533. }),
  1534. smalltalk.Browser);
  1535. smalltalk.addMethod(
  1536. '_renderTopPanelOn_',
  1537. smalltalk.method({
  1538. selector: 'renderTopPanelOn:',
  1539. category: 'rendering',
  1540. fn: function (html){
  1541. var self=this;
  1542. (function($rec){smalltalk.send($rec, "_class_", ["top"]);return smalltalk.send($rec, "_with_", [(function(){smalltalk.send(self, "_renderInputOn_", [html]);self['@categoriesList']=smalltalk.send(smalltalk.send(html, "_ul", []), "_class_", ["jt_column browser categories"]);self['@commitButton']=(function($rec){smalltalk.send($rec, "_class_", ["jt_commit"]);smalltalk.send($rec, "_title_", ["Commit classes in this category to disk"]);smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_commitCategory", []);})]);return smalltalk.send($rec, "_with_", ["Commit category"]);})(smalltalk.send(html, "_button", []));self['@classesList']=smalltalk.send(smalltalk.send(html, "_ul", []), "_class_", ["jt_column browser classes"]);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", []));
  1543. return self;},
  1544. source: unescape('renderTopPanelOn%3A%20html%0A%20%20%20%20html%20div%20%0A%09class%3A%20%27top%27%3B%20%0A%09with%3A%20%5B%0A%09%20%20%20%20self%20renderInputOn%3A%20html.%0A%09%20%20%20%20categoriesList%20%3A%3D%20html%20ul%20class%3A%20%27jt_column%20browser%20categories%27.%0A%09%20%20%20%20commitButton%20%3A%3D%20html%20button%20%0A%09%09class%3A%20%27jt_commit%27%3B%0A%09%09title%3A%20%27Commit%20classes%20in%20this%20category%20to%20disk%27%3B%0A%09%09onClick%3A%20%5Bself%20commitCategory%5D%3B%0A%09%09with%3A%20%27Commit%20category%27.%0A%09%20%20%20%20classesList%20%3A%3D%20html%20ul%20class%3A%20%27jt_column%20browser%20classes%27.%0A%09%20%20%20%20protocolsList%20%3A%3D%20html%20ul%20class%3A%20%27jt_column%20browser%20protocols%27.%0A%09%20%20%20%20methodsList%20%3A%3D%20html%20ul%20class%3A%20%27jt_column%20browser%20methods%27.%0A%09%20%20%20%20self%0A%09%09updateCategoriesList%3B%0A%09%09updateClassesList%3B%0A%09%09updateProtocolsList%3B%0A%09%09updateMethodsList.%0A%09%20%20%20%20html%20div%20class%3A%20%27jt_clear%27%5D'),
  1545. messageSends: ["class:", "with:", "renderInputOn:", "ul", "title:", "onClick:", "commitCategory", "button", "updateCategoriesList", "updateClassesList", "updateProtocolsList", "updateMethodsList", "div"],
  1546. referencedClasses: []
  1547. }),
  1548. smalltalk.Browser);
  1549. smalltalk.addMethod(
  1550. '_renderTabsOn_',
  1551. smalltalk.method({
  1552. selector: 'renderTabsOn:',
  1553. category: 'rendering',
  1554. fn: function (html){
  1555. var self=this;
  1556. self['@tabsList']=smalltalk.send(smalltalk.send(html, "_ul", []), "_class_", ["jt_tabs"]);
  1557. smalltalk.send(self, "_updateTabsList", []);
  1558. return self;},
  1559. source: unescape('renderTabsOn%3A%20html%0A%20%20%20%20tabsList%20%3A%3D%20html%20ul%20class%3A%20%27jt_tabs%27.%0A%20%20%20%20self%20updateTabsList.'),
  1560. messageSends: ["class:", "ul", "updateTabsList"],
  1561. referencedClasses: []
  1562. }),
  1563. smalltalk.Browser);
  1564. smalltalk.addMethod(
  1565. '_renderBottomPanelOn_',
  1566. smalltalk.method({
  1567. selector: 'renderBottomPanelOn:',
  1568. category: 'rendering',
  1569. fn: function (html){
  1570. var self=this;
  1571. (function($rec){smalltalk.send($rec, "_class_", ["jt_sourceCode"]);return smalltalk.send($rec, "_with_", [(function(){self['@sourceTextarea']=(function($rec){smalltalk.send($rec, "_onKeyPress_", [(function(){return smalltalk.send(self, "_enableSaveButton", []);})]);smalltalk.send($rec, "_class_", ["source"]);return smalltalk.send($rec, "_at_put_", ["spellcheck", "false"]);})(smalltalk.send(html, "_textarea", []));return smalltalk.send(smalltalk.send(self['@sourceTextarea'], "_asJQuery", []), "_call_", ["tabby"]);})]);})(smalltalk.send(html, "_div", []));
  1572. return self;},
  1573. source: unescape('renderBottomPanelOn%3A%20html%0A%20%20%20%20html%20div%0A%09class%3A%20%27jt_sourceCode%27%3B%0A%09with%3A%20%5B%0A%09%20%20%20%20sourceTextarea%20%3A%3D%20html%20textarea%20%0A%09%09onKeyPress%3A%20%5Bself%20enableSaveButton%5D%3B%0A%09%09class%3A%20%27source%27%3B%0A%09%09at%3A%20%27spellcheck%27%20put%3A%20%27false%27.%0A%09%20%20%20%20sourceTextarea%20asJQuery%20call%3A%20%27tabby%27%5D'),
  1574. messageSends: ["class:", "with:", "onKeyPress:", "enableSaveButton", "at:put:", "textarea", "call:", "asJQuery", "div"],
  1575. referencedClasses: []
  1576. }),
  1577. smalltalk.Browser);
  1578. smalltalk.addMethod(
  1579. '_renderButtonsOn_',
  1580. smalltalk.method({
  1581. selector: 'renderButtonsOn:',
  1582. category: 'rendering',
  1583. fn: function (html){
  1584. var self=this;
  1585. self['@saveButton']=smalltalk.send(html, "_button", []);
  1586. (function($rec){smalltalk.send($rec, "_with_", ["Save"]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_compile", []);})]);})(self['@saveButton']);
  1587. self['@methodButtons']=smalltalk.send(html, "_span", []);
  1588. self['@classButtons']=smalltalk.send(html, "_span", []);
  1589. smalltalk.send(self, "_updateSourceAndButtons", []);
  1590. return self;},
  1591. source: unescape('renderButtonsOn%3A%20html%0A%20%20%20%20saveButton%20%3A%3D%20html%20button.%0A%20%20%20%20saveButton%20%0A%09with%3A%20%27Save%27%3B%0A%09onClick%3A%20%5Bself%20compile%5D.%0A%20%20%20%20methodButtons%20%3A%3D%20html%20span.%0A%20%20%20%20classButtons%20%3A%3D%20html%20span.%0A%20%20%20%20self%20updateSourceAndButtons'),
  1592. messageSends: ["button", "with:", "onClick:", "compile", "span", "updateSourceAndButtons"],
  1593. referencedClasses: []
  1594. }),
  1595. smalltalk.Browser);
  1596. smalltalk.addMethod(
  1597. '_canBeClosed',
  1598. smalltalk.method({
  1599. selector: 'canBeClosed',
  1600. category: 'testing',
  1601. fn: function (){
  1602. var self=this;
  1603. return true;
  1604. return self;},
  1605. source: unescape('canBeClosed%0A%20%20%20%20%5Etrue'),
  1606. messageSends: [],
  1607. referencedClasses: []
  1608. }),
  1609. smalltalk.Browser);
  1610. smalltalk.addMethod(
  1611. '_updateCategoriesList',
  1612. smalltalk.method({
  1613. selector: 'updateCategoriesList',
  1614. category: 'updating',
  1615. fn: function (){
  1616. var self=this;
  1617. smalltalk.send(self['@categoriesList'], "_contents_", [(function(html){return smalltalk.send(smalltalk.send(self, "_categories", []), "_do_", [(function(each){var li=nil;
  1618. var label=nil;
  1619. smalltalk.send(smalltalk.send(each, "_isEmpty", []), "_ifTrue_ifFalse_", [(function(){return label="Unclassified";}), (function(){return label=each;})]);li=smalltalk.send(html, "_li", []);smalltalk.send(smalltalk.send(self['@selectedCategory'], "__eq", [each]), "_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);})]);})]);
  1620. return self;},
  1621. source: unescape('updateCategoriesList%0A%20%20%20%20categoriesList%20contents%3A%20%5B%3Ahtml%20%7C%0A%09self%20categories%20do%3A%20%5B%3Aeach%20%7C%7C%20li%20label%20%7C%0A%09%20%20%20%20each%20isEmpty%20%0A%09%09ifTrue%3A%20%5Blabel%20%3A%3D%20%27Unclassified%27%5D%0A%09%09ifFalse%3A%20%5Blabel%20%3A%3D%20each%5D.%0A%09%20%20%20%20li%20%3A%3D%20html%20li.%0A%09%20%20%20%20selectedCategory%20%3D%20each%20ifTrue%3A%20%5B%0A%09%09li%20class%3A%20%27selected%27%5D.%0A%09%20%20%20%20li%0A%09%09with%3A%20label%3B%0A%09%09onClick%3A%20%5Bself%20selectCategory%3A%20each%5D%5D%5D'),
  1622. messageSends: ["contents:", "do:", "categories", "ifTrue:ifFalse:", "isEmpty", "li", "ifTrue:", unescape("%3D"), "class:", "with:", "onClick:", "selectCategory:"],
  1623. referencedClasses: []
  1624. }),
  1625. smalltalk.Browser);
  1626. smalltalk.addMethod(
  1627. '_updateClassesList',
  1628. smalltalk.method({
  1629. selector: 'updateClassesList',
  1630. category: 'updating',
  1631. fn: function (){
  1632. var self=this;
  1633. smalltalk.send(smalltalk.send(smalltalk.TabManager, "_current", []), "_update", []);
  1634. smalltalk.send(self['@classesList'], "_contents_", [(function(html){return smalltalk.send(smalltalk.send(self, "_classes", []), "_do_", [(function(each){var li=nil;
  1635. li=smalltalk.send(html, "_li", []);smalltalk.send(smalltalk.send(self['@selectedClass'], "__eq", [each]), "_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, "_selectClass_", [each]);})]);})(li);})]);})]);
  1636. return self;},
  1637. source: unescape('updateClassesList%0A%20%20%20%20TabManager%20current%20update.%0A%20%20%20%20classesList%20contents%3A%20%5B%3Ahtml%20%7C%0A%09self%20classes%20do%3A%20%5B%3Aeach%20%7C%7C%20li%20%7C%0A%09%20%20%20%20li%20%3A%3D%20html%20li.%0A%09%20%20%20%20selectedClass%20%3D%20each%20ifTrue%3A%20%5B%0A%09%09li%20class%3A%20%27selected%27%5D.%0A%09%20%20%20%20li%0A%09%09with%3A%20each%20name%3B%0A%09%09onClick%3A%20%5Bself%20selectClass%3A%20each%5D%5D%5D'),
  1638. messageSends: ["update", "current", "contents:", "do:", "classes", "li", "ifTrue:", unescape("%3D"), "class:", "with:", "name", "onClick:", "selectClass:"],
  1639. referencedClasses: [smalltalk.TabManager]
  1640. }),
  1641. smalltalk.Browser);
  1642. smalltalk.addMethod(
  1643. '_updateProtocolsList',
  1644. smalltalk.method({
  1645. selector: 'updateProtocolsList',
  1646. category: 'updating',
  1647. fn: function (){
  1648. var self=this;
  1649. smalltalk.send(self['@protocolsList'], "_contents_", [(function(html){return smalltalk.send(smalltalk.send(self, "_protocols", []), "_do_", [(function(each){var li=nil;
  1650. li=smalltalk.send(html, "_li", []);smalltalk.send(smalltalk.send(self['@selectedProtocol'], "__eq", [each]), "_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);})]);})]);
  1651. return self;},
  1652. source: unescape('updateProtocolsList%0A%20%20%20%20protocolsList%20contents%3A%20%5B%3Ahtml%20%7C%0A%09self%20protocols%20do%3A%20%5B%3Aeach%20%7C%7C%20li%20%7C%0A%09%20%20%20%20li%20%3A%3D%20html%20li.%0A%09%20%20%20%20selectedProtocol%20%3D%20each%20ifTrue%3A%20%5B%0A%09%09li%20class%3A%20%27selected%27%5D.%0A%09%20%20%20%20li%20%0A%09%09with%3A%20each%3B%0A%09%09onClick%3A%20%5Bself%20selectProtocol%3A%20each%5D%5D%5D'),
  1653. messageSends: ["contents:", "do:", "protocols", "li", "ifTrue:", unescape("%3D"), "class:", "with:", "onClick:", "selectProtocol:"],
  1654. referencedClasses: []
  1655. }),
  1656. smalltalk.Browser);
  1657. smalltalk.addMethod(
  1658. '_updateMethodsList',
  1659. smalltalk.method({
  1660. selector: 'updateMethodsList',
  1661. category: 'updating',
  1662. fn: function (){
  1663. var self=this;
  1664. smalltalk.send(self['@methodsList'], "_contents_", [(function(html){return smalltalk.send(smalltalk.send(self, "_methods", []), "_do_", [(function(each){var li=nil;
  1665. li=smalltalk.send(html, "_li", []);smalltalk.send(smalltalk.send(self['@selectedMethod'], "__eq", [each]), "_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);})]);})]);
  1666. return self;},
  1667. source: unescape('updateMethodsList%0A%20%20%20%20methodsList%20contents%3A%20%5B%3Ahtml%20%7C%0A%09self%20methods%20do%3A%20%5B%3Aeach%20%7C%7C%20li%20%7C%0A%09%20%20%20%20li%20%3A%3D%20html%20li.%0A%09%20%20%20%20selectedMethod%20%3D%20each%20ifTrue%3A%20%5B%0A%09%09li%20class%3A%20%27selected%27%5D.%0A%09%20%20%20%20li%0A%09%09with%3A%20each%20selector%3B%0A%09%09onClick%3A%20%5Bself%20selectMethod%3A%20each%5D%5D%5D'),
  1668. messageSends: ["contents:", "do:", "methods", "li", "ifTrue:", unescape("%3D"), "class:", "with:", "selector", "onClick:", "selectMethod:"],
  1669. referencedClasses: []
  1670. }),
  1671. smalltalk.Browser);
  1672. smalltalk.addMethod(
  1673. '_updateTabsList',
  1674. smalltalk.method({
  1675. selector: 'updateTabsList',
  1676. category: 'updating',
  1677. fn: function (){
  1678. var self=this;
  1679. smalltalk.send(self['@tabsList'], "_contents_", [(function(html){var li=nil;
  1680. li=smalltalk.send(html, "_li", []);smalltalk.send(smalltalk.send(self['@selectedTab'], "__eq", ["instance"]), "_ifTrue_", [(function(){return smalltalk.send(li, "_class_", ["selected"]);})]);(function($rec){smalltalk.send($rec, "_with_", ["Instance"]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_selectTab_", ["instance"]);})]);})(li);li=smalltalk.send(html, "_li", []);smalltalk.send(smalltalk.send(self['@selectedTab'], "__eq", ["class"]), "_ifTrue_", [(function(){return smalltalk.send(li, "_class_", ["selected"]);})]);(function($rec){smalltalk.send($rec, "_with_", ["Class"]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_selectTab_", ["class"]);})]);})(li);li=smalltalk.send(html, "_li", []);smalltalk.send(smalltalk.send(self['@selectedTab'], "__eq", ["comment"]), "_ifTrue_", [(function(){return smalltalk.send(li, "_class_", ["selected"]);})]);return (function($rec){smalltalk.send($rec, "_with_", ["Comment"]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_selectTab_", ["comment"]);})]);})(li);})]);
  1681. return self;},
  1682. source: unescape('updateTabsList%0A%20%20%20%20tabsList%20contents%3A%20%5B%3Ahtml%20%7C%7C%20li%20%7C%0A%09li%20%3A%3D%20html%20li.%0A%09selectedTab%20%3D%20%23instance%20ifTrue%3A%20%5Bli%20class%3A%20%27selected%27%5D.%0A%09li%0A%09%20%20%20%20with%3A%20%27Instance%27%3B%0A%09%20%20%20%20onClick%3A%20%5Bself%20selectTab%3A%20%23instance%5D.%0A%09li%20%3A%3D%20html%20li.%0A%09selectedTab%20%3D%20%23class%20ifTrue%3A%20%5Bli%20class%3A%20%27selected%27%5D.%0A%09li%0A%09%20%20%20%20with%3A%20%27Class%27%3B%0A%09%20%20%20%20onClick%3A%20%5Bself%20selectTab%3A%20%23class%5D.%0A%09li%20%3A%3D%20html%20li.%0A%09selectedTab%20%3D%20%23comment%20ifTrue%3A%20%5Bli%20class%3A%20%27selected%27%5D.%0A%09li%0A%09%20%20%20%20with%3A%20%27Comment%27%3B%0A%09%20%20%20%20onClick%3A%20%5Bself%20selectTab%3A%20%23comment%5D%5D'),
  1683. messageSends: ["contents:", "li", "ifTrue:", unescape("%3D"), "class:", "with:", "onClick:", "selectTab:"],
  1684. referencedClasses: []
  1685. }),
  1686. smalltalk.Browser);
  1687. smalltalk.addMethod(
  1688. '_updateSourceAndButtons',
  1689. smalltalk.method({
  1690. selector: 'updateSourceAndButtons',
  1691. category: 'updating',
  1692. fn: function (){
  1693. var self=this;
  1694. smalltalk.send(self, "_disableSaveButton", []);
  1695. 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", []));})]);
  1696. 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 smalltalk.send(smalltalk.send(self['@selectedMethod'], "_isNil", []), "_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", []));})]);})]);
  1697. smalltalk.send(smalltalk.send(self['@selectedMethod'], "_isNil", []), "_ifTrue_ifFalse_", [(function(){smalltalk.send(self, "_hideMethodButtons", []);return smalltalk.send(smalltalk.send(smalltalk.send(self['@selectedClass'], "_isNil", []), "_or_", [(function(){return smalltalk.send(self['@selectedProtocol'], "_notNil", []);})]), "_ifTrue_ifFalse_", [(function(){return smalltalk.send(self, "_hideClassButtons", []);}), (function(){return smalltalk.send(self, "_showClassButtons", []);})]);}), (function(){smalltalk.send(self, "_hideClassButtons", []);return smalltalk.send(self, "_showMethodButtons", []);})]);
  1698. smalltalk.send(smalltalk.send(self['@sourceTextarea'], "_asJQuery", []), "_val_", [smalltalk.send(self, "_source", [])]);
  1699. return self;},
  1700. source: unescape('updateSourceAndButtons%0A%09self%20disableSaveButton.%0A%09classButtons%20contents%3A%20%5B%3Ahtml%20%7C%0A%09%09html%20button%0A%09%09%09with%3A%20%27Rename%20class%27%3B%0A%09%09%09onClick%3A%20%5Bself%20renameClass%5D.%0A%09%09html%20button%0A%09%09%09with%3A%20%27Remove%20class%27%3B%0A%09%09%09onClick%3A%20%5Bself%20removeClass%5D.%0A%09%09html%20button%0A%09%09%09with%3A%20%27References%27%3B%0A%09%09%09onClick%3A%20%5Bself%20searchClassReferences%5D%5D.%0A%09methodButtons%20contents%3A%20%5B%3Ahtml%20%7C%0A%09%09html%20button%0A%09%09%09with%3A%20%27Remove%20method%27%3B%0A%09%09%09onClick%3A%20%5Bself%20removeMethod%5D.%0A%09%09html%20select%20%0A%09%20%20%20%20%09%09onChange%3A%20%5B%3Ae%20%3Aselect%20%7C%20self%20setMethodProtocol%3A%20select%20val%5D%3B%0A%09%20%20%20%20%09%09with%3A%20%5B%0A%09%09%09%09html%20option%0A%09%09%20%20%20%20%09%09%09with%3A%20%27Method%20protocol%27%3B%0A%09%09%09%09%09at%3A%20%27disabled%27%20put%3A%20%27disabled%27.%0A%09%09%09%09html%20option%0A%09%09%20%20%20%20%09%09%09class%3A%20%27important%27%3B%0A%09%09%20%20%20%20%09%09%09with%3A%20%27New...%27.%0A%09%09%09%09self%20protocols%20do%3A%20%5B%3Aeach%20%7C%0A%09%09%20%20%20%20%09%09%09html%20option%20with%3A%20each%5D%5D.%0A%09%09selectedMethod%20isNil%20ifFalse%3A%20%5B%0A%09%09%09html%20select%20%0A%09%20%20%20%20%09%09%09onChange%3A%20%5B%3Ae%20%3Aselect%20%7C%20self%20searchReferencesOf%3A%20select%20val%5D%3B%0A%09%20%20%20%20%09%09%09with%3A%20%5B%0A%09%09%09%09%09html%20option%0A%09%09%20%20%20%20%09%09%09%09with%3A%20%27References%27%3B%0A%09%09%09%09%09%09at%3A%20%27disabled%27%20put%3A%20%27disabled%27.%0A%09%09%09%09%09html%20option%0A%09%09%20%20%20%20%09%09%09%09class%3A%20%27important%27%3B%0A%09%09%20%20%20%20%09%09%09%09with%3A%20selectedMethod%20selector.%0A%09%09%09%09%09selectedMethod%20messageSends%20sorted%20do%3A%20%5B%3Aeach%20%7C%0A%09%09%20%20%20%20%09%09%09%09html%20option%20with%3A%20each%5D%5D%5D%5D.%0A%20%20%20%20%09selectedMethod%20isNil%0A%09%09ifTrue%3A%20%5B%0A%09%20%20%20%20%09%09self%20hideMethodButtons.%0A%09%20%20%20%20%09%09%09%28selectedClass%20isNil%20or%3A%20%5BselectedProtocol%20notNil%5D%29%0A%09%09%09%09%09ifTrue%3A%20%5Bself%20hideClassButtons%5D%0A%09%20%20%20%20%09%09%09%09ifFalse%3A%20%5Bself%20showClassButtons%5D%5D%0A%09%09ifFalse%3A%20%5B%0A%09%20%20%20%20%09%09self%20hideClassButtons.%0A%09%20%20%20%20%09%09self%20showMethodButtons%5D.%0A%20%20%20%20%09sourceTextarea%20asJQuery%20val%3A%20self%20source'),
  1701. messageSends: ["disableSaveButton", "contents:", "with:", "onClick:", "renameClass", "button", "removeClass", "searchClassReferences", "removeMethod", "onChange:", "setMethodProtocol:", "val", "at:put:", "option", "class:", "do:", "protocols", "select", "ifFalse:", "isNil", "searchReferencesOf:", "selector", "sorted", "messageSends", "ifTrue:ifFalse:", "hideMethodButtons", "or:", "notNil", "hideClassButtons", "showClassButtons", "showMethodButtons", "val:", "asJQuery", "source"],
  1702. referencedClasses: []
  1703. }),
  1704. smalltalk.Browser);
  1705. smalltalk.addMethod(
  1706. '_renderInputOn_',
  1707. smalltalk.method({
  1708. selector: 'renderInputOn:',
  1709. category: 'rendering',
  1710. fn: function (html){
  1711. var self=this;
  1712. self['@input']=(function($rec){smalltalk.send($rec, "_class_", ["implementors"]);return smalltalk.send($rec, "_yourself", []);})(smalltalk.send(html, "_input", []));
  1713. smalltalk.send(self['@input'], "_onKeyPress_", [(function(event){return smalltalk.send(smalltalk.send(smalltalk.send(event, "_keyCode", []), "__eq", [(13)]), "_ifTrue_", [(function(){return smalltalk.send(self, "_search_", [smalltalk.send(smalltalk.send(self['@input'], "_asJQuery", []), "_val", [])]);})]);})]);
  1714. return self;},
  1715. source: unescape('renderInputOn%3A%20html%20%0A%09input%20%3A%3D%20html%20input%20%0A%09%09class%3A%20%27implementors%27%3B%0A%09%09yourself.%0A%09input%20onKeyPress%3A%20%5B%3Aevent%20%7C%0A%09%09event%20keyCode%20%3D%2013%20ifTrue%3A%20%5B%0A%09%09%09self%20search%3A%20input%20asJQuery%20val%5D%5D'),
  1716. messageSends: ["class:", "yourself", "input", "onKeyPress:", "ifTrue:", unescape("%3D"), "keyCode", "search:", "val", "asJQuery"],
  1717. referencedClasses: []
  1718. }),
  1719. smalltalk.Browser);
  1720. smalltalk.addMethod(
  1721. '_search_',
  1722. smalltalk.method({
  1723. selector: 'search:',
  1724. category: 'actions',
  1725. fn: function (aString){
  1726. var self=this;
  1727. smalltalk.send(smalltalk.send(self, "_cancelChanges", []), "_ifTrue_", [(function(){var searchedClass=nil;
  1728. searchedClass=smalltalk.send(smalltalk.send(smalltalk.Smalltalk, "_current", []), "_at_", [aString]);return smalltalk.send(smalltalk.send(searchedClass, "_isClass", []), "_ifTrue_ifFalse_", [(function(){return smalltalk.send(smalltalk.send(self, "_class", []), "_openOn_", [searchedClass]);}), (function(){return smalltalk.send(self, "_searchReferencesOf_", [aString]);})]);})]);
  1729. return self;},
  1730. source: unescape('search%3A%20aString%0A%09self%20cancelChanges%20ifTrue%3A%20%5B%7C%20searchedClass%20%7C%0A%09%09searchedClass%20%3A%3D%20Smalltalk%20current%20at%3A%20aString.%0A%09%09searchedClass%20isClass%0A%09%09%09ifTrue%3A%20%5Bself%20class%20openOn%3A%20searchedClass%5D%0A%09%09%09ifFalse%3A%20%5Bself%20searchReferencesOf%3A%20aString%5D%5D'),
  1731. messageSends: ["ifTrue:", "cancelChanges", "at:", "current", "ifTrue:ifFalse:", "isClass", "openOn:", "class", "searchReferencesOf:"],
  1732. referencedClasses: [smalltalk.Smalltalk]
  1733. }),
  1734. smalltalk.Browser);
  1735. smalltalk.addMethod(
  1736. '_commitPathJs',
  1737. smalltalk.method({
  1738. selector: 'commitPathJs',
  1739. category: 'accessing',
  1740. fn: function (){
  1741. var self=this;
  1742. return "js";
  1743. return self;},
  1744. source: unescape('commitPathJs%0A%09%5E%27js%27'),
  1745. messageSends: [],
  1746. referencedClasses: []
  1747. }),
  1748. smalltalk.Browser.klass);
  1749. smalltalk.addMethod(
  1750. '_commitPathSt',
  1751. smalltalk.method({
  1752. selector: 'commitPathSt',
  1753. category: 'accessing',
  1754. fn: function (){
  1755. var self=this;
  1756. return "st";
  1757. return self;},
  1758. source: unescape('commitPathSt%0A%09%5E%27st%27'),
  1759. messageSends: [],
  1760. referencedClasses: []
  1761. }),
  1762. smalltalk.Browser.klass);
  1763. smalltalk.addMethod(
  1764. '_openOn_',
  1765. smalltalk.method({
  1766. selector: 'openOn:',
  1767. category: 'convenience',
  1768. fn: function (aClass){
  1769. var self=this;
  1770. 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", []));
  1771. return self;},
  1772. source: unescape('openOn%3A%20aClass%0A%20%20%20%20%5Eself%20new%0A%09open%3B%0A%09selectCategory%3A%20aClass%20category%3B%0A%09selectClass%3A%20aClass'),
  1773. messageSends: ["open", "selectCategory:", "category", "selectClass:", "new"],
  1774. referencedClasses: []
  1775. }),
  1776. smalltalk.Browser.klass);
  1777. smalltalk.addMethod(
  1778. '_open',
  1779. smalltalk.method({
  1780. selector: 'open',
  1781. category: 'convenience',
  1782. fn: function (){
  1783. var self=this;
  1784. smalltalk.send(smalltalk.send(self, "_new", []), "_open", []);
  1785. return self;},
  1786. source: unescape('open%0A%20%20%20%20self%20new%20open'),
  1787. messageSends: ["open", "new"],
  1788. referencedClasses: []
  1789. }),
  1790. smalltalk.Browser.klass);
  1791. smalltalk.addClass('Inspector', smalltalk.TabWidget, ['label', 'variables', 'object', 'selectedVariable', 'variablesList', 'valueTextarea', 'workspaceTextarea', 'diveButton'], 'IDE');
  1792. smalltalk.addMethod(
  1793. '_label',
  1794. smalltalk.method({
  1795. selector: 'label',
  1796. category: 'accessing',
  1797. fn: function (){
  1798. var self=this;
  1799. return smalltalk.send(self['@label'], "_ifNil_", [(function(){return unescape("Inspector%20%28nil%29");})]);
  1800. return self;},
  1801. source: unescape('label%0A%09%5Elabel%20ifNil%3A%20%5B%27Inspector%20%28nil%29%27%5D'),
  1802. messageSends: ["ifNil:"],
  1803. referencedClasses: []
  1804. }),
  1805. smalltalk.Inspector);
  1806. smalltalk.addMethod(
  1807. '_variables',
  1808. smalltalk.method({
  1809. selector: 'variables',
  1810. category: 'accessing',
  1811. fn: function (){
  1812. var self=this;
  1813. return self['@variables'];
  1814. return self;},
  1815. source: unescape('variables%0A%09%5Evariables'),
  1816. messageSends: [],
  1817. referencedClasses: []
  1818. }),
  1819. smalltalk.Inspector);
  1820. smalltalk.addMethod(
  1821. '_setVariables_',
  1822. smalltalk.method({
  1823. selector: 'setVariables:',
  1824. category: 'accessing',
  1825. fn: function (aCollection){
  1826. var self=this;
  1827. self['@variables']=aCollection;
  1828. return self;},
  1829. source: unescape('setVariables%3A%20aCollection%0A%09variables%20%3A%3D%20aCollection'),
  1830. messageSends: [],
  1831. referencedClasses: []
  1832. }),
  1833. smalltalk.Inspector);
  1834. smalltalk.addMethod(
  1835. '_setLabel_',
  1836. smalltalk.method({
  1837. selector: 'setLabel:',
  1838. category: 'accessing',
  1839. fn: function (aString){
  1840. var self=this;
  1841. self['@label']=aString;
  1842. return self;},
  1843. source: unescape('setLabel%3A%20aString%0A%09label%20%3A%3D%20aString'),
  1844. messageSends: [],
  1845. referencedClasses: []
  1846. }),
  1847. smalltalk.Inspector);
  1848. smalltalk.addMethod(
  1849. '_selectedVariable',
  1850. smalltalk.method({
  1851. selector: 'selectedVariable',
  1852. category: 'accessing',
  1853. fn: function (){
  1854. var self=this;
  1855. return self['@selectedVariable'];
  1856. return self;},
  1857. source: unescape('selectedVariable%0A%09%5EselectedVariable'),
  1858. messageSends: [],
  1859. referencedClasses: []
  1860. }),
  1861. smalltalk.Inspector);
  1862. smalltalk.addMethod(
  1863. '_selectedVariable_',
  1864. smalltalk.method({
  1865. selector: 'selectedVariable:',
  1866. category: 'accessing',
  1867. fn: function (aString){
  1868. var self=this;
  1869. self['@selectedVariable']=aString;
  1870. return self;},
  1871. source: unescape('selectedVariable%3A%20aString%0A%09selectedVariable%20%3A%3D%20aString'),
  1872. messageSends: [],
  1873. referencedClasses: []
  1874. }),
  1875. smalltalk.Inspector);
  1876. smalltalk.addMethod(
  1877. '_inspect_',
  1878. smalltalk.method({
  1879. selector: 'inspect:',
  1880. category: 'actions',
  1881. fn: function (anObject){
  1882. var self=this;
  1883. self['@object']=anObject;
  1884. self['@variables']=[];
  1885. smalltalk.send(self['@object'], "_inspectOn_", [self]);
  1886. return self;},
  1887. source: unescape('inspect%3A%20anObject%0A%09object%20%3A%3D%20anObject.%0A%09variables%20%3A%3D%20%23%28%29.%0A%09object%20inspectOn%3A%20self'),
  1888. messageSends: ["inspectOn:"],
  1889. referencedClasses: []
  1890. }),
  1891. smalltalk.Inspector);
  1892. smalltalk.addMethod(
  1893. '_dive',
  1894. smalltalk.method({
  1895. selector: 'dive',
  1896. category: 'actions',
  1897. fn: function (){
  1898. var self=this;
  1899. smalltalk.send(smalltalk.send(smalltalk.send(self, "_variables", []), "_at_", [smalltalk.send(self, "_selectedVariable", [])]), "_inspect", []);
  1900. return self;},
  1901. source: unescape('dive%0A%09%28self%20variables%20at%3A%20self%20selectedVariable%29%20inspect'),
  1902. messageSends: ["inspect", "at:", "variables", "selectedVariable"],
  1903. referencedClasses: []
  1904. }),
  1905. smalltalk.Inspector);
  1906. smalltalk.addMethod(
  1907. '_refresh',
  1908. smalltalk.method({
  1909. selector: 'refresh',
  1910. category: 'actions',
  1911. fn: function (){
  1912. var self=this;
  1913. (function($rec){smalltalk.send($rec, "_inspect_", [self['@object']]);smalltalk.send($rec, "_updateVariablesList", []);return smalltalk.send($rec, "_updateValueTextarea", []);})(self);
  1914. return self;},
  1915. source: unescape('refresh%0A%09self%20%0A%09%09inspect%3A%20object%3B%20%0A%09%09updateVariablesList%3B%0A%09%09updateValueTextarea'),
  1916. messageSends: ["inspect:", "updateVariablesList", "updateValueTextarea"],
  1917. referencedClasses: []
  1918. }),
  1919. smalltalk.Inspector);
  1920. smalltalk.addMethod(
  1921. '_renderBoxOn_',
  1922. smalltalk.method({
  1923. selector: 'renderBoxOn:',
  1924. category: 'rendering',
  1925. fn: function (html){
  1926. var self=this;
  1927. (function($rec){smalltalk.send($rec, "_renderTopPanelOn_", [html]);return smalltalk.send($rec, "_renderBottomPanelOn_", [html]);})(self);
  1928. return self;},
  1929. source: unescape('renderBoxOn%3A%20html%0A%09self%20%0A%09%09renderTopPanelOn%3A%20html%3B%0A%09%09renderBottomPanelOn%3A%20html'),
  1930. messageSends: ["renderTopPanelOn:", "renderBottomPanelOn:"],
  1931. referencedClasses: []
  1932. }),
  1933. smalltalk.Inspector);
  1934. smalltalk.addMethod(
  1935. '_renderTopPanelOn_',
  1936. smalltalk.method({
  1937. selector: 'renderTopPanelOn:',
  1938. category: 'rendering',
  1939. fn: function (html){
  1940. var self=this;
  1941. (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, "_updateVariablesList", []);return smalltalk.send($rec, "_updateValueTextarea", []);})(self);return smalltalk.send(smalltalk.send(html, "_div", []), "_class_", ["jt_clear"]);})]);})(smalltalk.send(html, "_div", []));
  1942. return self;},
  1943. source: unescape('renderTopPanelOn%3A%20html%0A%20%20%20%20html%20div%20%0A%09class%3A%20%27top%27%3B%20%0A%09with%3A%20%5B%0A%09%20%20%20%20variablesList%20%3A%3D%20html%20ul%20class%3A%20%27jt_column%20variables%27.%0A%09%20%20%20%20valueTextarea%20%3A%3D%20html%20textarea%20class%3A%20%27jt_column%20value%27%3B%20at%3A%20%27readonly%27%20put%3A%20%27readonly%27.%0A%09%20%20%20%20self%0A%09%09updateVariablesList%3B%0A%09%09updateValueTextarea.%0A%09%20%20%20%20html%20div%20class%3A%20%27jt_clear%27%5D'),
  1944. messageSends: ["class:", "with:", "ul", "at:put:", "textarea", "updateVariablesList", "updateValueTextarea", "div"],
  1945. referencedClasses: []
  1946. }),
  1947. smalltalk.Inspector);
  1948. smalltalk.addMethod(
  1949. '_renderBottomPanelOn_',
  1950. smalltalk.method({
  1951. selector: 'renderBottomPanelOn:',
  1952. category: 'rendering',
  1953. fn: function (html){
  1954. var self=this;
  1955. (function($rec){smalltalk.send($rec, "_class_", ["jt_sourceCode"]);return smalltalk.send($rec, "_with_", [(function(){self['@workspaceTextarea']=(function($rec){smalltalk.send($rec, "_class_", ["source"]);return smalltalk.send($rec, "_at_put_", ["spellcheck", "false"]);})(smalltalk.send(html, "_textarea", []));return smalltalk.send(smalltalk.send(self['@workspaceTextarea'], "_asJQuery", []), "_call_", ["tabby"]);})]);})(smalltalk.send(html, "_div", []));
  1956. return self;},
  1957. source: unescape('renderBottomPanelOn%3A%20html%0A%20%20%20%20html%20div%0A%09class%3A%20%27jt_sourceCode%27%3B%0A%09with%3A%20%5B%0A%09%20%20%20%20workspaceTextarea%20%3A%3D%20html%20textarea%20%0A%09%09class%3A%20%27source%27%3B%0A%09%09at%3A%20%27spellcheck%27%20put%3A%20%27false%27.%0A%09%20%20%20%20workspaceTextarea%20asJQuery%20call%3A%20%27tabby%27%5D'),
  1958. messageSends: ["class:", "with:", "at:put:", "textarea", "call:", "asJQuery", "div"],
  1959. referencedClasses: []
  1960. }),
  1961. smalltalk.Inspector);
  1962. smalltalk.addMethod(
  1963. '_renderButtonsOn_',
  1964. smalltalk.method({
  1965. selector: 'renderButtonsOn:',
  1966. category: 'rendering',
  1967. fn: function (html){
  1968. var self=this;
  1969. (function($rec){smalltalk.send($rec, "_with_", ["Refresh"]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_refresh", []);})]);})(smalltalk.send(html, "_button", []));
  1970. self['@diveButton']=(function($rec){smalltalk.send($rec, "_with_", ["Dive"]);return smalltalk.send($rec, "_onClick_", [(function(){return smalltalk.send(self, "_dive", []);})]);})(smalltalk.send(html, "_button", []));
  1971. smalltalk.send(self, "_updateButtons", []);
  1972. return self;},
  1973. source: unescape('renderButtonsOn%3A%20html%0A%09html%20button%0A%09%09with%3A%20%27Refresh%27%3B%0A%09%09onClick%3A%20%5Bself%20refresh%5D.%0A%09diveButton%20%3A%3D%20html%20button%20%0A%09%09with%3A%20%27Dive%27%3B%20%0A%09%09onClick%3A%20%5Bself%20dive%5D.%0A%09self%20updateButtons'),
  1974. messageSends: ["with:", "onClick:", "refresh", "button", "dive", "updateButtons"],
  1975. referencedClasses: []
  1976. }),
  1977. smalltalk.Inspector);
  1978. smalltalk.addMethod(
  1979. '_canBeClosed',
  1980. smalltalk.method({
  1981. selector: 'canBeClosed',
  1982. category: 'testing',
  1983. fn: function (){
  1984. var self=this;
  1985. return true;
  1986. return self;},
  1987. source: unescape('canBeClosed%0A%09%5Etrue'),
  1988. messageSends: [],
  1989. referencedClasses: []
  1990. }),
  1991. smalltalk.Inspector);
  1992. smalltalk.addMethod(
  1993. '_updateVariablesList',
  1994. smalltalk.method({
  1995. selector: 'updateVariablesList',
  1996. category: 'updating',
  1997. fn: function (){
  1998. var self=this;
  1999. smalltalk.send(self['@variablesList'], "_contents_", [(function(html){return smalltalk.send(smalltalk.send(smalltalk.send(self, "_variables", []), "_keys", []), "_do_", [(function(each){var li=nil;
  2000. 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 smalltalk.send(smalltalk.send(smalltalk.send(self, "_selectedVariable", []), "__eq", [each]), "_ifTrue_", [(function(){return smalltalk.send(li, "_class_", ["selected"]);})]);})]);})]);
  2001. return self;},
  2002. source: unescape('updateVariablesList%0A%09variablesList%20contents%3A%20%5B%3Ahtml%20%7C%0A%09%09self%20variables%20keys%20do%3A%20%5B%3Aeach%20%7C%7C%20li%20%7C%0A%09%09%09li%20%3A%3D%20html%20li.%0A%09%09%09li%0A%09%09%09%09with%3A%20each%3B%0A%09%09%09%09onClick%3A%20%5Bself%20selectVariable%3A%20each%5D.%0A%09%09%09self%20selectedVariable%20%3D%20each%20ifTrue%3A%20%5B%0A%09%09%09%09li%20class%3A%20%27selected%27%5D%5D%5D'),
  2003. messageSends: ["contents:", "do:", "keys", "variables", "li", "with:", "onClick:", "selectVariable:", "ifTrue:", unescape("%3D"), "selectedVariable", "class:"],
  2004. referencedClasses: []
  2005. }),
  2006. smalltalk.Inspector);
  2007. smalltalk.addMethod(
  2008. '_selectVariable_',
  2009. smalltalk.method({
  2010. selector: 'selectVariable:',
  2011. category: 'updating',
  2012. fn: function (aString){
  2013. var self=this;
  2014. smalltalk.send(self, "_selectedVariable_", [aString]);
  2015. (function($rec){smalltalk.send($rec, "_updateVariablesList", []);smalltalk.send($rec, "_updateValueTextarea", []);return smalltalk.send($rec, "_updateButtons", []);})(self);
  2016. return self;},
  2017. source: unescape('selectVariable%3A%20aString%0A%09self%20selectedVariable%3A%20aString.%0A%09self%20%0A%09%09updateVariablesList%3B%0A%09%09updateValueTextarea%3B%0A%09%09updateButtons'),
  2018. messageSends: ["selectedVariable:", "updateVariablesList", "updateValueTextarea", "updateButtons"],
  2019. referencedClasses: []
  2020. }),
  2021. smalltalk.Inspector);
  2022. smalltalk.addMethod(
  2023. '_updateValueTextarea',
  2024. smalltalk.method({
  2025. selector: 'updateValueTextarea',
  2026. category: 'updating',
  2027. fn: function (){
  2028. var self=this;
  2029. smalltalk.send(smalltalk.send(self['@valueTextarea'], "_asJQuery", []), "_val_", [smalltalk.send(smalltalk.send(smalltalk.send(self, "_selectedVariable", []), "_isNil", []), "_ifTrue_ifFalse_", [(function(){return "";}), (function(){return smalltalk.send(smalltalk.send(smalltalk.send(self, "_variables", []), "_at_", [smalltalk.send(self, "_selectedVariable", [])]), "_printString", []);})])]);
  2030. return self;},
  2031. source: unescape('updateValueTextarea%0A%09valueTextarea%20asJQuery%20val%3A%20%28self%20selectedVariable%20isNil%0A%09%09ifTrue%3A%20%5B%27%27%5D%0A%09%09ifFalse%3A%20%5B%28self%20variables%20at%3A%20self%20selectedVariable%29%20printString%5D%29'),
  2032. messageSends: ["val:", "asJQuery", "ifTrue:ifFalse:", "isNil", "selectedVariable", "printString", "at:", "variables"],
  2033. referencedClasses: []
  2034. }),
  2035. smalltalk.Inspector);
  2036. smalltalk.addMethod(
  2037. '_updateButtons',
  2038. smalltalk.method({
  2039. selector: 'updateButtons',
  2040. category: 'updating',
  2041. fn: function (){
  2042. var self=this;
  2043. smalltalk.send(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", []);})]), "_ifFalse_ifTrue_", [(function(){return smalltalk.send(self['@diveButton'], "_at_put_", ["disabled", true]);}), (function(){return smalltalk.send(self['@diveButton'], "_removeAt_", ["disabled"]);})]);
  2044. return self;},
  2045. source: unescape('updateButtons%0A%09%28self%20selectedVariable%20notNil%20and%3A%20%5B%28self%20variables%20at%3A%20self%20selectedVariable%29%20notNil%5D%29%0A%09%09ifFalse%3A%20%5BdiveButton%20at%3A%20%27disabled%27%20put%3A%20true%5D%20%0A%09%09ifTrue%3A%20%5BdiveButton%20removeAt%3A%20%27disabled%27%5D'),
  2046. messageSends: ["ifFalse:ifTrue:", "and:", "notNil", "selectedVariable", "at:", "variables", "at:put:", "removeAt:"],
  2047. referencedClasses: []
  2048. }),
  2049. smalltalk.Inspector);
  2050. smalltalk.addMethod(
  2051. '_on_',
  2052. smalltalk.method({
  2053. selector: 'on:',
  2054. category: 'instance creation',
  2055. fn: function (anObject){
  2056. var self=this;
  2057. return (function($rec){smalltalk.send($rec, "_inspect_", [anObject]);return smalltalk.send($rec, "_yourself", []);})(smalltalk.send(self, "_new", []));
  2058. return self;},
  2059. source: unescape('on%3A%20anObject%0A%09%5Eself%20new%0A%09%09inspect%3A%20anObject%3B%0A%09%09yourself'),
  2060. messageSends: ["inspect:", "yourself", "new"],
  2061. referencedClasses: []
  2062. }),
  2063. smalltalk.Inspector.klass);
  2064. smalltalk.addClass('ReferencesBrowser', smalltalk.TabWidget, ['implementors', 'senders', 'implementorsList', 'input', 'timer', 'selector', 'sendersList', 'referencedClasses', 'referencedClassesList'], 'IDE');
  2065. smalltalk.addMethod(
  2066. '_implementors',
  2067. smalltalk.method({
  2068. selector: 'implementors',
  2069. category: 'accessing',
  2070. fn: function (){
  2071. var self=this;
  2072. return smalltalk.send(self['@implementors'], "_ifNil_", [(function(){return self['@implementors']=smalltalk.send(smalltalk.Array, "_new", []);})]);
  2073. return self;},
  2074. source: unescape('implementors%0A%09%5Eimplementors%20ifNil%3A%20%5Bimplementors%20%3A%3D%20Array%20new%5D'),
  2075. messageSends: ["ifNil:", "new"],
  2076. referencedClasses: [smalltalk.Array]
  2077. }),
  2078. smalltalk.ReferencesBrowser);
  2079. smalltalk.addMethod(
  2080. '_label',
  2081. smalltalk.method({
  2082. selector: 'label',
  2083. category: 'accessing',
  2084. fn: function (){
  2085. var self=this;
  2086. return unescape("%5BReferencesBrowser%5D");
  2087. return self;},
  2088. source: unescape('label%0A%09%5E%27%5BReferencesBrowser%5D%27'),
  2089. messageSends: [],
  2090. referencedClasses: []
  2091. }),
  2092. smalltalk.ReferencesBrowser);
  2093. smalltalk.addMethod(
  2094. '_selector',
  2095. smalltalk.method({
  2096. selector: 'selector',
  2097. category: 'accessing',
  2098. fn: function (){
  2099. var self=this;
  2100. return self['@selector'];
  2101. return self;},
  2102. source: unescape('selector%0A%09%5Eselector'),
  2103. messageSends: [],
  2104. referencedClasses: []
  2105. }),
  2106. smalltalk.ReferencesBrowser);
  2107. smalltalk.addMethod(
  2108. '_senders',
  2109. smalltalk.method({
  2110. selector: 'senders',
  2111. category: 'accessing',
  2112. fn: function (){
  2113. var self=this;
  2114. return smalltalk.send(self['@senders'], "_ifNil_", [(function(){return self['@senders']=smalltalk.send(smalltalk.Array, "_new", []);})]);
  2115. return self;},
  2116. source: unescape('senders%0A%09%5Esenders%20ifNil%3A%20%5Bsenders%20%3A%3D%20Array%20new%5D'),
  2117. messageSends: ["ifNil:", "new"],
  2118. referencedClasses: [smalltalk.Array]
  2119. }),
  2120. smalltalk.ReferencesBrowser);
  2121. smalltalk.addMethod(
  2122. '_classesAndMetaclasses',
  2123. smalltalk.method({
  2124. selector: 'classesAndMetaclasses',
  2125. category: 'accessing',
  2126. fn: function (){
  2127. var self=this;
  2128. return smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.Smalltalk, "_current", []), "_classes", []), "__comma", [smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.Smalltalk, "_current", []), "_classes", []), "_collect_", [(function(each){return smalltalk.send(each, "_class", []);})])]);
  2129. return self;},
  2130. source: unescape('classesAndMetaclasses%0A%09%5ESmalltalk%20current%20classes%2C%20%28Smalltalk%20current%20classes%20collect%3A%20%5B%3Aeach%20%7C%20each%20class%5D%29'),
  2131. messageSends: [unescape("%2C"), "classes", "current", "collect:", "class"],
  2132. referencedClasses: [smalltalk.Smalltalk]
  2133. }),
  2134. smalltalk.ReferencesBrowser);
  2135. smalltalk.addMethod(
  2136. '_referencedClasses',
  2137. smalltalk.method({
  2138. selector: 'referencedClasses',
  2139. category: 'accessing',
  2140. fn: function (){
  2141. var self=this;
  2142. return smalltalk.send(self['@referencedClasses'], "_ifNil_", [(function(){return self['@referencedClasses']=smalltalk.send(smalltalk.Array, "_new", []);})]);
  2143. return self;},
  2144. source: unescape('referencedClasses%0A%09%5EreferencedClasses%20ifNil%3A%20%5BreferencedClasses%20%3A%3D%20Array%20new%5D'),
  2145. messageSends: ["ifNil:", "new"],
  2146. referencedClasses: [smalltalk.Array]
  2147. }),
  2148. smalltalk.ReferencesBrowser);
  2149. smalltalk.addMethod(
  2150. '_openBrowserOn_',
  2151. smalltalk.method({
  2152. selector: 'openBrowserOn:',
  2153. category: 'actions',
  2154. fn: function (aMethod){
  2155. var self=this;
  2156. var browser=nil;
  2157. browser=smalltalk.send(smalltalk.Browser, "_openOn_", [smalltalk.send(smalltalk.send(smalltalk.send(aMethod, "_class", []), "_isMetaclass", []), "_ifTrue_ifFalse_", [(function(){return smalltalk.send(smalltalk.send(aMethod, "_methodClass", []), "_instanceClass", []);}), (function(){return smalltalk.send(aMethod, "_methodClass", []);})])]);
  2158. smalltalk.send(smalltalk.send(smalltalk.send(aMethod, "_methodClass", []), "_isMetaclass", []), "_ifTrue_", [(function(){return smalltalk.send(browser, "_selectTab_", ["class"]);})]);
  2159. (function($rec){smalltalk.send($rec, "_selectProtocol_", [smalltalk.send(aMethod, "_category", [])]);return smalltalk.send($rec, "_selectMethod_", [aMethod]);})(browser);
  2160. return self;},
  2161. source: unescape('openBrowserOn%3A%20aMethod%0A%20%20%20%20%20%20%20%7C%20browser%20%7C%0A%20%20%20%20%20%20%20browser%20%3A%3D%20Browser%20openOn%3A%20%28aMethod%20class%20isMetaclass%20%0A%09%09ifTrue%3A%20%5BaMethod%20methodClass%20instanceClass%5D%20ifFalse%3A%20%5BaMethod%20methodClass%5D%29.%0A%20%20%20%20%20%20%20aMethod%20methodClass%20isMetaclass%20ifTrue%3A%20%5Bbrowser%20selectTab%3A%20%23class%5D.%0A%20%20%20%20%20%20%20browser%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20selectProtocol%3A%20aMethod%20category%3B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20selectMethod%3A%20aMethod'),
  2162. messageSends: ["openOn:", "ifTrue:ifFalse:", "isMetaclass", "class", "instanceClass", "methodClass", "ifTrue:", "selectTab:", "selectProtocol:", "category", "selectMethod:"],
  2163. referencedClasses: [smalltalk.Browser]
  2164. }),
  2165. smalltalk.ReferencesBrowser);
  2166. smalltalk.addMethod(
  2167. '_searchReferencesFor_',
  2168. smalltalk.method({
  2169. selector: 'searchReferencesFor:',
  2170. category: 'actions',
  2171. fn: function (aString){
  2172. var self=this;
  2173. self['@selector']=aString;
  2174. self['@implementors']=smalltalk.send(smalltalk.Array, "_new", []);
  2175. self['@senders']=smalltalk.send(smalltalk.Array, "_new", []);
  2176. self['@referencedClasses']=smalltalk.send(smalltalk.Array, "_new", []);
  2177. smalltalk.send(smalltalk.send(self['@selector'], "_match_", [unescape("%5E%5BA-Z%5D")]), "_ifFalse_ifTrue_", [(function(){return smalltalk.send(self, "_searchSelectorReferencesFor_", [self['@selector']]);}), (function(){return smalltalk.send(self, "_searchReferencedClassesFor_", [self['@selector']]);})]);
  2178. return self;},
  2179. source: unescape('searchReferencesFor%3A%20aString%0A%09selector%20%3A%3D%20aString.%0A%09implementors%20%3A%3D%20Array%20new.%0A%09senders%20%3A%3D%20Array%20new.%0A%09referencedClasses%20%3A%3D%20Array%20new.%0A%09%28selector%20match%3A%20%27%5E%5BA-Z%5D%27%29%20%0A%09%09ifFalse%3A%20%5Bself%20searchSelectorReferencesFor%3A%20selector%5D%0A%09%09ifTrue%3A%20%5Bself%20searchReferencedClassesFor%3A%20selector%5D'),
  2180. messageSends: ["new", "ifFalse:ifTrue:", "match:", "searchSelectorReferencesFor:", "searchReferencedClassesFor:"],
  2181. referencedClasses: [smalltalk.Array]
  2182. }),
  2183. smalltalk.ReferencesBrowser);
  2184. smalltalk.addMethod(
  2185. '_search_',
  2186. smalltalk.method({
  2187. selector: 'search:',
  2188. category: 'actions',
  2189. fn: function (aString){
  2190. var self=this;
  2191. (function($rec){smalltalk.send($rec, "_searchReferencesFor_", [aString]);smalltalk.send($rec, "_updateImplementorsList", []);smalltalk.send($rec, "_updateSendersList", []);return smalltalk.send($rec, "_updateReferencedClassesList", []);})(self);
  2192. return self;},
  2193. source: unescape('search%3A%20aString%0A%09self%20%0A%09%09searchReferencesFor%3A%20aString%3B%0A%09%09updateImplementorsList%3B%0A%09%09updateSendersList%3B%0A%09%09updateReferencedClassesList'),
  2194. messageSends: ["searchReferencesFor:", "updateImplementorsList", "updateSendersList", "updateReferencedClassesList"],
  2195. referencedClasses: []
  2196. }),
  2197. smalltalk.ReferencesBrowser);
  2198. smalltalk.addMethod(
  2199. '_searchReferencedClassesFor_',
  2200. smalltalk.method({
  2201. selector: 'searchReferencedClassesFor:',
  2202. category: 'actions',
  2203. fn: function (aString){
  2204. var self=this;
  2205. smalltalk.send(smalltalk.send(self, "_classesAndMetaclasses", []), "_do_", [(function(each){return smalltalk.send(smalltalk.send(smalltalk.send(each, "_methodDictionary", []), "_values", []), "_do_", [(function(value){return smalltalk.send(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']]), "_ifTrue_", [(function(){return smalltalk.send(smalltalk.send(self, "_referencedClasses", []), "_add_", [value]);})]);})]);})]);
  2206. return self;},
  2207. source: unescape('searchReferencedClassesFor%3A%20aString%0A%09self%20classesAndMetaclasses%20do%3A%20%5B%3Aeach%20%7C%0A%09%09each%20methodDictionary%20values%20do%3A%20%5B%3Avalue%20%7C%0A%09%09%09%28%28%28value%20referencedClasses%20select%3A%20%5B%3Aeach%20%7C%20each%20notNil%5D%29collect%3A%20%5B%3Aeach%20%7C%20each%20name%5D%29%20includes%3A%20selector%29%20ifTrue%3A%20%5B%0A%09%09%09%09self%20referencedClasses%20add%3A%20value%5D%5D%5D'),
  2208. messageSends: ["do:", "classesAndMetaclasses", "values", "methodDictionary", "ifTrue:", "includes:", "collect:", "select:", "referencedClasses", "notNil", "name", "add:"],
  2209. referencedClasses: []
  2210. }),
  2211. smalltalk.ReferencesBrowser);
  2212. smalltalk.addMethod(
  2213. '_searchSelectorReferencesFor_',
  2214. smalltalk.method({
  2215. selector: 'searchSelectorReferencesFor:',
  2216. category: 'actions',
  2217. fn: function (aString){
  2218. var self=this;
  2219. smalltalk.send(smalltalk.send(self, "_classesAndMetaclasses", []), "_do_", [(function(each){smalltalk.send(smalltalk.send(each, "_methodDictionary", []), "_keysAndValuesDo_", [(function(key, value){return smalltalk.send(smalltalk.send(key, "__eq", [self['@selector']]), "_ifTrue_", [(function(){return smalltalk.send(smalltalk.send(self, "_implementors", []), "_add_", [value]);})]);})]);return smalltalk.send(smalltalk.send(each, "_methodDictionary", []), "_keysAndValuesDo_", [(function(key, value){return smalltalk.send(smalltalk.send(smalltalk.send(value, "_messageSends", []), "_includes_", [self['@selector']]), "_ifTrue_", [(function(){return smalltalk.send(smalltalk.send(self, "_senders", []), "_add_", [value]);})]);})]);})]);
  2220. return self;},
  2221. source: unescape('searchSelectorReferencesFor%3A%20aString%0A%09self%20classesAndMetaclasses%20do%3A%20%5B%3Aeach%20%7C%20%0A%09%09each%20methodDictionary%20keysAndValuesDo%3A%20%5B%3Akey%20%3Avalue%20%7C%20%0A%09%09%09key%20%3D%20selector%20ifTrue%3A%20%5Bself%20implementors%20add%3A%20value%5D%5D.%0A%09%09each%20methodDictionary%20keysAndValuesDo%3A%20%5B%3Akey%20%3Avalue%20%7C%20%0A%09%09%09%28value%20messageSends%20includes%3A%20selector%29%20ifTrue%3A%20%5B%0A%09%09%09%09self%20senders%20add%3A%20value%5D%5D%5D'),
  2222. messageSends: ["do:", "classesAndMetaclasses", "keysAndValuesDo:", "methodDictionary", "ifTrue:", unescape("%3D"), "add:", "implementors", "includes:", "messageSends", "senders"],
  2223. referencedClasses: []
  2224. }),
  2225. smalltalk.ReferencesBrowser);
  2226. smalltalk.addMethod(
  2227. '_initialize',
  2228. smalltalk.method({
  2229. selector: 'initialize',
  2230. category: 'initialization',
  2231. fn: function (){
  2232. var self=this;
  2233. smalltalk.send(self, "_initialize", [], smalltalk.TabWidget);
  2234. self['@selector']="";
  2235. return self;},
  2236. source: unescape('initialize%0A%09super%20initialize.%0A%09selector%20%3A%3D%20%27%27'),
  2237. messageSends: ["initialize"],
  2238. referencedClasses: []
  2239. }),
  2240. smalltalk.ReferencesBrowser);
  2241. smalltalk.addMethod(
  2242. '_setInputEvents',
  2243. smalltalk.method({
  2244. selector: 'setInputEvents',
  2245. category: 'private',
  2246. fn: function (){
  2247. var self=this;
  2248. (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 smalltalk.send(self['@timer'], "_ifNotNil_", [(function(){return smalltalk.send(self['@timer'], "_clearTimeout", []);})]);})]);})(self['@input']);
  2249. return self;},
  2250. source: unescape('setInputEvents%0A%09input%0A%09%09onKeyUp%3A%20%5Btimer%20%3A%3D%20%5Bself%20search%3A%20input%20asJQuery%20val%5D%20valueWithTimeout%3A%20100%5D%3B%0A%09%09onKeyDown%3A%20%5Btimer%20ifNotNil%3A%20%5Btimer%20clearTimeout%5D%5D'),
  2251. messageSends: ["onKeyUp:", "valueWithTimeout:", "search:", "val", "asJQuery", "onKeyDown:", "ifNotNil:", "clearTimeout"],
  2252. referencedClasses: []
  2253. }),
  2254. smalltalk.ReferencesBrowser);
  2255. smalltalk.addMethod(
  2256. '_renderBoxOn_',
  2257. smalltalk.method({
  2258. selector: 'renderBoxOn:',
  2259. category: 'rendering',
  2260. fn: function (html){
  2261. var self=this;
  2262. (function($rec){smalltalk.send($rec, "_renderInputOn_", [html]);smalltalk.send($rec, "_renderImplementorsOn_", [html]);smalltalk.send($rec, "_renderSendersOn_", [html]);return smalltalk.send($rec, "_renderReferencedClassesOn_", [html]);})(self);
  2263. return self;},
  2264. source: unescape('renderBoxOn%3A%20html%0A%09self%20%0A%09%09renderInputOn%3A%20html%3B%0A%09%09renderImplementorsOn%3A%20html%3B%0A%09%09renderSendersOn%3A%20html%3B%0A%09%09renderReferencedClassesOn%3A%20html'),
  2265. messageSends: ["renderInputOn:", "renderImplementorsOn:", "renderSendersOn:", "renderReferencedClassesOn:"],
  2266. referencedClasses: []
  2267. }),
  2268. smalltalk.ReferencesBrowser);
  2269. smalltalk.addMethod(
  2270. '_renderInputOn_',
  2271. smalltalk.method({
  2272. selector: 'renderInputOn:',
  2273. category: 'rendering',
  2274. fn: function (html){
  2275. var self=this;
  2276. self['@input']=(function($rec){smalltalk.send($rec, "_class_", ["implementors"]);return smalltalk.send($rec, "_yourself", []);})(smalltalk.send(html, "_input", []));
  2277. smalltalk.send(smalltalk.send(self['@input'], "_asJQuery", []), "_val_", [self['@selector']]);
  2278. smalltalk.send(self, "_setInputEvents", []);
  2279. return self;},
  2280. source: unescape('renderInputOn%3A%20html%0A%09input%20%3A%3D%20html%20input%20%0A%09%09class%3A%20%27implementors%27%3B%0A%09%09yourself.%0A%09input%20asJQuery%20val%3A%20selector.%0A%09self%20setInputEvents'),
  2281. messageSends: ["class:", "yourself", "input", "val:", "asJQuery", "setInputEvents"],
  2282. referencedClasses: []
  2283. }),
  2284. smalltalk.ReferencesBrowser);
  2285. smalltalk.addMethod(
  2286. '_renderImplementorsOn_',
  2287. smalltalk.method({
  2288. selector: 'renderImplementorsOn:',
  2289. category: 'rendering',
  2290. fn: function (html){
  2291. var self=this;
  2292. self['@implementorsList']=smalltalk.send(smalltalk.send(html, "_ul", []), "_class_", ["jt_column implementors"]);
  2293. smalltalk.send(self, "_updateImplementorsList", []);
  2294. return self;},
  2295. source: unescape('renderImplementorsOn%3A%20html%0A%20%20%20%20%09implementorsList%20%3A%3D%20html%20ul%20class%3A%20%27jt_column%20implementors%27.%0A%09self%20updateImplementorsList'),
  2296. messageSends: ["class:", "ul", "updateImplementorsList"],
  2297. referencedClasses: []
  2298. }),
  2299. smalltalk.ReferencesBrowser);
  2300. smalltalk.addMethod(
  2301. '_renderSendersOn_',
  2302. smalltalk.method({
  2303. selector: 'renderSendersOn:',
  2304. category: 'rendering',
  2305. fn: function (html){
  2306. var self=this;
  2307. self['@sendersList']=smalltalk.send(smalltalk.send(html, "_ul", []), "_class_", ["jt_column senders"]);
  2308. smalltalk.send(self, "_updateSendersList", []);
  2309. return self;},
  2310. source: unescape('renderSendersOn%3A%20html%0A%20%20%20%20%09sendersList%20%3A%3D%20html%20ul%20class%3A%20%27jt_column%20senders%27.%0A%09self%20updateSendersList'),
  2311. messageSends: ["class:", "ul", "updateSendersList"],
  2312. referencedClasses: []
  2313. }),
  2314. smalltalk.ReferencesBrowser);
  2315. smalltalk.addMethod(
  2316. '_renderReferencedClassesOn_',
  2317. smalltalk.method({
  2318. selector: 'renderReferencedClassesOn:',
  2319. category: 'rendering',
  2320. fn: function (html){
  2321. var self=this;
  2322. self['@referencedClassesList']=smalltalk.send(smalltalk.send(html, "_ul", []), "_class_", ["jt_column referenced_classes"]);
  2323. smalltalk.send(self, "_updateReferencedClassesList", []);
  2324. return self;},
  2325. source: unescape('renderReferencedClassesOn%3A%20html%0A%20%20%20%20%09referencedClassesList%20%3A%3D%20html%20ul%20class%3A%20%27jt_column%20referenced_classes%27.%0A%09self%20updateReferencedClassesList'),
  2326. messageSends: ["class:", "ul", "updateReferencedClassesList"],
  2327. referencedClasses: []
  2328. }),
  2329. smalltalk.ReferencesBrowser);
  2330. smalltalk.addMethod(
  2331. '_canBeClosed',
  2332. smalltalk.method({
  2333. selector: 'canBeClosed',
  2334. category: 'testing',
  2335. fn: function (){
  2336. var self=this;
  2337. return true;
  2338. return self;},
  2339. source: unescape('canBeClosed%0A%09%5Etrue'),
  2340. messageSends: [],
  2341. referencedClasses: []
  2342. }),
  2343. smalltalk.ReferencesBrowser);
  2344. smalltalk.addMethod(
  2345. '_updateImplementorsList',
  2346. smalltalk.method({
  2347. selector: 'updateImplementorsList',
  2348. category: 'updating',
  2349. fn: function (){
  2350. var self=this;
  2351. 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;
  2352. 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);})]);})]);
  2353. return self;},
  2354. source: unescape('updateImplementorsList%0A%20%20%20%20implementorsList%20contents%3A%20%5B%3Ahtml%20%7C%0A%09html%20li%0A%09%09class%3A%20%27column_label%27%3B%20%0A%09%09with%3A%20%27Implementors%20%28%27%2C%20self%20implementors%20size%20asString%2C%20%27%29%27%3B%0A%09%09style%3A%20%27font-weight%3A%20bold%27.%0A%09self%20implementors%20do%3A%20%5B%3Aeach%20%7C%7C%20li%20%7C%0A%09%20%20%20%20li%20%3A%3D%20html%20li.%0A%09%20%20%20%20li%0A%09%09with%3A%20%28each%20methodClass%20asString%2C%20%27%20%3E%3E%20%27%2C%20self%20selector%29%3B%0A%09%09onClick%3A%20%5Bself%20openBrowserOn%3A%20each%5D%5D%5D'),
  2355. messageSends: ["contents:", "class:", "with:", unescape("%2C"), "asString", "size", "implementors", "style:", "li", "do:", "methodClass", "selector", "onClick:", "openBrowserOn:"],
  2356. referencedClasses: []
  2357. }),
  2358. smalltalk.ReferencesBrowser);
  2359. smalltalk.addMethod(
  2360. '_updateSendersList',
  2361. smalltalk.method({
  2362. selector: 'updateSendersList',
  2363. category: 'updating',
  2364. fn: function (){
  2365. var self=this;
  2366. 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", []));})]);})]);
  2367. return self;},
  2368. source: unescape('updateSendersList%0A%20%20%20%20%09sendersList%20contents%3A%20%5B%3Ahtml%20%7C%0A%09html%20li%0A%09%09class%3A%20%27column_label%27%3B%20%0A%09%09with%3A%20%27Senders%20%28%27%2C%20self%20senders%20size%20asString%2C%20%27%29%27%3B%0A%09%09style%3A%20%27font-weight%3A%20bold%27.%0A%09self%20senders%20do%3A%20%5B%3Aeach%20%7C%0A%09%09html%20li%0A%09%20%20%20%20%09%09with%3A%20%28each%20methodClass%20asString%2C%20%27%20%3E%3E%20%27%2C%20each%20selector%29%3B%0A%09%09%09onClick%3A%20%5Bself%20openBrowserOn%3A%20each%5D%5D%5D'),
  2369. messageSends: ["contents:", "class:", "with:", unescape("%2C"), "asString", "size", "senders", "style:", "li", "do:", "methodClass", "selector", "onClick:", "openBrowserOn:"],
  2370. referencedClasses: []
  2371. }),
  2372. smalltalk.ReferencesBrowser);
  2373. smalltalk.addMethod(
  2374. '_updateReferencedClassesList',
  2375. smalltalk.method({
  2376. selector: 'updateReferencedClassesList',
  2377. category: 'updating',
  2378. fn: function (){
  2379. var self=this;
  2380. 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", []));})]);})]);
  2381. return self;},
  2382. source: unescape('updateReferencedClassesList%0A%20%20%20%20%09referencedClassesList%20contents%3A%20%5B%3Ahtml%20%7C%0A%09html%20li%0A%09%09class%3A%20%27column_label%27%3B%20%0A%09%09with%3A%20%27Class%20references%20%28%27%2C%20self%20referencedClasses%20size%20asString%2C%20%27%29%27%3B%0A%09%09style%3A%20%27font-weight%3A%20bold%27.%0A%09self%20referencedClasses%20do%3A%20%5B%3Aeach%20%7C%0A%09%09html%20li%0A%09%20%20%20%20%09%09with%3A%20%28each%20methodClass%20asString%2C%20%27%20%3E%3E%20%27%2C%20each%20selector%29%3B%0A%09%09%09onClick%3A%20%5Bself%20openBrowserOn%3A%20each%5D%5D%5D'),
  2383. messageSends: ["contents:", "class:", "with:", unescape("%2C"), "asString", "size", "referencedClasses", "style:", "li", "do:", "methodClass", "selector", "onClick:", "openBrowserOn:"],
  2384. referencedClasses: []
  2385. }),
  2386. smalltalk.ReferencesBrowser);
  2387. smalltalk.addMethod(
  2388. '_search_',
  2389. smalltalk.method({
  2390. selector: 'search:',
  2391. category: 'instance creation',
  2392. fn: function (aString){
  2393. var self=this;
  2394. return (function($rec){smalltalk.send($rec, "_searchReferencesFor_", [aString]);return smalltalk.send($rec, "_open", []);})(smalltalk.send(self, "_new", []));
  2395. return self;},
  2396. source: unescape('search%3A%20aString%0A%09%5Eself%20new%0A%09%09searchReferencesFor%3A%20aString%3B%0A%09%09open'),
  2397. messageSends: ["searchReferencesFor:", "open", "new"],
  2398. referencedClasses: []
  2399. }),
  2400. smalltalk.ReferencesBrowser.klass);
  2401. smalltalk.addMethod(
  2402. '_inspect',
  2403. smalltalk.method({
  2404. selector: 'inspect',
  2405. category: '*IDE',
  2406. fn: function (){
  2407. var self=this;
  2408. (function($rec){smalltalk.send($rec, "_inspect_", [self]);return smalltalk.send($rec, "_open", []);})(smalltalk.send(smalltalk.Inspector, "_new", []));
  2409. return self;},
  2410. source: unescape('inspect%0A%09Inspector%20new%20%0A%09%09inspect%3A%20self%3B%0A%09%09open'),
  2411. messageSends: ["inspect:", "open", "new"],
  2412. referencedClasses: [smalltalk.Inspector]
  2413. }),
  2414. smalltalk.Object);
  2415. smalltalk.addMethod(
  2416. '_inspectOn_',
  2417. smalltalk.method({
  2418. selector: 'inspectOn:',
  2419. category: '*IDE',
  2420. fn: function (anInspector){
  2421. var self=this;
  2422. var variables=nil;
  2423. variables=smalltalk.send(smalltalk.Dictionary, "_new", []);
  2424. smalltalk.send(variables, "_at_put_", [unescape("%23self"), self]);
  2425. smalltalk.send(smalltalk.send(smalltalk.send(self, "_class", []), "_allInstanceVariableNames", []), "_do_", [(function(each){return smalltalk.send(variables, "_at_put_", [each, smalltalk.send(self, "_instVarAt_", [each])]);})]);
  2426. (function($rec){smalltalk.send($rec, "_setLabel_", [smalltalk.send(self, "_printString", [])]);return smalltalk.send($rec, "_setVariables_", [variables]);})(anInspector);
  2427. return self;},
  2428. source: unescape('inspectOn%3A%20anInspector%0A%09%7C%20variables%20%7C%0A%09variables%20%3A%3D%20Dictionary%20new.%0A%09variables%20at%3A%20%27%23self%27%20put%3A%20self.%0A%09self%20class%20allInstanceVariableNames%20do%3A%20%5B%3Aeach%20%7C%0A%09%09variables%20at%3A%20each%20put%3A%20%28self%20instVarAt%3A%20each%29%5D.%0A%09anInspector%20%0A%09%09setLabel%3A%20self%20printString%3B%0A%09%09setVariables%3A%20variables'),
  2429. messageSends: ["new", "at:put:", "do:", "allInstanceVariableNames", "class", "instVarAt:", "setLabel:", "printString", "setVariables:"],
  2430. referencedClasses: [smalltalk.Dictionary]
  2431. }),
  2432. smalltalk.Object);
  2433. smalltalk.addMethod(
  2434. '_inspectOn_',
  2435. smalltalk.method({
  2436. selector: 'inspectOn:',
  2437. category: '*IDE',
  2438. fn: function (anInspector){
  2439. var self=this;
  2440. var variables=nil;
  2441. variables=smalltalk.send(smalltalk.Dictionary, "_new", []);
  2442. smalltalk.send(variables, "_at_put_", [unescape("%23self"), self]);
  2443. smalltalk.send(variables, "_at_put_", [unescape("%23year"), smalltalk.send(self, "_year", [])]);
  2444. smalltalk.send(variables, "_at_put_", [unescape("%23month"), smalltalk.send(self, "_month", [])]);
  2445. smalltalk.send(variables, "_at_put_", [unescape("%23day"), smalltalk.send(self, "_day", [])]);
  2446. smalltalk.send(variables, "_at_put_", [unescape("%23hours"), smalltalk.send(self, "_hours", [])]);
  2447. smalltalk.send(variables, "_at_put_", [unescape("%23minutes"), smalltalk.send(self, "_minutes", [])]);
  2448. smalltalk.send(variables, "_at_put_", [unescape("%23seconds"), smalltalk.send(self, "_seconds", [])]);
  2449. smalltalk.send(variables, "_at_put_", [unescape("%23milliseconds"), smalltalk.send(self, "_milliseconds", [])]);
  2450. (function($rec){smalltalk.send($rec, "_setLabel_", [smalltalk.send(self, "_printString", [])]);return smalltalk.send($rec, "_setVariables_", [variables]);})(anInspector);
  2451. return self;},
  2452. source: unescape('inspectOn%3A%20anInspector%0A%09%7C%20variables%20%7C%0A%09variables%20%3A%3D%20Dictionary%20new.%0A%09variables%20at%3A%20%27%23self%27%20put%3A%20self.%0A%09variables%20at%3A%20%27%23year%27%20put%3A%20self%20year.%0A%09variables%20at%3A%20%27%23month%27%20put%3A%20self%20month.%0A%09variables%20at%3A%20%27%23day%27%20put%3A%20self%20day.%0A%09variables%20at%3A%20%27%23hours%27%20put%3A%20self%20hours.%0A%09variables%20at%3A%20%27%23minutes%27%20put%3A%20self%20minutes.%0A%09variables%20at%3A%20%27%23seconds%27%20put%3A%20self%20seconds.%0A%09variables%20at%3A%20%27%23milliseconds%27%20put%3A%20self%20milliseconds.%0A%09anInspector%20%0A%09%09setLabel%3A%20self%20printString%3B%0A%09%09setVariables%3A%20variables'),
  2453. messageSends: ["new", "at:put:", "year", "month", "day", "hours", "minutes", "seconds", "milliseconds", "setLabel:", "printString", "setVariables:"],
  2454. referencedClasses: [smalltalk.Dictionary]
  2455. }),
  2456. smalltalk.Date);
  2457. smalltalk.addMethod(
  2458. '_inspectOn_',
  2459. smalltalk.method({
  2460. selector: 'inspectOn:',
  2461. category: '*IDE',
  2462. fn: function (anInspector){
  2463. var self=this;
  2464. var variables=nil;
  2465. variables=smalltalk.send(smalltalk.Dictionary, "_new", []);
  2466. smalltalk.send(variables, "_at_put_", [unescape("%23self"), self]);
  2467. smalltalk.send(self, "_withIndexDo_", [(function(each, i){return smalltalk.send(variables, "_at_put_", [i, each]);})]);
  2468. (function($rec){smalltalk.send($rec, "_setLabel_", [smalltalk.send(self, "_printString", [])]);return smalltalk.send($rec, "_setVariables_", [variables]);})(anInspector);
  2469. return self;},
  2470. source: unescape('inspectOn%3A%20anInspector%0A%09%7C%20variables%20%7C%0A%09variables%20%3A%3D%20Dictionary%20new.%0A%09variables%20at%3A%20%27%23self%27%20put%3A%20self.%0A%09self%20withIndexDo%3A%20%5B%3Aeach%20%3Ai%20%7C%0A%09%09variables%20at%3A%20i%20put%3A%20each%5D.%0A%09anInspector%20%0A%09%09setLabel%3A%20self%20printString%3B%0A%09%09setVariables%3A%20variables'),
  2471. messageSends: ["new", "at:put:", "withIndexDo:", "setLabel:", "printString", "setVariables:"],
  2472. referencedClasses: [smalltalk.Dictionary]
  2473. }),
  2474. smalltalk.Collection);
  2475. smalltalk.addMethod(
  2476. '_inspectOn_',
  2477. smalltalk.method({
  2478. selector: 'inspectOn:',
  2479. category: '*IDE',
  2480. fn: function (anInspector){
  2481. var self=this;
  2482. var label=nil;
  2483. smalltalk.send(self, "_inspectOn_", [anInspector], smalltalk.SequenceableCollection);
  2484. smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(self, "_printString", []), "_size", []), "__gt", [(30)]), "_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", []);})]);
  2485. smalltalk.send(anInspector, "_setLabel_", [label]);
  2486. return self;},
  2487. source: unescape('inspectOn%3A%20anInspector%0A%09%7C%20label%20%7C%0A%09super%20inspectOn%3A%20anInspector.%0A%09self%20printString%20size%20%3E%2030%20%0A%09%09ifTrue%3A%20%5Blabel%20%3A%3D%20%28self%20printString%20copyFrom%3A%201%20to%3A%2030%29%2C%20%27...%27%27%27%5D%0A%09%09ifFalse%3A%20%5Blabel%20%3A%3D%20self%20printString%5D.%20%0A%09anInspector%20setLabel%3A%20label'),
  2488. messageSends: ["inspectOn:", "ifTrue:ifFalse:", unescape("%3E"), "size", "printString", unescape("%2C"), "copyFrom:to:", "setLabel:"],
  2489. referencedClasses: []
  2490. }),
  2491. smalltalk.String);
  2492. smalltalk.addMethod(
  2493. '_inspectOn_',
  2494. smalltalk.method({
  2495. selector: 'inspectOn:',
  2496. category: '*IDE',
  2497. fn: function (anInspector){
  2498. var self=this;
  2499. var variables=nil;
  2500. variables=smalltalk.send(smalltalk.Dictionary, "_new", []);
  2501. smalltalk.send(variables, "_at_put_", [unescape("%23self"), self]);
  2502. smalltalk.send(variables, "_at_put_", [unescape("%23home"), smalltalk.send(self, "_home", [])]);
  2503. smalltalk.send(variables, "_at_put_", [unescape("%23receiver"), smalltalk.send(self, "_receiver", [])]);
  2504. smalltalk.send(variables, "_at_put_", [unescape("%23selector"), smalltalk.send(self, "_selector", [])]);
  2505. smalltalk.send(smalltalk.send(smalltalk.send(self, "_class", []), "_instanceVariableNames", []), "_do_", [(function(each){return smalltalk.send(variables, "_at_put_", [each, smalltalk.send(self, "_instVarAt_", [each])]);})]);
  2506. (function($rec){smalltalk.send($rec, "_setLabel_", [smalltalk.send(self, "_printString", [])]);return smalltalk.send($rec, "_setVariables_", [variables]);})(anInspector);
  2507. return self;},
  2508. source: unescape('inspectOn%3A%20anInspector%0A%09%7C%20variables%20%7C%0A%09variables%20%3A%3D%20Dictionary%20new.%0A%09variables%20at%3A%20%27%23self%27%20put%3A%20self.%0A%09variables%20at%3A%20%27%23home%27%20put%3A%20self%20home.%0A%09variables%20at%3A%20%27%23receiver%27%20put%3A%20self%20receiver.%0A%09variables%20at%3A%20%27%23selector%27%20put%3A%20self%20selector.%0A%09self%20class%20instanceVariableNames%20do%3A%20%5B%3Aeach%20%7C%0A%09%09variables%20at%3A%20each%20put%3A%20%28self%20instVarAt%3A%20each%29%5D.%0A%09anInspector%20%0A%09%09setLabel%3A%20self%20printString%3B%0A%09%09setVariables%3A%20variables'),
  2509. messageSends: ["new", "at:put:", "home", "receiver", "selector", "do:", "instanceVariableNames", "class", "instVarAt:", "setLabel:", "printString", "setVariables:"],
  2510. referencedClasses: [smalltalk.Dictionary]
  2511. }),
  2512. smalltalk.MethodContext);
  2513. smalltalk.addMethod(
  2514. '_inspectOn_',
  2515. smalltalk.method({
  2516. selector: 'inspectOn:',
  2517. category: '*IDE',
  2518. fn: function (anInspector){
  2519. var self=this;
  2520. var variables=nil;
  2521. variables=smalltalk.send(smalltalk.Dictionary, "_new", []);
  2522. smalltalk.send(variables, "_at_put_", [unescape("%23self"), self]);
  2523. smalltalk.send(variables, "_at_put_", [unescape("%23keys"), smalltalk.send(self, "_keys", [])]);
  2524. smalltalk.send(self, "_keysAndValuesDo_", [(function(key, value){return smalltalk.send(variables, "_at_put_", [key, value]);})]);
  2525. (function($rec){smalltalk.send($rec, "_setLabel_", [smalltalk.send(self, "_printString", [])]);return smalltalk.send($rec, "_setVariables_", [variables]);})(anInspector);
  2526. return self;},
  2527. source: unescape('inspectOn%3A%20anInspector%0A%09%7C%20variables%20%7C%0A%09variables%20%3A%3D%20Dictionary%20new.%0A%09variables%20at%3A%20%27%23self%27%20put%3A%20self.%0A%09variables%20at%3A%20%27%23keys%27%20put%3A%20self%20keys.%0A%09self%20keysAndValuesDo%3A%20%5B%3Akey%20%3Avalue%20%7C%0A%09%09variables%20at%3A%20key%20put%3A%20value%5D.%0A%09anInspector%20%0A%09%09setLabel%3A%20self%20printString%3B%0A%09%09setVariables%3A%20variables'),
  2528. messageSends: ["new", "at:put:", "keys", "keysAndValuesDo:", "setLabel:", "printString", "setVariables:"],
  2529. referencedClasses: [smalltalk.Dictionary]
  2530. }),
  2531. smalltalk.Dictionary);