Helios-Browser.deploy.js 136 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537253825392540254125422543254425452546254725482549255025512552255325542555255625572558255925602561256225632564256525662567256825692570257125722573257425752576257725782579258025812582258325842585258625872588258925902591259225932594259525962597259825992600260126022603260426052606260726082609261026112612261326142615261626172618261926202621262226232624262526262627262826292630263126322633263426352636263726382639264026412642264326442645264626472648264926502651265226532654265526562657265826592660266126622663266426652666266726682669267026712672267326742675267626772678267926802681268226832684268526862687268826892690269126922693269426952696269726982699270027012702270327042705270627072708270927102711271227132714271527162717271827192720272127222723272427252726272727282729273027312732273327342735273627372738273927402741274227432744274527462747274827492750275127522753275427552756275727582759276027612762276327642765276627672768276927702771277227732774277527762777277827792780278127822783278427852786278727882789279027912792279327942795279627972798279928002801280228032804280528062807280828092810281128122813281428152816281728182819282028212822282328242825282628272828282928302831283228332834283528362837283828392840284128422843284428452846284728482849285028512852285328542855285628572858285928602861286228632864286528662867286828692870287128722873287428752876287728782879288028812882288328842885288628872888288928902891289228932894289528962897289828992900290129022903290429052906290729082909291029112912291329142915291629172918291929202921292229232924292529262927292829292930293129322933293429352936293729382939294029412942294329442945294629472948294929502951295229532954295529562957295829592960296129622963296429652966296729682969297029712972297329742975297629772978297929802981298229832984298529862987298829892990299129922993299429952996299729982999300030013002300330043005300630073008300930103011301230133014301530163017301830193020302130223023302430253026302730283029303030313032303330343035303630373038303930403041304230433044304530463047304830493050305130523053305430553056305730583059306030613062306330643065306630673068306930703071307230733074307530763077307830793080308130823083308430853086308730883089309030913092309330943095309630973098309931003101310231033104310531063107310831093110311131123113311431153116311731183119312031213122312331243125312631273128312931303131313231333134313531363137313831393140314131423143314431453146314731483149315031513152315331543155315631573158315931603161316231633164316531663167316831693170317131723173317431753176317731783179318031813182318331843185318631873188318931903191319231933194319531963197319831993200320132023203320432053206320732083209321032113212321332143215321632173218321932203221322232233224322532263227322832293230323132323233323432353236323732383239324032413242324332443245324632473248324932503251325232533254325532563257325832593260326132623263326432653266326732683269327032713272327332743275327632773278327932803281328232833284328532863287328832893290329132923293329432953296329732983299330033013302330333043305330633073308330933103311331233133314331533163317331833193320332133223323332433253326332733283329333033313332333333343335333633373338333933403341334233433344334533463347334833493350335133523353335433553356335733583359336033613362336333643365336633673368336933703371337233733374337533763377337833793380338133823383338433853386338733883389339033913392339333943395339633973398339934003401340234033404340534063407340834093410341134123413341434153416341734183419342034213422342334243425342634273428342934303431343234333434343534363437343834393440344134423443344434453446344734483449345034513452345334543455345634573458345934603461346234633464346534663467346834693470347134723473347434753476347734783479348034813482348334843485348634873488348934903491349234933494349534963497349834993500350135023503350435053506350735083509351035113512351335143515351635173518351935203521352235233524352535263527352835293530353135323533353435353536353735383539354035413542354335443545354635473548354935503551355235533554355535563557355835593560356135623563356435653566356735683569357035713572357335743575357635773578357935803581358235833584358535863587358835893590359135923593359435953596359735983599360036013602360336043605360636073608360936103611361236133614361536163617361836193620362136223623362436253626362736283629363036313632363336343635363636373638363936403641364236433644364536463647
  1. smalltalk.addPackage('Helios-Browser');
  2. smalltalk.addClass('HLBrowser', smalltalk.HLWidget, ['model', 'packagesListWidget', 'classesListWidget', 'protocolsListWidget', 'methodsListWidget', 'sourceWidget', 'bottomDiv'], 'Helios-Browser');
  3. smalltalk.addMethod(
  4. smalltalk.method({
  5. selector: "canHaveFocus",
  6. fn: function (){
  7. var self=this;
  8. return smalltalk.withContext(function($ctx1) {
  9. return true;
  10. }, function($ctx1) {$ctx1.fill(self,"canHaveFocus",{},smalltalk.HLBrowser)})},
  11. messageSends: []}),
  12. smalltalk.HLBrowser);
  13. smalltalk.addMethod(
  14. smalltalk.method({
  15. selector: "classesListWidget",
  16. fn: function (){
  17. var self=this;
  18. function $HLClassesListWidget(){return smalltalk.HLClassesListWidget||(typeof HLClassesListWidget=="undefined"?nil:HLClassesListWidget)}
  19. return smalltalk.withContext(function($ctx1) {
  20. var $2,$1;
  21. $2=self["@classesListWidget"];
  22. if(($receiver = $2) == nil || $receiver == undefined){
  23. self["@classesListWidget"]=_st($HLClassesListWidget())._on_(_st(self)._model());
  24. self["@classesListWidget"];
  25. $1=_st(self["@classesListWidget"])._next_(_st(self)._protocolsListWidget());
  26. } else {
  27. $1=$2;
  28. };
  29. return $1;
  30. }, function($ctx1) {$ctx1.fill(self,"classesListWidget",{},smalltalk.HLBrowser)})},
  31. messageSends: ["ifNil:", "on:", "model", "next:", "protocolsListWidget"]}),
  32. smalltalk.HLBrowser);
  33. smalltalk.addMethod(
  34. smalltalk.method({
  35. selector: "environment",
  36. fn: function (){
  37. var self=this;
  38. return smalltalk.withContext(function($ctx1) {
  39. var $1;
  40. $1=_st(_st(self)._model())._environment();
  41. return $1;
  42. }, function($ctx1) {$ctx1.fill(self,"environment",{},smalltalk.HLBrowser)})},
  43. messageSends: ["environment", "model"]}),
  44. smalltalk.HLBrowser);
  45. smalltalk.addMethod(
  46. smalltalk.method({
  47. selector: "focus",
  48. fn: function (){
  49. var self=this;
  50. return smalltalk.withContext(function($ctx1) {
  51. var $1;
  52. $1=_st(_st(self)._packagesListWidget())._focus();
  53. return $1;
  54. }, function($ctx1) {$ctx1.fill(self,"focus",{},smalltalk.HLBrowser)})},
  55. messageSends: ["focus", "packagesListWidget"]}),
  56. smalltalk.HLBrowser);
  57. smalltalk.addMethod(
  58. smalltalk.method({
  59. selector: "methodsListWidget",
  60. fn: function (){
  61. var self=this;
  62. function $HLMethodsListWidget(){return smalltalk.HLMethodsListWidget||(typeof HLMethodsListWidget=="undefined"?nil:HLMethodsListWidget)}
  63. return smalltalk.withContext(function($ctx1) {
  64. var $2,$1;
  65. $2=self["@methodsListWidget"];
  66. if(($receiver = $2) == nil || $receiver == undefined){
  67. self["@methodsListWidget"]=_st($HLMethodsListWidget())._on_(_st(self)._model());
  68. self["@methodsListWidget"];
  69. $1=_st(self["@methodsListWidget"])._next_(_st(self)._sourceWidget());
  70. } else {
  71. $1=$2;
  72. };
  73. return $1;
  74. }, function($ctx1) {$ctx1.fill(self,"methodsListWidget",{},smalltalk.HLBrowser)})},
  75. messageSends: ["ifNil:", "on:", "model", "next:", "sourceWidget"]}),
  76. smalltalk.HLBrowser);
  77. smalltalk.addMethod(
  78. smalltalk.method({
  79. selector: "model",
  80. fn: function (){
  81. var self=this;
  82. function $HLBrowserModel(){return smalltalk.HLBrowserModel||(typeof HLBrowserModel=="undefined"?nil:HLBrowserModel)}
  83. return smalltalk.withContext(function($ctx1) {
  84. var $2,$1;
  85. $2=self["@model"];
  86. if(($receiver = $2) == nil || $receiver == undefined){
  87. self["@model"]=_st($HLBrowserModel())._new();
  88. $1=self["@model"];
  89. } else {
  90. $1=$2;
  91. };
  92. return $1;
  93. }, function($ctx1) {$ctx1.fill(self,"model",{},smalltalk.HLBrowser)})},
  94. messageSends: ["ifNil:", "new"]}),
  95. smalltalk.HLBrowser);
  96. smalltalk.addMethod(
  97. smalltalk.method({
  98. selector: "model:",
  99. fn: function (aModel){
  100. var self=this;
  101. return smalltalk.withContext(function($ctx1) {
  102. self["@model"]=aModel;
  103. return self}, function($ctx1) {$ctx1.fill(self,"model:",{aModel:aModel},smalltalk.HLBrowser)})},
  104. messageSends: []}),
  105. smalltalk.HLBrowser);
  106. smalltalk.addMethod(
  107. smalltalk.method({
  108. selector: "packagesListWidget",
  109. fn: function (){
  110. var self=this;
  111. function $HLPackagesListWidget(){return smalltalk.HLPackagesListWidget||(typeof HLPackagesListWidget=="undefined"?nil:HLPackagesListWidget)}
  112. return smalltalk.withContext(function($ctx1) {
  113. var $2,$1;
  114. $2=self["@packagesListWidget"];
  115. if(($receiver = $2) == nil || $receiver == undefined){
  116. self["@packagesListWidget"]=_st($HLPackagesListWidget())._on_(_st(self)._model());
  117. self["@packagesListWidget"];
  118. $1=_st(self["@packagesListWidget"])._next_(_st(self)._classesListWidget());
  119. } else {
  120. $1=$2;
  121. };
  122. return $1;
  123. }, function($ctx1) {$ctx1.fill(self,"packagesListWidget",{},smalltalk.HLBrowser)})},
  124. messageSends: ["ifNil:", "on:", "model", "next:", "classesListWidget"]}),
  125. smalltalk.HLBrowser);
  126. smalltalk.addMethod(
  127. smalltalk.method({
  128. selector: "protocolsListWidget",
  129. fn: function (){
  130. var self=this;
  131. function $HLProtocolsListWidget(){return smalltalk.HLProtocolsListWidget||(typeof HLProtocolsListWidget=="undefined"?nil:HLProtocolsListWidget)}
  132. return smalltalk.withContext(function($ctx1) {
  133. var $2,$1;
  134. $2=self["@protocolsListWidget"];
  135. if(($receiver = $2) == nil || $receiver == undefined){
  136. self["@protocolsListWidget"]=_st($HLProtocolsListWidget())._on_(_st(self)._model());
  137. self["@protocolsListWidget"];
  138. $1=_st(self["@protocolsListWidget"])._next_(_st(self)._methodsListWidget());
  139. } else {
  140. $1=$2;
  141. };
  142. return $1;
  143. }, function($ctx1) {$ctx1.fill(self,"protocolsListWidget",{},smalltalk.HLBrowser)})},
  144. messageSends: ["ifNil:", "on:", "model", "next:", "methodsListWidget"]}),
  145. smalltalk.HLBrowser);
  146. smalltalk.addMethod(
  147. smalltalk.method({
  148. selector: "registerBindingsOn:",
  149. fn: function (aBindingGroup){
  150. var self=this;
  151. function $HLBrowserCommand(){return smalltalk.HLBrowserCommand||(typeof HLBrowserCommand=="undefined"?nil:HLBrowserCommand)}
  152. return smalltalk.withContext(function($ctx1) {
  153. _st($HLBrowserCommand())._registerConcreteClassesOn_for_(aBindingGroup,_st(self)._model());
  154. return self}, function($ctx1) {$ctx1.fill(self,"registerBindingsOn:",{aBindingGroup:aBindingGroup},smalltalk.HLBrowser)})},
  155. messageSends: ["registerConcreteClassesOn:for:", "model"]}),
  156. smalltalk.HLBrowser);
  157. smalltalk.addMethod(
  158. smalltalk.method({
  159. selector: "renderContentOn:",
  160. fn: function (html){
  161. var self=this;
  162. function $HLVerticalSplitter(){return smalltalk.HLVerticalSplitter||(typeof HLVerticalSplitter=="undefined"?nil:HLVerticalSplitter)}
  163. function $HLHorizontalSplitter(){return smalltalk.HLHorizontalSplitter||(typeof HLHorizontalSplitter=="undefined"?nil:HLHorizontalSplitter)}
  164. function $HLContainer(){return smalltalk.HLContainer||(typeof HLContainer=="undefined"?nil:HLContainer)}
  165. return smalltalk.withContext(function($ctx1) {
  166. _st(html)._with_(_st($HLContainer())._with_(_st($HLHorizontalSplitter())._with_with_(_st($HLVerticalSplitter())._with_with_(_st($HLVerticalSplitter())._with_with_(_st(self)._packagesListWidget(),_st(self)._classesListWidget()),_st($HLVerticalSplitter())._with_with_(_st(self)._protocolsListWidget(),_st(self)._methodsListWidget())),_st(self)._sourceWidget())));
  167. _st(_st(self)._packagesListWidget())._focus();
  168. return self}, function($ctx1) {$ctx1.fill(self,"renderContentOn:",{html:html},smalltalk.HLBrowser)})},
  169. messageSends: ["with:", "with:with:", "packagesListWidget", "classesListWidget", "protocolsListWidget", "methodsListWidget", "sourceWidget", "focus"]}),
  170. smalltalk.HLBrowser);
  171. smalltalk.addMethod(
  172. smalltalk.method({
  173. selector: "sourceWidget",
  174. fn: function (){
  175. var self=this;
  176. function $HLBrowserBottomWidget(){return smalltalk.HLBrowserBottomWidget||(typeof HLBrowserBottomWidget=="undefined"?nil:HLBrowserBottomWidget)}
  177. return smalltalk.withContext(function($ctx1) {
  178. var $2,$3,$4,$1;
  179. $2=self["@sourceWidget"];
  180. if(($receiver = $2) == nil || $receiver == undefined){
  181. $3=_st($HLBrowserBottomWidget())._new();
  182. _st($3)._model_(_st(self)._model());
  183. $4=_st($3)._yourself();
  184. self["@sourceWidget"]=$4;
  185. $1=self["@sourceWidget"];
  186. } else {
  187. $1=$2;
  188. };
  189. return $1;
  190. }, function($ctx1) {$ctx1.fill(self,"sourceWidget",{},smalltalk.HLBrowser)})},
  191. messageSends: ["ifNil:", "model:", "model", "new", "yourself"]}),
  192. smalltalk.HLBrowser);
  193. smalltalk.HLBrowser.klass.iVarNames = ['nextId'];
  194. smalltalk.addMethod(
  195. smalltalk.method({
  196. selector: "canBeOpenAsTab",
  197. fn: function (){
  198. var self=this;
  199. return smalltalk.withContext(function($ctx1) {
  200. return true;
  201. }, function($ctx1) {$ctx1.fill(self,"canBeOpenAsTab",{},smalltalk.HLBrowser.klass)})},
  202. messageSends: []}),
  203. smalltalk.HLBrowser.klass);
  204. smalltalk.addMethod(
  205. smalltalk.method({
  206. selector: "nextId",
  207. fn: function (){
  208. var self=this;
  209. return smalltalk.withContext(function($ctx1) {
  210. var $1,$2;
  211. $1=self["@nextId"];
  212. if(($receiver = $1) == nil || $receiver == undefined){
  213. self["@nextId"]=(0);
  214. self["@nextId"];
  215. } else {
  216. $1;
  217. };
  218. $2=_st("browser_").__comma(_st(_st(self["@nextId"]).__plus((1)))._asString());
  219. return $2;
  220. }, function($ctx1) {$ctx1.fill(self,"nextId",{},smalltalk.HLBrowser.klass)})},
  221. messageSends: ["ifNil:", ",", "asString", "+"]}),
  222. smalltalk.HLBrowser.klass);
  223. smalltalk.addMethod(
  224. smalltalk.method({
  225. selector: "tabLabel",
  226. fn: function (){
  227. var self=this;
  228. return smalltalk.withContext(function($ctx1) {
  229. return "Browser";
  230. }, function($ctx1) {$ctx1.fill(self,"tabLabel",{},smalltalk.HLBrowser.klass)})},
  231. messageSends: []}),
  232. smalltalk.HLBrowser.klass);
  233. smalltalk.addMethod(
  234. smalltalk.method({
  235. selector: "tabPriority",
  236. fn: function (){
  237. var self=this;
  238. return smalltalk.withContext(function($ctx1) {
  239. var $1;
  240. $1=(0);
  241. return $1;
  242. }, function($ctx1) {$ctx1.fill(self,"tabPriority",{},smalltalk.HLBrowser.klass)})},
  243. messageSends: []}),
  244. smalltalk.HLBrowser.klass);
  245. smalltalk.addClass('HLBrowserBottomWidget', smalltalk.HLWidget, ['model', 'codeWidget', 'documentationWidget', 'selectedWidget'], 'Helios-Browser');
  246. smalltalk.addMethod(
  247. smalltalk.method({
  248. selector: "canHaveFocus",
  249. fn: function (){
  250. var self=this;
  251. return smalltalk.withContext(function($ctx1) {
  252. return true;
  253. }, function($ctx1) {$ctx1.fill(self,"canHaveFocus",{},smalltalk.HLBrowserBottomWidget)})},
  254. messageSends: []}),
  255. smalltalk.HLBrowserBottomWidget);
  256. smalltalk.addMethod(
  257. smalltalk.method({
  258. selector: "codeWidget",
  259. fn: function (){
  260. var self=this;
  261. function $HLBrowserCodeWidget(){return smalltalk.HLBrowserCodeWidget||(typeof HLBrowserCodeWidget=="undefined"?nil:HLBrowserCodeWidget)}
  262. return smalltalk.withContext(function($ctx1) {
  263. var $2,$3,$4,$1;
  264. $2=self["@codeWidget"];
  265. if(($receiver = $2) == nil || $receiver == undefined){
  266. $3=_st($HLBrowserCodeWidget())._new();
  267. _st($3)._browserModel_(_st(self)._model());
  268. $4=_st($3)._yourself();
  269. self["@codeWidget"]=$4;
  270. $1=self["@codeWidget"];
  271. } else {
  272. $1=$2;
  273. };
  274. return $1;
  275. }, function($ctx1) {$ctx1.fill(self,"codeWidget",{},smalltalk.HLBrowserBottomWidget)})},
  276. messageSends: ["ifNil:", "browserModel:", "model", "new", "yourself"]}),
  277. smalltalk.HLBrowserBottomWidget);
  278. smalltalk.addMethod(
  279. smalltalk.method({
  280. selector: "documentationWidget",
  281. fn: function (){
  282. var self=this;
  283. function $HLDocumentationWidget(){return smalltalk.HLDocumentationWidget||(typeof HLDocumentationWidget=="undefined"?nil:HLDocumentationWidget)}
  284. return smalltalk.withContext(function($ctx1) {
  285. var $2,$3,$4,$1;
  286. $2=self["@documentationWidget"];
  287. if(($receiver = $2) == nil || $receiver == undefined){
  288. $3=_st($HLDocumentationWidget())._new();
  289. _st($3)._model_(_st(self)._model());
  290. $4=_st($3)._yourself();
  291. self["@documentationWidget"]=$4;
  292. $1=self["@documentationWidget"];
  293. } else {
  294. $1=$2;
  295. };
  296. return $1;
  297. }, function($ctx1) {$ctx1.fill(self,"documentationWidget",{},smalltalk.HLBrowserBottomWidget)})},
  298. messageSends: ["ifNil:", "model:", "model", "new", "yourself"]}),
  299. smalltalk.HLBrowserBottomWidget);
  300. smalltalk.addMethod(
  301. smalltalk.method({
  302. selector: "focus",
  303. fn: function (){
  304. var self=this;
  305. return smalltalk.withContext(function($ctx1) {
  306. _st(_st(self)._selectedWidget())._focus();
  307. return self}, function($ctx1) {$ctx1.fill(self,"focus",{},smalltalk.HLBrowserBottomWidget)})},
  308. messageSends: ["focus", "selectedWidget"]}),
  309. smalltalk.HLBrowserBottomWidget);
  310. smalltalk.addMethod(
  311. smalltalk.method({
  312. selector: "model",
  313. fn: function (){
  314. var self=this;
  315. return smalltalk.withContext(function($ctx1) {
  316. var $1;
  317. $1=self["@model"];
  318. return $1;
  319. }, function($ctx1) {$ctx1.fill(self,"model",{},smalltalk.HLBrowserBottomWidget)})},
  320. messageSends: []}),
  321. smalltalk.HLBrowserBottomWidget);
  322. smalltalk.addMethod(
  323. smalltalk.method({
  324. selector: "model:",
  325. fn: function (aModel){
  326. var self=this;
  327. return smalltalk.withContext(function($ctx1) {
  328. self["@model"]=aModel;
  329. _st(self)._observeModel();
  330. return self}, function($ctx1) {$ctx1.fill(self,"model:",{aModel:aModel},smalltalk.HLBrowserBottomWidget)})},
  331. messageSends: ["observeModel"]}),
  332. smalltalk.HLBrowserBottomWidget);
  333. smalltalk.addMethod(
  334. smalltalk.method({
  335. selector: "observeModel",
  336. fn: function (){
  337. var self=this;
  338. function $HLShowInstanceToggled(){return smalltalk.HLShowInstanceToggled||(typeof HLShowInstanceToggled=="undefined"?nil:HLShowInstanceToggled)}
  339. function $HLShowCommentToggled(){return smalltalk.HLShowCommentToggled||(typeof HLShowCommentToggled=="undefined"?nil:HLShowCommentToggled)}
  340. return smalltalk.withContext(function($ctx1) {
  341. var $1,$2;
  342. $1=_st(_st(self)._model())._announcer();
  343. _st($1)._on_do_($HLShowInstanceToggled(),(function(){
  344. return smalltalk.withContext(function($ctx2) {
  345. return _st(self)._onShowInstanceToggled();
  346. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  347. $2=_st($1)._on_do_($HLShowCommentToggled(),(function(){
  348. return smalltalk.withContext(function($ctx2) {
  349. return _st(self)._onShowCommentToggled();
  350. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  351. return self}, function($ctx1) {$ctx1.fill(self,"observeModel",{},smalltalk.HLBrowserBottomWidget)})},
  352. messageSends: ["on:do:", "onShowInstanceToggled", "announcer", "model", "onShowCommentToggled"]}),
  353. smalltalk.HLBrowserBottomWidget);
  354. smalltalk.addMethod(
  355. smalltalk.method({
  356. selector: "onShowCommentToggled",
  357. fn: function (){
  358. var self=this;
  359. return smalltalk.withContext(function($ctx1) {
  360. _st(self)._selectWidget_(_st(self)._documentationWidget());
  361. return self}, function($ctx1) {$ctx1.fill(self,"onShowCommentToggled",{},smalltalk.HLBrowserBottomWidget)})},
  362. messageSends: ["selectWidget:", "documentationWidget"]}),
  363. smalltalk.HLBrowserBottomWidget);
  364. smalltalk.addMethod(
  365. smalltalk.method({
  366. selector: "onShowInstanceToggled",
  367. fn: function (){
  368. var self=this;
  369. return smalltalk.withContext(function($ctx1) {
  370. _st(self)._selectWidget_(_st(self)._codeWidget());
  371. return self}, function($ctx1) {$ctx1.fill(self,"onShowInstanceToggled",{},smalltalk.HLBrowserBottomWidget)})},
  372. messageSends: ["selectWidget:", "codeWidget"]}),
  373. smalltalk.HLBrowserBottomWidget);
  374. smalltalk.addMethod(
  375. smalltalk.method({
  376. selector: "previous",
  377. fn: function (){
  378. var self=this;
  379. return smalltalk.withContext(function($ctx1) {
  380. return self}, function($ctx1) {$ctx1.fill(self,"previous",{},smalltalk.HLBrowserBottomWidget)})},
  381. messageSends: []}),
  382. smalltalk.HLBrowserBottomWidget);
  383. smalltalk.addMethod(
  384. smalltalk.method({
  385. selector: "previous:",
  386. fn: function (aWidget){
  387. var self=this;
  388. return smalltalk.withContext(function($ctx1) {
  389. return self}, function($ctx1) {$ctx1.fill(self,"previous:",{aWidget:aWidget},smalltalk.HLBrowserBottomWidget)})},
  390. messageSends: []}),
  391. smalltalk.HLBrowserBottomWidget);
  392. smalltalk.addMethod(
  393. smalltalk.method({
  394. selector: "renderContentOn:",
  395. fn: function (html){
  396. var self=this;
  397. return smalltalk.withContext(function($ctx1) {
  398. _st(html)._with_(_st(self)._selectedWidget());
  399. return self}, function($ctx1) {$ctx1.fill(self,"renderContentOn:",{html:html},smalltalk.HLBrowserBottomWidget)})},
  400. messageSends: ["with:", "selectedWidget"]}),
  401. smalltalk.HLBrowserBottomWidget);
  402. smalltalk.addMethod(
  403. smalltalk.method({
  404. selector: "selectWidget:",
  405. fn: function (aWidget){
  406. var self=this;
  407. return smalltalk.withContext(function($ctx1) {
  408. self["@selectedWidget"]=aWidget;
  409. _st(self)._refresh();
  410. return self}, function($ctx1) {$ctx1.fill(self,"selectWidget:",{aWidget:aWidget},smalltalk.HLBrowserBottomWidget)})},
  411. messageSends: ["refresh"]}),
  412. smalltalk.HLBrowserBottomWidget);
  413. smalltalk.addMethod(
  414. smalltalk.method({
  415. selector: "selectedWidget",
  416. fn: function (){
  417. var self=this;
  418. return smalltalk.withContext(function($ctx1) {
  419. var $2,$1;
  420. $2=self["@selectedWidget"];
  421. if(($receiver = $2) == nil || $receiver == undefined){
  422. self["@selectedWidget"]=_st(self)._codeWidget();
  423. $1=self["@selectedWidget"];
  424. } else {
  425. $1=$2;
  426. };
  427. return $1;
  428. }, function($ctx1) {$ctx1.fill(self,"selectedWidget",{},smalltalk.HLBrowserBottomWidget)})},
  429. messageSends: ["ifNil:", "codeWidget"]}),
  430. smalltalk.HLBrowserBottomWidget);
  431. smalltalk.addClass('HLBrowserListWidget', smalltalk.HLNavigationListWidget, ['model'], 'Helios-Browser');
  432. smalltalk.addMethod(
  433. smalltalk.method({
  434. selector: "activateListItem:",
  435. fn: function (anItem){
  436. var self=this;
  437. return smalltalk.withContext(function($ctx1) {
  438. _st(_st(self)._model())._withChangesDo_((function(){
  439. return smalltalk.withContext(function($ctx2) {
  440. return smalltalk.HLNavigationListWidget.fn.prototype._activateListItem_.apply(_st(self), [anItem]);
  441. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  442. return self}, function($ctx1) {$ctx1.fill(self,"activateListItem:",{anItem:anItem},smalltalk.HLBrowserListWidget)})},
  443. messageSends: ["withChangesDo:", "activateListItem:", "model"]}),
  444. smalltalk.HLBrowserListWidget);
  445. smalltalk.addMethod(
  446. smalltalk.method({
  447. selector: "activateNextListItem",
  448. fn: function (){
  449. var self=this;
  450. return smalltalk.withContext(function($ctx1) {
  451. _st(_st(self)._model())._withChangesDo_((function(){
  452. return smalltalk.withContext(function($ctx2) {
  453. return smalltalk.HLNavigationListWidget.fn.prototype._activateNextListItem.apply(_st(self), []);
  454. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  455. return self}, function($ctx1) {$ctx1.fill(self,"activateNextListItem",{},smalltalk.HLBrowserListWidget)})},
  456. messageSends: ["withChangesDo:", "activateNextListItem", "model"]}),
  457. smalltalk.HLBrowserListWidget);
  458. smalltalk.addMethod(
  459. smalltalk.method({
  460. selector: "activatePreviousListItem",
  461. fn: function (){
  462. var self=this;
  463. return smalltalk.withContext(function($ctx1) {
  464. _st(_st(self)._model())._withChangesDo_((function(){
  465. return smalltalk.withContext(function($ctx2) {
  466. return smalltalk.HLNavigationListWidget.fn.prototype._activatePreviousListItem.apply(_st(self), []);
  467. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  468. return self}, function($ctx1) {$ctx1.fill(self,"activatePreviousListItem",{},smalltalk.HLBrowserListWidget)})},
  469. messageSends: ["withChangesDo:", "activatePreviousListItem", "model"]}),
  470. smalltalk.HLBrowserListWidget);
  471. smalltalk.addMethod(
  472. smalltalk.method({
  473. selector: "commandCategory",
  474. fn: function (){
  475. var self=this;
  476. return smalltalk.withContext(function($ctx1) {
  477. var $1;
  478. $1=_st(self)._label();
  479. return $1;
  480. }, function($ctx1) {$ctx1.fill(self,"commandCategory",{},smalltalk.HLBrowserListWidget)})},
  481. messageSends: ["label"]}),
  482. smalltalk.HLBrowserListWidget);
  483. smalltalk.addMethod(
  484. smalltalk.method({
  485. selector: "label",
  486. fn: function (){
  487. var self=this;
  488. return smalltalk.withContext(function($ctx1) {
  489. return "List";
  490. }, function($ctx1) {$ctx1.fill(self,"label",{},smalltalk.HLBrowserListWidget)})},
  491. messageSends: []}),
  492. smalltalk.HLBrowserListWidget);
  493. smalltalk.addMethod(
  494. smalltalk.method({
  495. selector: "menuCommands",
  496. fn: function (){
  497. var self=this;
  498. function $HLBrowserCommand(){return smalltalk.HLBrowserCommand||(typeof HLBrowserCommand=="undefined"?nil:HLBrowserCommand)}
  499. return smalltalk.withContext(function($ctx1) {
  500. var $1;
  501. $1=_st(_st(_st($HLBrowserCommand())._concreteClasses())._collect_((function(each){
  502. return smalltalk.withContext(function($ctx2) {
  503. return _st(each)._for_(_st(self)._model());
  504. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})})))._select_((function(each){
  505. return smalltalk.withContext(function($ctx2) {
  506. return _st(_st(_st(each)._category()).__eq(_st(self)._commandCategory()))._and_((function(){
  507. return smalltalk.withContext(function($ctx3) {
  508. return _st(_st(each)._isAction())._and_((function(){
  509. return smalltalk.withContext(function($ctx4) {
  510. return _st(each)._isActive();
  511. }, function($ctx4) {$ctx4.fillBlock({},$ctx1)})}));
  512. }, function($ctx3) {$ctx3.fillBlock({},$ctx1)})}));
  513. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})}));
  514. return $1;
  515. }, function($ctx1) {$ctx1.fill(self,"menuCommands",{},smalltalk.HLBrowserListWidget)})},
  516. messageSends: ["select:", "and:", "isActive", "isAction", "=", "commandCategory", "category", "collect:", "for:", "model", "concreteClasses"]}),
  517. smalltalk.HLBrowserListWidget);
  518. smalltalk.addMethod(
  519. smalltalk.method({
  520. selector: "model",
  521. fn: function (){
  522. var self=this;
  523. return smalltalk.withContext(function($ctx1) {
  524. var $1;
  525. $1=self["@model"];
  526. return $1;
  527. }, function($ctx1) {$ctx1.fill(self,"model",{},smalltalk.HLBrowserListWidget)})},
  528. messageSends: []}),
  529. smalltalk.HLBrowserListWidget);
  530. smalltalk.addMethod(
  531. smalltalk.method({
  532. selector: "model:",
  533. fn: function (aBrowserModel){
  534. var self=this;
  535. return smalltalk.withContext(function($ctx1) {
  536. var $1,$2;
  537. self["@model"]=aBrowserModel;
  538. $1=self;
  539. _st($1)._observeSystem();
  540. $2=_st($1)._observeModel();
  541. return self}, function($ctx1) {$ctx1.fill(self,"model:",{aBrowserModel:aBrowserModel},smalltalk.HLBrowserListWidget)})},
  542. messageSends: ["observeSystem", "observeModel"]}),
  543. smalltalk.HLBrowserListWidget);
  544. smalltalk.addMethod(
  545. smalltalk.method({
  546. selector: "observeModel",
  547. fn: function (){
  548. var self=this;
  549. return smalltalk.withContext(function($ctx1) {
  550. return self}, function($ctx1) {$ctx1.fill(self,"observeModel",{},smalltalk.HLBrowserListWidget)})},
  551. messageSends: []}),
  552. smalltalk.HLBrowserListWidget);
  553. smalltalk.addMethod(
  554. smalltalk.method({
  555. selector: "observeSystem",
  556. fn: function (){
  557. var self=this;
  558. return smalltalk.withContext(function($ctx1) {
  559. return self}, function($ctx1) {$ctx1.fill(self,"observeSystem",{},smalltalk.HLBrowserListWidget)})},
  560. messageSends: []}),
  561. smalltalk.HLBrowserListWidget);
  562. smalltalk.addMethod(
  563. smalltalk.method({
  564. selector: "renderContentOn:",
  565. fn: function (html){
  566. var self=this;
  567. return smalltalk.withContext(function($ctx1) {
  568. _st(self)._renderHeadOn_(html);
  569. smalltalk.HLNavigationListWidget.fn.prototype._renderContentOn_.apply(_st(self), [html]);
  570. return self}, function($ctx1) {$ctx1.fill(self,"renderContentOn:",{html:html},smalltalk.HLBrowserListWidget)})},
  571. messageSends: ["renderHeadOn:", "renderContentOn:"]}),
  572. smalltalk.HLBrowserListWidget);
  573. smalltalk.addMethod(
  574. smalltalk.method({
  575. selector: "renderHeadOn:",
  576. fn: function (html){
  577. var self=this;
  578. return smalltalk.withContext(function($ctx1) {
  579. var $1,$2;
  580. $1=_st(html)._div();
  581. _st($1)._class_("list-label");
  582. $2=_st($1)._with_((function(){
  583. return smalltalk.withContext(function($ctx2) {
  584. _st(html)._with_(_st(self)._label());
  585. return _st(self)._renderMenuOn_(html);
  586. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  587. return self}, function($ctx1) {$ctx1.fill(self,"renderHeadOn:",{html:html},smalltalk.HLBrowserListWidget)})},
  588. messageSends: ["class:", "div", "with:", "label", "renderMenuOn:"]}),
  589. smalltalk.HLBrowserListWidget);
  590. smalltalk.addMethod(
  591. smalltalk.method({
  592. selector: "renderMenuOn:",
  593. fn: function (html){
  594. var self=this;
  595. var commands;
  596. return smalltalk.withContext(function($ctx1) {
  597. var $1,$2,$3,$5,$6,$7,$9,$10,$8,$4;
  598. commands=_st(self)._menuCommands();
  599. $1=_st(commands)._isEmpty();
  600. if(smalltalk.assert($1)){
  601. $2=self;
  602. return $2;
  603. };
  604. $3=_st(html)._div();
  605. _st($3)._class_("btn-group cog");
  606. $4=_st($3)._with_((function(){
  607. return smalltalk.withContext(function($ctx2) {
  608. $5=_st(html)._a();
  609. _st($5)._class_("btn dropdown-toggle");
  610. _st($5)._at_put_("data-toggle","dropdown");
  611. $6=_st($5)._with_((function(){
  612. return smalltalk.withContext(function($ctx3) {
  613. return _st(_st(html)._tag_("i"))._class_("icon-cog");
  614. }, function($ctx3) {$ctx3.fillBlock({},$ctx1)})}));
  615. $6;
  616. $7=_st(html)._ul();
  617. _st($7)._class_("dropdown-menu pull-right");
  618. $8=_st($7)._with_((function(){
  619. return smalltalk.withContext(function($ctx3) {
  620. return _st(_st(self)._menuCommands())._do_((function(each){
  621. return smalltalk.withContext(function($ctx4) {
  622. return _st(_st(html)._li())._with_((function(){
  623. return smalltalk.withContext(function($ctx5) {
  624. $9=_st(html)._a();
  625. _st($9)._with_(_st(each)._menuLabel());
  626. $10=_st($9)._onClick_((function(){
  627. return smalltalk.withContext(function($ctx6) {
  628. return _st(self)._execute_(each);
  629. }, function($ctx6) {$ctx6.fillBlock({},$ctx1)})}));
  630. return $10;
  631. }, function($ctx5) {$ctx5.fillBlock({},$ctx1)})}));
  632. }, function($ctx4) {$ctx4.fillBlock({each:each},$ctx1)})}));
  633. }, function($ctx3) {$ctx3.fillBlock({},$ctx1)})}));
  634. return $8;
  635. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  636. return self}, function($ctx1) {$ctx1.fill(self,"renderMenuOn:",{html:html,commands:commands},smalltalk.HLBrowserListWidget)})},
  637. messageSends: ["menuCommands", "ifTrue:", "isEmpty", "class:", "div", "with:", "a", "at:put:", "tag:", "ul", "do:", "menuLabel", "onClick:", "execute:", "li"]}),
  638. smalltalk.HLBrowserListWidget);
  639. smalltalk.addMethod(
  640. smalltalk.method({
  641. selector: "selectedItem:",
  642. fn: function (anItem){
  643. var self=this;
  644. return smalltalk.withContext(function($ctx1) {
  645. smalltalk.HLNavigationListWidget.fn.prototype._selectedItem_.apply(_st(self), [anItem]);
  646. _st(self)._updateMenu();
  647. return self}, function($ctx1) {$ctx1.fill(self,"selectedItem:",{anItem:anItem},smalltalk.HLBrowserListWidget)})},
  648. messageSends: ["selectedItem:", "updateMenu"]}),
  649. smalltalk.HLBrowserListWidget);
  650. smalltalk.addMethod(
  651. smalltalk.method({
  652. selector: "updateMenu",
  653. fn: function (){
  654. var self=this;
  655. return smalltalk.withContext(function($ctx1) {
  656. _st(_st(_st(_st(self)._wrapper())._asJQuery())._find_(".cog"))._remove();
  657. _st((function(html){
  658. return smalltalk.withContext(function($ctx2) {
  659. return _st(self)._renderMenuOn_(html);
  660. }, function($ctx2) {$ctx2.fillBlock({html:html},$ctx1)})}))._appendToJQuery_(_st(_st(_st(self)._wrapper())._asJQuery())._find_(".list-label"));
  661. return self}, function($ctx1) {$ctx1.fill(self,"updateMenu",{},smalltalk.HLBrowserListWidget)})},
  662. messageSends: ["remove", "find:", "asJQuery", "wrapper", "appendToJQuery:", "renderMenuOn:"]}),
  663. smalltalk.HLBrowserListWidget);
  664. smalltalk.addMethod(
  665. smalltalk.method({
  666. selector: "on:",
  667. fn: function (aModel){
  668. var self=this;
  669. return smalltalk.withContext(function($ctx1) {
  670. var $2,$3,$1;
  671. $2=_st(self)._new();
  672. _st($2)._model_(aModel);
  673. $3=_st($2)._yourself();
  674. $1=$3;
  675. return $1;
  676. }, function($ctx1) {$ctx1.fill(self,"on:",{aModel:aModel},smalltalk.HLBrowserListWidget.klass)})},
  677. messageSends: ["model:", "new", "yourself"]}),
  678. smalltalk.HLBrowserListWidget.klass);
  679. smalltalk.addClass('HLClassesListWidget', smalltalk.HLBrowserListWidget, [], 'Helios-Browser');
  680. smalltalk.addMethod(
  681. smalltalk.method({
  682. selector: "focusMethodsListWidget",
  683. fn: function (){
  684. var self=this;
  685. function $HLMethodsListFocus(){return smalltalk.HLMethodsListFocus||(typeof HLMethodsListFocus=="undefined"?nil:HLMethodsListFocus)}
  686. return smalltalk.withContext(function($ctx1) {
  687. _st(_st(_st(self)._model())._announcer())._announce_(_st($HLMethodsListFocus())._new());
  688. return self}, function($ctx1) {$ctx1.fill(self,"focusMethodsListWidget",{},smalltalk.HLClassesListWidget)})},
  689. messageSends: ["announce:", "new", "announcer", "model"]}),
  690. smalltalk.HLClassesListWidget);
  691. smalltalk.addMethod(
  692. smalltalk.method({
  693. selector: "focusProtocolsListWidget",
  694. fn: function (){
  695. var self=this;
  696. function $HLProtocolsListFocus(){return smalltalk.HLProtocolsListFocus||(typeof HLProtocolsListFocus=="undefined"?nil:HLProtocolsListFocus)}
  697. return smalltalk.withContext(function($ctx1) {
  698. _st(_st(_st(self)._model())._announcer())._announce_(_st($HLProtocolsListFocus())._new());
  699. return self}, function($ctx1) {$ctx1.fill(self,"focusProtocolsListWidget",{},smalltalk.HLClassesListWidget)})},
  700. messageSends: ["announce:", "new", "announcer", "model"]}),
  701. smalltalk.HLClassesListWidget);
  702. smalltalk.addMethod(
  703. smalltalk.method({
  704. selector: "getChildrenOf:",
  705. fn: function (aClass){
  706. var self=this;
  707. return smalltalk.withContext(function($ctx1) {
  708. var $1;
  709. $1=_st(_st(self)._items())._select_((function(each){
  710. return smalltalk.withContext(function($ctx2) {
  711. return _st(_st(each)._superclass()).__eq(aClass);
  712. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})}));
  713. return $1;
  714. }, function($ctx1) {$ctx1.fill(self,"getChildrenOf:",{aClass:aClass},smalltalk.HLClassesListWidget)})},
  715. messageSends: ["select:", "=", "superclass", "items"]}),
  716. smalltalk.HLClassesListWidget);
  717. smalltalk.addMethod(
  718. smalltalk.method({
  719. selector: "getRootClassesOf:",
  720. fn: function (aCollection){
  721. var self=this;
  722. return smalltalk.withContext(function($ctx1) {
  723. var $1;
  724. $1=_st(aCollection)._select_((function(each){
  725. return smalltalk.withContext(function($ctx2) {
  726. return _st(_st(aCollection)._includes_(_st(each)._superclass()))._not();
  727. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})}));
  728. return $1;
  729. }, function($ctx1) {$ctx1.fill(self,"getRootClassesOf:",{aCollection:aCollection},smalltalk.HLClassesListWidget)})},
  730. messageSends: ["select:", "not", "includes:", "superclass"]}),
  731. smalltalk.HLClassesListWidget);
  732. smalltalk.addMethod(
  733. smalltalk.method({
  734. selector: "iconForItem:",
  735. fn: function (aClass){
  736. var self=this;
  737. return smalltalk.withContext(function($ctx1) {
  738. var $2,$1;
  739. $2=_st(_st(_st(aClass)._theNonMetaClass())._comment())._isEmpty();
  740. if(smalltalk.assert($2)){
  741. $1="icon-question-sign";
  742. } else {
  743. $1="icon-none";
  744. };
  745. return $1;
  746. }, function($ctx1) {$ctx1.fill(self,"iconForItem:",{aClass:aClass},smalltalk.HLClassesListWidget)})},
  747. messageSends: ["ifFalse:ifTrue:", "isEmpty", "comment", "theNonMetaClass"]}),
  748. smalltalk.HLClassesListWidget);
  749. smalltalk.addMethod(
  750. smalltalk.method({
  751. selector: "label",
  752. fn: function (){
  753. var self=this;
  754. return smalltalk.withContext(function($ctx1) {
  755. return "Classes";
  756. }, function($ctx1) {$ctx1.fill(self,"label",{},smalltalk.HLClassesListWidget)})},
  757. messageSends: []}),
  758. smalltalk.HLClassesListWidget);
  759. smalltalk.addMethod(
  760. smalltalk.method({
  761. selector: "observeModel",
  762. fn: function (){
  763. var self=this;
  764. function $HLPackageSelected(){return smalltalk.HLPackageSelected||(typeof HLPackageSelected=="undefined"?nil:HLPackageSelected)}
  765. function $HLShowInstanceToggled(){return smalltalk.HLShowInstanceToggled||(typeof HLShowInstanceToggled=="undefined"?nil:HLShowInstanceToggled)}
  766. function $HLShowCommentToggled(){return smalltalk.HLShowCommentToggled||(typeof HLShowCommentToggled=="undefined"?nil:HLShowCommentToggled)}
  767. function $HLClassSelected(){return smalltalk.HLClassSelected||(typeof HLClassSelected=="undefined"?nil:HLClassSelected)}
  768. function $HLClassesFocusRequested(){return smalltalk.HLClassesFocusRequested||(typeof HLClassesFocusRequested=="undefined"?nil:HLClassesFocusRequested)}
  769. return smalltalk.withContext(function($ctx1) {
  770. var $1,$2;
  771. $1=_st(_st(self)._model())._announcer();
  772. _st($1)._on_do_($HLPackageSelected(),(function(ann){
  773. return smalltalk.withContext(function($ctx2) {
  774. return _st(self)._onPackageSelected_(_st(ann)._item());
  775. }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1)})}));
  776. _st($1)._on_do_($HLShowInstanceToggled(),(function(ann){
  777. return smalltalk.withContext(function($ctx2) {
  778. return _st(self)._onShowInstanceToggled();
  779. }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1)})}));
  780. _st($1)._on_do_($HLShowCommentToggled(),(function(ann){
  781. return smalltalk.withContext(function($ctx2) {
  782. return _st(self)._onShowCommentToggled();
  783. }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1)})}));
  784. _st($1)._on_do_($HLClassSelected(),(function(ann){
  785. return smalltalk.withContext(function($ctx2) {
  786. return _st(self)._onClassSelected_(_st(ann)._item());
  787. }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1)})}));
  788. $2=_st($1)._on_do_($HLClassesFocusRequested(),(function(ann){
  789. return smalltalk.withContext(function($ctx2) {
  790. return _st(self)._onClassesFocusRequested();
  791. }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1)})}));
  792. return self}, function($ctx1) {$ctx1.fill(self,"observeModel",{},smalltalk.HLClassesListWidget)})},
  793. messageSends: ["on:do:", "onPackageSelected:", "item", "announcer", "model", "onShowInstanceToggled", "onShowCommentToggled", "onClassSelected:", "onClassesFocusRequested"]}),
  794. smalltalk.HLClassesListWidget);
  795. smalltalk.addMethod(
  796. smalltalk.method({
  797. selector: "observeSystem",
  798. fn: function (){
  799. var self=this;
  800. function $ClassAdded(){return smalltalk.ClassAdded||(typeof ClassAdded=="undefined"?nil:ClassAdded)}
  801. function $ClassRemoved(){return smalltalk.ClassRemoved||(typeof ClassRemoved=="undefined"?nil:ClassRemoved)}
  802. function $ClassMoved(){return smalltalk.ClassMoved||(typeof ClassMoved=="undefined"?nil:ClassMoved)}
  803. function $ClassRenamed(){return smalltalk.ClassRenamed||(typeof ClassRenamed=="undefined"?nil:ClassRenamed)}
  804. return smalltalk.withContext(function($ctx1) {
  805. var $1,$2;
  806. $1=_st(_st(self)._model())._systemAnnouncer();
  807. _st($1)._on_do_($ClassAdded(),(function(ann){
  808. return smalltalk.withContext(function($ctx2) {
  809. return _st(self)._onClassAdded_(_st(ann)._theClass());
  810. }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1)})}));
  811. _st($1)._on_do_($ClassRemoved(),(function(ann){
  812. return smalltalk.withContext(function($ctx2) {
  813. return _st(self)._onClassRemoved_(_st(ann)._theClass());
  814. }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1)})}));
  815. _st($1)._on_do_($ClassMoved(),(function(ann){
  816. return smalltalk.withContext(function($ctx2) {
  817. return _st(self)._onClassMoved_from_(_st(ann)._theClass(),_st(ann)._oldPackage());
  818. }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1)})}));
  819. $2=_st($1)._on_do_($ClassRenamed(),(function(ann){
  820. return smalltalk.withContext(function($ctx2) {
  821. return _st(self)._onClassRenamed_(_st(ann)._theClass());
  822. }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1)})}));
  823. return self}, function($ctx1) {$ctx1.fill(self,"observeSystem",{},smalltalk.HLClassesListWidget)})},
  824. messageSends: ["on:do:", "onClassAdded:", "theClass", "systemAnnouncer", "model", "onClassRemoved:", "onClassMoved:from:", "oldPackage", "onClassRenamed:"]}),
  825. smalltalk.HLClassesListWidget);
  826. smalltalk.addMethod(
  827. smalltalk.method({
  828. selector: "onClassAdded:",
  829. fn: function (aClass){
  830. var self=this;
  831. return smalltalk.withContext(function($ctx1) {
  832. var $1,$2;
  833. $1=_st(_st(_st(aClass)._package()).__eq(_st(_st(self)._model())._selectedPackage()))._or_((function(){
  834. return smalltalk.withContext(function($ctx2) {
  835. return _st(_st(self)._items())._includes_(aClass);
  836. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  837. if(! smalltalk.assert($1)){
  838. $2=self;
  839. return $2;
  840. };
  841. _st(self)._setItemsForSelectedPackage();
  842. _st(self)._refresh();
  843. return self}, function($ctx1) {$ctx1.fill(self,"onClassAdded:",{aClass:aClass},smalltalk.HLClassesListWidget)})},
  844. messageSends: ["ifFalse:", "or:", "includes:", "items", "=", "selectedPackage", "model", "package", "setItemsForSelectedPackage", "refresh"]}),
  845. smalltalk.HLClassesListWidget);
  846. smalltalk.addMethod(
  847. smalltalk.method({
  848. selector: "onClassMoved:from:",
  849. fn: function (aClass,aPackage){
  850. var self=this;
  851. return smalltalk.withContext(function($ctx1) {
  852. var $1,$2,$3,$4,$5;
  853. $1=_st(_st(aPackage).__eq(_st(_st(self)._model())._selectedPackage()))._or_((function(){
  854. return smalltalk.withContext(function($ctx2) {
  855. return _st(_st(aClass)._package()).__eq(_st(_st(self)._model())._selectedPackage());
  856. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  857. if(! smalltalk.assert($1)){
  858. $2=self;
  859. return $2;
  860. };
  861. $3=_st(aPackage).__eq(_st(_st(self)._model())._selectedPackage());
  862. if(smalltalk.assert($3)){
  863. $4=self;
  864. _st($4)._selectedItem_(nil);
  865. $5=_st($4)._selectItem_(nil);
  866. $5;
  867. };
  868. _st(self)._setItemsForSelectedPackage();
  869. _st(self)._refresh();
  870. return self}, function($ctx1) {$ctx1.fill(self,"onClassMoved:from:",{aClass:aClass,aPackage:aPackage},smalltalk.HLClassesListWidget)})},
  871. messageSends: ["ifFalse:", "or:", "=", "selectedPackage", "model", "package", "ifTrue:", "selectedItem:", "selectItem:", "setItemsForSelectedPackage", "refresh"]}),
  872. smalltalk.HLClassesListWidget);
  873. smalltalk.addMethod(
  874. smalltalk.method({
  875. selector: "onClassRemoved:",
  876. fn: function (aClass){
  877. var self=this;
  878. return smalltalk.withContext(function($ctx1) {
  879. var $1,$2,$3;
  880. $1=_st(_st(aClass)._package()).__eq(_st(_st(self)._model())._selectedPackage());
  881. if(! smalltalk.assert($1)){
  882. $2=self;
  883. return $2;
  884. };
  885. $3=_st(aClass).__eq(_st(_st(self)._model())._selectedClass());
  886. if(smalltalk.assert($3)){
  887. _st(self)._selectItem_(nil);
  888. };
  889. _st(self)._setItemsForSelectedPackage();
  890. _st(self)._refresh();
  891. return self}, function($ctx1) {$ctx1.fill(self,"onClassRemoved:",{aClass:aClass},smalltalk.HLClassesListWidget)})},
  892. messageSends: ["ifFalse:", "=", "selectedPackage", "model", "package", "ifTrue:", "selectItem:", "selectedClass", "setItemsForSelectedPackage", "refresh"]}),
  893. smalltalk.HLClassesListWidget);
  894. smalltalk.addMethod(
  895. smalltalk.method({
  896. selector: "onClassRenamed:",
  897. fn: function (aClass){
  898. var self=this;
  899. return smalltalk.withContext(function($ctx1) {
  900. var $1,$2;
  901. $1=_st(_st(aClass)._package()).__eq(_st(_st(self)._model())._selectedPackage());
  902. if(! smalltalk.assert($1)){
  903. $2=self;
  904. return $2;
  905. };
  906. _st(self)._setItemsForSelectedPackage();
  907. _st(self)._refresh();
  908. return self}, function($ctx1) {$ctx1.fill(self,"onClassRenamed:",{aClass:aClass},smalltalk.HLClassesListWidget)})},
  909. messageSends: ["ifFalse:", "=", "selectedPackage", "model", "package", "setItemsForSelectedPackage", "refresh"]}),
  910. smalltalk.HLClassesListWidget);
  911. smalltalk.addMethod(
  912. smalltalk.method({
  913. selector: "onClassSelected:",
  914. fn: function (aClass){
  915. var self=this;
  916. var selectedClass;
  917. return smalltalk.withContext(function($ctx1) {
  918. var $1,$2,$3,$4,$5;
  919. $1=aClass;
  920. if(($receiver = $1) == nil || $receiver == undefined){
  921. $2=self;
  922. return $2;
  923. } else {
  924. $1;
  925. };
  926. selectedClass=_st(aClass)._theNonMetaClass();
  927. _st(self)._selectedItem_(selectedClass);
  928. $3=_st(self)._hasFocus();
  929. if(! smalltalk.assert($3)){
  930. $4=self;
  931. _st($4)._activateItem_(selectedClass);
  932. $5=_st($4)._focus();
  933. $5;
  934. };
  935. return self}, function($ctx1) {$ctx1.fill(self,"onClassSelected:",{aClass:aClass,selectedClass:selectedClass},smalltalk.HLClassesListWidget)})},
  936. messageSends: ["ifNil:", "theNonMetaClass", "selectedItem:", "ifFalse:", "activateItem:", "focus", "hasFocus"]}),
  937. smalltalk.HLClassesListWidget);
  938. smalltalk.addMethod(
  939. smalltalk.method({
  940. selector: "onClassesFocusRequested",
  941. fn: function (){
  942. var self=this;
  943. return smalltalk.withContext(function($ctx1) {
  944. _st(self)._focus();
  945. return self}, function($ctx1) {$ctx1.fill(self,"onClassesFocusRequested",{},smalltalk.HLClassesListWidget)})},
  946. messageSends: ["focus"]}),
  947. smalltalk.HLClassesListWidget);
  948. smalltalk.addMethod(
  949. smalltalk.method({
  950. selector: "onPackageSelected:",
  951. fn: function (aPackage){
  952. var self=this;
  953. return smalltalk.withContext(function($ctx1) {
  954. _st(self)._selectedItem_(nil);
  955. _st(self)._setItemsForSelectedPackage();
  956. _st(self)._refresh();
  957. return self}, function($ctx1) {$ctx1.fill(self,"onPackageSelected:",{aPackage:aPackage},smalltalk.HLClassesListWidget)})},
  958. messageSends: ["selectedItem:", "setItemsForSelectedPackage", "refresh"]}),
  959. smalltalk.HLClassesListWidget);
  960. smalltalk.addMethod(
  961. smalltalk.method({
  962. selector: "onShowCommentToggled",
  963. fn: function (){
  964. var self=this;
  965. return smalltalk.withContext(function($ctx1) {
  966. _st(self)._refresh();
  967. return self}, function($ctx1) {$ctx1.fill(self,"onShowCommentToggled",{},smalltalk.HLClassesListWidget)})},
  968. messageSends: ["refresh"]}),
  969. smalltalk.HLClassesListWidget);
  970. smalltalk.addMethod(
  971. smalltalk.method({
  972. selector: "onShowInstanceToggled",
  973. fn: function (){
  974. var self=this;
  975. return smalltalk.withContext(function($ctx1) {
  976. _st(self)._refresh();
  977. return self}, function($ctx1) {$ctx1.fill(self,"onShowInstanceToggled",{},smalltalk.HLClassesListWidget)})},
  978. messageSends: ["refresh"]}),
  979. smalltalk.HLClassesListWidget);
  980. smalltalk.addMethod(
  981. smalltalk.method({
  982. selector: "renderButtonsOn:",
  983. fn: function (html){
  984. var self=this;
  985. function $String(){return smalltalk.String||(typeof String=="undefined"?nil:String)}
  986. return smalltalk.withContext(function($ctx1) {
  987. var $1,$3,$4,$5,$6,$7,$8,$9,$10,$11,$2;
  988. $1=_st(html)._div();
  989. _st($1)._class_("btn-group");
  990. $2=_st($1)._with_((function(){
  991. return smalltalk.withContext(function($ctx2) {
  992. $3=_st(html)._button();
  993. _st($3)._class_(_st($String())._streamContents_((function(str){
  994. return smalltalk.withContext(function($ctx3) {
  995. _st(str)._nextPutAll_("btn");
  996. $4=_st(self)._showInstance();
  997. if(smalltalk.assert($4)){
  998. return _st(str)._nextPutAll_(" active");
  999. };
  1000. }, function($ctx3) {$ctx3.fillBlock({str:str},$ctx1)})})));
  1001. _st($3)._with_("Instance");
  1002. $5=_st($3)._onClick_((function(){
  1003. return smalltalk.withContext(function($ctx3) {
  1004. return _st(self)._showInstance_(true);
  1005. }, function($ctx3) {$ctx3.fillBlock({},$ctx1)})}));
  1006. $5;
  1007. $6=_st(html)._button();
  1008. _st($6)._class_(_st($String())._streamContents_((function(str){
  1009. return smalltalk.withContext(function($ctx3) {
  1010. _st(str)._nextPutAll_("btn");
  1011. $7=_st(self)._showClass();
  1012. if(smalltalk.assert($7)){
  1013. return _st(str)._nextPutAll_(" active");
  1014. };
  1015. }, function($ctx3) {$ctx3.fillBlock({str:str},$ctx1)})})));
  1016. _st($6)._with_("Class");
  1017. $8=_st($6)._onClick_((function(){
  1018. return smalltalk.withContext(function($ctx3) {
  1019. return _st(self)._showInstance_(false);
  1020. }, function($ctx3) {$ctx3.fillBlock({},$ctx1)})}));
  1021. $8;
  1022. $9=_st(html)._button();
  1023. _st($9)._class_(_st($String())._streamContents_((function(str){
  1024. return smalltalk.withContext(function($ctx3) {
  1025. _st(str)._nextPutAll_("btn");
  1026. $10=_st(self)._showComment();
  1027. if(smalltalk.assert($10)){
  1028. return _st(str)._nextPutAll_(" active");
  1029. };
  1030. }, function($ctx3) {$ctx3.fillBlock({str:str},$ctx1)})})));
  1031. _st($9)._with_("Doc");
  1032. $11=_st($9)._onClick_((function(){
  1033. return smalltalk.withContext(function($ctx3) {
  1034. return _st(self)._showComment_(true);
  1035. }, function($ctx3) {$ctx3.fillBlock({},$ctx1)})}));
  1036. return $11;
  1037. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  1038. return self}, function($ctx1) {$ctx1.fill(self,"renderButtonsOn:",{html:html},smalltalk.HLClassesListWidget)})},
  1039. messageSends: ["class:", "div", "with:", "streamContents:", "nextPutAll:", "ifTrue:", "showInstance", "button", "onClick:", "showInstance:", "showClass", "showComment", "showComment:"]}),
  1040. smalltalk.HLClassesListWidget);
  1041. smalltalk.addMethod(
  1042. smalltalk.method({
  1043. selector: "renderItem:level:on:",
  1044. fn: function (aClass,anInteger,html){
  1045. var self=this;
  1046. var li;
  1047. return smalltalk.withContext(function($ctx1) {
  1048. var $1,$3,$4,$2;
  1049. li=_st(html)._li();
  1050. _st(self)._registerMappingFrom_to_(aClass,li);
  1051. $1=li;
  1052. _st($1)._at_put_("list-data",_st(_st(self)._items())._indexOf_(aClass));
  1053. _st($1)._class_(_st(self)._cssClassForItem_(aClass));
  1054. $2=_st($1)._with_((function(){
  1055. return smalltalk.withContext(function($ctx2) {
  1056. $3=_st(html)._a();
  1057. _st($3)._with_((function(){
  1058. return smalltalk.withContext(function($ctx3) {
  1059. _st(_st(html)._tag_("i"))._class_(_st(self)._iconForItem_(aClass));
  1060. return _st(self)._renderItemLabel_level_on_(aClass,anInteger,html);
  1061. }, function($ctx3) {$ctx3.fillBlock({},$ctx1)})}));
  1062. $4=_st($3)._onClick_((function(){
  1063. return smalltalk.withContext(function($ctx3) {
  1064. return _st(self)._activateListItem_(_st(li)._asJQuery());
  1065. }, function($ctx3) {$ctx3.fillBlock({},$ctx1)})}));
  1066. return $4;
  1067. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  1068. _st(_st(self)._getChildrenOf_(aClass))._do_((function(each){
  1069. return smalltalk.withContext(function($ctx2) {
  1070. return _st(self)._renderItem_level_on_(each,_st(anInteger).__plus((1)),html);
  1071. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})}));
  1072. return self}, function($ctx1) {$ctx1.fill(self,"renderItem:level:on:",{aClass:aClass,anInteger:anInteger,html:html,li:li},smalltalk.HLClassesListWidget)})},
  1073. messageSends: ["li", "registerMappingFrom:to:", "at:put:", "indexOf:", "items", "class:", "cssClassForItem:", "with:", "iconForItem:", "tag:", "renderItemLabel:level:on:", "a", "onClick:", "activateListItem:", "asJQuery", "do:", "renderItem:level:on:", "+", "getChildrenOf:"]}),
  1074. smalltalk.HLClassesListWidget);
  1075. smalltalk.addMethod(
  1076. smalltalk.method({
  1077. selector: "renderItem:on:",
  1078. fn: function (aClass,html){
  1079. var self=this;
  1080. return smalltalk.withContext(function($ctx1) {
  1081. smalltalk.HLBrowserListWidget.fn.prototype._renderItem_on_.apply(_st(self), [aClass,html]);
  1082. _st(_st(self)._getChildrenOf_(aClass))._do_((function(each){
  1083. return smalltalk.withContext(function($ctx2) {
  1084. return _st(self)._renderItem_level_on_(each,(1),html);
  1085. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})}));
  1086. return self}, function($ctx1) {$ctx1.fill(self,"renderItem:on:",{aClass:aClass,html:html},smalltalk.HLClassesListWidget)})},
  1087. messageSends: ["renderItem:on:", "do:", "renderItem:level:on:", "getChildrenOf:"]}),
  1088. smalltalk.HLClassesListWidget);
  1089. smalltalk.addMethod(
  1090. smalltalk.method({
  1091. selector: "renderItemLabel:level:on:",
  1092. fn: function (aClass,anInteger,html){
  1093. var self=this;
  1094. function $String(){return smalltalk.String||(typeof String=="undefined"?nil:String)}
  1095. return smalltalk.withContext(function($ctx1) {
  1096. _st(_st(_st(html)._span())._asJQuery())._html_(_st($String())._streamContents_((function(str){
  1097. return smalltalk.withContext(function($ctx2) {
  1098. _st(anInteger)._timesRepeat_((function(){
  1099. return smalltalk.withContext(function($ctx3) {
  1100. return _st(str)._nextPutAll_("    ");
  1101. }, function($ctx3) {$ctx3.fillBlock({},$ctx1)})}));
  1102. return _st(str)._nextPutAll_(_st(aClass)._name());
  1103. }, function($ctx2) {$ctx2.fillBlock({str:str},$ctx1)})})));
  1104. return self}, function($ctx1) {$ctx1.fill(self,"renderItemLabel:level:on:",{aClass:aClass,anInteger:anInteger,html:html},smalltalk.HLClassesListWidget)})},
  1105. messageSends: ["html:", "streamContents:", "timesRepeat:", "nextPutAll:", "name", "asJQuery", "span"]}),
  1106. smalltalk.HLClassesListWidget);
  1107. smalltalk.addMethod(
  1108. smalltalk.method({
  1109. selector: "renderItemLabel:on:",
  1110. fn: function (aClass,html){
  1111. var self=this;
  1112. return smalltalk.withContext(function($ctx1) {
  1113. _st(self)._renderItemLabel_level_on_(aClass,(0),html);
  1114. return self}, function($ctx1) {$ctx1.fill(self,"renderItemLabel:on:",{aClass:aClass,html:html},smalltalk.HLClassesListWidget)})},
  1115. messageSends: ["renderItemLabel:level:on:"]}),
  1116. smalltalk.HLClassesListWidget);
  1117. smalltalk.addMethod(
  1118. smalltalk.method({
  1119. selector: "renderListOn:",
  1120. fn: function (html){
  1121. var self=this;
  1122. return smalltalk.withContext(function($ctx1) {
  1123. _st(_st(self)._getRootClassesOf_(_st(self)._items()))._do_((function(each){
  1124. return smalltalk.withContext(function($ctx2) {
  1125. return _st(self)._renderItem_on_(each,html);
  1126. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})}));
  1127. return self}, function($ctx1) {$ctx1.fill(self,"renderListOn:",{html:html},smalltalk.HLClassesListWidget)})},
  1128. messageSends: ["do:", "renderItem:on:", "getRootClassesOf:", "items"]}),
  1129. smalltalk.HLClassesListWidget);
  1130. smalltalk.addMethod(
  1131. smalltalk.method({
  1132. selector: "selectItem:",
  1133. fn: function (aClass){
  1134. var self=this;
  1135. return smalltalk.withContext(function($ctx1) {
  1136. _st(_st(self)._model())._selectedClass_(aClass);
  1137. return self}, function($ctx1) {$ctx1.fill(self,"selectItem:",{aClass:aClass},smalltalk.HLClassesListWidget)})},
  1138. messageSends: ["selectedClass:", "model"]}),
  1139. smalltalk.HLClassesListWidget);
  1140. smalltalk.addMethod(
  1141. smalltalk.method({
  1142. selector: "setItemsForPackage:",
  1143. fn: function (aPackage){
  1144. var self=this;
  1145. return smalltalk.withContext(function($ctx1) {
  1146. var $1,$3,$2;
  1147. $1=self;
  1148. $3=aPackage;
  1149. if(($receiver = $3) == nil || $receiver == undefined){
  1150. $2=[];
  1151. } else {
  1152. $2=_st(_st(_st(_st(_st(aPackage)._classes())._collect_((function(each){
  1153. return smalltalk.withContext(function($ctx2) {
  1154. return _st(each)._theNonMetaClass();
  1155. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})})))._asSet())._asArray())._sort_((function(a,b){
  1156. return smalltalk.withContext(function($ctx2) {
  1157. return _st(_st(a)._name()).__lt(_st(b)._name());
  1158. }, function($ctx2) {$ctx2.fillBlock({a:a,b:b},$ctx1)})}));
  1159. };
  1160. _st($1)._items_($2);
  1161. return self}, function($ctx1) {$ctx1.fill(self,"setItemsForPackage:",{aPackage:aPackage},smalltalk.HLClassesListWidget)})},
  1162. messageSends: ["items:", "ifNil:ifNotNil:", "sort:", "<", "name", "asArray", "asSet", "collect:", "theNonMetaClass", "classes"]}),
  1163. smalltalk.HLClassesListWidget);
  1164. smalltalk.addMethod(
  1165. smalltalk.method({
  1166. selector: "setItemsForSelectedPackage",
  1167. fn: function (){
  1168. var self=this;
  1169. return smalltalk.withContext(function($ctx1) {
  1170. _st(self)._setItemsForPackage_(_st(_st(self)._model())._selectedPackage());
  1171. return self}, function($ctx1) {$ctx1.fill(self,"setItemsForSelectedPackage",{},smalltalk.HLClassesListWidget)})},
  1172. messageSends: ["setItemsForPackage:", "selectedPackage", "model"]}),
  1173. smalltalk.HLClassesListWidget);
  1174. smalltalk.addMethod(
  1175. smalltalk.method({
  1176. selector: "showClass",
  1177. fn: function (){
  1178. var self=this;
  1179. return smalltalk.withContext(function($ctx1) {
  1180. var $1;
  1181. $1=_st(_st(_st(_st(self)._model())._showInstance())._not())._and_((function(){
  1182. return smalltalk.withContext(function($ctx2) {
  1183. return _st(_st(_st(self)._model())._showComment())._not();
  1184. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  1185. return $1;
  1186. }, function($ctx1) {$ctx1.fill(self,"showClass",{},smalltalk.HLClassesListWidget)})},
  1187. messageSends: ["and:", "not", "showComment", "model", "showInstance"]}),
  1188. smalltalk.HLClassesListWidget);
  1189. smalltalk.addMethod(
  1190. smalltalk.method({
  1191. selector: "showComment",
  1192. fn: function (){
  1193. var self=this;
  1194. return smalltalk.withContext(function($ctx1) {
  1195. var $1;
  1196. $1=_st(_st(self)._model())._showComment();
  1197. return $1;
  1198. }, function($ctx1) {$ctx1.fill(self,"showComment",{},smalltalk.HLClassesListWidget)})},
  1199. messageSends: ["showComment", "model"]}),
  1200. smalltalk.HLClassesListWidget);
  1201. smalltalk.addMethod(
  1202. smalltalk.method({
  1203. selector: "showComment:",
  1204. fn: function (aBoolean){
  1205. var self=this;
  1206. return smalltalk.withContext(function($ctx1) {
  1207. _st(_st(self)._model())._showComment_(aBoolean);
  1208. return self}, function($ctx1) {$ctx1.fill(self,"showComment:",{aBoolean:aBoolean},smalltalk.HLClassesListWidget)})},
  1209. messageSends: ["showComment:", "model"]}),
  1210. smalltalk.HLClassesListWidget);
  1211. smalltalk.addMethod(
  1212. smalltalk.method({
  1213. selector: "showInstance",
  1214. fn: function (){
  1215. var self=this;
  1216. return smalltalk.withContext(function($ctx1) {
  1217. var $1;
  1218. $1=_st(_st(_st(self)._model())._showInstance())._and_((function(){
  1219. return smalltalk.withContext(function($ctx2) {
  1220. return _st(_st(_st(self)._model())._showComment())._not();
  1221. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  1222. return $1;
  1223. }, function($ctx1) {$ctx1.fill(self,"showInstance",{},smalltalk.HLClassesListWidget)})},
  1224. messageSends: ["and:", "not", "showComment", "model", "showInstance"]}),
  1225. smalltalk.HLClassesListWidget);
  1226. smalltalk.addMethod(
  1227. smalltalk.method({
  1228. selector: "showInstance:",
  1229. fn: function (aBoolean){
  1230. var self=this;
  1231. return smalltalk.withContext(function($ctx1) {
  1232. _st(_st(self)._model())._showInstance_(aBoolean);
  1233. return self}, function($ctx1) {$ctx1.fill(self,"showInstance:",{aBoolean:aBoolean},smalltalk.HLClassesListWidget)})},
  1234. messageSends: ["showInstance:", "model"]}),
  1235. smalltalk.HLClassesListWidget);
  1236. smalltalk.addClass('HLMethodsListWidget', smalltalk.HLBrowserListWidget, ['selectorsCache'], 'Helios-Browser');
  1237. smalltalk.addMethod(
  1238. smalltalk.method({
  1239. selector: "allProtocol",
  1240. fn: function (){
  1241. var self=this;
  1242. return smalltalk.withContext(function($ctx1) {
  1243. var $1;
  1244. $1=_st(_st(self)._model())._allProtocol();
  1245. return $1;
  1246. }, function($ctx1) {$ctx1.fill(self,"allProtocol",{},smalltalk.HLMethodsListWidget)})},
  1247. messageSends: ["allProtocol", "model"]}),
  1248. smalltalk.HLMethodsListWidget);
  1249. smalltalk.addMethod(
  1250. smalltalk.method({
  1251. selector: "iconForItem:",
  1252. fn: function (aSelector){
  1253. var self=this;
  1254. var override,overriden,method;
  1255. return smalltalk.withContext(function($ctx1) {
  1256. var $2,$3,$4,$1;
  1257. method=_st(self)._methodForSelector_(aSelector);
  1258. override=_st(self)._isOverride_(method);
  1259. overriden=_st(self)._isOverridden_(method);
  1260. $2=override;
  1261. if(smalltalk.assert($2)){
  1262. $3=overriden;
  1263. if(smalltalk.assert($3)){
  1264. $1="icon-resize-vertical";
  1265. } else {
  1266. $1="icon-arrow-up";
  1267. };
  1268. } else {
  1269. $4=overriden;
  1270. if(smalltalk.assert($4)){
  1271. $1="icon-arrow-down";
  1272. } else {
  1273. $1="icon-none";
  1274. };
  1275. };
  1276. return $1;
  1277. }, function($ctx1) {$ctx1.fill(self,"iconForItem:",{aSelector:aSelector,override:override,overriden:overriden,method:method},smalltalk.HLMethodsListWidget)})},
  1278. messageSends: ["methodForSelector:", "isOverride:", "isOverridden:", "ifTrue:ifFalse:"]}),
  1279. smalltalk.HLMethodsListWidget);
  1280. smalltalk.addMethod(
  1281. smalltalk.method({
  1282. selector: "isOverridden:",
  1283. fn: function (aMethod){
  1284. var self=this;
  1285. return smalltalk.withContext(function($ctx1) {
  1286. var $1;
  1287. $1=_st(_st(self)._selectorsCache())._isOverridden_(aMethod);
  1288. return $1;
  1289. }, function($ctx1) {$ctx1.fill(self,"isOverridden:",{aMethod:aMethod},smalltalk.HLMethodsListWidget)})},
  1290. messageSends: ["isOverridden:", "selectorsCache"]}),
  1291. smalltalk.HLMethodsListWidget);
  1292. smalltalk.addMethod(
  1293. smalltalk.method({
  1294. selector: "isOverride:",
  1295. fn: function (aMethod){
  1296. var self=this;
  1297. return smalltalk.withContext(function($ctx1) {
  1298. var $1;
  1299. $1=_st(_st(self)._selectorsCache())._isOverride_(aMethod);
  1300. return $1;
  1301. }, function($ctx1) {$ctx1.fill(self,"isOverride:",{aMethod:aMethod},smalltalk.HLMethodsListWidget)})},
  1302. messageSends: ["isOverride:", "selectorsCache"]}),
  1303. smalltalk.HLMethodsListWidget);
  1304. smalltalk.addMethod(
  1305. smalltalk.method({
  1306. selector: "label",
  1307. fn: function (){
  1308. var self=this;
  1309. return smalltalk.withContext(function($ctx1) {
  1310. return "Methods";
  1311. }, function($ctx1) {$ctx1.fill(self,"label",{},smalltalk.HLMethodsListWidget)})},
  1312. messageSends: []}),
  1313. smalltalk.HLMethodsListWidget);
  1314. smalltalk.addMethod(
  1315. smalltalk.method({
  1316. selector: "methodForSelector:",
  1317. fn: function (aSelector){
  1318. var self=this;
  1319. return smalltalk.withContext(function($ctx1) {
  1320. var $1;
  1321. $1=_st(_st(_st(_st(self)._model())._selectedClass())._methodDictionary())._at_(aSelector);
  1322. return $1;
  1323. }, function($ctx1) {$ctx1.fill(self,"methodForSelector:",{aSelector:aSelector},smalltalk.HLMethodsListWidget)})},
  1324. messageSends: ["at:", "methodDictionary", "selectedClass", "model"]}),
  1325. smalltalk.HLMethodsListWidget);
  1326. smalltalk.addMethod(
  1327. smalltalk.method({
  1328. selector: "methodsInProtocol:",
  1329. fn: function (aString){
  1330. var self=this;
  1331. return smalltalk.withContext(function($ctx1) {
  1332. var $1,$2,$4,$3;
  1333. $1=_st(_st(self)._model())._selectedClass();
  1334. if(($receiver = $1) == nil || $receiver == undefined){
  1335. $2=[];
  1336. return $2;
  1337. } else {
  1338. $1;
  1339. };
  1340. $4=_st(aString).__eq(_st(self)._allProtocol());
  1341. if(smalltalk.assert($4)){
  1342. $3=_st(_st(_st(self)._model())._selectedClass())._methods();
  1343. } else {
  1344. $3=_st(_st(_st(self)._model())._selectedClass())._methodsInProtocol_(aString);
  1345. };
  1346. return $3;
  1347. }, function($ctx1) {$ctx1.fill(self,"methodsInProtocol:",{aString:aString},smalltalk.HLMethodsListWidget)})},
  1348. messageSends: ["ifNil:", "selectedClass", "model", "ifTrue:ifFalse:", "methods", "methodsInProtocol:", "=", "allProtocol"]}),
  1349. smalltalk.HLMethodsListWidget);
  1350. smalltalk.addMethod(
  1351. smalltalk.method({
  1352. selector: "observeModel",
  1353. fn: function (){
  1354. var self=this;
  1355. function $HLProtocolSelected(){return smalltalk.HLProtocolSelected||(typeof HLProtocolSelected=="undefined"?nil:HLProtocolSelected)}
  1356. function $HLShowInstanceToggled(){return smalltalk.HLShowInstanceToggled||(typeof HLShowInstanceToggled=="undefined"?nil:HLShowInstanceToggled)}
  1357. function $HLMethodSelected(){return smalltalk.HLMethodSelected||(typeof HLMethodSelected=="undefined"?nil:HLMethodSelected)}
  1358. function $HLMethodsFocusRequested(){return smalltalk.HLMethodsFocusRequested||(typeof HLMethodsFocusRequested=="undefined"?nil:HLMethodsFocusRequested)}
  1359. return smalltalk.withContext(function($ctx1) {
  1360. var $1,$2;
  1361. $1=_st(_st(self)._model())._announcer();
  1362. _st($1)._on_do_($HLProtocolSelected(),(function(ann){
  1363. return smalltalk.withContext(function($ctx2) {
  1364. return _st(self)._onProtocolSelected_(_st(ann)._item());
  1365. }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1)})}));
  1366. _st($1)._on_do_($HLShowInstanceToggled(),(function(ann){
  1367. return smalltalk.withContext(function($ctx2) {
  1368. return _st(self)._onProtocolSelected_(nil);
  1369. }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1)})}));
  1370. _st($1)._on_do_($HLMethodSelected(),(function(ann){
  1371. return smalltalk.withContext(function($ctx2) {
  1372. return _st(self)._onMethodSelected_(_st(ann)._item());
  1373. }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1)})}));
  1374. $2=_st($1)._on_do_($HLMethodsFocusRequested(),(function(ann){
  1375. return smalltalk.withContext(function($ctx2) {
  1376. return _st(self)._onMethodsFocusRequested();
  1377. }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1)})}));
  1378. return self}, function($ctx1) {$ctx1.fill(self,"observeModel",{},smalltalk.HLMethodsListWidget)})},
  1379. messageSends: ["on:do:", "onProtocolSelected:", "item", "announcer", "model", "onMethodSelected:", "onMethodsFocusRequested"]}),
  1380. smalltalk.HLMethodsListWidget);
  1381. smalltalk.addMethod(
  1382. smalltalk.method({
  1383. selector: "observeSystem",
  1384. fn: function (){
  1385. var self=this;
  1386. function $ProtocolAdded(){return smalltalk.ProtocolAdded||(typeof ProtocolAdded=="undefined"?nil:ProtocolAdded)}
  1387. function $ProtocolRemoved(){return smalltalk.ProtocolRemoved||(typeof ProtocolRemoved=="undefined"?nil:ProtocolRemoved)}
  1388. function $MethodAdded(){return smalltalk.MethodAdded||(typeof MethodAdded=="undefined"?nil:MethodAdded)}
  1389. function $MethodRemoved(){return smalltalk.MethodRemoved||(typeof MethodRemoved=="undefined"?nil:MethodRemoved)}
  1390. function $MethodMoved(){return smalltalk.MethodMoved||(typeof MethodMoved=="undefined"?nil:MethodMoved)}
  1391. return smalltalk.withContext(function($ctx1) {
  1392. var $1,$2;
  1393. $1=_st(_st(self)._model())._systemAnnouncer();
  1394. _st($1)._on_do_($ProtocolAdded(),(function(ann){
  1395. return smalltalk.withContext(function($ctx2) {
  1396. return _st(self)._onProtocolAdded_(_st(ann)._theClass());
  1397. }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1)})}));
  1398. _st($1)._on_do_($ProtocolRemoved(),(function(ann){
  1399. return smalltalk.withContext(function($ctx2) {
  1400. return _st(self)._onProtocolRemoved_(_st(ann)._theClass());
  1401. }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1)})}));
  1402. _st($1)._on_do_($MethodAdded(),(function(ann){
  1403. return smalltalk.withContext(function($ctx2) {
  1404. return _st(self)._onMethodAdded_(_st(ann)._method());
  1405. }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1)})}));
  1406. _st($1)._on_do_($MethodRemoved(),(function(ann){
  1407. return smalltalk.withContext(function($ctx2) {
  1408. return _st(self)._onMethodRemoved_(_st(ann)._method());
  1409. }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1)})}));
  1410. $2=_st($1)._on_do_($MethodMoved(),(function(ann){
  1411. return smalltalk.withContext(function($ctx2) {
  1412. return _st(self)._onMethodMoved_(_st(ann)._method());
  1413. }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1)})}));
  1414. return self}, function($ctx1) {$ctx1.fill(self,"observeSystem",{},smalltalk.HLMethodsListWidget)})},
  1415. messageSends: ["on:do:", "onProtocolAdded:", "theClass", "systemAnnouncer", "model", "onProtocolRemoved:", "onMethodAdded:", "method", "onMethodRemoved:", "onMethodMoved:"]}),
  1416. smalltalk.HLMethodsListWidget);
  1417. smalltalk.addMethod(
  1418. smalltalk.method({
  1419. selector: "onMethodAdded:",
  1420. fn: function (aMethod){
  1421. var self=this;
  1422. return smalltalk.withContext(function($ctx1) {
  1423. var $1,$2;
  1424. $1=_st(_st(_st(self)._model())._selectedClass()).__eq(_st(aMethod)._methodClass());
  1425. if(! smalltalk.assert($1)){
  1426. $2=self;
  1427. return $2;
  1428. };
  1429. _st(self)._setItemsForSelectedProtocol();
  1430. _st(self)._refresh();
  1431. return self}, function($ctx1) {$ctx1.fill(self,"onMethodAdded:",{aMethod:aMethod},smalltalk.HLMethodsListWidget)})},
  1432. messageSends: ["ifFalse:", "=", "methodClass", "selectedClass", "model", "setItemsForSelectedProtocol", "refresh"]}),
  1433. smalltalk.HLMethodsListWidget);
  1434. smalltalk.addMethod(
  1435. smalltalk.method({
  1436. selector: "onMethodMoved:",
  1437. fn: function (aMethod){
  1438. var self=this;
  1439. return smalltalk.withContext(function($ctx1) {
  1440. var $1,$2,$3,$4,$5;
  1441. $1=_st(_st(_st(self)._model())._selectedMethod()).__eq(aMethod);
  1442. if(! smalltalk.assert($1)){
  1443. $2=self;
  1444. return $2;
  1445. };
  1446. $3=_st(_st(_st(self)._model())._selectedProtocol()).__eq(_st(_st(self)._model())._allProtocol());
  1447. if(! smalltalk.assert($3)){
  1448. $4=self;
  1449. _st($4)._selectedItem_(nil);
  1450. _st($4)._selectItem_(nil);
  1451. _st($4)._setItemsForSelectedProtocol();
  1452. $5=_st($4)._refresh();
  1453. $5;
  1454. };
  1455. return self}, function($ctx1) {$ctx1.fill(self,"onMethodMoved:",{aMethod:aMethod},smalltalk.HLMethodsListWidget)})},
  1456. messageSends: ["ifFalse:", "=", "selectedMethod", "model", "selectedItem:", "selectItem:", "setItemsForSelectedProtocol", "refresh", "allProtocol", "selectedProtocol"]}),
  1457. smalltalk.HLMethodsListWidget);
  1458. smalltalk.addMethod(
  1459. smalltalk.method({
  1460. selector: "onMethodRemoved:",
  1461. fn: function (aMethod){
  1462. var self=this;
  1463. return smalltalk.withContext(function($ctx1) {
  1464. var $1,$2,$3,$4,$5;
  1465. var $early={};
  1466. try {
  1467. _st(_st(self)._items())._detect_ifNone_((function(each){
  1468. return smalltalk.withContext(function($ctx2) {
  1469. return _st(each).__eq(_st(aMethod)._selector());
  1470. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})}),(function(){
  1471. return smalltalk.withContext(function($ctx2) {
  1472. $1=self;
  1473. throw $early=[$1];
  1474. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  1475. $2=_st(self)._selectedItem();
  1476. if(($receiver = $2) == nil || $receiver == undefined){
  1477. $2;
  1478. } else {
  1479. $3=_st(_st(_st(aMethod)._methodClass()).__eq(_st(_st(self)._model())._selectedClass()))._and_((function(){
  1480. return smalltalk.withContext(function($ctx2) {
  1481. return _st(_st(aMethod)._selector()).__eq(_st(self)._selectedItem());
  1482. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  1483. if(smalltalk.assert($3)){
  1484. $4=self;
  1485. _st($4)._selectedItem_(nil);
  1486. $5=_st($4)._selectItem_(nil);
  1487. $5;
  1488. };
  1489. };
  1490. _st(self)._setItemsForSelectedProtocol();
  1491. _st(self)._refresh();
  1492. return self}
  1493. catch(e) {if(e===$early)return e[0]; throw e}
  1494. }, function($ctx1) {$ctx1.fill(self,"onMethodRemoved:",{aMethod:aMethod},smalltalk.HLMethodsListWidget)})},
  1495. messageSends: ["detect:ifNone:", "=", "selector", "items", "ifNotNil:", "ifTrue:", "selectedItem:", "selectItem:", "and:", "selectedItem", "selectedClass", "model", "methodClass", "setItemsForSelectedProtocol", "refresh"]}),
  1496. smalltalk.HLMethodsListWidget);
  1497. smalltalk.addMethod(
  1498. smalltalk.method({
  1499. selector: "onMethodSelected:",
  1500. fn: function (aMethod){
  1501. var self=this;
  1502. var selector;
  1503. return smalltalk.withContext(function($ctx1) {
  1504. var $1,$2,$3;
  1505. $1=_st(aMethod)._isCompiledMethod();
  1506. if(smalltalk.assert($1)){
  1507. selector=_st(aMethod)._selector();
  1508. } else {
  1509. selector=nil;
  1510. };
  1511. $2=self;
  1512. _st($2)._selectedItem_(selector);
  1513. $3=_st($2)._activateItem_(selector);
  1514. return self}, function($ctx1) {$ctx1.fill(self,"onMethodSelected:",{aMethod:aMethod,selector:selector},smalltalk.HLMethodsListWidget)})},
  1515. messageSends: ["ifTrue:ifFalse:", "selector", "isCompiledMethod", "selectedItem:", "activateItem:"]}),
  1516. smalltalk.HLMethodsListWidget);
  1517. smalltalk.addMethod(
  1518. smalltalk.method({
  1519. selector: "onMethodsFocusRequested",
  1520. fn: function (){
  1521. var self=this;
  1522. return smalltalk.withContext(function($ctx1) {
  1523. _st(self)._focus();
  1524. return self}, function($ctx1) {$ctx1.fill(self,"onMethodsFocusRequested",{},smalltalk.HLMethodsListWidget)})},
  1525. messageSends: ["focus"]}),
  1526. smalltalk.HLMethodsListWidget);
  1527. smalltalk.addMethod(
  1528. smalltalk.method({
  1529. selector: "onProtocolAdded:",
  1530. fn: function (aClass){
  1531. var self=this;
  1532. return smalltalk.withContext(function($ctx1) {
  1533. var $1,$2;
  1534. $1=_st(_st(_st(self)._model())._selectedClass()).__eq(aClass);
  1535. if(! smalltalk.assert($1)){
  1536. $2=self;
  1537. return $2;
  1538. };
  1539. _st(self)._setItemsForSelectedProtocol();
  1540. _st(self)._refresh();
  1541. _st(self)._focus();
  1542. return self}, function($ctx1) {$ctx1.fill(self,"onProtocolAdded:",{aClass:aClass},smalltalk.HLMethodsListWidget)})},
  1543. messageSends: ["ifFalse:", "=", "selectedClass", "model", "setItemsForSelectedProtocol", "refresh", "focus"]}),
  1544. smalltalk.HLMethodsListWidget);
  1545. smalltalk.addMethod(
  1546. smalltalk.method({
  1547. selector: "onProtocolRemoved:",
  1548. fn: function (aClass){
  1549. var self=this;
  1550. return smalltalk.withContext(function($ctx1) {
  1551. var $1,$2;
  1552. $1=_st(_st(_st(self)._model())._selectedClass()).__eq(aClass);
  1553. if(! smalltalk.assert($1)){
  1554. $2=self;
  1555. return $2;
  1556. };
  1557. _st(self)._setItemsForSelectedProtocol();
  1558. _st(self)._refresh();
  1559. _st(self)._focus();
  1560. return self}, function($ctx1) {$ctx1.fill(self,"onProtocolRemoved:",{aClass:aClass},smalltalk.HLMethodsListWidget)})},
  1561. messageSends: ["ifFalse:", "=", "selectedClass", "model", "setItemsForSelectedProtocol", "refresh", "focus"]}),
  1562. smalltalk.HLMethodsListWidget);
  1563. smalltalk.addMethod(
  1564. smalltalk.method({
  1565. selector: "onProtocolSelected:",
  1566. fn: function (aString){
  1567. var self=this;
  1568. return smalltalk.withContext(function($ctx1) {
  1569. _st(self)._selectedItem_(nil);
  1570. _st(self)._setItemsForSelectedProtocol();
  1571. _st(self)._refresh();
  1572. return self}, function($ctx1) {$ctx1.fill(self,"onProtocolSelected:",{aString:aString},smalltalk.HLMethodsListWidget)})},
  1573. messageSends: ["selectedItem:", "setItemsForSelectedProtocol", "refresh"]}),
  1574. smalltalk.HLMethodsListWidget);
  1575. smalltalk.addMethod(
  1576. smalltalk.method({
  1577. selector: "overrideSelectors",
  1578. fn: function (){
  1579. var self=this;
  1580. function $Set(){return smalltalk.Set||(typeof Set=="undefined"?nil:Set)}
  1581. return smalltalk.withContext(function($ctx1) {
  1582. var $2,$3,$1;
  1583. $1=_st(_st(self)._selectorsCache())._at_ifAbsentPut_("override",(function(){
  1584. return smalltalk.withContext(function($ctx2) {
  1585. return _st(_st(_st(_st(self)._model())._selectedClass())._allSuperclasses())._inject_into_(_st($Set())._new(),(function(acc,each){
  1586. return smalltalk.withContext(function($ctx3) {
  1587. $2=acc;
  1588. _st($2)._addAll_(_st(each)._selectors());
  1589. $3=_st($2)._yourself();
  1590. return $3;
  1591. }, function($ctx3) {$ctx3.fillBlock({acc:acc,each:each},$ctx1)})}));
  1592. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  1593. return $1;
  1594. }, function($ctx1) {$ctx1.fill(self,"overrideSelectors",{},smalltalk.HLMethodsListWidget)})},
  1595. messageSends: ["at:ifAbsentPut:", "inject:into:", "new", "addAll:", "selectors", "yourself", "allSuperclasses", "selectedClass", "model", "selectorsCache"]}),
  1596. smalltalk.HLMethodsListWidget);
  1597. smalltalk.addMethod(
  1598. smalltalk.method({
  1599. selector: "overridenSelectors",
  1600. fn: function (){
  1601. var self=this;
  1602. function $Set(){return smalltalk.Set||(typeof Set=="undefined"?nil:Set)}
  1603. return smalltalk.withContext(function($ctx1) {
  1604. var $2,$3,$1;
  1605. $1=_st(_st(self)._selectorsCache())._at_ifAbsentPut_("overriden",(function(){
  1606. return smalltalk.withContext(function($ctx2) {
  1607. return _st(_st(_st(_st(self)._model())._selectedClass())._allSubclasses())._inject_into_(_st($Set())._new(),(function(acc,each){
  1608. return smalltalk.withContext(function($ctx3) {
  1609. $2=acc;
  1610. _st($2)._addAll_(_st(each)._selectors());
  1611. $3=_st($2)._yourself();
  1612. return $3;
  1613. }, function($ctx3) {$ctx3.fillBlock({acc:acc,each:each},$ctx1)})}));
  1614. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  1615. return $1;
  1616. }, function($ctx1) {$ctx1.fill(self,"overridenSelectors",{},smalltalk.HLMethodsListWidget)})},
  1617. messageSends: ["at:ifAbsentPut:", "inject:into:", "new", "addAll:", "selectors", "yourself", "allSubclasses", "selectedClass", "model", "selectorsCache"]}),
  1618. smalltalk.HLMethodsListWidget);
  1619. smalltalk.addMethod(
  1620. smalltalk.method({
  1621. selector: "renderContentOn:",
  1622. fn: function (html){
  1623. var self=this;
  1624. return smalltalk.withContext(function($ctx1) {
  1625. var $1,$2,$3;
  1626. $1=_st(_st(self)._model())._showInstance();
  1627. if(smalltalk.assert($1)){
  1628. smalltalk.HLBrowserListWidget.fn.prototype._renderContentOn_.apply(_st(self), [html]);
  1629. } else {
  1630. $2=_st(html)._div();
  1631. _st($2)._class_("class_side");
  1632. $3=_st($2)._with_((function(){
  1633. return smalltalk.withContext(function($ctx2) {
  1634. return smalltalk.HLBrowserListWidget.fn.prototype._renderContentOn_.apply(_st(self), [html]);
  1635. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  1636. $3;
  1637. };
  1638. return self}, function($ctx1) {$ctx1.fill(self,"renderContentOn:",{html:html},smalltalk.HLMethodsListWidget)})},
  1639. messageSends: ["ifFalse:ifTrue:", "class:", "div", "with:", "renderContentOn:", "showInstance", "model"]}),
  1640. smalltalk.HLMethodsListWidget);
  1641. smalltalk.addMethod(
  1642. smalltalk.method({
  1643. selector: "renderItemLabel:on:",
  1644. fn: function (aSelector,html){
  1645. var self=this;
  1646. return smalltalk.withContext(function($ctx1) {
  1647. _st(html)._with_(aSelector);
  1648. return self}, function($ctx1) {$ctx1.fill(self,"renderItemLabel:on:",{aSelector:aSelector,html:html},smalltalk.HLMethodsListWidget)})},
  1649. messageSends: ["with:"]}),
  1650. smalltalk.HLMethodsListWidget);
  1651. smalltalk.addMethod(
  1652. smalltalk.method({
  1653. selector: "selectItem:",
  1654. fn: function (aSelector){
  1655. var self=this;
  1656. return smalltalk.withContext(function($ctx1) {
  1657. var $1,$2;
  1658. $1=aSelector;
  1659. if(($receiver = $1) == nil || $receiver == undefined){
  1660. $2=_st(_st(self)._model())._selectedMethod_(nil);
  1661. return $2;
  1662. } else {
  1663. $1;
  1664. };
  1665. _st(_st(self)._model())._selectedMethod_(_st(self)._methodForSelector_(aSelector));
  1666. return self}, function($ctx1) {$ctx1.fill(self,"selectItem:",{aSelector:aSelector},smalltalk.HLMethodsListWidget)})},
  1667. messageSends: ["ifNil:", "selectedMethod:", "model", "methodForSelector:"]}),
  1668. smalltalk.HLMethodsListWidget);
  1669. smalltalk.addMethod(
  1670. smalltalk.method({
  1671. selector: "selectorsCache",
  1672. fn: function (){
  1673. var self=this;
  1674. return smalltalk.withContext(function($ctx1) {
  1675. var $1;
  1676. $1=_st(_st(self)._class())._selectorsCache();
  1677. return $1;
  1678. }, function($ctx1) {$ctx1.fill(self,"selectorsCache",{},smalltalk.HLMethodsListWidget)})},
  1679. messageSends: ["selectorsCache", "class"]}),
  1680. smalltalk.HLMethodsListWidget);
  1681. smalltalk.addMethod(
  1682. smalltalk.method({
  1683. selector: "selectorsInProtocol:",
  1684. fn: function (aString){
  1685. var self=this;
  1686. return smalltalk.withContext(function($ctx1) {
  1687. var $1;
  1688. $1=_st(_st(_st(self)._methodsInProtocol_(aString))._collect_((function(each){
  1689. return smalltalk.withContext(function($ctx2) {
  1690. return _st(each)._selector();
  1691. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})})))._sorted();
  1692. return $1;
  1693. }, function($ctx1) {$ctx1.fill(self,"selectorsInProtocol:",{aString:aString},smalltalk.HLMethodsListWidget)})},
  1694. messageSends: ["sorted", "collect:", "selector", "methodsInProtocol:"]}),
  1695. smalltalk.HLMethodsListWidget);
  1696. smalltalk.addMethod(
  1697. smalltalk.method({
  1698. selector: "setItemsForProtocol:",
  1699. fn: function (aString){
  1700. var self=this;
  1701. return smalltalk.withContext(function($ctx1) {
  1702. var $2,$4,$3,$1;
  1703. $2=self;
  1704. $4=aString;
  1705. if(($receiver = $4) == nil || $receiver == undefined){
  1706. $3=[];
  1707. } else {
  1708. $3=_st(self)._selectorsInProtocol_(aString);
  1709. };
  1710. $1=_st($2)._items_($3);
  1711. return $1;
  1712. }, function($ctx1) {$ctx1.fill(self,"setItemsForProtocol:",{aString:aString},smalltalk.HLMethodsListWidget)})},
  1713. messageSends: ["items:", "ifNil:ifNotNil:", "selectorsInProtocol:"]}),
  1714. smalltalk.HLMethodsListWidget);
  1715. smalltalk.addMethod(
  1716. smalltalk.method({
  1717. selector: "setItemsForSelectedProtocol",
  1718. fn: function (){
  1719. var self=this;
  1720. return smalltalk.withContext(function($ctx1) {
  1721. _st(self)._setItemsForProtocol_(_st(_st(self)._model())._selectedProtocol());
  1722. return self}, function($ctx1) {$ctx1.fill(self,"setItemsForSelectedProtocol",{},smalltalk.HLMethodsListWidget)})},
  1723. messageSends: ["setItemsForProtocol:", "selectedProtocol", "model"]}),
  1724. smalltalk.HLMethodsListWidget);
  1725. smalltalk.HLMethodsListWidget.klass.iVarNames = ['selectorsCache'];
  1726. smalltalk.addMethod(
  1727. smalltalk.method({
  1728. selector: "selectorsCache",
  1729. fn: function (){
  1730. var self=this;
  1731. function $HLSelectorsCache(){return smalltalk.HLSelectorsCache||(typeof HLSelectorsCache=="undefined"?nil:HLSelectorsCache)}
  1732. return smalltalk.withContext(function($ctx1) {
  1733. var $1;
  1734. $1=_st($HLSelectorsCache())._current();
  1735. return $1;
  1736. }, function($ctx1) {$ctx1.fill(self,"selectorsCache",{},smalltalk.HLMethodsListWidget.klass)})},
  1737. messageSends: ["current"]}),
  1738. smalltalk.HLMethodsListWidget.klass);
  1739. smalltalk.addClass('HLPackagesListWidget', smalltalk.HLBrowserListWidget, [], 'Helios-Browser');
  1740. smalltalk.addMethod(
  1741. smalltalk.method({
  1742. selector: "commitPackage",
  1743. fn: function (){
  1744. var self=this;
  1745. return smalltalk.withContext(function($ctx1) {
  1746. _st(_st(self)._model())._commitPackage();
  1747. return self}, function($ctx1) {$ctx1.fill(self,"commitPackage",{},smalltalk.HLPackagesListWidget)})},
  1748. messageSends: ["commitPackage", "model"]}),
  1749. smalltalk.HLPackagesListWidget);
  1750. smalltalk.addMethod(
  1751. smalltalk.method({
  1752. selector: "focusClassesListWidget",
  1753. fn: function (){
  1754. var self=this;
  1755. function $HLClassesListFocus(){return smalltalk.HLClassesListFocus||(typeof HLClassesListFocus=="undefined"?nil:HLClassesListFocus)}
  1756. return smalltalk.withContext(function($ctx1) {
  1757. _st(_st(_st(self)._model())._announcer())._announce_(_st($HLClassesListFocus())._new());
  1758. return self}, function($ctx1) {$ctx1.fill(self,"focusClassesListWidget",{},smalltalk.HLPackagesListWidget)})},
  1759. messageSends: ["announce:", "new", "announcer", "model"]}),
  1760. smalltalk.HLPackagesListWidget);
  1761. smalltalk.addMethod(
  1762. smalltalk.method({
  1763. selector: "initializeItems",
  1764. fn: function (){
  1765. var self=this;
  1766. return smalltalk.withContext(function($ctx1) {
  1767. var $1;
  1768. self["@items"]=_st(_st(_st(self)._model())._packages())._sort_((function(a,b){
  1769. return smalltalk.withContext(function($ctx2) {
  1770. return _st(_st(a)._name()).__lt(_st(b)._name());
  1771. }, function($ctx2) {$ctx2.fillBlock({a:a,b:b},$ctx1)})}));
  1772. $1=self["@items"];
  1773. return $1;
  1774. }, function($ctx1) {$ctx1.fill(self,"initializeItems",{},smalltalk.HLPackagesListWidget)})},
  1775. messageSends: ["sort:", "<", "name", "packages", "model"]}),
  1776. smalltalk.HLPackagesListWidget);
  1777. smalltalk.addMethod(
  1778. smalltalk.method({
  1779. selector: "items",
  1780. fn: function (){
  1781. var self=this;
  1782. return smalltalk.withContext(function($ctx1) {
  1783. var $2,$1;
  1784. $2=self["@items"];
  1785. if(($receiver = $2) == nil || $receiver == undefined){
  1786. $1=_st(self)._initializeItems();
  1787. } else {
  1788. $1=$2;
  1789. };
  1790. return $1;
  1791. }, function($ctx1) {$ctx1.fill(self,"items",{},smalltalk.HLPackagesListWidget)})},
  1792. messageSends: ["ifNil:", "initializeItems"]}),
  1793. smalltalk.HLPackagesListWidget);
  1794. smalltalk.addMethod(
  1795. smalltalk.method({
  1796. selector: "label",
  1797. fn: function (){
  1798. var self=this;
  1799. return smalltalk.withContext(function($ctx1) {
  1800. return "Packages";
  1801. }, function($ctx1) {$ctx1.fill(self,"label",{},smalltalk.HLPackagesListWidget)})},
  1802. messageSends: []}),
  1803. smalltalk.HLPackagesListWidget);
  1804. smalltalk.addMethod(
  1805. smalltalk.method({
  1806. selector: "observeModel",
  1807. fn: function (){
  1808. var self=this;
  1809. function $HLPackageSelected(){return smalltalk.HLPackageSelected||(typeof HLPackageSelected=="undefined"?nil:HLPackageSelected)}
  1810. function $HLPackagesFocusRequested(){return smalltalk.HLPackagesFocusRequested||(typeof HLPackagesFocusRequested=="undefined"?nil:HLPackagesFocusRequested)}
  1811. return smalltalk.withContext(function($ctx1) {
  1812. var $1,$2;
  1813. $1=_st(_st(self)._model())._announcer();
  1814. _st($1)._on_do_($HLPackageSelected(),(function(ann){
  1815. return smalltalk.withContext(function($ctx2) {
  1816. return _st(self)._onPackageSelected_(_st(ann)._item());
  1817. }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1)})}));
  1818. $2=_st($1)._on_do_($HLPackagesFocusRequested(),(function(ann){
  1819. return smalltalk.withContext(function($ctx2) {
  1820. return _st(self)._onPackagesFocusRequested();
  1821. }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1)})}));
  1822. return self}, function($ctx1) {$ctx1.fill(self,"observeModel",{},smalltalk.HLPackagesListWidget)})},
  1823. messageSends: ["on:do:", "onPackageSelected:", "item", "announcer", "model", "onPackagesFocusRequested"]}),
  1824. smalltalk.HLPackagesListWidget);
  1825. smalltalk.addMethod(
  1826. smalltalk.method({
  1827. selector: "observeSystem",
  1828. fn: function (){
  1829. var self=this;
  1830. function $ClassAdded(){return smalltalk.ClassAdded||(typeof ClassAdded=="undefined"?nil:ClassAdded)}
  1831. return smalltalk.withContext(function($ctx1) {
  1832. _st(_st(_st(self)._model())._systemAnnouncer())._on_do_($ClassAdded(),(function(ann){
  1833. return smalltalk.withContext(function($ctx2) {
  1834. return _st(self)._onClassAdded_(_st(ann)._theClass());
  1835. }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1)})}));
  1836. return self}, function($ctx1) {$ctx1.fill(self,"observeSystem",{},smalltalk.HLPackagesListWidget)})},
  1837. messageSends: ["on:do:", "onClassAdded:", "theClass", "systemAnnouncer", "model"]}),
  1838. smalltalk.HLPackagesListWidget);
  1839. smalltalk.addMethod(
  1840. smalltalk.method({
  1841. selector: "onClassAdded:",
  1842. fn: function (aClass){
  1843. var self=this;
  1844. return smalltalk.withContext(function($ctx1) {
  1845. var $1,$2,$3;
  1846. $1=_st(_st(self)._items())._includes_(_st(aClass)._package());
  1847. if(! smalltalk.assert($1)){
  1848. $2=self;
  1849. _st($2)._initializeItems();
  1850. $3=_st($2)._refresh();
  1851. $3;
  1852. };
  1853. return self}, function($ctx1) {$ctx1.fill(self,"onClassAdded:",{aClass:aClass},smalltalk.HLPackagesListWidget)})},
  1854. messageSends: ["ifFalse:", "initializeItems", "refresh", "includes:", "package", "items"]}),
  1855. smalltalk.HLPackagesListWidget);
  1856. smalltalk.addMethod(
  1857. smalltalk.method({
  1858. selector: "onPackageSelected:",
  1859. fn: function (aPackage){
  1860. var self=this;
  1861. return smalltalk.withContext(function($ctx1) {
  1862. var $1,$2,$3;
  1863. _st(self)._selectedItem_(aPackage);
  1864. $1=_st(self)._hasFocus();
  1865. if(! smalltalk.assert($1)){
  1866. $2=self;
  1867. _st($2)._activateItem_(aPackage);
  1868. $3=_st($2)._focus();
  1869. $3;
  1870. };
  1871. return self}, function($ctx1) {$ctx1.fill(self,"onPackageSelected:",{aPackage:aPackage},smalltalk.HLPackagesListWidget)})},
  1872. messageSends: ["selectedItem:", "ifFalse:", "activateItem:", "focus", "hasFocus"]}),
  1873. smalltalk.HLPackagesListWidget);
  1874. smalltalk.addMethod(
  1875. smalltalk.method({
  1876. selector: "onPackagesFocusRequested",
  1877. fn: function (){
  1878. var self=this;
  1879. return smalltalk.withContext(function($ctx1) {
  1880. _st(self)._focus();
  1881. return self}, function($ctx1) {$ctx1.fill(self,"onPackagesFocusRequested",{},smalltalk.HLPackagesListWidget)})},
  1882. messageSends: ["focus"]}),
  1883. smalltalk.HLPackagesListWidget);
  1884. smalltalk.addMethod(
  1885. smalltalk.method({
  1886. selector: "renderButtonsOn:",
  1887. fn: function (html){
  1888. var self=this;
  1889. return smalltalk.withContext(function($ctx1) {
  1890. var $1,$3,$4,$2;
  1891. $1=_st(html)._div();
  1892. _st($1)._class_("buttons");
  1893. $2=_st($1)._with_((function(){
  1894. return smalltalk.withContext(function($ctx2) {
  1895. $3=_st(html)._button();
  1896. _st($3)._class_("btn");
  1897. _st($3)._with_("Commit");
  1898. $4=_st($3)._onClick_((function(){
  1899. return smalltalk.withContext(function($ctx3) {
  1900. return _st(self)._commitPackage();
  1901. }, function($ctx3) {$ctx3.fillBlock({},$ctx1)})}));
  1902. return $4;
  1903. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  1904. return self}, function($ctx1) {$ctx1.fill(self,"renderButtonsOn:",{html:html},smalltalk.HLPackagesListWidget)})},
  1905. messageSends: ["class:", "div", "with:", "button", "onClick:", "commitPackage"]}),
  1906. smalltalk.HLPackagesListWidget);
  1907. smalltalk.addMethod(
  1908. smalltalk.method({
  1909. selector: "renderItemLabel:on:",
  1910. fn: function (aPackage,html){
  1911. var self=this;
  1912. return smalltalk.withContext(function($ctx1) {
  1913. _st(html)._with_(_st(aPackage)._name());
  1914. return self}, function($ctx1) {$ctx1.fill(self,"renderItemLabel:on:",{aPackage:aPackage,html:html},smalltalk.HLPackagesListWidget)})},
  1915. messageSends: ["with:", "name"]}),
  1916. smalltalk.HLPackagesListWidget);
  1917. smalltalk.addMethod(
  1918. smalltalk.method({
  1919. selector: "selectItem:",
  1920. fn: function (aPackage){
  1921. var self=this;
  1922. return smalltalk.withContext(function($ctx1) {
  1923. _st(_st(self)._model())._selectedPackage_(aPackage);
  1924. return self}, function($ctx1) {$ctx1.fill(self,"selectItem:",{aPackage:aPackage},smalltalk.HLPackagesListWidget)})},
  1925. messageSends: ["selectedPackage:", "model"]}),
  1926. smalltalk.HLPackagesListWidget);
  1927. smalltalk.addClass('HLProtocolsListWidget', smalltalk.HLBrowserListWidget, [], 'Helios-Browser');
  1928. smalltalk.addMethod(
  1929. smalltalk.method({
  1930. selector: "allProtocol",
  1931. fn: function (){
  1932. var self=this;
  1933. return smalltalk.withContext(function($ctx1) {
  1934. var $1;
  1935. $1=_st(_st(self)._model())._allProtocol();
  1936. return $1;
  1937. }, function($ctx1) {$ctx1.fill(self,"allProtocol",{},smalltalk.HLProtocolsListWidget)})},
  1938. messageSends: ["allProtocol", "model"]}),
  1939. smalltalk.HLProtocolsListWidget);
  1940. smalltalk.addMethod(
  1941. smalltalk.method({
  1942. selector: "label",
  1943. fn: function (){
  1944. var self=this;
  1945. return smalltalk.withContext(function($ctx1) {
  1946. return "Protocols";
  1947. }, function($ctx1) {$ctx1.fill(self,"label",{},smalltalk.HLProtocolsListWidget)})},
  1948. messageSends: []}),
  1949. smalltalk.HLProtocolsListWidget);
  1950. smalltalk.addMethod(
  1951. smalltalk.method({
  1952. selector: "observeModel",
  1953. fn: function (){
  1954. var self=this;
  1955. function $HLClassSelected(){return smalltalk.HLClassSelected||(typeof HLClassSelected=="undefined"?nil:HLClassSelected)}
  1956. function $HLShowInstanceToggled(){return smalltalk.HLShowInstanceToggled||(typeof HLShowInstanceToggled=="undefined"?nil:HLShowInstanceToggled)}
  1957. function $HLProtocolSelected(){return smalltalk.HLProtocolSelected||(typeof HLProtocolSelected=="undefined"?nil:HLProtocolSelected)}
  1958. function $HLProtocolsFocusRequested(){return smalltalk.HLProtocolsFocusRequested||(typeof HLProtocolsFocusRequested=="undefined"?nil:HLProtocolsFocusRequested)}
  1959. return smalltalk.withContext(function($ctx1) {
  1960. var $1,$2;
  1961. $1=_st(_st(self)._model())._announcer();
  1962. _st($1)._on_do_($HLClassSelected(),(function(ann){
  1963. return smalltalk.withContext(function($ctx2) {
  1964. return _st(self)._onClassSelected_(_st(ann)._item());
  1965. }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1)})}));
  1966. _st($1)._on_do_($HLShowInstanceToggled(),(function(ann){
  1967. return smalltalk.withContext(function($ctx2) {
  1968. return _st(self)._onClassSelected_(_st(_st(self)._model())._selectedClass());
  1969. }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1)})}));
  1970. _st($1)._on_do_($HLProtocolSelected(),(function(ann){
  1971. return smalltalk.withContext(function($ctx2) {
  1972. return _st(self)._onProtocolSelected_(_st(ann)._item());
  1973. }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1)})}));
  1974. $2=_st($1)._on_do_($HLProtocolsFocusRequested(),(function(ann){
  1975. return smalltalk.withContext(function($ctx2) {
  1976. return _st(self)._onProtocolsFocusRequested();
  1977. }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1)})}));
  1978. return self}, function($ctx1) {$ctx1.fill(self,"observeModel",{},smalltalk.HLProtocolsListWidget)})},
  1979. messageSends: ["on:do:", "onClassSelected:", "item", "announcer", "model", "selectedClass", "onProtocolSelected:", "onProtocolsFocusRequested"]}),
  1980. smalltalk.HLProtocolsListWidget);
  1981. smalltalk.addMethod(
  1982. smalltalk.method({
  1983. selector: "observeSystem",
  1984. fn: function (){
  1985. var self=this;
  1986. function $ProtocolAdded(){return smalltalk.ProtocolAdded||(typeof ProtocolAdded=="undefined"?nil:ProtocolAdded)}
  1987. function $ProtocolRemoved(){return smalltalk.ProtocolRemoved||(typeof ProtocolRemoved=="undefined"?nil:ProtocolRemoved)}
  1988. return smalltalk.withContext(function($ctx1) {
  1989. var $1,$2;
  1990. $1=_st(_st(self)._model())._systemAnnouncer();
  1991. _st($1)._on_do_($ProtocolAdded(),(function(ann){
  1992. return smalltalk.withContext(function($ctx2) {
  1993. return _st(self)._onProtocolAdded_to_(_st(ann)._protocol(),_st(ann)._theClass());
  1994. }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1)})}));
  1995. $2=_st($1)._on_do_($ProtocolRemoved(),(function(ann){
  1996. return smalltalk.withContext(function($ctx2) {
  1997. return _st(self)._onProtocolRemoved_from_(_st(ann)._protocol(),_st(ann)._theClass());
  1998. }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1)})}));
  1999. return self}, function($ctx1) {$ctx1.fill(self,"observeSystem",{},smalltalk.HLProtocolsListWidget)})},
  2000. messageSends: ["on:do:", "onProtocolAdded:to:", "protocol", "theClass", "systemAnnouncer", "model", "onProtocolRemoved:from:"]}),
  2001. smalltalk.HLProtocolsListWidget);
  2002. smalltalk.addMethod(
  2003. smalltalk.method({
  2004. selector: "onClassSelected:",
  2005. fn: function (aClass){
  2006. var self=this;
  2007. return smalltalk.withContext(function($ctx1) {
  2008. _st(self)._selectedItem_(nil);
  2009. _st(self)._setItemsForSelectedClass();
  2010. _st(self)._refresh();
  2011. return self}, function($ctx1) {$ctx1.fill(self,"onClassSelected:",{aClass:aClass},smalltalk.HLProtocolsListWidget)})},
  2012. messageSends: ["selectedItem:", "setItemsForSelectedClass", "refresh"]}),
  2013. smalltalk.HLProtocolsListWidget);
  2014. smalltalk.addMethod(
  2015. smalltalk.method({
  2016. selector: "onProtocolAdded:to:",
  2017. fn: function (aString,aClass){
  2018. var self=this;
  2019. return smalltalk.withContext(function($ctx1) {
  2020. var $1,$2;
  2021. $1=_st(aClass).__eq(_st(_st(self)._model())._selectedClass());
  2022. if(! smalltalk.assert($1)){
  2023. $2=self;
  2024. return $2;
  2025. };
  2026. _st(self)._setItemsForSelectedClass();
  2027. _st(self)._refresh();
  2028. return self}, function($ctx1) {$ctx1.fill(self,"onProtocolAdded:to:",{aString:aString,aClass:aClass},smalltalk.HLProtocolsListWidget)})},
  2029. messageSends: ["ifFalse:", "=", "selectedClass", "model", "setItemsForSelectedClass", "refresh"]}),
  2030. smalltalk.HLProtocolsListWidget);
  2031. smalltalk.addMethod(
  2032. smalltalk.method({
  2033. selector: "onProtocolRemoved:from:",
  2034. fn: function (aString,aClass){
  2035. var self=this;
  2036. return smalltalk.withContext(function($ctx1) {
  2037. var $1,$2,$3,$4,$5;
  2038. $1=_st(aClass).__eq(_st(_st(self)._model())._selectedClass());
  2039. if(! smalltalk.assert($1)){
  2040. $2=self;
  2041. return $2;
  2042. };
  2043. $3=_st(_st(_st(self)._model())._selectedProtocol()).__eq(aString);
  2044. if(smalltalk.assert($3)){
  2045. $4=self;
  2046. _st($4)._selectedItem_(nil);
  2047. $5=_st($4)._selectItem_(nil);
  2048. $5;
  2049. };
  2050. _st(self)._setItemsForSelectedClass();
  2051. _st(self)._refresh();
  2052. return self}, function($ctx1) {$ctx1.fill(self,"onProtocolRemoved:from:",{aString:aString,aClass:aClass},smalltalk.HLProtocolsListWidget)})},
  2053. messageSends: ["ifFalse:", "=", "selectedClass", "model", "ifTrue:", "selectedItem:", "selectItem:", "selectedProtocol", "setItemsForSelectedClass", "refresh"]}),
  2054. smalltalk.HLProtocolsListWidget);
  2055. smalltalk.addMethod(
  2056. smalltalk.method({
  2057. selector: "onProtocolSelected:",
  2058. fn: function (aString){
  2059. var self=this;
  2060. return smalltalk.withContext(function($ctx1) {
  2061. var $1,$2,$3,$4,$5;
  2062. _st(self)._selectedItem_(aString);
  2063. $1=aString;
  2064. if(($receiver = $1) == nil || $receiver == undefined){
  2065. $2=self;
  2066. return $2;
  2067. } else {
  2068. $1;
  2069. };
  2070. $3=_st(self)._hasFocus();
  2071. if(! smalltalk.assert($3)){
  2072. $4=self;
  2073. _st($4)._activateItem_(aString);
  2074. $5=_st($4)._focus();
  2075. $5;
  2076. };
  2077. return self}, function($ctx1) {$ctx1.fill(self,"onProtocolSelected:",{aString:aString},smalltalk.HLProtocolsListWidget)})},
  2078. messageSends: ["selectedItem:", "ifNil:", "ifFalse:", "activateItem:", "focus", "hasFocus"]}),
  2079. smalltalk.HLProtocolsListWidget);
  2080. smalltalk.addMethod(
  2081. smalltalk.method({
  2082. selector: "onProtocolsFocusRequested",
  2083. fn: function (){
  2084. var self=this;
  2085. return smalltalk.withContext(function($ctx1) {
  2086. _st(self)._focus();
  2087. return self}, function($ctx1) {$ctx1.fill(self,"onProtocolsFocusRequested",{},smalltalk.HLProtocolsListWidget)})},
  2088. messageSends: ["focus"]}),
  2089. smalltalk.HLProtocolsListWidget);
  2090. smalltalk.addMethod(
  2091. smalltalk.method({
  2092. selector: "renderContentOn:",
  2093. fn: function (html){
  2094. var self=this;
  2095. return smalltalk.withContext(function($ctx1) {
  2096. var $1,$2,$3;
  2097. $1=_st(_st(self)._model())._showInstance();
  2098. if(smalltalk.assert($1)){
  2099. smalltalk.HLBrowserListWidget.fn.prototype._renderContentOn_.apply(_st(self), [html]);
  2100. } else {
  2101. $2=_st(html)._div();
  2102. _st($2)._class_("class_side");
  2103. $3=_st($2)._with_((function(){
  2104. return smalltalk.withContext(function($ctx2) {
  2105. return smalltalk.HLBrowserListWidget.fn.prototype._renderContentOn_.apply(_st(self), [html]);
  2106. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  2107. $3;
  2108. };
  2109. return self}, function($ctx1) {$ctx1.fill(self,"renderContentOn:",{html:html},smalltalk.HLProtocolsListWidget)})},
  2110. messageSends: ["ifFalse:ifTrue:", "class:", "div", "with:", "renderContentOn:", "showInstance", "model"]}),
  2111. smalltalk.HLProtocolsListWidget);
  2112. smalltalk.addMethod(
  2113. smalltalk.method({
  2114. selector: "selectItem:",
  2115. fn: function (aString){
  2116. var self=this;
  2117. return smalltalk.withContext(function($ctx1) {
  2118. _st(_st(self)._model())._selectedProtocol_(aString);
  2119. return self}, function($ctx1) {$ctx1.fill(self,"selectItem:",{aString:aString},smalltalk.HLProtocolsListWidget)})},
  2120. messageSends: ["selectedProtocol:", "model"]}),
  2121. smalltalk.HLProtocolsListWidget);
  2122. smalltalk.addMethod(
  2123. smalltalk.method({
  2124. selector: "selectedItem",
  2125. fn: function (){
  2126. var self=this;
  2127. return smalltalk.withContext(function($ctx1) {
  2128. var $1;
  2129. $1=smalltalk.HLBrowserListWidget.fn.prototype._selectedItem.apply(_st(self), []);
  2130. return $1;
  2131. }, function($ctx1) {$ctx1.fill(self,"selectedItem",{},smalltalk.HLProtocolsListWidget)})},
  2132. messageSends: ["selectedItem"]}),
  2133. smalltalk.HLProtocolsListWidget);
  2134. smalltalk.addMethod(
  2135. smalltalk.method({
  2136. selector: "setItemsForClass:",
  2137. fn: function (aClass){
  2138. var self=this;
  2139. function $Array(){return smalltalk.Array||(typeof Array=="undefined"?nil:Array)}
  2140. return smalltalk.withContext(function($ctx1) {
  2141. var $1,$3,$4,$5,$2;
  2142. $1=self;
  2143. $3=aClass;
  2144. if(($receiver = $3) == nil || $receiver == undefined){
  2145. $2=_st($Array())._with_(_st(self)._allProtocol());
  2146. } else {
  2147. $4=_st($Array())._with_(_st(self)._allProtocol());
  2148. _st($4)._addAll_(_st(aClass)._protocols());
  2149. $5=_st($4)._yourself();
  2150. $2=$5;
  2151. };
  2152. _st($1)._items_($2);
  2153. return self}, function($ctx1) {$ctx1.fill(self,"setItemsForClass:",{aClass:aClass},smalltalk.HLProtocolsListWidget)})},
  2154. messageSends: ["items:", "ifNil:ifNotNil:", "with:", "allProtocol", "addAll:", "protocols", "yourself"]}),
  2155. smalltalk.HLProtocolsListWidget);
  2156. smalltalk.addMethod(
  2157. smalltalk.method({
  2158. selector: "setItemsForSelectedClass",
  2159. fn: function (){
  2160. var self=this;
  2161. return smalltalk.withContext(function($ctx1) {
  2162. _st(self)._setItemsForClass_(_st(_st(self)._model())._selectedClass());
  2163. return self}, function($ctx1) {$ctx1.fill(self,"setItemsForSelectedClass",{},smalltalk.HLProtocolsListWidget)})},
  2164. messageSends: ["setItemsForClass:", "selectedClass", "model"]}),
  2165. smalltalk.HLProtocolsListWidget);
  2166. smalltalk.addClass('HLBrowserModel', smalltalk.HLModel, ['selectedPackage', 'selectedClass', 'selectedProtocol', 'selectedSelector', 'showInstance', 'showComment'], 'Helios-Browser');
  2167. smalltalk.addMethod(
  2168. smalltalk.method({
  2169. selector: "addInstVarNamed:",
  2170. fn: function (aString){
  2171. var self=this;
  2172. function $HLInstVarAdded(){return smalltalk.HLInstVarAdded||(typeof HLInstVarAdded=="undefined"?nil:HLInstVarAdded)}
  2173. return smalltalk.withContext(function($ctx1) {
  2174. var $1,$2;
  2175. _st(_st(self)._environment())._addInstVarNamed_to_(aString,_st(self)._selectedClass());
  2176. $1=_st($HLInstVarAdded())._new();
  2177. _st($1)._theClass_(_st(self)._selectedClass());
  2178. _st($1)._variableName_(aString);
  2179. $2=_st($1)._yourself();
  2180. _st(_st(self)._announcer())._announce_($2);
  2181. return self}, function($ctx1) {$ctx1.fill(self,"addInstVarNamed:",{aString:aString},smalltalk.HLBrowserModel)})},
  2182. messageSends: ["addInstVarNamed:to:", "selectedClass", "environment", "announce:", "theClass:", "new", "variableName:", "yourself", "announcer"]}),
  2183. smalltalk.HLBrowserModel);
  2184. smalltalk.addMethod(
  2185. smalltalk.method({
  2186. selector: "allProtocol",
  2187. fn: function (){
  2188. var self=this;
  2189. return smalltalk.withContext(function($ctx1) {
  2190. return "-- all --";
  2191. }, function($ctx1) {$ctx1.fill(self,"allProtocol",{},smalltalk.HLBrowserModel)})},
  2192. messageSends: []}),
  2193. smalltalk.HLBrowserModel);
  2194. smalltalk.addMethod(
  2195. smalltalk.method({
  2196. selector: "allSelectors",
  2197. fn: function (){
  2198. var self=this;
  2199. return smalltalk.withContext(function($ctx1) {
  2200. var $1;
  2201. $1=_st(_st(self)._environment())._allSelectors();
  2202. return $1;
  2203. }, function($ctx1) {$ctx1.fill(self,"allSelectors",{},smalltalk.HLBrowserModel)})},
  2204. messageSends: ["allSelectors", "environment"]}),
  2205. smalltalk.HLBrowserModel);
  2206. smalltalk.addMethod(
  2207. smalltalk.method({
  2208. selector: "availableClassNames",
  2209. fn: function (){
  2210. var self=this;
  2211. return smalltalk.withContext(function($ctx1) {
  2212. var $1;
  2213. $1=_st(_st(self)._environment())._availableClassNames();
  2214. return $1;
  2215. }, function($ctx1) {$ctx1.fill(self,"availableClassNames",{},smalltalk.HLBrowserModel)})},
  2216. messageSends: ["availableClassNames", "environment"]}),
  2217. smalltalk.HLBrowserModel);
  2218. smalltalk.addMethod(
  2219. smalltalk.method({
  2220. selector: "availablePackageNames",
  2221. fn: function (){
  2222. var self=this;
  2223. return smalltalk.withContext(function($ctx1) {
  2224. var $1;
  2225. $1=_st(_st(self)._environment())._availablePackageNames();
  2226. return $1;
  2227. }, function($ctx1) {$ctx1.fill(self,"availablePackageNames",{},smalltalk.HLBrowserModel)})},
  2228. messageSends: ["availablePackageNames", "environment"]}),
  2229. smalltalk.HLBrowserModel);
  2230. smalltalk.addMethod(
  2231. smalltalk.method({
  2232. selector: "availablePackages",
  2233. fn: function (){
  2234. var self=this;
  2235. return smalltalk.withContext(function($ctx1) {
  2236. var $1;
  2237. $1=_st(_st(self)._environment())._availablePackageNames();
  2238. return $1;
  2239. }, function($ctx1) {$ctx1.fill(self,"availablePackages",{},smalltalk.HLBrowserModel)})},
  2240. messageSends: ["availablePackageNames", "environment"]}),
  2241. smalltalk.HLBrowserModel);
  2242. smalltalk.addMethod(
  2243. smalltalk.method({
  2244. selector: "availableProtocols",
  2245. fn: function (){
  2246. var self=this;
  2247. return smalltalk.withContext(function($ctx1) {
  2248. var $1;
  2249. $1=_st(_st(self)._environment())._availableProtocolsFor_(_st(self)._selectedClass());
  2250. return $1;
  2251. }, function($ctx1) {$ctx1.fill(self,"availableProtocols",{},smalltalk.HLBrowserModel)})},
  2252. messageSends: ["availableProtocolsFor:", "selectedClass", "environment"]}),
  2253. smalltalk.HLBrowserModel);
  2254. smalltalk.addMethod(
  2255. smalltalk.method({
  2256. selector: "commitPackage",
  2257. fn: function (){
  2258. var self=this;
  2259. return smalltalk.withContext(function($ctx1) {
  2260. _st(self)._withHelperLabelled_do_(_st(_st("Committing package ").__comma(_st(_st(self)._selectedPackage())._name())).__comma("..."),(function(){
  2261. return smalltalk.withContext(function($ctx2) {
  2262. return _st(_st(self)._environment())._commitPackage_(_st(self)._selectedPackage());
  2263. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  2264. return self}, function($ctx1) {$ctx1.fill(self,"commitPackage",{},smalltalk.HLBrowserModel)})},
  2265. messageSends: ["withHelperLabelled:do:", ",", "name", "selectedPackage", "commitPackage:", "environment"]}),
  2266. smalltalk.HLBrowserModel);
  2267. smalltalk.addMethod(
  2268. smalltalk.method({
  2269. selector: "compilationProtocol",
  2270. fn: function (){
  2271. var self=this;
  2272. var currentProtocol;
  2273. return smalltalk.withContext(function($ctx1) {
  2274. var $1,$2,$4,$3;
  2275. currentProtocol=_st(self)._selectedProtocol();
  2276. $1=currentProtocol;
  2277. if(($receiver = $1) == nil || $receiver == undefined){
  2278. currentProtocol=_st(self)._unclassifiedProtocol();
  2279. currentProtocol;
  2280. } else {
  2281. $1;
  2282. };
  2283. $2=_st(self)._selectedMethod();
  2284. if(($receiver = $2) == nil || $receiver == undefined){
  2285. $2;
  2286. } else {
  2287. currentProtocol=_st(_st(self)._selectedMethod())._protocol();
  2288. currentProtocol;
  2289. };
  2290. $4=_st(currentProtocol).__eq(_st(self)._allProtocol());
  2291. if(smalltalk.assert($4)){
  2292. $3=_st(self)._unclassifiedProtocol();
  2293. } else {
  2294. $3=currentProtocol;
  2295. };
  2296. return $3;
  2297. }, function($ctx1) {$ctx1.fill(self,"compilationProtocol",{currentProtocol:currentProtocol},smalltalk.HLBrowserModel)})},
  2298. messageSends: ["selectedProtocol", "ifNil:", "unclassifiedProtocol", "ifNotNil:", "protocol", "selectedMethod", "ifTrue:ifFalse:", "=", "allProtocol"]}),
  2299. smalltalk.HLBrowserModel);
  2300. smalltalk.addMethod(
  2301. smalltalk.method({
  2302. selector: "compileClassComment:",
  2303. fn: function (aString){
  2304. var self=this;
  2305. return smalltalk.withContext(function($ctx1) {
  2306. _st(_st(self)._environment())._compileClassComment_for_(aString,_st(self)._selectedClass());
  2307. return self}, function($ctx1) {$ctx1.fill(self,"compileClassComment:",{aString:aString},smalltalk.HLBrowserModel)})},
  2308. messageSends: ["compileClassComment:for:", "selectedClass", "environment"]}),
  2309. smalltalk.HLBrowserModel);
  2310. smalltalk.addMethod(
  2311. smalltalk.method({
  2312. selector: "compileClassDefinition:",
  2313. fn: function (aString){
  2314. var self=this;
  2315. return smalltalk.withContext(function($ctx1) {
  2316. _st(_st(self)._environment())._compileClassDefinition_(aString);
  2317. return self}, function($ctx1) {$ctx1.fill(self,"compileClassDefinition:",{aString:aString},smalltalk.HLBrowserModel)})},
  2318. messageSends: ["compileClassDefinition:", "environment"]}),
  2319. smalltalk.HLBrowserModel);
  2320. smalltalk.addMethod(
  2321. smalltalk.method({
  2322. selector: "compileMethod:",
  2323. fn: function (aString){
  2324. var self=this;
  2325. var method;
  2326. return smalltalk.withContext(function($ctx1) {
  2327. _st(self)._withCompileErrorHandling_((function(){
  2328. return smalltalk.withContext(function($ctx2) {
  2329. method=_st(_st(self)._environment())._compileMethod_for_protocol_(aString,_st(self)._selectedClass(),_st(self)._compilationProtocol());
  2330. method;
  2331. return _st(self)._selectedMethod_(method);
  2332. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  2333. return self}, function($ctx1) {$ctx1.fill(self,"compileMethod:",{aString:aString,method:method},smalltalk.HLBrowserModel)})},
  2334. messageSends: ["withCompileErrorHandling:", "compileMethod:for:protocol:", "selectedClass", "compilationProtocol", "environment", "selectedMethod:"]}),
  2335. smalltalk.HLBrowserModel);
  2336. smalltalk.addMethod(
  2337. smalltalk.method({
  2338. selector: "copyClassTo:",
  2339. fn: function (aClassName){
  2340. var self=this;
  2341. return smalltalk.withContext(function($ctx1) {
  2342. _st(self)._withChangesDo_((function(){
  2343. return smalltalk.withContext(function($ctx2) {
  2344. return _st(_st(self)._environment())._copyClass_to_(_st(_st(self)._selectedClass())._theNonMetaClass(),aClassName);
  2345. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  2346. return self}, function($ctx1) {$ctx1.fill(self,"copyClassTo:",{aClassName:aClassName},smalltalk.HLBrowserModel)})},
  2347. messageSends: ["withChangesDo:", "copyClass:to:", "theNonMetaClass", "selectedClass", "environment"]}),
  2348. smalltalk.HLBrowserModel);
  2349. smalltalk.addMethod(
  2350. smalltalk.method({
  2351. selector: "focusOnClasses",
  2352. fn: function (){
  2353. var self=this;
  2354. function $HLClassesFocusRequested(){return smalltalk.HLClassesFocusRequested||(typeof HLClassesFocusRequested=="undefined"?nil:HLClassesFocusRequested)}
  2355. return smalltalk.withContext(function($ctx1) {
  2356. _st(_st(self)._announcer())._announce_(_st($HLClassesFocusRequested())._new());
  2357. return self}, function($ctx1) {$ctx1.fill(self,"focusOnClasses",{},smalltalk.HLBrowserModel)})},
  2358. messageSends: ["announce:", "new", "announcer"]}),
  2359. smalltalk.HLBrowserModel);
  2360. smalltalk.addMethod(
  2361. smalltalk.method({
  2362. selector: "focusOnMethods",
  2363. fn: function (){
  2364. var self=this;
  2365. function $HLMethodsFocusRequested(){return smalltalk.HLMethodsFocusRequested||(typeof HLMethodsFocusRequested=="undefined"?nil:HLMethodsFocusRequested)}
  2366. return smalltalk.withContext(function($ctx1) {
  2367. _st(_st(self)._announcer())._announce_(_st($HLMethodsFocusRequested())._new());
  2368. return self}, function($ctx1) {$ctx1.fill(self,"focusOnMethods",{},smalltalk.HLBrowserModel)})},
  2369. messageSends: ["announce:", "new", "announcer"]}),
  2370. smalltalk.HLBrowserModel);
  2371. smalltalk.addMethod(
  2372. smalltalk.method({
  2373. selector: "focusOnPackages",
  2374. fn: function (){
  2375. var self=this;
  2376. function $HLPackagesFocusRequested(){return smalltalk.HLPackagesFocusRequested||(typeof HLPackagesFocusRequested=="undefined"?nil:HLPackagesFocusRequested)}
  2377. return smalltalk.withContext(function($ctx1) {
  2378. _st(_st(self)._announcer())._announce_(_st($HLPackagesFocusRequested())._new());
  2379. return self}, function($ctx1) {$ctx1.fill(self,"focusOnPackages",{},smalltalk.HLBrowserModel)})},
  2380. messageSends: ["announce:", "new", "announcer"]}),
  2381. smalltalk.HLBrowserModel);
  2382. smalltalk.addMethod(
  2383. smalltalk.method({
  2384. selector: "focusOnProtocols",
  2385. fn: function (){
  2386. var self=this;
  2387. function $HLProtocolsFocusRequested(){return smalltalk.HLProtocolsFocusRequested||(typeof HLProtocolsFocusRequested=="undefined"?nil:HLProtocolsFocusRequested)}
  2388. return smalltalk.withContext(function($ctx1) {
  2389. _st(_st(self)._announcer())._announce_(_st($HLProtocolsFocusRequested())._new());
  2390. return self}, function($ctx1) {$ctx1.fill(self,"focusOnProtocols",{},smalltalk.HLBrowserModel)})},
  2391. messageSends: ["announce:", "new", "announcer"]}),
  2392. smalltalk.HLBrowserModel);
  2393. smalltalk.addMethod(
  2394. smalltalk.method({
  2395. selector: "focusOnSourceCode",
  2396. fn: function (){
  2397. var self=this;
  2398. function $HLSourceCodeFocusRequested(){return smalltalk.HLSourceCodeFocusRequested||(typeof HLSourceCodeFocusRequested=="undefined"?nil:HLSourceCodeFocusRequested)}
  2399. return smalltalk.withContext(function($ctx1) {
  2400. _st(_st(self)._announcer())._announce_(_st($HLSourceCodeFocusRequested())._new());
  2401. return self}, function($ctx1) {$ctx1.fill(self,"focusOnSourceCode",{},smalltalk.HLBrowserModel)})},
  2402. messageSends: ["announce:", "new", "announcer"]}),
  2403. smalltalk.HLBrowserModel);
  2404. smalltalk.addMethod(
  2405. smalltalk.method({
  2406. selector: "handleCompileError:",
  2407. fn: function (anError){
  2408. var self=this;
  2409. function $HLCompileErrorRaised(){return smalltalk.HLCompileErrorRaised||(typeof HLCompileErrorRaised=="undefined"?nil:HLCompileErrorRaised)}
  2410. return smalltalk.withContext(function($ctx1) {
  2411. var $1,$2;
  2412. $1=_st($HLCompileErrorRaised())._new();
  2413. _st($1)._error_(anError);
  2414. $2=_st($1)._yourself();
  2415. _st(_st(self)._announcer())._announce_($2);
  2416. return self}, function($ctx1) {$ctx1.fill(self,"handleCompileError:",{anError:anError},smalltalk.HLBrowserModel)})},
  2417. messageSends: ["announce:", "error:", "new", "yourself", "announcer"]}),
  2418. smalltalk.HLBrowserModel);
  2419. smalltalk.addMethod(
  2420. smalltalk.method({
  2421. selector: "handleParseError:",
  2422. fn: function (anError){
  2423. var self=this;
  2424. var split,line,column,messageToInsert;
  2425. function $HLParseErrorRaised(){return smalltalk.HLParseErrorRaised||(typeof HLParseErrorRaised=="undefined"?nil:HLParseErrorRaised)}
  2426. return smalltalk.withContext(function($ctx1) {
  2427. var $1,$2;
  2428. split=_st(_st(anError)._messageText())._tokenize_(" : ");
  2429. messageToInsert=_st(split)._second();
  2430. split=_st(_st(split)._first())._copyFrom_to_((21),_st(_st(split)._first())._size());
  2431. split=_st(split)._tokenize_(" column ");
  2432. line=_st(split)._first();
  2433. column=_st(split)._second();
  2434. $1=_st($HLParseErrorRaised())._new();
  2435. _st($1)._line_(_st(line)._asNumber());
  2436. _st($1)._column_(_st(column)._asNumber());
  2437. _st($1)._message_(messageToInsert);
  2438. _st($1)._error_(anError);
  2439. $2=_st($1)._yourself();
  2440. _st(_st(self)._announcer())._announce_($2);
  2441. return self}, function($ctx1) {$ctx1.fill(self,"handleParseError:",{anError:anError,split:split,line:line,column:column,messageToInsert:messageToInsert},smalltalk.HLBrowserModel)})},
  2442. messageSends: ["tokenize:", "messageText", "second", "copyFrom:to:", "size", "first", "announce:", "line:", "asNumber", "new", "column:", "message:", "error:", "yourself", "announcer"]}),
  2443. smalltalk.HLBrowserModel);
  2444. smalltalk.addMethod(
  2445. smalltalk.method({
  2446. selector: "handleUnkownVariableError:",
  2447. fn: function (anError){
  2448. var self=this;
  2449. function $HLUnknownVariableErrorRaised(){return smalltalk.HLUnknownVariableErrorRaised||(typeof HLUnknownVariableErrorRaised=="undefined"?nil:HLUnknownVariableErrorRaised)}
  2450. return smalltalk.withContext(function($ctx1) {
  2451. var $1,$2;
  2452. $1=_st($HLUnknownVariableErrorRaised())._new();
  2453. _st($1)._error_(anError);
  2454. $2=_st($1)._yourself();
  2455. _st(_st(self)._announcer())._announce_($2);
  2456. return self}, function($ctx1) {$ctx1.fill(self,"handleUnkownVariableError:",{anError:anError},smalltalk.HLBrowserModel)})},
  2457. messageSends: ["announce:", "error:", "new", "yourself", "announcer"]}),
  2458. smalltalk.HLBrowserModel);
  2459. smalltalk.addMethod(
  2460. smalltalk.method({
  2461. selector: "moveClassToPackage:",
  2462. fn: function (aPackageName){
  2463. var self=this;
  2464. return smalltalk.withContext(function($ctx1) {
  2465. _st(self)._withChangesDo_((function(){
  2466. return smalltalk.withContext(function($ctx2) {
  2467. return _st(_st(self)._environment())._moveClass_toPackage_(_st(_st(self)._selectedClass())._theNonMetaClass(),aPackageName);
  2468. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  2469. return self}, function($ctx1) {$ctx1.fill(self,"moveClassToPackage:",{aPackageName:aPackageName},smalltalk.HLBrowserModel)})},
  2470. messageSends: ["withChangesDo:", "moveClass:toPackage:", "theNonMetaClass", "selectedClass", "environment"]}),
  2471. smalltalk.HLBrowserModel);
  2472. smalltalk.addMethod(
  2473. smalltalk.method({
  2474. selector: "moveMethodToClass:",
  2475. fn: function (aClassName){
  2476. var self=this;
  2477. return smalltalk.withContext(function($ctx1) {
  2478. _st(self)._withChangesDo_((function(){
  2479. return smalltalk.withContext(function($ctx2) {
  2480. return _st(_st(self)._environment())._moveMethod_toClass_(_st(self)._selectedMethod(),aClassName);
  2481. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  2482. return self}, function($ctx1) {$ctx1.fill(self,"moveMethodToClass:",{aClassName:aClassName},smalltalk.HLBrowserModel)})},
  2483. messageSends: ["withChangesDo:", "moveMethod:toClass:", "selectedMethod", "environment"]}),
  2484. smalltalk.HLBrowserModel);
  2485. smalltalk.addMethod(
  2486. smalltalk.method({
  2487. selector: "moveMethodToProtocol:",
  2488. fn: function (aProtocol){
  2489. var self=this;
  2490. return smalltalk.withContext(function($ctx1) {
  2491. _st(self)._withChangesDo_((function(){
  2492. return smalltalk.withContext(function($ctx2) {
  2493. return _st(_st(self)._environment())._moveMethod_toProtocol_(_st(self)._selectedMethod(),aProtocol);
  2494. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  2495. return self}, function($ctx1) {$ctx1.fill(self,"moveMethodToProtocol:",{aProtocol:aProtocol},smalltalk.HLBrowserModel)})},
  2496. messageSends: ["withChangesDo:", "moveMethod:toProtocol:", "selectedMethod", "environment"]}),
  2497. smalltalk.HLBrowserModel);
  2498. smalltalk.addMethod(
  2499. smalltalk.method({
  2500. selector: "openClassNamed:",
  2501. fn: function (aString){
  2502. var self=this;
  2503. var class_;
  2504. return smalltalk.withContext(function($ctx1) {
  2505. _st(self)._withChangesDo_((function(){
  2506. return smalltalk.withContext(function($ctx2) {
  2507. class_=_st(_st(self)._environment())._classNamed_(aString);
  2508. class_;
  2509. _st(self)._selectedPackage_(_st(class_)._package());
  2510. return _st(self)._selectedClass_(class_);
  2511. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  2512. return self}, function($ctx1) {$ctx1.fill(self,"openClassNamed:",{aString:aString,class_:class_},smalltalk.HLBrowserModel)})},
  2513. messageSends: ["withChangesDo:", "classNamed:", "environment", "selectedPackage:", "package", "selectedClass:"]}),
  2514. smalltalk.HLBrowserModel);
  2515. smalltalk.addMethod(
  2516. smalltalk.method({
  2517. selector: "packages",
  2518. fn: function (){
  2519. var self=this;
  2520. return smalltalk.withContext(function($ctx1) {
  2521. var $1;
  2522. $1=_st(_st(self)._environment())._packages();
  2523. return $1;
  2524. }, function($ctx1) {$ctx1.fill(self,"packages",{},smalltalk.HLBrowserModel)})},
  2525. messageSends: ["packages", "environment"]}),
  2526. smalltalk.HLBrowserModel);
  2527. smalltalk.addMethod(
  2528. smalltalk.method({
  2529. selector: "removeClass",
  2530. fn: function (){
  2531. var self=this;
  2532. return smalltalk.withContext(function($ctx1) {
  2533. _st(self)._withChangesDo_((function(){
  2534. return smalltalk.withContext(function($ctx2) {
  2535. return _st(_st(self)._manager())._confirm_ifTrue_(_st("Do you REALLY want to remove class ").__comma(_st(_st(self)._selectedClass())._name()),(function(){
  2536. return smalltalk.withContext(function($ctx3) {
  2537. return _st(_st(self)._environment())._removeClass_(_st(self)._selectedClass());
  2538. }, function($ctx3) {$ctx3.fillBlock({},$ctx1)})}));
  2539. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  2540. return self}, function($ctx1) {$ctx1.fill(self,"removeClass",{},smalltalk.HLBrowserModel)})},
  2541. messageSends: ["withChangesDo:", "confirm:ifTrue:", ",", "name", "selectedClass", "removeClass:", "environment", "manager"]}),
  2542. smalltalk.HLBrowserModel);
  2543. smalltalk.addMethod(
  2544. smalltalk.method({
  2545. selector: "removeMethod",
  2546. fn: function (){
  2547. var self=this;
  2548. return smalltalk.withContext(function($ctx1) {
  2549. _st(self)._withChangesDo_((function(){
  2550. return smalltalk.withContext(function($ctx2) {
  2551. return _st(_st(self)._manager())._confirm_ifTrue_(_st(_st(_st("Do you REALLY want to remove method ").__comma(_st(_st(_st(self)._selectedMethod())._methodClass())._name())).__comma(" >> #")).__comma(_st(_st(self)._selectedMethod())._selector()),(function(){
  2552. return smalltalk.withContext(function($ctx3) {
  2553. return _st(_st(self)._environment())._removeMethod_(_st(self)._selectedMethod());
  2554. }, function($ctx3) {$ctx3.fillBlock({},$ctx1)})}));
  2555. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  2556. return self}, function($ctx1) {$ctx1.fill(self,"removeMethod",{},smalltalk.HLBrowserModel)})},
  2557. messageSends: ["withChangesDo:", "confirm:ifTrue:", ",", "selector", "selectedMethod", "name", "methodClass", "removeMethod:", "environment", "manager"]}),
  2558. smalltalk.HLBrowserModel);
  2559. smalltalk.addMethod(
  2560. smalltalk.method({
  2561. selector: "removeProtocol",
  2562. fn: function (){
  2563. var self=this;
  2564. return smalltalk.withContext(function($ctx1) {
  2565. _st(self)._withChangesDo_((function(){
  2566. return smalltalk.withContext(function($ctx2) {
  2567. return _st(_st(self)._manager())._confirm_ifTrue_(_st("Do you REALLY want to remove protocol ").__comma(_st(self)._selectedProtocol()),(function(){
  2568. return smalltalk.withContext(function($ctx3) {
  2569. return _st(_st(self)._environment())._removeProtocol_from_(_st(self)._selectedProtocol(),_st(self)._selectedClass());
  2570. }, function($ctx3) {$ctx3.fillBlock({},$ctx1)})}));
  2571. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  2572. return self}, function($ctx1) {$ctx1.fill(self,"removeProtocol",{},smalltalk.HLBrowserModel)})},
  2573. messageSends: ["withChangesDo:", "confirm:ifTrue:", ",", "selectedProtocol", "removeProtocol:from:", "selectedClass", "environment", "manager"]}),
  2574. smalltalk.HLBrowserModel);
  2575. smalltalk.addMethod(
  2576. smalltalk.method({
  2577. selector: "renameClassTo:",
  2578. fn: function (aClassName){
  2579. var self=this;
  2580. return smalltalk.withContext(function($ctx1) {
  2581. _st(self)._withChangesDo_((function(){
  2582. return smalltalk.withContext(function($ctx2) {
  2583. return _st(_st(self)._environment())._renameClass_to_(_st(_st(self)._selectedClass())._theNonMetaClass(),aClassName);
  2584. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  2585. return self}, function($ctx1) {$ctx1.fill(self,"renameClassTo:",{aClassName:aClassName},smalltalk.HLBrowserModel)})},
  2586. messageSends: ["withChangesDo:", "renameClass:to:", "theNonMetaClass", "selectedClass", "environment"]}),
  2587. smalltalk.HLBrowserModel);
  2588. smalltalk.addMethod(
  2589. smalltalk.method({
  2590. selector: "renameProtocolTo:",
  2591. fn: function (aString){
  2592. var self=this;
  2593. return smalltalk.withContext(function($ctx1) {
  2594. _st(self)._withChangesDo_((function(){
  2595. return smalltalk.withContext(function($ctx2) {
  2596. return _st(_st(self)._environment())._renameProtocol_to_in_(_st(self)._selectedProtocol(),aString,_st(self)._selectedClass());
  2597. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  2598. return self}, function($ctx1) {$ctx1.fill(self,"renameProtocolTo:",{aString:aString},smalltalk.HLBrowserModel)})},
  2599. messageSends: ["withChangesDo:", "renameProtocol:to:in:", "selectedProtocol", "selectedClass", "environment"]}),
  2600. smalltalk.HLBrowserModel);
  2601. smalltalk.addMethod(
  2602. smalltalk.method({
  2603. selector: "save:",
  2604. fn: function (aString){
  2605. var self=this;
  2606. function $HLSourceCodeSaved(){return smalltalk.HLSourceCodeSaved||(typeof HLSourceCodeSaved=="undefined"?nil:HLSourceCodeSaved)}
  2607. return smalltalk.withContext(function($ctx1) {
  2608. var $1;
  2609. _st(_st(self)._announcer())._announce_(_st($HLSourceCodeSaved())._new());
  2610. $1=_st(self)._shouldCompileClassDefinition_(aString);
  2611. if(smalltalk.assert($1)){
  2612. _st(self)._compileClassDefinition_(aString);
  2613. } else {
  2614. _st(self)._compileMethod_(aString);
  2615. };
  2616. return self}, function($ctx1) {$ctx1.fill(self,"save:",{aString:aString},smalltalk.HLBrowserModel)})},
  2617. messageSends: ["announce:", "new", "announcer", "ifTrue:ifFalse:", "compileClassDefinition:", "compileMethod:", "shouldCompileClassDefinition:"]}),
  2618. smalltalk.HLBrowserModel);
  2619. smalltalk.addMethod(
  2620. smalltalk.method({
  2621. selector: "saveSourceCode",
  2622. fn: function (){
  2623. var self=this;
  2624. function $HLSaveSourceCode(){return smalltalk.HLSaveSourceCode||(typeof HLSaveSourceCode=="undefined"?nil:HLSaveSourceCode)}
  2625. return smalltalk.withContext(function($ctx1) {
  2626. _st(_st(self)._announcer())._announce_(_st($HLSaveSourceCode())._new());
  2627. return self}, function($ctx1) {$ctx1.fill(self,"saveSourceCode",{},smalltalk.HLBrowserModel)})},
  2628. messageSends: ["announce:", "new", "announcer"]}),
  2629. smalltalk.HLBrowserModel);
  2630. smalltalk.addMethod(
  2631. smalltalk.method({
  2632. selector: "selectedClass",
  2633. fn: function (){
  2634. var self=this;
  2635. return smalltalk.withContext(function($ctx1) {
  2636. var $1;
  2637. $1=self["@selectedClass"];
  2638. return $1;
  2639. }, function($ctx1) {$ctx1.fill(self,"selectedClass",{},smalltalk.HLBrowserModel)})},
  2640. messageSends: []}),
  2641. smalltalk.HLBrowserModel);
  2642. smalltalk.addMethod(
  2643. smalltalk.method({
  2644. selector: "selectedClass:",
  2645. fn: function (aClass){
  2646. var self=this;
  2647. function $HLClassSelected(){return smalltalk.HLClassSelected||(typeof HLClassSelected=="undefined"?nil:HLClassSelected)}
  2648. return smalltalk.withContext(function($ctx1) {
  2649. var $1,$2,$3,$4,$5;
  2650. $1=_st(_st(_st(self)._selectedClass()).__eq(aClass))._and_((function(){
  2651. return smalltalk.withContext(function($ctx2) {
  2652. return _st(aClass)._isNil();
  2653. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  2654. if(smalltalk.assert($1)){
  2655. $2=self;
  2656. return $2;
  2657. };
  2658. _st(self)._withChangesDo_((function(){
  2659. return smalltalk.withContext(function($ctx2) {
  2660. $3=_st(self["@selectedClass"]).__eq(aClass);
  2661. if(smalltalk.assert($3)){
  2662. _st(self)._selectedProtocol_(nil);
  2663. };
  2664. $4=aClass;
  2665. if(($receiver = $4) == nil || $receiver == undefined){
  2666. self["@selectedClass"]=nil;
  2667. self["@selectedClass"];
  2668. } else {
  2669. $5=_st(self)._showInstance();
  2670. if(smalltalk.assert($5)){
  2671. self["@selectedClass"]=_st(aClass)._theNonMetaClass();
  2672. self["@selectedClass"];
  2673. } else {
  2674. self["@selectedClass"]=_st(aClass)._theMetaClass();
  2675. self["@selectedClass"];
  2676. };
  2677. };
  2678. _st(self)._selectedProtocol_(nil);
  2679. return _st(_st(self)._announcer())._announce_(_st($HLClassSelected())._on_(_st(self)._selectedClass()));
  2680. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  2681. return self}, function($ctx1) {$ctx1.fill(self,"selectedClass:",{aClass:aClass},smalltalk.HLBrowserModel)})},
  2682. messageSends: ["ifTrue:", "and:", "isNil", "=", "selectedClass", "withChangesDo:", "selectedProtocol:", "ifNil:ifNotNil:", "ifTrue:ifFalse:", "theNonMetaClass", "theMetaClass", "showInstance", "announce:", "on:", "announcer"]}),
  2683. smalltalk.HLBrowserModel);
  2684. smalltalk.addMethod(
  2685. smalltalk.method({
  2686. selector: "selectedMethod",
  2687. fn: function (){
  2688. var self=this;
  2689. return smalltalk.withContext(function($ctx1) {
  2690. var $2,$1;
  2691. $2=_st(self)._selectedClass();
  2692. if(($receiver = $2) == nil || $receiver == undefined){
  2693. $1=$2;
  2694. } else {
  2695. $1=_st(_st(_st(self)._selectedClass())._methodDictionary())._at_ifAbsent_(self["@selectedSelector"],(function(){
  2696. return smalltalk.withContext(function($ctx2) {
  2697. return nil;
  2698. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  2699. };
  2700. return $1;
  2701. }, function($ctx1) {$ctx1.fill(self,"selectedMethod",{},smalltalk.HLBrowserModel)})},
  2702. messageSends: ["ifNotNil:", "at:ifAbsent:", "methodDictionary", "selectedClass"]}),
  2703. smalltalk.HLBrowserModel);
  2704. smalltalk.addMethod(
  2705. smalltalk.method({
  2706. selector: "selectedMethod:",
  2707. fn: function (aCompiledMethod){
  2708. var self=this;
  2709. function $HLMethodSelected(){return smalltalk.HLMethodSelected||(typeof HLMethodSelected=="undefined"?nil:HLMethodSelected)}
  2710. return smalltalk.withContext(function($ctx1) {
  2711. var $1,$2,$3;
  2712. $1=_st(self["@selectedSelector"]).__eq(aCompiledMethod);
  2713. if(smalltalk.assert($1)){
  2714. $2=self;
  2715. return $2;
  2716. };
  2717. _st(self)._withChangesDo_((function(){
  2718. return smalltalk.withContext(function($ctx2) {
  2719. $3=aCompiledMethod;
  2720. if(($receiver = $3) == nil || $receiver == undefined){
  2721. self["@selectedSelector"]=nil;
  2722. self["@selectedSelector"];
  2723. } else {
  2724. self["@selectedSelector"]=_st(aCompiledMethod)._selector();
  2725. self["@selectedSelector"];
  2726. };
  2727. return _st(_st(self)._announcer())._announce_(_st($HLMethodSelected())._on_(aCompiledMethod));
  2728. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  2729. return self}, function($ctx1) {$ctx1.fill(self,"selectedMethod:",{aCompiledMethod:aCompiledMethod},smalltalk.HLBrowserModel)})},
  2730. messageSends: ["ifTrue:", "=", "withChangesDo:", "ifNil:ifNotNil:", "selector", "announce:", "on:", "announcer"]}),
  2731. smalltalk.HLBrowserModel);
  2732. smalltalk.addMethod(
  2733. smalltalk.method({
  2734. selector: "selectedPackage",
  2735. fn: function (){
  2736. var self=this;
  2737. return smalltalk.withContext(function($ctx1) {
  2738. var $1;
  2739. $1=self["@selectedPackage"];
  2740. return $1;
  2741. }, function($ctx1) {$ctx1.fill(self,"selectedPackage",{},smalltalk.HLBrowserModel)})},
  2742. messageSends: []}),
  2743. smalltalk.HLBrowserModel);
  2744. smalltalk.addMethod(
  2745. smalltalk.method({
  2746. selector: "selectedPackage:",
  2747. fn: function (aPackage){
  2748. var self=this;
  2749. function $HLPackageSelected(){return smalltalk.HLPackageSelected||(typeof HLPackageSelected=="undefined"?nil:HLPackageSelected)}
  2750. return smalltalk.withContext(function($ctx1) {
  2751. var $1,$2;
  2752. $1=_st(self["@selectedPackage"]).__eq(aPackage);
  2753. if(smalltalk.assert($1)){
  2754. $2=self;
  2755. return $2;
  2756. };
  2757. _st(self)._withChangesDo_((function(){
  2758. return smalltalk.withContext(function($ctx2) {
  2759. self["@selectedPackage"]=aPackage;
  2760. self["@selectedPackage"];
  2761. _st(self)._selectedClass_(nil);
  2762. return _st(_st(self)._announcer())._announce_(_st($HLPackageSelected())._on_(aPackage));
  2763. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  2764. return self}, function($ctx1) {$ctx1.fill(self,"selectedPackage:",{aPackage:aPackage},smalltalk.HLBrowserModel)})},
  2765. messageSends: ["ifTrue:", "=", "withChangesDo:", "selectedClass:", "announce:", "on:", "announcer"]}),
  2766. smalltalk.HLBrowserModel);
  2767. smalltalk.addMethod(
  2768. smalltalk.method({
  2769. selector: "selectedProtocol",
  2770. fn: function (){
  2771. var self=this;
  2772. return smalltalk.withContext(function($ctx1) {
  2773. var $1;
  2774. $1=self["@selectedProtocol"];
  2775. return $1;
  2776. }, function($ctx1) {$ctx1.fill(self,"selectedProtocol",{},smalltalk.HLBrowserModel)})},
  2777. messageSends: []}),
  2778. smalltalk.HLBrowserModel);
  2779. smalltalk.addMethod(
  2780. smalltalk.method({
  2781. selector: "selectedProtocol:",
  2782. fn: function (aString){
  2783. var self=this;
  2784. function $HLProtocolSelected(){return smalltalk.HLProtocolSelected||(typeof HLProtocolSelected=="undefined"?nil:HLProtocolSelected)}
  2785. return smalltalk.withContext(function($ctx1) {
  2786. var $1,$2;
  2787. $1=_st(self["@selectedProtocol"]).__eq(aString);
  2788. if(smalltalk.assert($1)){
  2789. $2=self;
  2790. return $2;
  2791. };
  2792. _st(self)._withChangesDo_((function(){
  2793. return smalltalk.withContext(function($ctx2) {
  2794. self["@selectedProtocol"]=aString;
  2795. self["@selectedProtocol"];
  2796. _st(self)._selectedMethod_(nil);
  2797. return _st(_st(self)._announcer())._announce_(_st($HLProtocolSelected())._on_(aString));
  2798. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  2799. return self}, function($ctx1) {$ctx1.fill(self,"selectedProtocol:",{aString:aString},smalltalk.HLBrowserModel)})},
  2800. messageSends: ["ifTrue:", "=", "withChangesDo:", "selectedMethod:", "announce:", "on:", "announcer"]}),
  2801. smalltalk.HLBrowserModel);
  2802. smalltalk.addMethod(
  2803. smalltalk.method({
  2804. selector: "shouldCompileClassDefinition:",
  2805. fn: function (aString){
  2806. var self=this;
  2807. return smalltalk.withContext(function($ctx1) {
  2808. var $1;
  2809. $1=_st(_st(_st(self)._selectedClass())._isNil())._or_((function(){
  2810. return smalltalk.withContext(function($ctx2) {
  2811. return _st(_st(_st(aString)._first())._asUppercase()).__eq(_st(aString)._first());
  2812. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  2813. return $1;
  2814. }, function($ctx1) {$ctx1.fill(self,"shouldCompileClassDefinition:",{aString:aString},smalltalk.HLBrowserModel)})},
  2815. messageSends: ["or:", "=", "first", "asUppercase", "isNil", "selectedClass"]}),
  2816. smalltalk.HLBrowserModel);
  2817. smalltalk.addMethod(
  2818. smalltalk.method({
  2819. selector: "showComment",
  2820. fn: function (){
  2821. var self=this;
  2822. return smalltalk.withContext(function($ctx1) {
  2823. var $2,$1;
  2824. $2=self["@showComment"];
  2825. if(($receiver = $2) == nil || $receiver == undefined){
  2826. $1=false;
  2827. } else {
  2828. $1=$2;
  2829. };
  2830. return $1;
  2831. }, function($ctx1) {$ctx1.fill(self,"showComment",{},smalltalk.HLBrowserModel)})},
  2832. messageSends: ["ifNil:"]}),
  2833. smalltalk.HLBrowserModel);
  2834. smalltalk.addMethod(
  2835. smalltalk.method({
  2836. selector: "showComment:",
  2837. fn: function (aBoolean){
  2838. var self=this;
  2839. function $HLShowCommentToggled(){return smalltalk.HLShowCommentToggled||(typeof HLShowCommentToggled=="undefined"?nil:HLShowCommentToggled)}
  2840. return smalltalk.withContext(function($ctx1) {
  2841. _st(self)._withChangesDo_((function(){
  2842. return smalltalk.withContext(function($ctx2) {
  2843. self["@showComment"]=aBoolean;
  2844. self["@showComment"];
  2845. return _st(_st(self)._announcer())._announce_(_st($HLShowCommentToggled())._new());
  2846. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  2847. return self}, function($ctx1) {$ctx1.fill(self,"showComment:",{aBoolean:aBoolean},smalltalk.HLBrowserModel)})},
  2848. messageSends: ["withChangesDo:", "announce:", "new", "announcer"]}),
  2849. smalltalk.HLBrowserModel);
  2850. smalltalk.addMethod(
  2851. smalltalk.method({
  2852. selector: "showInstance",
  2853. fn: function (){
  2854. var self=this;
  2855. return smalltalk.withContext(function($ctx1) {
  2856. var $2,$1;
  2857. $2=self["@showInstance"];
  2858. if(($receiver = $2) == nil || $receiver == undefined){
  2859. $1=true;
  2860. } else {
  2861. $1=$2;
  2862. };
  2863. return $1;
  2864. }, function($ctx1) {$ctx1.fill(self,"showInstance",{},smalltalk.HLBrowserModel)})},
  2865. messageSends: ["ifNil:"]}),
  2866. smalltalk.HLBrowserModel);
  2867. smalltalk.addMethod(
  2868. smalltalk.method({
  2869. selector: "showInstance:",
  2870. fn: function (aBoolean){
  2871. var self=this;
  2872. function $HLShowInstanceToggled(){return smalltalk.HLShowInstanceToggled||(typeof HLShowInstanceToggled=="undefined"?nil:HLShowInstanceToggled)}
  2873. return smalltalk.withContext(function($ctx1) {
  2874. var $1,$2,$4,$3;
  2875. _st(self)._withChangesDo_((function(){
  2876. return smalltalk.withContext(function($ctx2) {
  2877. self["@showInstance"]=aBoolean;
  2878. self["@showInstance"];
  2879. self["@showComment"]=false;
  2880. self["@showComment"];
  2881. $1=_st(self)._selectedClass();
  2882. if(($receiver = $1) == nil || $receiver == undefined){
  2883. $1;
  2884. } else {
  2885. $2=self;
  2886. $4=aBoolean;
  2887. if(smalltalk.assert($4)){
  2888. $3=_st(_st(self)._selectedClass())._theNonMetaClass();
  2889. } else {
  2890. $3=_st(_st(self)._selectedClass())._theMetaClass();
  2891. };
  2892. _st($2)._selectedClass_($3);
  2893. };
  2894. return _st(_st(self)._announcer())._announce_(_st($HLShowInstanceToggled())._new());
  2895. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  2896. return self}, function($ctx1) {$ctx1.fill(self,"showInstance:",{aBoolean:aBoolean},smalltalk.HLBrowserModel)})},
  2897. messageSends: ["withChangesDo:", "ifNotNil:", "selectedClass:", "ifTrue:ifFalse:", "theNonMetaClass", "selectedClass", "theMetaClass", "announce:", "new", "announcer"]}),
  2898. smalltalk.HLBrowserModel);
  2899. smalltalk.addMethod(
  2900. smalltalk.method({
  2901. selector: "unclassifiedProtocol",
  2902. fn: function (){
  2903. var self=this;
  2904. return smalltalk.withContext(function($ctx1) {
  2905. return "as yet unclassified";
  2906. }, function($ctx1) {$ctx1.fill(self,"unclassifiedProtocol",{},smalltalk.HLBrowserModel)})},
  2907. messageSends: []}),
  2908. smalltalk.HLBrowserModel);
  2909. smalltalk.addMethod(
  2910. smalltalk.method({
  2911. selector: "withCompileErrorHandling:",
  2912. fn: function (aBlock){
  2913. var self=this;
  2914. function $CompilerError(){return smalltalk.CompilerError||(typeof CompilerError=="undefined"?nil:CompilerError)}
  2915. function $UnknownVariableError(){return smalltalk.UnknownVariableError||(typeof UnknownVariableError=="undefined"?nil:UnknownVariableError)}
  2916. function $ParseError(){return smalltalk.ParseError||(typeof ParseError=="undefined"?nil:ParseError)}
  2917. return smalltalk.withContext(function($ctx1) {
  2918. _st((function(){
  2919. return smalltalk.withContext(function($ctx2) {
  2920. return _st((function(){
  2921. return smalltalk.withContext(function($ctx3) {
  2922. return _st(aBlock)._on_do_($ParseError(),(function(ex){
  2923. return smalltalk.withContext(function($ctx4) {
  2924. return _st(self)._handleParseError_(ex);
  2925. }, function($ctx4) {$ctx4.fillBlock({ex:ex},$ctx1)})}));
  2926. }, function($ctx3) {$ctx3.fillBlock({},$ctx1)})}))._on_do_($UnknownVariableError(),(function(ex){
  2927. return smalltalk.withContext(function($ctx3) {
  2928. return _st(self)._handleUnkownVariableError_(ex);
  2929. }, function($ctx3) {$ctx3.fillBlock({ex:ex},$ctx1)})}));
  2930. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}))._on_do_($CompilerError(),(function(ex){
  2931. return smalltalk.withContext(function($ctx2) {
  2932. return _st(self)._handleCompileError_(ex);
  2933. }, function($ctx2) {$ctx2.fillBlock({ex:ex},$ctx1)})}));
  2934. return self}, function($ctx1) {$ctx1.fill(self,"withCompileErrorHandling:",{aBlock:aBlock},smalltalk.HLBrowserModel)})},
  2935. messageSends: ["on:do:", "handleCompileError:", "handleUnkownVariableError:", "handleParseError:"]}),
  2936. smalltalk.HLBrowserModel);
  2937. smalltalk.addMethod(
  2938. smalltalk.method({
  2939. selector: "withHelperLabelled:do:",
  2940. fn: function (aString,aBlock){
  2941. var self=this;
  2942. return smalltalk.withContext(function($ctx1) {
  2943. var $1,$2;
  2944. _st(_st(window)._jQuery_("#helper"))._remove();
  2945. _st((function(html){
  2946. return smalltalk.withContext(function($ctx2) {
  2947. $1=_st(html)._div();
  2948. _st($1)._id_("helper");
  2949. $2=_st($1)._with_(aString);
  2950. return $2;
  2951. }, function($ctx2) {$ctx2.fillBlock({html:html},$ctx1)})}))._appendToJQuery_(_st("body")._asJQuery());
  2952. _st((function(){
  2953. return smalltalk.withContext(function($ctx2) {
  2954. _st(aBlock)._value();
  2955. return _st(_st(window)._jQuery_("#helper"))._remove();
  2956. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}))._valueWithTimeout_((10));
  2957. return self}, function($ctx1) {$ctx1.fill(self,"withHelperLabelled:do:",{aString:aString,aBlock:aBlock},smalltalk.HLBrowserModel)})},
  2958. messageSends: ["remove", "jQuery:", "appendToJQuery:", "asJQuery", "id:", "div", "with:", "valueWithTimeout:", "value"]}),
  2959. smalltalk.HLBrowserModel);
  2960. smalltalk.addMethod(
  2961. smalltalk.method({
  2962. selector: "on:",
  2963. fn: function (anEnvironment){
  2964. var self=this;
  2965. return smalltalk.withContext(function($ctx1) {
  2966. var $2,$3,$1;
  2967. $2=_st(self)._new();
  2968. _st($2)._environment_(anEnvironment);
  2969. $3=_st($2)._yourself();
  2970. $1=$3;
  2971. return $1;
  2972. }, function($ctx1) {$ctx1.fill(self,"on:",{anEnvironment:anEnvironment},smalltalk.HLBrowserModel.klass)})},
  2973. messageSends: ["environment:", "new", "yourself"]}),
  2974. smalltalk.HLBrowserModel.klass);
  2975. smalltalk.addClass('HLClassCache', smalltalk.Object, ['class', 'selectorsCache', 'overrideCache', 'overriddenCache'], 'Helios-Browser');
  2976. smalltalk.addMethod(
  2977. smalltalk.method({
  2978. selector: "invalidateChildrenSelector:",
  2979. fn: function (aSelector){
  2980. var self=this;
  2981. return smalltalk.withContext(function($ctx1) {
  2982. var $1,$2;
  2983. _st(_st(_st(self)._theClass())._subclasses())._do_((function(each){
  2984. return smalltalk.withContext(function($ctx2) {
  2985. $1=_st(_st(self)._selectorsCache())._cacheFor_(each);
  2986. _st($1)._removeSelector_(aSelector);
  2987. $2=_st($1)._invalidateChildrenSelector_(aSelector);
  2988. return $2;
  2989. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})}));
  2990. return self}, function($ctx1) {$ctx1.fill(self,"invalidateChildrenSelector:",{aSelector:aSelector},smalltalk.HLClassCache)})},
  2991. messageSends: ["do:", "removeSelector:", "cacheFor:", "selectorsCache", "invalidateChildrenSelector:", "subclasses", "theClass"]}),
  2992. smalltalk.HLClassCache);
  2993. smalltalk.addMethod(
  2994. smalltalk.method({
  2995. selector: "invalidateParentSelector:",
  2996. fn: function (aSelector){
  2997. var self=this;
  2998. return smalltalk.withContext(function($ctx1) {
  2999. var $1,$2,$3;
  3000. $1=_st(_st(self)._theClass())._superclass();
  3001. if(($receiver = $1) == nil || $receiver == undefined){
  3002. $1;
  3003. } else {
  3004. $2=_st(_st(self)._selectorsCache())._cacheFor_(_st(_st(self)._theClass())._superclass());
  3005. _st($2)._removeSelector_(aSelector);
  3006. $3=_st($2)._invalidateParentSelector_(aSelector);
  3007. $3;
  3008. };
  3009. return self}, function($ctx1) {$ctx1.fill(self,"invalidateParentSelector:",{aSelector:aSelector},smalltalk.HLClassCache)})},
  3010. messageSends: ["ifNotNil:", "removeSelector:", "cacheFor:", "superclass", "theClass", "selectorsCache", "invalidateParentSelector:"]}),
  3011. smalltalk.HLClassCache);
  3012. smalltalk.addMethod(
  3013. smalltalk.method({
  3014. selector: "invalidateSelector:",
  3015. fn: function (aSelector){
  3016. var self=this;
  3017. return smalltalk.withContext(function($ctx1) {
  3018. var $1,$2;
  3019. $1=self;
  3020. _st($1)._invalidateParentSelector_(aSelector);
  3021. _st($1)._invalidateChildrenSelector_(aSelector);
  3022. $2=_st($1)._removeSelector_(aSelector);
  3023. return self}, function($ctx1) {$ctx1.fill(self,"invalidateSelector:",{aSelector:aSelector},smalltalk.HLClassCache)})},
  3024. messageSends: ["invalidateParentSelector:", "invalidateChildrenSelector:", "removeSelector:"]}),
  3025. smalltalk.HLClassCache);
  3026. smalltalk.addMethod(
  3027. smalltalk.method({
  3028. selector: "isOverridden:",
  3029. fn: function (aMethod){
  3030. var self=this;
  3031. return smalltalk.withContext(function($ctx1) {
  3032. var $1;
  3033. $1=_st(_st(self)._overriddenCache())._at_ifAbsentPut_(_st(aMethod)._selector(),(function(){
  3034. return smalltalk.withContext(function($ctx2) {
  3035. return _st(aMethod)._isOverridden();
  3036. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  3037. return $1;
  3038. }, function($ctx1) {$ctx1.fill(self,"isOverridden:",{aMethod:aMethod},smalltalk.HLClassCache)})},
  3039. messageSends: ["at:ifAbsentPut:", "selector", "isOverridden", "overriddenCache"]}),
  3040. smalltalk.HLClassCache);
  3041. smalltalk.addMethod(
  3042. smalltalk.method({
  3043. selector: "isOverride:",
  3044. fn: function (aMethod){
  3045. var self=this;
  3046. return smalltalk.withContext(function($ctx1) {
  3047. var $1;
  3048. $1=_st(_st(self)._overrideCache())._at_ifAbsentPut_(_st(aMethod)._selector(),(function(){
  3049. return smalltalk.withContext(function($ctx2) {
  3050. return _st(aMethod)._isOverride();
  3051. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  3052. return $1;
  3053. }, function($ctx1) {$ctx1.fill(self,"isOverride:",{aMethod:aMethod},smalltalk.HLClassCache)})},
  3054. messageSends: ["at:ifAbsentPut:", "selector", "isOverride", "overrideCache"]}),
  3055. smalltalk.HLClassCache);
  3056. smalltalk.addMethod(
  3057. smalltalk.method({
  3058. selector: "overriddenCache",
  3059. fn: function (){
  3060. var self=this;
  3061. function $HashedCollection(){return smalltalk.HashedCollection||(typeof HashedCollection=="undefined"?nil:HashedCollection)}
  3062. return smalltalk.withContext(function($ctx1) {
  3063. var $2,$1;
  3064. $2=self["@overriddenCache"];
  3065. if(($receiver = $2) == nil || $receiver == undefined){
  3066. self["@overriddenCache"]=_st($HashedCollection())._new();
  3067. $1=self["@overriddenCache"];
  3068. } else {
  3069. $1=$2;
  3070. };
  3071. return $1;
  3072. }, function($ctx1) {$ctx1.fill(self,"overriddenCache",{},smalltalk.HLClassCache)})},
  3073. messageSends: ["ifNil:", "new"]}),
  3074. smalltalk.HLClassCache);
  3075. smalltalk.addMethod(
  3076. smalltalk.method({
  3077. selector: "overrideCache",
  3078. fn: function (){
  3079. var self=this;
  3080. function $HashedCollection(){return smalltalk.HashedCollection||(typeof HashedCollection=="undefined"?nil:HashedCollection)}
  3081. return smalltalk.withContext(function($ctx1) {
  3082. var $2,$1;
  3083. $2=self["@overrideCache"];
  3084. if(($receiver = $2) == nil || $receiver == undefined){
  3085. self["@overrideCache"]=_st($HashedCollection())._new();
  3086. $1=self["@overrideCache"];
  3087. } else {
  3088. $1=$2;
  3089. };
  3090. return $1;
  3091. }, function($ctx1) {$ctx1.fill(self,"overrideCache",{},smalltalk.HLClassCache)})},
  3092. messageSends: ["ifNil:", "new"]}),
  3093. smalltalk.HLClassCache);
  3094. smalltalk.addMethod(
  3095. smalltalk.method({
  3096. selector: "removeSelector:",
  3097. fn: function (aSelector){
  3098. var self=this;
  3099. return smalltalk.withContext(function($ctx1) {
  3100. _st(_st(self)._overriddenCache())._removeKey_ifAbsent_(aSelector,(function(){
  3101. return smalltalk.withContext(function($ctx2) {
  3102. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  3103. _st(_st(self)._overrideCache())._removeKey_ifAbsent_(aSelector,(function(){
  3104. return smalltalk.withContext(function($ctx2) {
  3105. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  3106. return self}, function($ctx1) {$ctx1.fill(self,"removeSelector:",{aSelector:aSelector},smalltalk.HLClassCache)})},
  3107. messageSends: ["removeKey:ifAbsent:", "overriddenCache", "overrideCache"]}),
  3108. smalltalk.HLClassCache);
  3109. smalltalk.addMethod(
  3110. smalltalk.method({
  3111. selector: "selectorsCache",
  3112. fn: function (){
  3113. var self=this;
  3114. return smalltalk.withContext(function($ctx1) {
  3115. var $1;
  3116. $1=self["@selectorsCache"];
  3117. return $1;
  3118. }, function($ctx1) {$ctx1.fill(self,"selectorsCache",{},smalltalk.HLClassCache)})},
  3119. messageSends: []}),
  3120. smalltalk.HLClassCache);
  3121. smalltalk.addMethod(
  3122. smalltalk.method({
  3123. selector: "selectorsCache:",
  3124. fn: function (aCache){
  3125. var self=this;
  3126. return smalltalk.withContext(function($ctx1) {
  3127. self["@selectorsCache"]=aCache;
  3128. return self}, function($ctx1) {$ctx1.fill(self,"selectorsCache:",{aCache:aCache},smalltalk.HLClassCache)})},
  3129. messageSends: []}),
  3130. smalltalk.HLClassCache);
  3131. smalltalk.addMethod(
  3132. smalltalk.method({
  3133. selector: "theClass",
  3134. fn: function (){
  3135. var self=this;
  3136. return smalltalk.withContext(function($ctx1) {
  3137. var $1;
  3138. $1=self["@class"];
  3139. return $1;
  3140. }, function($ctx1) {$ctx1.fill(self,"theClass",{},smalltalk.HLClassCache)})},
  3141. messageSends: []}),
  3142. smalltalk.HLClassCache);
  3143. smalltalk.addMethod(
  3144. smalltalk.method({
  3145. selector: "theClass:",
  3146. fn: function (aClass){
  3147. var self=this;
  3148. return smalltalk.withContext(function($ctx1) {
  3149. self["@class"]=aClass;
  3150. return self}, function($ctx1) {$ctx1.fill(self,"theClass:",{aClass:aClass},smalltalk.HLClassCache)})},
  3151. messageSends: []}),
  3152. smalltalk.HLClassCache);
  3153. smalltalk.addMethod(
  3154. smalltalk.method({
  3155. selector: "on:selectorsCache:",
  3156. fn: function (aClass,aSelectorsCache){
  3157. var self=this;
  3158. return smalltalk.withContext(function($ctx1) {
  3159. var $2,$3,$1;
  3160. $2=_st(self)._new();
  3161. _st($2)._theClass_(aClass);
  3162. _st($2)._selectorsCache_(aSelectorsCache);
  3163. $3=_st($2)._yourself();
  3164. $1=$3;
  3165. return $1;
  3166. }, function($ctx1) {$ctx1.fill(self,"on:selectorsCache:",{aClass:aClass,aSelectorsCache:aSelectorsCache},smalltalk.HLClassCache.klass)})},
  3167. messageSends: ["theClass:", "new", "selectorsCache:", "yourself"]}),
  3168. smalltalk.HLClassCache.klass);
  3169. smalltalk.addClass('HLDocumentationWidget', smalltalk.HLFocusableWidget, ['model'], 'Helios-Browser');
  3170. smalltalk.addMethod(
  3171. smalltalk.method({
  3172. selector: "defaultDocumentation",
  3173. fn: function (){
  3174. var self=this;
  3175. return smalltalk.withContext(function($ctx1) {
  3176. return "#No documentation available. \x0a##That's bad. Seriously.";
  3177. }, function($ctx1) {$ctx1.fill(self,"defaultDocumentation",{},smalltalk.HLDocumentationWidget)})},
  3178. messageSends: []}),
  3179. smalltalk.HLDocumentationWidget);
  3180. smalltalk.addMethod(
  3181. smalltalk.method({
  3182. selector: "documentation",
  3183. fn: function (){
  3184. var self=this;
  3185. return smalltalk.withContext(function($ctx1) {
  3186. var $2,$1;
  3187. $2=_st(_st(_st(_st(self)._model())._selectedClass())._theNonMetaClass())._comment();
  3188. if(($receiver = $2) == nil || $receiver == undefined){
  3189. $1=_st(self)._defaultDocumentation();
  3190. } else {
  3191. $1=$2;
  3192. };
  3193. return $1;
  3194. }, function($ctx1) {$ctx1.fill(self,"documentation",{},smalltalk.HLDocumentationWidget)})},
  3195. messageSends: ["ifNil:", "defaultDocumentation", "comment", "theNonMetaClass", "selectedClass", "model"]}),
  3196. smalltalk.HLDocumentationWidget);
  3197. smalltalk.addMethod(
  3198. smalltalk.method({
  3199. selector: "model",
  3200. fn: function (){
  3201. var self=this;
  3202. return smalltalk.withContext(function($ctx1) {
  3203. var $1;
  3204. $1=self["@model"];
  3205. return $1;
  3206. }, function($ctx1) {$ctx1.fill(self,"model",{},smalltalk.HLDocumentationWidget)})},
  3207. messageSends: []}),
  3208. smalltalk.HLDocumentationWidget);
  3209. smalltalk.addMethod(
  3210. smalltalk.method({
  3211. selector: "model:",
  3212. fn: function (aModel){
  3213. var self=this;
  3214. return smalltalk.withContext(function($ctx1) {
  3215. self["@model"]=aModel;
  3216. return self}, function($ctx1) {$ctx1.fill(self,"model:",{aModel:aModel},smalltalk.HLDocumentationWidget)})},
  3217. messageSends: []}),
  3218. smalltalk.HLDocumentationWidget);
  3219. smalltalk.addMethod(
  3220. smalltalk.method({
  3221. selector: "renderContentOn:",
  3222. fn: function (html){
  3223. var self=this;
  3224. function $Showdown(){return smalltalk.Showdown||(typeof Showdown=="undefined"?nil:Showdown)}
  3225. return smalltalk.withContext(function($ctx1) {
  3226. var $1,$2;
  3227. $1=_st(html)._div();
  3228. _st($1)._class_("markdown");
  3229. $2=_st($1)._asJQuery();
  3230. _st($2)._html_(_st(_st(_st($Showdown())._at_("converter"))._new())._makeHtml_(_st(self)._documentation()));
  3231. return self}, function($ctx1) {$ctx1.fill(self,"renderContentOn:",{html:html},smalltalk.HLDocumentationWidget)})},
  3232. messageSends: ["html:", "makeHtml:", "documentation", "new", "at:", "class:", "div", "asJQuery"]}),
  3233. smalltalk.HLDocumentationWidget);
  3234. smalltalk.addClass('HLSelectorsCache', smalltalk.Object, ['classesCache'], 'Helios-Browser');
  3235. smalltalk.addMethod(
  3236. smalltalk.method({
  3237. selector: "cacheFor:",
  3238. fn: function (aClass){
  3239. var self=this;
  3240. return smalltalk.withContext(function($ctx1) {
  3241. var $1,$2;
  3242. $1=aClass;
  3243. if(($receiver = $1) == nil || $receiver == undefined){
  3244. return nil;
  3245. } else {
  3246. $1;
  3247. };
  3248. $2=_st(_st(self)._classesCache())._at_ifAbsentPut_(_st(aClass)._name(),(function(){
  3249. return smalltalk.withContext(function($ctx2) {
  3250. return _st(self)._newCacheFor_(aClass);
  3251. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  3252. return $2;
  3253. }, function($ctx1) {$ctx1.fill(self,"cacheFor:",{aClass:aClass},smalltalk.HLSelectorsCache)})},
  3254. messageSends: ["ifNil:", "at:ifAbsentPut:", "name", "newCacheFor:", "classesCache"]}),
  3255. smalltalk.HLSelectorsCache);
  3256. smalltalk.addMethod(
  3257. smalltalk.method({
  3258. selector: "classesCache",
  3259. fn: function (){
  3260. var self=this;
  3261. function $HashedCollection(){return smalltalk.HashedCollection||(typeof HashedCollection=="undefined"?nil:HashedCollection)}
  3262. return smalltalk.withContext(function($ctx1) {
  3263. var $2,$1;
  3264. $2=self["@classesCache"];
  3265. if(($receiver = $2) == nil || $receiver == undefined){
  3266. self["@classesCache"]=_st($HashedCollection())._new();
  3267. $1=self["@classesCache"];
  3268. } else {
  3269. $1=$2;
  3270. };
  3271. return $1;
  3272. }, function($ctx1) {$ctx1.fill(self,"classesCache",{},smalltalk.HLSelectorsCache)})},
  3273. messageSends: ["ifNil:", "new"]}),
  3274. smalltalk.HLSelectorsCache);
  3275. smalltalk.addMethod(
  3276. smalltalk.method({
  3277. selector: "initialize",
  3278. fn: function (){
  3279. var self=this;
  3280. return smalltalk.withContext(function($ctx1) {
  3281. smalltalk.Object.fn.prototype._initialize.apply(_st(self), []);
  3282. _st(self)._observeSystem();
  3283. return self}, function($ctx1) {$ctx1.fill(self,"initialize",{},smalltalk.HLSelectorsCache)})},
  3284. messageSends: ["initialize", "observeSystem"]}),
  3285. smalltalk.HLSelectorsCache);
  3286. smalltalk.addMethod(
  3287. smalltalk.method({
  3288. selector: "invalidateCacheFor:",
  3289. fn: function (aMethod){
  3290. var self=this;
  3291. return smalltalk.withContext(function($ctx1) {
  3292. _st(_st(self)._cacheFor_(_st(aMethod)._methodClass()))._invalidateSelector_(_st(aMethod)._selector());
  3293. return self}, function($ctx1) {$ctx1.fill(self,"invalidateCacheFor:",{aMethod:aMethod},smalltalk.HLSelectorsCache)})},
  3294. messageSends: ["invalidateSelector:", "selector", "cacheFor:", "methodClass"]}),
  3295. smalltalk.HLSelectorsCache);
  3296. smalltalk.addMethod(
  3297. smalltalk.method({
  3298. selector: "isOverridden:",
  3299. fn: function (aMethod){
  3300. var self=this;
  3301. return smalltalk.withContext(function($ctx1) {
  3302. var $1;
  3303. $1=_st(_st(self)._cacheFor_(_st(aMethod)._methodClass()))._isOverridden_(aMethod);
  3304. return $1;
  3305. }, function($ctx1) {$ctx1.fill(self,"isOverridden:",{aMethod:aMethod},smalltalk.HLSelectorsCache)})},
  3306. messageSends: ["isOverridden:", "cacheFor:", "methodClass"]}),
  3307. smalltalk.HLSelectorsCache);
  3308. smalltalk.addMethod(
  3309. smalltalk.method({
  3310. selector: "isOverride:",
  3311. fn: function (aMethod){
  3312. var self=this;
  3313. return smalltalk.withContext(function($ctx1) {
  3314. var $1;
  3315. $1=_st(_st(self)._cacheFor_(_st(aMethod)._methodClass()))._isOverride_(aMethod);
  3316. return $1;
  3317. }, function($ctx1) {$ctx1.fill(self,"isOverride:",{aMethod:aMethod},smalltalk.HLSelectorsCache)})},
  3318. messageSends: ["isOverride:", "cacheFor:", "methodClass"]}),
  3319. smalltalk.HLSelectorsCache);
  3320. smalltalk.addMethod(
  3321. smalltalk.method({
  3322. selector: "newCacheFor:",
  3323. fn: function (aClass){
  3324. var self=this;
  3325. function $HLClassCache(){return smalltalk.HLClassCache||(typeof HLClassCache=="undefined"?nil:HLClassCache)}
  3326. return smalltalk.withContext(function($ctx1) {
  3327. var $1;
  3328. $1=_st($HLClassCache())._on_selectorsCache_(aClass,self);
  3329. return $1;
  3330. }, function($ctx1) {$ctx1.fill(self,"newCacheFor:",{aClass:aClass},smalltalk.HLSelectorsCache)})},
  3331. messageSends: ["on:selectorsCache:"]}),
  3332. smalltalk.HLSelectorsCache);
  3333. smalltalk.addMethod(
  3334. smalltalk.method({
  3335. selector: "observeSystem",
  3336. fn: function (){
  3337. var self=this;
  3338. function $MethodAdded(){return smalltalk.MethodAdded||(typeof MethodAdded=="undefined"?nil:MethodAdded)}
  3339. function $SystemAnnouncer(){return smalltalk.SystemAnnouncer||(typeof SystemAnnouncer=="undefined"?nil:SystemAnnouncer)}
  3340. function $MethodRemoved(){return smalltalk.MethodRemoved||(typeof MethodRemoved=="undefined"?nil:MethodRemoved)}
  3341. return smalltalk.withContext(function($ctx1) {
  3342. var $1,$2;
  3343. $1=_st($SystemAnnouncer())._current();
  3344. _st($1)._on_do_($MethodAdded(),(function(ann){
  3345. return smalltalk.withContext(function($ctx2) {
  3346. return _st(self)._onMethodAdded_(_st(ann)._method());
  3347. }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1)})}));
  3348. $2=_st($1)._on_do_($MethodRemoved(),(function(ann){
  3349. return smalltalk.withContext(function($ctx2) {
  3350. return _st(self)._onMethodRemoved_(_st(ann)._method());
  3351. }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1)})}));
  3352. return self}, function($ctx1) {$ctx1.fill(self,"observeSystem",{},smalltalk.HLSelectorsCache)})},
  3353. messageSends: ["on:do:", "onMethodAdded:", "method", "current", "onMethodRemoved:"]}),
  3354. smalltalk.HLSelectorsCache);
  3355. smalltalk.addMethod(
  3356. smalltalk.method({
  3357. selector: "onMethodAdded:",
  3358. fn: function (aMethod){
  3359. var self=this;
  3360. return smalltalk.withContext(function($ctx1) {
  3361. _st(self)._invalidateCacheFor_(aMethod);
  3362. return self}, function($ctx1) {$ctx1.fill(self,"onMethodAdded:",{aMethod:aMethod},smalltalk.HLSelectorsCache)})},
  3363. messageSends: ["invalidateCacheFor:"]}),
  3364. smalltalk.HLSelectorsCache);
  3365. smalltalk.addMethod(
  3366. smalltalk.method({
  3367. selector: "onMethodRemoved:",
  3368. fn: function (aMethod){
  3369. var self=this;
  3370. return smalltalk.withContext(function($ctx1) {
  3371. _st(self)._invalidateCacheFor_(aMethod);
  3372. return self}, function($ctx1) {$ctx1.fill(self,"onMethodRemoved:",{aMethod:aMethod},smalltalk.HLSelectorsCache)})},
  3373. messageSends: ["invalidateCacheFor:"]}),
  3374. smalltalk.HLSelectorsCache);
  3375. smalltalk.HLSelectorsCache.klass.iVarNames = ['current'];
  3376. smalltalk.addMethod(
  3377. smalltalk.method({
  3378. selector: "current",
  3379. fn: function (){
  3380. var self=this;
  3381. return smalltalk.withContext(function($ctx1) {
  3382. var $2,$1;
  3383. $2=self["@current"];
  3384. if(($receiver = $2) == nil || $receiver == undefined){
  3385. self["@current"]=smalltalk.Object.klass.fn.prototype._new.apply(_st(self), []);
  3386. $1=self["@current"];
  3387. } else {
  3388. $1=$2;
  3389. };
  3390. return $1;
  3391. }, function($ctx1) {$ctx1.fill(self,"current",{},smalltalk.HLSelectorsCache.klass)})},
  3392. messageSends: ["ifNil:", "new"]}),
  3393. smalltalk.HLSelectorsCache.klass);
  3394. smalltalk.addMethod(
  3395. smalltalk.method({
  3396. selector: "flush",
  3397. fn: function (){
  3398. var self=this;
  3399. return smalltalk.withContext(function($ctx1) {
  3400. self["@current"]=nil;
  3401. return self}, function($ctx1) {$ctx1.fill(self,"flush",{},smalltalk.HLSelectorsCache.klass)})},
  3402. messageSends: []}),
  3403. smalltalk.HLSelectorsCache.klass);
  3404. smalltalk.addMethod(
  3405. smalltalk.method({
  3406. selector: "new",
  3407. fn: function (){
  3408. var self=this;
  3409. return smalltalk.withContext(function($ctx1) {
  3410. _st(self)._shouldNotImplement();
  3411. return self}, function($ctx1) {$ctx1.fill(self,"new",{},smalltalk.HLSelectorsCache.klass)})},
  3412. messageSends: ["shouldNotImplement"]}),
  3413. smalltalk.HLSelectorsCache.klass);