2
0

Helios-Browser.deploy.js 107 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537253825392540254125422543254425452546254725482549255025512552255325542555255625572558255925602561256225632564256525662567256825692570257125722573257425752576257725782579258025812582258325842585258625872588258925902591259225932594259525962597259825992600260126022603260426052606260726082609261026112612261326142615261626172618261926202621262226232624262526262627262826292630263126322633263426352636263726382639264026412642264326442645264626472648264926502651265226532654265526562657265826592660266126622663266426652666266726682669267026712672267326742675267626772678267926802681268226832684268526862687268826892690269126922693269426952696269726982699270027012702270327042705270627072708270927102711271227132714271527162717271827192720272127222723272427252726272727282729273027312732273327342735273627372738273927402741274227432744274527462747274827492750275127522753275427552756275727582759276027612762276327642765276627672768276927702771277227732774277527762777277827792780278127822783278427852786278727882789279027912792279327942795279627972798279928002801280228032804280528062807280828092810281128122813281428152816281728182819282028212822282328242825282628272828282928302831283228332834283528362837283828392840284128422843284428452846284728482849285028512852285328542855285628572858285928602861286228632864286528662867286828692870287128722873287428752876287728782879288028812882288328842885288628872888288928902891289228932894289528962897289828992900290129022903290429052906290729082909291029112912291329142915291629172918291929202921292229232924292529262927292829292930293129322933293429352936293729382939294029412942294329442945294629472948294929502951295229532954295529562957295829592960296129622963296429652966296729682969297029712972297329742975297629772978297929802981298229832984298529862987298829892990
  1. (function(smalltalk,nil,_st){
  2. smalltalk.addPackage('Helios-Browser');
  3. smalltalk.addClass('HLBrowser', smalltalk.HLWidget, ['model', 'packagesListWidget', 'classesListWidget', 'protocolsListWidget', 'methodsListWidget', 'sourceWidget', 'bottomDiv'], 'Helios-Browser');
  4. smalltalk.addMethod(
  5. smalltalk.method({
  6. selector: "canHaveFocus",
  7. fn: function (){
  8. var self=this;
  9. return smalltalk.withContext(function($ctx1) {
  10. return true;
  11. }, function($ctx1) {$ctx1.fill(self,"canHaveFocus",{},smalltalk.HLBrowser)})},
  12. messageSends: []}),
  13. smalltalk.HLBrowser);
  14. smalltalk.addMethod(
  15. smalltalk.method({
  16. selector: "classesListWidget",
  17. fn: function (){
  18. var self=this;
  19. function $HLClassesListWidget(){return smalltalk.HLClassesListWidget||(typeof HLClassesListWidget=="undefined"?nil:HLClassesListWidget)}
  20. return smalltalk.withContext(function($ctx1) {
  21. var $2,$1;
  22. $2=self["@classesListWidget"];
  23. if(($receiver = $2) == nil || $receiver == undefined){
  24. self["@classesListWidget"]=_st($HLClassesListWidget())._on_(self._model());
  25. self["@classesListWidget"];
  26. $1=_st(self["@classesListWidget"])._next_(self._protocolsListWidget());
  27. } else {
  28. $1=$2;
  29. };
  30. return $1;
  31. }, function($ctx1) {$ctx1.fill(self,"classesListWidget",{},smalltalk.HLBrowser)})},
  32. messageSends: ["ifNil:", "on:", "model", "next:", "protocolsListWidget"]}),
  33. smalltalk.HLBrowser);
  34. smalltalk.addMethod(
  35. smalltalk.method({
  36. selector: "environment",
  37. fn: function (){
  38. var self=this;
  39. return smalltalk.withContext(function($ctx1) {
  40. var $1;
  41. $1=_st(self._model())._environment();
  42. return $1;
  43. }, function($ctx1) {$ctx1.fill(self,"environment",{},smalltalk.HLBrowser)})},
  44. messageSends: ["environment", "model"]}),
  45. smalltalk.HLBrowser);
  46. smalltalk.addMethod(
  47. smalltalk.method({
  48. selector: "focus",
  49. fn: function (){
  50. var self=this;
  51. return smalltalk.withContext(function($ctx1) {
  52. var $1;
  53. $1=_st(self._packagesListWidget())._focus();
  54. return $1;
  55. }, function($ctx1) {$ctx1.fill(self,"focus",{},smalltalk.HLBrowser)})},
  56. messageSends: ["focus", "packagesListWidget"]}),
  57. smalltalk.HLBrowser);
  58. smalltalk.addMethod(
  59. smalltalk.method({
  60. selector: "methodsListWidget",
  61. fn: function (){
  62. var self=this;
  63. function $HLMethodsListWidget(){return smalltalk.HLMethodsListWidget||(typeof HLMethodsListWidget=="undefined"?nil:HLMethodsListWidget)}
  64. return smalltalk.withContext(function($ctx1) {
  65. var $2,$1;
  66. $2=self["@methodsListWidget"];
  67. if(($receiver = $2) == nil || $receiver == undefined){
  68. self["@methodsListWidget"]=_st($HLMethodsListWidget())._on_(self._model());
  69. self["@methodsListWidget"];
  70. $1=_st(self["@methodsListWidget"])._next_(self._sourceWidget());
  71. } else {
  72. $1=$2;
  73. };
  74. return $1;
  75. }, function($ctx1) {$ctx1.fill(self,"methodsListWidget",{},smalltalk.HLBrowser)})},
  76. messageSends: ["ifNil:", "on:", "model", "next:", "sourceWidget"]}),
  77. smalltalk.HLBrowser);
  78. smalltalk.addMethod(
  79. smalltalk.method({
  80. selector: "model",
  81. fn: function (){
  82. var self=this;
  83. function $HLBrowserModel(){return smalltalk.HLBrowserModel||(typeof HLBrowserModel=="undefined"?nil:HLBrowserModel)}
  84. return smalltalk.withContext(function($ctx1) {
  85. var $2,$1;
  86. $2=self["@model"];
  87. if(($receiver = $2) == nil || $receiver == undefined){
  88. self["@model"]=_st($HLBrowserModel())._new();
  89. $1=self["@model"];
  90. } else {
  91. $1=$2;
  92. };
  93. return $1;
  94. }, function($ctx1) {$ctx1.fill(self,"model",{},smalltalk.HLBrowser)})},
  95. messageSends: ["ifNil:", "new"]}),
  96. smalltalk.HLBrowser);
  97. smalltalk.addMethod(
  98. smalltalk.method({
  99. selector: "model:",
  100. fn: function (aModel){
  101. var self=this;
  102. return smalltalk.withContext(function($ctx1) {
  103. self["@model"]=aModel;
  104. return self}, function($ctx1) {$ctx1.fill(self,"model:",{aModel:aModel},smalltalk.HLBrowser)})},
  105. messageSends: []}),
  106. smalltalk.HLBrowser);
  107. smalltalk.addMethod(
  108. smalltalk.method({
  109. selector: "packagesListWidget",
  110. fn: function (){
  111. var self=this;
  112. function $HLPackagesListWidget(){return smalltalk.HLPackagesListWidget||(typeof HLPackagesListWidget=="undefined"?nil:HLPackagesListWidget)}
  113. return smalltalk.withContext(function($ctx1) {
  114. var $2,$1;
  115. $2=self["@packagesListWidget"];
  116. if(($receiver = $2) == nil || $receiver == undefined){
  117. self["@packagesListWidget"]=_st($HLPackagesListWidget())._on_(self._model());
  118. self["@packagesListWidget"];
  119. $1=_st(self["@packagesListWidget"])._next_(self._classesListWidget());
  120. } else {
  121. $1=$2;
  122. };
  123. return $1;
  124. }, function($ctx1) {$ctx1.fill(self,"packagesListWidget",{},smalltalk.HLBrowser)})},
  125. messageSends: ["ifNil:", "on:", "model", "next:", "classesListWidget"]}),
  126. smalltalk.HLBrowser);
  127. smalltalk.addMethod(
  128. smalltalk.method({
  129. selector: "protocolsListWidget",
  130. fn: function (){
  131. var self=this;
  132. function $HLProtocolsListWidget(){return smalltalk.HLProtocolsListWidget||(typeof HLProtocolsListWidget=="undefined"?nil:HLProtocolsListWidget)}
  133. return smalltalk.withContext(function($ctx1) {
  134. var $2,$1;
  135. $2=self["@protocolsListWidget"];
  136. if(($receiver = $2) == nil || $receiver == undefined){
  137. self["@protocolsListWidget"]=_st($HLProtocolsListWidget())._on_(self._model());
  138. self["@protocolsListWidget"];
  139. $1=_st(self["@protocolsListWidget"])._next_(self._methodsListWidget());
  140. } else {
  141. $1=$2;
  142. };
  143. return $1;
  144. }, function($ctx1) {$ctx1.fill(self,"protocolsListWidget",{},smalltalk.HLBrowser)})},
  145. messageSends: ["ifNil:", "on:", "model", "next:", "methodsListWidget"]}),
  146. smalltalk.HLBrowser);
  147. smalltalk.addMethod(
  148. smalltalk.method({
  149. selector: "registerBindingsOn:",
  150. fn: function (aBindingGroup){
  151. var self=this;
  152. function $HLToolCommand(){return smalltalk.HLToolCommand||(typeof HLToolCommand=="undefined"?nil:HLToolCommand)}
  153. return smalltalk.withContext(function($ctx1) {
  154. _st($HLToolCommand())._registerConcreteClassesOn_for_(aBindingGroup,self._model());
  155. return self}, function($ctx1) {$ctx1.fill(self,"registerBindingsOn:",{aBindingGroup:aBindingGroup},smalltalk.HLBrowser)})},
  156. messageSends: ["registerConcreteClassesOn:for:", "model"]}),
  157. smalltalk.HLBrowser);
  158. smalltalk.addMethod(
  159. smalltalk.method({
  160. selector: "renderContentOn:",
  161. fn: function (html){
  162. var self=this;
  163. function $HLVerticalSplitter(){return smalltalk.HLVerticalSplitter||(typeof HLVerticalSplitter=="undefined"?nil:HLVerticalSplitter)}
  164. function $HLHorizontalSplitter(){return smalltalk.HLHorizontalSplitter||(typeof HLHorizontalSplitter=="undefined"?nil:HLHorizontalSplitter)}
  165. function $HLContainer(){return smalltalk.HLContainer||(typeof HLContainer=="undefined"?nil:HLContainer)}
  166. return smalltalk.withContext(function($ctx1) {
  167. _st(html)._with_(_st($HLContainer())._with_(_st($HLHorizontalSplitter())._with_with_(_st($HLVerticalSplitter())._with_with_(_st($HLVerticalSplitter())._with_with_(self._packagesListWidget(),self._classesListWidget()),_st($HLVerticalSplitter())._with_with_(self._protocolsListWidget(),self._methodsListWidget())),self._sourceWidget())));
  168. _st(self._packagesListWidget())._focus();
  169. return self}, function($ctx1) {$ctx1.fill(self,"renderContentOn:",{html:html},smalltalk.HLBrowser)})},
  170. messageSends: ["with:", "with:with:", "packagesListWidget", "classesListWidget", "protocolsListWidget", "methodsListWidget", "sourceWidget", "focus"]}),
  171. smalltalk.HLBrowser);
  172. smalltalk.addMethod(
  173. smalltalk.method({
  174. selector: "sourceWidget",
  175. fn: function (){
  176. var self=this;
  177. function $HLBrowserBottomWidget(){return smalltalk.HLBrowserBottomWidget||(typeof HLBrowserBottomWidget=="undefined"?nil:HLBrowserBottomWidget)}
  178. return smalltalk.withContext(function($ctx1) {
  179. var $2,$3,$4,$1;
  180. $2=self["@sourceWidget"];
  181. if(($receiver = $2) == nil || $receiver == undefined){
  182. $3=_st($HLBrowserBottomWidget())._new();
  183. _st($3)._model_(self._model());
  184. $4=_st($3)._yourself();
  185. self["@sourceWidget"]=$4;
  186. $1=self["@sourceWidget"];
  187. } else {
  188. $1=$2;
  189. };
  190. return $1;
  191. }, function($ctx1) {$ctx1.fill(self,"sourceWidget",{},smalltalk.HLBrowser)})},
  192. messageSends: ["ifNil:", "model:", "model", "new", "yourself"]}),
  193. smalltalk.HLBrowser);
  194. smalltalk.addMethod(
  195. smalltalk.method({
  196. selector: "unregister",
  197. fn: function (){
  198. var self=this;
  199. return smalltalk.withContext(function($ctx1) {
  200. smalltalk.HLBrowser.superclass.fn.prototype._unregister.apply(_st(self), []);
  201. _st([self._packagesListWidget(),self._classesListWidget(),self._protocolsListWidget(),self._methodsListWidget(),self._sourceWidget()])._do_((function(each){
  202. return smalltalk.withContext(function($ctx2) {
  203. return _st(each)._unregister();
  204. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})}));
  205. return self}, function($ctx1) {$ctx1.fill(self,"unregister",{},smalltalk.HLBrowser)})},
  206. messageSends: ["unregister", "do:", "packagesListWidget", "classesListWidget", "protocolsListWidget", "methodsListWidget", "sourceWidget"]}),
  207. smalltalk.HLBrowser);
  208. smalltalk.HLBrowser.klass.iVarNames = ['nextId'];
  209. smalltalk.addMethod(
  210. smalltalk.method({
  211. selector: "canBeOpenAsTab",
  212. fn: function (){
  213. var self=this;
  214. return smalltalk.withContext(function($ctx1) {
  215. return true;
  216. }, function($ctx1) {$ctx1.fill(self,"canBeOpenAsTab",{},smalltalk.HLBrowser.klass)})},
  217. messageSends: []}),
  218. smalltalk.HLBrowser.klass);
  219. smalltalk.addMethod(
  220. smalltalk.method({
  221. selector: "nextId",
  222. fn: function (){
  223. var self=this;
  224. return smalltalk.withContext(function($ctx1) {
  225. var $1,$2;
  226. $1=self["@nextId"];
  227. if(($receiver = $1) == nil || $receiver == undefined){
  228. self["@nextId"]=(0);
  229. self["@nextId"];
  230. } else {
  231. $1;
  232. };
  233. $2="browser_".__comma(_st(_st(self["@nextId"]).__plus((1)))._asString());
  234. return $2;
  235. }, function($ctx1) {$ctx1.fill(self,"nextId",{},smalltalk.HLBrowser.klass)})},
  236. messageSends: ["ifNil:", ",", "asString", "+"]}),
  237. smalltalk.HLBrowser.klass);
  238. smalltalk.addMethod(
  239. smalltalk.method({
  240. selector: "tabClass",
  241. fn: function (){
  242. var self=this;
  243. return smalltalk.withContext(function($ctx1) {
  244. return "browser";
  245. }, function($ctx1) {$ctx1.fill(self,"tabClass",{},smalltalk.HLBrowser.klass)})},
  246. messageSends: []}),
  247. smalltalk.HLBrowser.klass);
  248. smalltalk.addMethod(
  249. smalltalk.method({
  250. selector: "tabLabel",
  251. fn: function (){
  252. var self=this;
  253. return smalltalk.withContext(function($ctx1) {
  254. return "Browser";
  255. }, function($ctx1) {$ctx1.fill(self,"tabLabel",{},smalltalk.HLBrowser.klass)})},
  256. messageSends: []}),
  257. smalltalk.HLBrowser.klass);
  258. smalltalk.addMethod(
  259. smalltalk.method({
  260. selector: "tabPriority",
  261. fn: function (){
  262. var self=this;
  263. return smalltalk.withContext(function($ctx1) {
  264. return (0);
  265. }, function($ctx1) {$ctx1.fill(self,"tabPriority",{},smalltalk.HLBrowser.klass)})},
  266. messageSends: []}),
  267. smalltalk.HLBrowser.klass);
  268. smalltalk.addClass('HLBrowserBottomWidget', smalltalk.HLWidget, ['model', 'codeWidget', 'documentationWidget'], 'Helios-Browser');
  269. smalltalk.addMethod(
  270. smalltalk.method({
  271. selector: "canHaveFocus",
  272. fn: function (){
  273. var self=this;
  274. return smalltalk.withContext(function($ctx1) {
  275. return true;
  276. }, function($ctx1) {$ctx1.fill(self,"canHaveFocus",{},smalltalk.HLBrowserBottomWidget)})},
  277. messageSends: []}),
  278. smalltalk.HLBrowserBottomWidget);
  279. smalltalk.addMethod(
  280. smalltalk.method({
  281. selector: "codeWidget",
  282. fn: function (){
  283. var self=this;
  284. function $HLBrowserCodeWidget(){return smalltalk.HLBrowserCodeWidget||(typeof HLBrowserCodeWidget=="undefined"?nil:HLBrowserCodeWidget)}
  285. return smalltalk.withContext(function($ctx1) {
  286. var $2,$3,$4,$1;
  287. $2=self["@codeWidget"];
  288. if(($receiver = $2) == nil || $receiver == undefined){
  289. $3=_st($HLBrowserCodeWidget())._new();
  290. _st($3)._browserModel_(self._model());
  291. $4=_st($3)._yourself();
  292. self["@codeWidget"]=$4;
  293. $1=self["@codeWidget"];
  294. } else {
  295. $1=$2;
  296. };
  297. return $1;
  298. }, function($ctx1) {$ctx1.fill(self,"codeWidget",{},smalltalk.HLBrowserBottomWidget)})},
  299. messageSends: ["ifNil:", "browserModel:", "model", "new", "yourself"]}),
  300. smalltalk.HLBrowserBottomWidget);
  301. smalltalk.addMethod(
  302. smalltalk.method({
  303. selector: "documentationWidget",
  304. fn: function (){
  305. var self=this;
  306. function $HLDocumentationWidget(){return smalltalk.HLDocumentationWidget||(typeof HLDocumentationWidget=="undefined"?nil:HLDocumentationWidget)}
  307. return smalltalk.withContext(function($ctx1) {
  308. var $2,$3,$4,$1;
  309. $2=self["@documentationWidget"];
  310. if(($receiver = $2) == nil || $receiver == undefined){
  311. $3=_st($HLDocumentationWidget())._new();
  312. _st($3)._model_(self._model());
  313. $4=_st($3)._yourself();
  314. self["@documentationWidget"]=$4;
  315. $1=self["@documentationWidget"];
  316. } else {
  317. $1=$2;
  318. };
  319. return $1;
  320. }, function($ctx1) {$ctx1.fill(self,"documentationWidget",{},smalltalk.HLBrowserBottomWidget)})},
  321. messageSends: ["ifNil:", "model:", "model", "new", "yourself"]}),
  322. smalltalk.HLBrowserBottomWidget);
  323. smalltalk.addMethod(
  324. smalltalk.method({
  325. selector: "focus",
  326. fn: function (){
  327. var self=this;
  328. return smalltalk.withContext(function($ctx1) {
  329. _st(self._codeWidget())._focus();
  330. return self}, function($ctx1) {$ctx1.fill(self,"focus",{},smalltalk.HLBrowserBottomWidget)})},
  331. messageSends: ["focus", "codeWidget"]}),
  332. smalltalk.HLBrowserBottomWidget);
  333. smalltalk.addMethod(
  334. smalltalk.method({
  335. selector: "model",
  336. fn: function (){
  337. var self=this;
  338. return smalltalk.withContext(function($ctx1) {
  339. var $1;
  340. $1=self["@model"];
  341. return $1;
  342. }, function($ctx1) {$ctx1.fill(self,"model",{},smalltalk.HLBrowserBottomWidget)})},
  343. messageSends: []}),
  344. smalltalk.HLBrowserBottomWidget);
  345. smalltalk.addMethod(
  346. smalltalk.method({
  347. selector: "model:",
  348. fn: function (aModel){
  349. var self=this;
  350. return smalltalk.withContext(function($ctx1) {
  351. self["@model"]=aModel;
  352. self._observeModel();
  353. return self}, function($ctx1) {$ctx1.fill(self,"model:",{aModel:aModel},smalltalk.HLBrowserBottomWidget)})},
  354. messageSends: ["observeModel"]}),
  355. smalltalk.HLBrowserBottomWidget);
  356. smalltalk.addMethod(
  357. smalltalk.method({
  358. selector: "observeModel",
  359. fn: function (){
  360. var self=this;
  361. function $HLShowInstanceToggled(){return smalltalk.HLShowInstanceToggled||(typeof HLShowInstanceToggled=="undefined"?nil:HLShowInstanceToggled)}
  362. function $HLShowCommentToggled(){return smalltalk.HLShowCommentToggled||(typeof HLShowCommentToggled=="undefined"?nil:HLShowCommentToggled)}
  363. return smalltalk.withContext(function($ctx1) {
  364. var $1,$2;
  365. $1=_st(self._model())._announcer();
  366. _st($1)._on_send_to_($HLShowInstanceToggled(),"onShowInstanceToggled",self);
  367. $2=_st($1)._on_send_to_($HLShowCommentToggled(),"onShowCommentToggled",self);
  368. return self}, function($ctx1) {$ctx1.fill(self,"observeModel",{},smalltalk.HLBrowserBottomWidget)})},
  369. messageSends: ["on:send:to:", "announcer", "model"]}),
  370. smalltalk.HLBrowserBottomWidget);
  371. smalltalk.addMethod(
  372. smalltalk.method({
  373. selector: "onShowCommentToggled",
  374. fn: function (){
  375. var self=this;
  376. return smalltalk.withContext(function($ctx1) {
  377. self._refresh();
  378. return self}, function($ctx1) {$ctx1.fill(self,"onShowCommentToggled",{},smalltalk.HLBrowserBottomWidget)})},
  379. messageSends: ["refresh"]}),
  380. smalltalk.HLBrowserBottomWidget);
  381. smalltalk.addMethod(
  382. smalltalk.method({
  383. selector: "onShowInstanceToggled",
  384. fn: function (){
  385. var self=this;
  386. return smalltalk.withContext(function($ctx1) {
  387. self._refresh();
  388. return self}, function($ctx1) {$ctx1.fill(self,"onShowInstanceToggled",{},smalltalk.HLBrowserBottomWidget)})},
  389. messageSends: ["refresh"]}),
  390. smalltalk.HLBrowserBottomWidget);
  391. smalltalk.addMethod(
  392. smalltalk.method({
  393. selector: "previous",
  394. fn: function (){
  395. var self=this;
  396. return smalltalk.withContext(function($ctx1) {
  397. return self}, function($ctx1) {$ctx1.fill(self,"previous",{},smalltalk.HLBrowserBottomWidget)})},
  398. messageSends: []}),
  399. smalltalk.HLBrowserBottomWidget);
  400. smalltalk.addMethod(
  401. smalltalk.method({
  402. selector: "previous:",
  403. fn: function (aWidget){
  404. var self=this;
  405. return smalltalk.withContext(function($ctx1) {
  406. return self}, function($ctx1) {$ctx1.fill(self,"previous:",{aWidget:aWidget},smalltalk.HLBrowserBottomWidget)})},
  407. messageSends: []}),
  408. smalltalk.HLBrowserBottomWidget);
  409. smalltalk.addMethod(
  410. smalltalk.method({
  411. selector: "renderContentOn:",
  412. fn: function (html){
  413. var self=this;
  414. return smalltalk.withContext(function($ctx1) {
  415. var $1;
  416. $1=_st(self._model())._showComment();
  417. if(smalltalk.assert($1)){
  418. self._renderPanesOn_(html);
  419. } else {
  420. _st(html)._with_(self._codeWidget());
  421. };
  422. return self}, function($ctx1) {$ctx1.fill(self,"renderContentOn:",{html:html},smalltalk.HLBrowserBottomWidget)})},
  423. messageSends: ["ifTrue:ifFalse:", "renderPanesOn:", "with:", "codeWidget", "showComment", "model"]}),
  424. smalltalk.HLBrowserBottomWidget);
  425. smalltalk.addMethod(
  426. smalltalk.method({
  427. selector: "renderPanesOn:",
  428. fn: function (html){
  429. var self=this;
  430. function $HLVerticalSplitter(){return smalltalk.HLVerticalSplitter||(typeof HLVerticalSplitter=="undefined"?nil:HLVerticalSplitter)}
  431. return smalltalk.withContext(function($ctx1) {
  432. _st(html)._with_(_st($HLVerticalSplitter())._with_with_(self._codeWidget(),self._documentationWidget()));
  433. return self}, function($ctx1) {$ctx1.fill(self,"renderPanesOn:",{html:html},smalltalk.HLBrowserBottomWidget)})},
  434. messageSends: ["with:", "with:with:", "codeWidget", "documentationWidget"]}),
  435. smalltalk.HLBrowserBottomWidget);
  436. smalltalk.addClass('HLBrowserModel', smalltalk.HLToolModel, ['showInstance', 'showComment'], 'Helios-Browser');
  437. smalltalk.addMethod(
  438. smalltalk.method({
  439. selector: "editComment",
  440. fn: function (){
  441. var self=this;
  442. function $HLEditComment(){return smalltalk.HLEditComment||(typeof HLEditComment=="undefined"?nil:HLEditComment)}
  443. return smalltalk.withContext(function($ctx1) {
  444. _st(self._announcer())._announce_(_st($HLEditComment())._new());
  445. return self}, function($ctx1) {$ctx1.fill(self,"editComment",{},smalltalk.HLBrowserModel)})},
  446. messageSends: ["announce:", "new", "announcer"]}),
  447. smalltalk.HLBrowserModel);
  448. smalltalk.addMethod(
  449. smalltalk.method({
  450. selector: "focusOnClasses",
  451. fn: function (){
  452. var self=this;
  453. function $HLClassesFocusRequested(){return smalltalk.HLClassesFocusRequested||(typeof HLClassesFocusRequested=="undefined"?nil:HLClassesFocusRequested)}
  454. return smalltalk.withContext(function($ctx1) {
  455. _st(self._announcer())._announce_(_st($HLClassesFocusRequested())._new());
  456. return self}, function($ctx1) {$ctx1.fill(self,"focusOnClasses",{},smalltalk.HLBrowserModel)})},
  457. messageSends: ["announce:", "new", "announcer"]}),
  458. smalltalk.HLBrowserModel);
  459. smalltalk.addMethod(
  460. smalltalk.method({
  461. selector: "focusOnMethods",
  462. fn: function (){
  463. var self=this;
  464. function $HLMethodsFocusRequested(){return smalltalk.HLMethodsFocusRequested||(typeof HLMethodsFocusRequested=="undefined"?nil:HLMethodsFocusRequested)}
  465. return smalltalk.withContext(function($ctx1) {
  466. _st(self._announcer())._announce_(_st($HLMethodsFocusRequested())._new());
  467. return self}, function($ctx1) {$ctx1.fill(self,"focusOnMethods",{},smalltalk.HLBrowserModel)})},
  468. messageSends: ["announce:", "new", "announcer"]}),
  469. smalltalk.HLBrowserModel);
  470. smalltalk.addMethod(
  471. smalltalk.method({
  472. selector: "focusOnPackages",
  473. fn: function (){
  474. var self=this;
  475. function $HLPackagesFocusRequested(){return smalltalk.HLPackagesFocusRequested||(typeof HLPackagesFocusRequested=="undefined"?nil:HLPackagesFocusRequested)}
  476. return smalltalk.withContext(function($ctx1) {
  477. _st(self._announcer())._announce_(_st($HLPackagesFocusRequested())._new());
  478. return self}, function($ctx1) {$ctx1.fill(self,"focusOnPackages",{},smalltalk.HLBrowserModel)})},
  479. messageSends: ["announce:", "new", "announcer"]}),
  480. smalltalk.HLBrowserModel);
  481. smalltalk.addMethod(
  482. smalltalk.method({
  483. selector: "focusOnProtocols",
  484. fn: function (){
  485. var self=this;
  486. function $HLProtocolsFocusRequested(){return smalltalk.HLProtocolsFocusRequested||(typeof HLProtocolsFocusRequested=="undefined"?nil:HLProtocolsFocusRequested)}
  487. return smalltalk.withContext(function($ctx1) {
  488. _st(self._announcer())._announce_(_st($HLProtocolsFocusRequested())._new());
  489. return self}, function($ctx1) {$ctx1.fill(self,"focusOnProtocols",{},smalltalk.HLBrowserModel)})},
  490. messageSends: ["announce:", "new", "announcer"]}),
  491. smalltalk.HLBrowserModel);
  492. smalltalk.addMethod(
  493. smalltalk.method({
  494. selector: "focusOnSourceCode",
  495. fn: function (){
  496. var self=this;
  497. function $HLSourceCodeFocusRequested(){return smalltalk.HLSourceCodeFocusRequested||(typeof HLSourceCodeFocusRequested=="undefined"?nil:HLSourceCodeFocusRequested)}
  498. return smalltalk.withContext(function($ctx1) {
  499. _st(self._announcer())._announce_(_st($HLSourceCodeFocusRequested())._new());
  500. return self}, function($ctx1) {$ctx1.fill(self,"focusOnSourceCode",{},smalltalk.HLBrowserModel)})},
  501. messageSends: ["announce:", "new", "announcer"]}),
  502. smalltalk.HLBrowserModel);
  503. smalltalk.addMethod(
  504. smalltalk.method({
  505. selector: "isBrowserModel",
  506. fn: function (){
  507. var self=this;
  508. return smalltalk.withContext(function($ctx1) {
  509. return true;
  510. }, function($ctx1) {$ctx1.fill(self,"isBrowserModel",{},smalltalk.HLBrowserModel)})},
  511. messageSends: []}),
  512. smalltalk.HLBrowserModel);
  513. smalltalk.addMethod(
  514. smalltalk.method({
  515. selector: "setClassComment:",
  516. fn: function (aString){
  517. var self=this;
  518. return smalltalk.withContext(function($ctx1) {
  519. _st(self._environment())._setClassCommentOf_to_(_st(self._selectedClass())._theNonMetaClass(),aString);
  520. return self}, function($ctx1) {$ctx1.fill(self,"setClassComment:",{aString:aString},smalltalk.HLBrowserModel)})},
  521. messageSends: ["setClassCommentOf:to:", "theNonMetaClass", "selectedClass", "environment"]}),
  522. smalltalk.HLBrowserModel);
  523. smalltalk.addMethod(
  524. smalltalk.method({
  525. selector: "showComment",
  526. fn: function (){
  527. var self=this;
  528. return smalltalk.withContext(function($ctx1) {
  529. var $2,$1;
  530. $2=self["@showComment"];
  531. if(($receiver = $2) == nil || $receiver == undefined){
  532. $1=false;
  533. } else {
  534. $1=$2;
  535. };
  536. return $1;
  537. }, function($ctx1) {$ctx1.fill(self,"showComment",{},smalltalk.HLBrowserModel)})},
  538. messageSends: ["ifNil:"]}),
  539. smalltalk.HLBrowserModel);
  540. smalltalk.addMethod(
  541. smalltalk.method({
  542. selector: "showComment:",
  543. fn: function (aBoolean){
  544. var self=this;
  545. function $HLShowCommentToggled(){return smalltalk.HLShowCommentToggled||(typeof HLShowCommentToggled=="undefined"?nil:HLShowCommentToggled)}
  546. return smalltalk.withContext(function($ctx1) {
  547. self._withChangesDo_((function(){
  548. return smalltalk.withContext(function($ctx2) {
  549. self["@showComment"]=aBoolean;
  550. self["@showComment"];
  551. return _st(self._announcer())._announce_(_st($HLShowCommentToggled())._new());
  552. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  553. return self}, function($ctx1) {$ctx1.fill(self,"showComment:",{aBoolean:aBoolean},smalltalk.HLBrowserModel)})},
  554. messageSends: ["withChangesDo:", "announce:", "new", "announcer"]}),
  555. smalltalk.HLBrowserModel);
  556. smalltalk.addMethod(
  557. smalltalk.method({
  558. selector: "showInstance",
  559. fn: function (){
  560. var self=this;
  561. return smalltalk.withContext(function($ctx1) {
  562. var $2,$1;
  563. $2=self["@showInstance"];
  564. if(($receiver = $2) == nil || $receiver == undefined){
  565. $1=true;
  566. } else {
  567. $1=$2;
  568. };
  569. return $1;
  570. }, function($ctx1) {$ctx1.fill(self,"showInstance",{},smalltalk.HLBrowserModel)})},
  571. messageSends: ["ifNil:"]}),
  572. smalltalk.HLBrowserModel);
  573. smalltalk.addMethod(
  574. smalltalk.method({
  575. selector: "showInstance:",
  576. fn: function (aBoolean){
  577. var self=this;
  578. function $HLShowInstanceToggled(){return smalltalk.HLShowInstanceToggled||(typeof HLShowInstanceToggled=="undefined"?nil:HLShowInstanceToggled)}
  579. return smalltalk.withContext(function($ctx1) {
  580. var $1,$2,$4,$3;
  581. self._withChangesDo_((function(){
  582. return smalltalk.withContext(function($ctx2) {
  583. self["@showInstance"]=aBoolean;
  584. self["@showInstance"];
  585. $1=self._selectedClass();
  586. if(($receiver = $1) == nil || $receiver == undefined){
  587. $1;
  588. } else {
  589. $2=self;
  590. $4=aBoolean;
  591. if(smalltalk.assert($4)){
  592. $3=_st(self._selectedClass())._theNonMetaClass();
  593. } else {
  594. $3=_st(self._selectedClass())._theMetaClass();
  595. };
  596. _st($2)._selectedClass_($3);
  597. };
  598. return _st(self._announcer())._announce_(_st($HLShowInstanceToggled())._new());
  599. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  600. return self}, function($ctx1) {$ctx1.fill(self,"showInstance:",{aBoolean:aBoolean},smalltalk.HLBrowserModel)})},
  601. messageSends: ["withChangesDo:", "ifNotNil:", "selectedClass:", "ifTrue:ifFalse:", "theNonMetaClass", "selectedClass", "theMetaClass", "announce:", "new", "announcer"]}),
  602. smalltalk.HLBrowserModel);
  603. smalltalk.addMethod(
  604. smalltalk.method({
  605. selector: "on:",
  606. fn: function (anEnvironment){
  607. var self=this;
  608. return smalltalk.withContext(function($ctx1) {
  609. var $2,$3,$1;
  610. $2=self._new();
  611. _st($2)._environment_(anEnvironment);
  612. $3=_st($2)._yourself();
  613. $1=$3;
  614. return $1;
  615. }, function($ctx1) {$ctx1.fill(self,"on:",{anEnvironment:anEnvironment},smalltalk.HLBrowserModel.klass)})},
  616. messageSends: ["environment:", "new", "yourself"]}),
  617. smalltalk.HLBrowserModel.klass);
  618. smalltalk.addClass('HLClassCache', smalltalk.Object, ['class', 'selectorsCache', 'overrideCache', 'overriddenCache'], 'Helios-Browser');
  619. smalltalk.addMethod(
  620. smalltalk.method({
  621. selector: "invalidateChildrenSelector:",
  622. fn: function (aSelector){
  623. var self=this;
  624. return smalltalk.withContext(function($ctx1) {
  625. var $1,$2;
  626. _st(_st(self._theClass())._subclasses())._do_((function(each){
  627. return smalltalk.withContext(function($ctx2) {
  628. $1=_st(self._selectorsCache())._cacheFor_(each);
  629. _st($1)._removeSelector_(aSelector);
  630. $2=_st($1)._invalidateChildrenSelector_(aSelector);
  631. return $2;
  632. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})}));
  633. return self}, function($ctx1) {$ctx1.fill(self,"invalidateChildrenSelector:",{aSelector:aSelector},smalltalk.HLClassCache)})},
  634. messageSends: ["do:", "removeSelector:", "cacheFor:", "selectorsCache", "invalidateChildrenSelector:", "subclasses", "theClass"]}),
  635. smalltalk.HLClassCache);
  636. smalltalk.addMethod(
  637. smalltalk.method({
  638. selector: "invalidateParentSelector:",
  639. fn: function (aSelector){
  640. var self=this;
  641. return smalltalk.withContext(function($ctx1) {
  642. var $1,$2,$3;
  643. $1=_st(self._theClass())._superclass();
  644. if(($receiver = $1) == nil || $receiver == undefined){
  645. $1;
  646. } else {
  647. $2=_st(self._selectorsCache())._cacheFor_(_st(self._theClass())._superclass());
  648. _st($2)._removeSelector_(aSelector);
  649. $3=_st($2)._invalidateParentSelector_(aSelector);
  650. $3;
  651. };
  652. return self}, function($ctx1) {$ctx1.fill(self,"invalidateParentSelector:",{aSelector:aSelector},smalltalk.HLClassCache)})},
  653. messageSends: ["ifNotNil:", "removeSelector:", "cacheFor:", "superclass", "theClass", "selectorsCache", "invalidateParentSelector:"]}),
  654. smalltalk.HLClassCache);
  655. smalltalk.addMethod(
  656. smalltalk.method({
  657. selector: "invalidateSelector:",
  658. fn: function (aSelector){
  659. var self=this;
  660. return smalltalk.withContext(function($ctx1) {
  661. var $1,$2;
  662. $1=self;
  663. _st($1)._invalidateParentSelector_(aSelector);
  664. _st($1)._invalidateChildrenSelector_(aSelector);
  665. $2=_st($1)._removeSelector_(aSelector);
  666. return self}, function($ctx1) {$ctx1.fill(self,"invalidateSelector:",{aSelector:aSelector},smalltalk.HLClassCache)})},
  667. messageSends: ["invalidateParentSelector:", "invalidateChildrenSelector:", "removeSelector:"]}),
  668. smalltalk.HLClassCache);
  669. smalltalk.addMethod(
  670. smalltalk.method({
  671. selector: "isOverridden:",
  672. fn: function (aMethod){
  673. var self=this;
  674. return smalltalk.withContext(function($ctx1) {
  675. var $1;
  676. $1=_st(self._overriddenCache())._at_ifAbsentPut_(_st(aMethod)._selector(),(function(){
  677. return smalltalk.withContext(function($ctx2) {
  678. return _st(aMethod)._isOverridden();
  679. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  680. return $1;
  681. }, function($ctx1) {$ctx1.fill(self,"isOverridden:",{aMethod:aMethod},smalltalk.HLClassCache)})},
  682. messageSends: ["at:ifAbsentPut:", "selector", "isOverridden", "overriddenCache"]}),
  683. smalltalk.HLClassCache);
  684. smalltalk.addMethod(
  685. smalltalk.method({
  686. selector: "isOverride:",
  687. fn: function (aMethod){
  688. var self=this;
  689. return smalltalk.withContext(function($ctx1) {
  690. var $1;
  691. $1=_st(self._overrideCache())._at_ifAbsentPut_(_st(aMethod)._selector(),(function(){
  692. return smalltalk.withContext(function($ctx2) {
  693. return _st(aMethod)._isOverride();
  694. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  695. return $1;
  696. }, function($ctx1) {$ctx1.fill(self,"isOverride:",{aMethod:aMethod},smalltalk.HLClassCache)})},
  697. messageSends: ["at:ifAbsentPut:", "selector", "isOverride", "overrideCache"]}),
  698. smalltalk.HLClassCache);
  699. smalltalk.addMethod(
  700. smalltalk.method({
  701. selector: "overriddenCache",
  702. fn: function (){
  703. var self=this;
  704. function $HashedCollection(){return smalltalk.HashedCollection||(typeof HashedCollection=="undefined"?nil:HashedCollection)}
  705. return smalltalk.withContext(function($ctx1) {
  706. var $2,$1;
  707. $2=self["@overriddenCache"];
  708. if(($receiver = $2) == nil || $receiver == undefined){
  709. self["@overriddenCache"]=_st($HashedCollection())._new();
  710. $1=self["@overriddenCache"];
  711. } else {
  712. $1=$2;
  713. };
  714. return $1;
  715. }, function($ctx1) {$ctx1.fill(self,"overriddenCache",{},smalltalk.HLClassCache)})},
  716. messageSends: ["ifNil:", "new"]}),
  717. smalltalk.HLClassCache);
  718. smalltalk.addMethod(
  719. smalltalk.method({
  720. selector: "overrideCache",
  721. fn: function (){
  722. var self=this;
  723. function $HashedCollection(){return smalltalk.HashedCollection||(typeof HashedCollection=="undefined"?nil:HashedCollection)}
  724. return smalltalk.withContext(function($ctx1) {
  725. var $2,$1;
  726. $2=self["@overrideCache"];
  727. if(($receiver = $2) == nil || $receiver == undefined){
  728. self["@overrideCache"]=_st($HashedCollection())._new();
  729. $1=self["@overrideCache"];
  730. } else {
  731. $1=$2;
  732. };
  733. return $1;
  734. }, function($ctx1) {$ctx1.fill(self,"overrideCache",{},smalltalk.HLClassCache)})},
  735. messageSends: ["ifNil:", "new"]}),
  736. smalltalk.HLClassCache);
  737. smalltalk.addMethod(
  738. smalltalk.method({
  739. selector: "removeSelector:",
  740. fn: function (aSelector){
  741. var self=this;
  742. return smalltalk.withContext(function($ctx1) {
  743. _st(self._overriddenCache())._removeKey_ifAbsent_(aSelector,(function(){
  744. return smalltalk.withContext(function($ctx2) {
  745. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  746. _st(self._overrideCache())._removeKey_ifAbsent_(aSelector,(function(){
  747. return smalltalk.withContext(function($ctx2) {
  748. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  749. return self}, function($ctx1) {$ctx1.fill(self,"removeSelector:",{aSelector:aSelector},smalltalk.HLClassCache)})},
  750. messageSends: ["removeKey:ifAbsent:", "overriddenCache", "overrideCache"]}),
  751. smalltalk.HLClassCache);
  752. smalltalk.addMethod(
  753. smalltalk.method({
  754. selector: "selectorsCache",
  755. fn: function (){
  756. var self=this;
  757. return smalltalk.withContext(function($ctx1) {
  758. var $1;
  759. $1=self["@selectorsCache"];
  760. return $1;
  761. }, function($ctx1) {$ctx1.fill(self,"selectorsCache",{},smalltalk.HLClassCache)})},
  762. messageSends: []}),
  763. smalltalk.HLClassCache);
  764. smalltalk.addMethod(
  765. smalltalk.method({
  766. selector: "selectorsCache:",
  767. fn: function (aCache){
  768. var self=this;
  769. return smalltalk.withContext(function($ctx1) {
  770. self["@selectorsCache"]=aCache;
  771. return self}, function($ctx1) {$ctx1.fill(self,"selectorsCache:",{aCache:aCache},smalltalk.HLClassCache)})},
  772. messageSends: []}),
  773. smalltalk.HLClassCache);
  774. smalltalk.addMethod(
  775. smalltalk.method({
  776. selector: "theClass",
  777. fn: function (){
  778. var self=this;
  779. return smalltalk.withContext(function($ctx1) {
  780. var $1;
  781. $1=self["@class"];
  782. return $1;
  783. }, function($ctx1) {$ctx1.fill(self,"theClass",{},smalltalk.HLClassCache)})},
  784. messageSends: []}),
  785. smalltalk.HLClassCache);
  786. smalltalk.addMethod(
  787. smalltalk.method({
  788. selector: "theClass:",
  789. fn: function (aClass){
  790. var self=this;
  791. return smalltalk.withContext(function($ctx1) {
  792. self["@class"]=aClass;
  793. return self}, function($ctx1) {$ctx1.fill(self,"theClass:",{aClass:aClass},smalltalk.HLClassCache)})},
  794. messageSends: []}),
  795. smalltalk.HLClassCache);
  796. smalltalk.addMethod(
  797. smalltalk.method({
  798. selector: "on:selectorsCache:",
  799. fn: function (aClass,aSelectorsCache){
  800. var self=this;
  801. return smalltalk.withContext(function($ctx1) {
  802. var $2,$3,$1;
  803. $2=self._new();
  804. _st($2)._theClass_(aClass);
  805. _st($2)._selectorsCache_(aSelectorsCache);
  806. $3=_st($2)._yourself();
  807. $1=$3;
  808. return $1;
  809. }, function($ctx1) {$ctx1.fill(self,"on:selectorsCache:",{aClass:aClass,aSelectorsCache:aSelectorsCache},smalltalk.HLClassCache.klass)})},
  810. messageSends: ["theClass:", "new", "selectorsCache:", "yourself"]}),
  811. smalltalk.HLClassCache.klass);
  812. smalltalk.addClass('HLClassesListWidget', smalltalk.HLToolListWidget, [], 'Helios-Browser');
  813. smalltalk.addMethod(
  814. smalltalk.method({
  815. selector: "cssClassForItem:",
  816. fn: function (aClass){
  817. var self=this;
  818. return smalltalk.withContext(function($ctx1) {
  819. var $1,$2;
  820. $1=_st(_st(_st(aClass)._theNonMetaClass())._comment())._isEmpty();
  821. if(smalltalk.assert($1)){
  822. return "uncommented";
  823. };
  824. $2=_st(_st(aClass)._theNonMetaClass())._heliosClass();
  825. return $2;
  826. }, function($ctx1) {$ctx1.fill(self,"cssClassForItem:",{aClass:aClass},smalltalk.HLClassesListWidget)})},
  827. messageSends: ["ifTrue:", "isEmpty", "comment", "theNonMetaClass", "heliosClass"]}),
  828. smalltalk.HLClassesListWidget);
  829. smalltalk.addMethod(
  830. smalltalk.method({
  831. selector: "focusMethodsListWidget",
  832. fn: function (){
  833. var self=this;
  834. function $HLMethodsListFocus(){return smalltalk.HLMethodsListFocus||(typeof HLMethodsListFocus=="undefined"?nil:HLMethodsListFocus)}
  835. return smalltalk.withContext(function($ctx1) {
  836. _st(_st(self._model())._announcer())._announce_(_st($HLMethodsListFocus())._new());
  837. return self}, function($ctx1) {$ctx1.fill(self,"focusMethodsListWidget",{},smalltalk.HLClassesListWidget)})},
  838. messageSends: ["announce:", "new", "announcer", "model"]}),
  839. smalltalk.HLClassesListWidget);
  840. smalltalk.addMethod(
  841. smalltalk.method({
  842. selector: "focusProtocolsListWidget",
  843. fn: function (){
  844. var self=this;
  845. function $HLProtocolsListFocus(){return smalltalk.HLProtocolsListFocus||(typeof HLProtocolsListFocus=="undefined"?nil:HLProtocolsListFocus)}
  846. return smalltalk.withContext(function($ctx1) {
  847. _st(_st(self._model())._announcer())._announce_(_st($HLProtocolsListFocus())._new());
  848. return self}, function($ctx1) {$ctx1.fill(self,"focusProtocolsListWidget",{},smalltalk.HLClassesListWidget)})},
  849. messageSends: ["announce:", "new", "announcer", "model"]}),
  850. smalltalk.HLClassesListWidget);
  851. smalltalk.addMethod(
  852. smalltalk.method({
  853. selector: "getChildrenOf:",
  854. fn: function (aClass){
  855. var self=this;
  856. return smalltalk.withContext(function($ctx1) {
  857. var $1;
  858. $1=_st(self._items())._select_((function(each){
  859. return smalltalk.withContext(function($ctx2) {
  860. return _st(_st(each)._superclass()).__eq(aClass);
  861. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})}));
  862. return $1;
  863. }, function($ctx1) {$ctx1.fill(self,"getChildrenOf:",{aClass:aClass},smalltalk.HLClassesListWidget)})},
  864. messageSends: ["select:", "=", "superclass", "items"]}),
  865. smalltalk.HLClassesListWidget);
  866. smalltalk.addMethod(
  867. smalltalk.method({
  868. selector: "getRootClassesOf:",
  869. fn: function (aCollection){
  870. var self=this;
  871. return smalltalk.withContext(function($ctx1) {
  872. var $1;
  873. $1=_st(aCollection)._select_((function(each){
  874. return smalltalk.withContext(function($ctx2) {
  875. return _st(_st(aCollection)._includes_(_st(each)._superclass()))._not();
  876. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})}));
  877. return $1;
  878. }, function($ctx1) {$ctx1.fill(self,"getRootClassesOf:",{aCollection:aCollection},smalltalk.HLClassesListWidget)})},
  879. messageSends: ["select:", "not", "includes:", "superclass"]}),
  880. smalltalk.HLClassesListWidget);
  881. smalltalk.addMethod(
  882. smalltalk.method({
  883. selector: "label",
  884. fn: function (){
  885. var self=this;
  886. return smalltalk.withContext(function($ctx1) {
  887. return "Classes";
  888. }, function($ctx1) {$ctx1.fill(self,"label",{},smalltalk.HLClassesListWidget)})},
  889. messageSends: []}),
  890. smalltalk.HLClassesListWidget);
  891. smalltalk.addMethod(
  892. smalltalk.method({
  893. selector: "observeModel",
  894. fn: function (){
  895. var self=this;
  896. function $HLPackageSelected(){return smalltalk.HLPackageSelected||(typeof HLPackageSelected=="undefined"?nil:HLPackageSelected)}
  897. function $HLShowInstanceToggled(){return smalltalk.HLShowInstanceToggled||(typeof HLShowInstanceToggled=="undefined"?nil:HLShowInstanceToggled)}
  898. function $HLShowCommentToggled(){return smalltalk.HLShowCommentToggled||(typeof HLShowCommentToggled=="undefined"?nil:HLShowCommentToggled)}
  899. function $HLClassSelected(){return smalltalk.HLClassSelected||(typeof HLClassSelected=="undefined"?nil:HLClassSelected)}
  900. function $HLClassesFocusRequested(){return smalltalk.HLClassesFocusRequested||(typeof HLClassesFocusRequested=="undefined"?nil:HLClassesFocusRequested)}
  901. return smalltalk.withContext(function($ctx1) {
  902. var $1,$2;
  903. $1=_st(self._model())._announcer();
  904. _st($1)._on_send_to_($HLPackageSelected(),"onPackageSelected:",self);
  905. _st($1)._on_send_to_($HLShowInstanceToggled(),"onShowInstanceToggled",self);
  906. _st($1)._on_send_to_($HLShowCommentToggled(),"onShowCommentToggled",self);
  907. _st($1)._on_send_to_($HLClassSelected(),"onClassSelected:",self);
  908. $2=_st($1)._on_send_to_($HLClassesFocusRequested(),"onClassesFocusRequested",self);
  909. return self}, function($ctx1) {$ctx1.fill(self,"observeModel",{},smalltalk.HLClassesListWidget)})},
  910. messageSends: ["on:send:to:", "announcer", "model"]}),
  911. smalltalk.HLClassesListWidget);
  912. smalltalk.addMethod(
  913. smalltalk.method({
  914. selector: "observeSystem",
  915. fn: function (){
  916. var self=this;
  917. function $ClassAdded(){return smalltalk.ClassAdded||(typeof ClassAdded=="undefined"?nil:ClassAdded)}
  918. function $ClassRemoved(){return smalltalk.ClassRemoved||(typeof ClassRemoved=="undefined"?nil:ClassRemoved)}
  919. function $ClassMoved(){return smalltalk.ClassMoved||(typeof ClassMoved=="undefined"?nil:ClassMoved)}
  920. function $ClassRenamed(){return smalltalk.ClassRenamed||(typeof ClassRenamed=="undefined"?nil:ClassRenamed)}
  921. function $ClassMigrated(){return smalltalk.ClassMigrated||(typeof ClassMigrated=="undefined"?nil:ClassMigrated)}
  922. function $ClassCommentChanged(){return smalltalk.ClassCommentChanged||(typeof ClassCommentChanged=="undefined"?nil:ClassCommentChanged)}
  923. return smalltalk.withContext(function($ctx1) {
  924. var $1,$2;
  925. $1=_st(self._model())._systemAnnouncer();
  926. _st($1)._on_send_to_($ClassAdded(),"onClassAdded:",self);
  927. _st($1)._on_send_to_($ClassRemoved(),"onClassRemoved:",self);
  928. _st($1)._on_send_to_($ClassMoved(),"onClassMoved:",self);
  929. _st($1)._on_send_to_($ClassRenamed(),"onClassRenamed:",self);
  930. _st($1)._on_send_to_($ClassMigrated(),"onClassMigrated:",self);
  931. $2=_st($1)._on_send_to_($ClassCommentChanged(),"onClassCommentChanged:",self);
  932. return self}, function($ctx1) {$ctx1.fill(self,"observeSystem",{},smalltalk.HLClassesListWidget)})},
  933. messageSends: ["on:send:to:", "systemAnnouncer", "model"]}),
  934. smalltalk.HLClassesListWidget);
  935. smalltalk.addMethod(
  936. smalltalk.method({
  937. selector: "onClassAdded:",
  938. fn: function (anAnnouncement){
  939. var self=this;
  940. var class_;
  941. return smalltalk.withContext(function($ctx1) {
  942. var $1,$2;
  943. class_=_st(anAnnouncement)._theClass();
  944. $1=_st(_st(_st(class_)._package()).__eq(_st(self._model())._selectedPackage()))._or_((function(){
  945. return smalltalk.withContext(function($ctx2) {
  946. return _st(self._items())._includes_(class_);
  947. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  948. if(! smalltalk.assert($1)){
  949. $2=self;
  950. return $2;
  951. };
  952. self._setItemsForSelectedPackage();
  953. self._refresh();
  954. return self}, function($ctx1) {$ctx1.fill(self,"onClassAdded:",{anAnnouncement:anAnnouncement,class_:class_},smalltalk.HLClassesListWidget)})},
  955. messageSends: ["theClass", "ifFalse:", "or:", "includes:", "items", "=", "selectedPackage", "model", "package", "setItemsForSelectedPackage", "refresh"]}),
  956. smalltalk.HLClassesListWidget);
  957. smalltalk.addMethod(
  958. smalltalk.method({
  959. selector: "onClassCommentChanged:",
  960. fn: function (anAnnouncement){
  961. var self=this;
  962. var class_;
  963. return smalltalk.withContext(function($ctx1) {
  964. var $1,$2;
  965. class_=_st(anAnnouncement)._theClass();
  966. $1=_st(_st(class_)._package()).__eq(_st(self._model())._selectedPackage());
  967. if(! smalltalk.assert($1)){
  968. $2=self;
  969. return $2;
  970. };
  971. self._refresh();
  972. return self}, function($ctx1) {$ctx1.fill(self,"onClassCommentChanged:",{anAnnouncement:anAnnouncement,class_:class_},smalltalk.HLClassesListWidget)})},
  973. messageSends: ["theClass", "ifFalse:", "=", "selectedPackage", "model", "package", "refresh"]}),
  974. smalltalk.HLClassesListWidget);
  975. smalltalk.addMethod(
  976. smalltalk.method({
  977. selector: "onClassMigrated:",
  978. fn: function (anAnnouncement){
  979. var self=this;
  980. var class_,oldClass;
  981. return smalltalk.withContext(function($ctx1) {
  982. var $1,$2,$3;
  983. class_=_st(anAnnouncement)._theClass();
  984. oldClass=_st(anAnnouncement)._oldClass();
  985. $1=_st(self._items())._includes_(oldClass);
  986. if(! smalltalk.assert($1)){
  987. $2=self;
  988. return $2;
  989. };
  990. $3=_st(_st(self._model())._selectedClass()).__eq(oldClass);
  991. if(smalltalk.assert($3)){
  992. _st(self._model())._selectedClass_(class_);
  993. };
  994. self._setItemsForSelectedPackage();
  995. self._refresh();
  996. return self}, function($ctx1) {$ctx1.fill(self,"onClassMigrated:",{anAnnouncement:anAnnouncement,class_:class_,oldClass:oldClass},smalltalk.HLClassesListWidget)})},
  997. messageSends: ["theClass", "oldClass", "ifFalse:", "includes:", "items", "ifTrue:", "selectedClass:", "model", "=", "selectedClass", "setItemsForSelectedPackage", "refresh"]}),
  998. smalltalk.HLClassesListWidget);
  999. smalltalk.addMethod(
  1000. smalltalk.method({
  1001. selector: "onClassMoved:",
  1002. fn: function (anAnnouncement){
  1003. var self=this;
  1004. var class_,oldPackage;
  1005. return smalltalk.withContext(function($ctx1) {
  1006. var $1,$2,$3,$4,$5;
  1007. class_=_st(anAnnouncement)._theClass();
  1008. oldPackage=_st(anAnnouncement)._oldPackage();
  1009. $1=_st(_st(oldPackage).__eq(_st(self._model())._selectedPackage()))._or_((function(){
  1010. return smalltalk.withContext(function($ctx2) {
  1011. return _st(_st(class_)._package()).__eq(_st(self._model())._selectedPackage());
  1012. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  1013. if(! smalltalk.assert($1)){
  1014. $2=self;
  1015. return $2;
  1016. };
  1017. $3=_st(oldPackage).__eq(_st(self._model())._selectedPackage());
  1018. if(smalltalk.assert($3)){
  1019. $4=self;
  1020. _st($4)._selectedItem_(nil);
  1021. $5=_st($4)._selectItem_(nil);
  1022. $5;
  1023. };
  1024. self._setItemsForSelectedPackage();
  1025. self._refresh();
  1026. return self}, function($ctx1) {$ctx1.fill(self,"onClassMoved:",{anAnnouncement:anAnnouncement,class_:class_,oldPackage:oldPackage},smalltalk.HLClassesListWidget)})},
  1027. messageSends: ["theClass", "oldPackage", "ifFalse:", "or:", "=", "selectedPackage", "model", "package", "ifTrue:", "selectedItem:", "selectItem:", "setItemsForSelectedPackage", "refresh"]}),
  1028. smalltalk.HLClassesListWidget);
  1029. smalltalk.addMethod(
  1030. smalltalk.method({
  1031. selector: "onClassRemoved:",
  1032. fn: function (anAnnouncement){
  1033. var self=this;
  1034. var class_;
  1035. return smalltalk.withContext(function($ctx1) {
  1036. var $1,$2;
  1037. class_=_st(anAnnouncement)._theClass();
  1038. $1=_st(_st(class_)._package()).__eq(_st(self._model())._selectedPackage());
  1039. if(! smalltalk.assert($1)){
  1040. $2=self;
  1041. return $2;
  1042. };
  1043. self._setItemsForSelectedPackage();
  1044. self._refresh();
  1045. return self}, function($ctx1) {$ctx1.fill(self,"onClassRemoved:",{anAnnouncement:anAnnouncement,class_:class_},smalltalk.HLClassesListWidget)})},
  1046. messageSends: ["theClass", "ifFalse:", "=", "selectedPackage", "model", "package", "setItemsForSelectedPackage", "refresh"]}),
  1047. smalltalk.HLClassesListWidget);
  1048. smalltalk.addMethod(
  1049. smalltalk.method({
  1050. selector: "onClassRenamed:",
  1051. fn: function (anAnnouncement){
  1052. var self=this;
  1053. return smalltalk.withContext(function($ctx1) {
  1054. var $1,$2;
  1055. $1=_st(_st(_st(anAnnouncement)._theClass())._package()).__eq(_st(self._model())._selectedPackage());
  1056. if(! smalltalk.assert($1)){
  1057. $2=self;
  1058. return $2;
  1059. };
  1060. self._setItemsForSelectedPackage();
  1061. self._refresh();
  1062. return self}, function($ctx1) {$ctx1.fill(self,"onClassRenamed:",{anAnnouncement:anAnnouncement},smalltalk.HLClassesListWidget)})},
  1063. messageSends: ["ifFalse:", "=", "selectedPackage", "model", "package", "theClass", "setItemsForSelectedPackage", "refresh"]}),
  1064. smalltalk.HLClassesListWidget);
  1065. smalltalk.addMethod(
  1066. smalltalk.method({
  1067. selector: "onClassSelected:",
  1068. fn: function (anAnnouncement){
  1069. var self=this;
  1070. var selectedClass;
  1071. return smalltalk.withContext(function($ctx1) {
  1072. var $1,$2,$3,$4,$5;
  1073. $1=_st(anAnnouncement)._item();
  1074. if(($receiver = $1) == nil || $receiver == undefined){
  1075. $2=self;
  1076. return $2;
  1077. } else {
  1078. $1;
  1079. };
  1080. selectedClass=_st(_st(anAnnouncement)._item())._theNonMetaClass();
  1081. self._selectedItem_(selectedClass);
  1082. $3=self._hasFocus();
  1083. if(! smalltalk.assert($3)){
  1084. $4=self;
  1085. _st($4)._activateItem_(selectedClass);
  1086. $5=_st($4)._focus();
  1087. $5;
  1088. };
  1089. return self}, function($ctx1) {$ctx1.fill(self,"onClassSelected:",{anAnnouncement:anAnnouncement,selectedClass:selectedClass},smalltalk.HLClassesListWidget)})},
  1090. messageSends: ["ifNil:", "item", "theNonMetaClass", "selectedItem:", "ifFalse:", "activateItem:", "focus", "hasFocus"]}),
  1091. smalltalk.HLClassesListWidget);
  1092. smalltalk.addMethod(
  1093. smalltalk.method({
  1094. selector: "onClassesFocusRequested",
  1095. fn: function (){
  1096. var self=this;
  1097. return smalltalk.withContext(function($ctx1) {
  1098. self._focus();
  1099. return self}, function($ctx1) {$ctx1.fill(self,"onClassesFocusRequested",{},smalltalk.HLClassesListWidget)})},
  1100. messageSends: ["focus"]}),
  1101. smalltalk.HLClassesListWidget);
  1102. smalltalk.addMethod(
  1103. smalltalk.method({
  1104. selector: "onPackageSelected:",
  1105. fn: function (anAnnouncement){
  1106. var self=this;
  1107. return smalltalk.withContext(function($ctx1) {
  1108. self._selectedItem_(nil);
  1109. self._setItemsForSelectedPackage();
  1110. self._refresh();
  1111. return self}, function($ctx1) {$ctx1.fill(self,"onPackageSelected:",{anAnnouncement:anAnnouncement},smalltalk.HLClassesListWidget)})},
  1112. messageSends: ["selectedItem:", "setItemsForSelectedPackage", "refresh"]}),
  1113. smalltalk.HLClassesListWidget);
  1114. smalltalk.addMethod(
  1115. smalltalk.method({
  1116. selector: "onShowCommentToggled",
  1117. fn: function (){
  1118. var self=this;
  1119. return smalltalk.withContext(function($ctx1) {
  1120. self._refresh();
  1121. return self}, function($ctx1) {$ctx1.fill(self,"onShowCommentToggled",{},smalltalk.HLClassesListWidget)})},
  1122. messageSends: ["refresh"]}),
  1123. smalltalk.HLClassesListWidget);
  1124. smalltalk.addMethod(
  1125. smalltalk.method({
  1126. selector: "onShowInstanceToggled",
  1127. fn: function (){
  1128. var self=this;
  1129. return smalltalk.withContext(function($ctx1) {
  1130. self._refresh();
  1131. return self}, function($ctx1) {$ctx1.fill(self,"onShowInstanceToggled",{},smalltalk.HLClassesListWidget)})},
  1132. messageSends: ["refresh"]}),
  1133. smalltalk.HLClassesListWidget);
  1134. smalltalk.addMethod(
  1135. smalltalk.method({
  1136. selector: "renderButtonsOn:",
  1137. fn: function (html){
  1138. var self=this;
  1139. var checkbox;
  1140. function $String(){return smalltalk.String||(typeof String=="undefined"?nil:String)}
  1141. return smalltalk.withContext(function($ctx1) {
  1142. var $1,$3,$4,$5,$6,$7,$8,$2,$9,$11,$12,$10,$13;
  1143. $1=_st(html)._div();
  1144. _st($1)._class_("btn-group");
  1145. $2=_st($1)._with_((function(){
  1146. return smalltalk.withContext(function($ctx2) {
  1147. $3=_st(html)._button();
  1148. _st($3)._class_(_st($String())._streamContents_((function(str){
  1149. return smalltalk.withContext(function($ctx3) {
  1150. _st(str)._nextPutAll_("btn");
  1151. $4=self._showInstance();
  1152. if(smalltalk.assert($4)){
  1153. return _st(str)._nextPutAll_(" active");
  1154. };
  1155. }, function($ctx3) {$ctx3.fillBlock({str:str},$ctx2)})})));
  1156. _st($3)._with_("Instance");
  1157. $5=_st($3)._onClick_((function(){
  1158. return smalltalk.withContext(function($ctx3) {
  1159. return self._showInstance_(true);
  1160. }, function($ctx3) {$ctx3.fillBlock({},$ctx2)})}));
  1161. $5;
  1162. $6=_st(html)._button();
  1163. _st($6)._class_(_st($String())._streamContents_((function(str){
  1164. return smalltalk.withContext(function($ctx3) {
  1165. _st(str)._nextPutAll_("btn");
  1166. $7=self._showClass();
  1167. if(smalltalk.assert($7)){
  1168. return _st(str)._nextPutAll_(" active");
  1169. };
  1170. }, function($ctx3) {$ctx3.fillBlock({str:str},$ctx2)})})));
  1171. _st($6)._with_("Class");
  1172. $8=_st($6)._onClick_((function(){
  1173. return smalltalk.withContext(function($ctx3) {
  1174. return self._showInstance_(false);
  1175. }, function($ctx3) {$ctx3.fillBlock({},$ctx2)})}));
  1176. return $8;
  1177. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  1178. $9=_st(html)._label();
  1179. _st($9)._class_("checkbox");
  1180. $10=_st($9)._with_((function(){
  1181. return smalltalk.withContext(function($ctx2) {
  1182. $11=_st(html)._input();
  1183. _st($11)._type_("checkbox");
  1184. $12=_st($11)._onClick_((function(){
  1185. return smalltalk.withContext(function($ctx3) {
  1186. return self._toggleShowComment();
  1187. }, function($ctx3) {$ctx3.fillBlock({},$ctx2)})}));
  1188. checkbox=$12;
  1189. checkbox;
  1190. return _st(html)._with_("Doc");
  1191. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  1192. $13=self._showComment();
  1193. if(smalltalk.assert($13)){
  1194. _st(checkbox)._at_put_("checked","checked");
  1195. };
  1196. return self}, function($ctx1) {$ctx1.fill(self,"renderButtonsOn:",{html:html,checkbox:checkbox},smalltalk.HLClassesListWidget)})},
  1197. messageSends: ["class:", "div", "with:", "streamContents:", "nextPutAll:", "ifTrue:", "showInstance", "button", "onClick:", "showInstance:", "showClass", "label", "type:", "input", "toggleShowComment", "at:put:", "showComment"]}),
  1198. smalltalk.HLClassesListWidget);
  1199. smalltalk.addMethod(
  1200. smalltalk.method({
  1201. selector: "renderItem:level:on:",
  1202. fn: function (aClass,anInteger,html){
  1203. var self=this;
  1204. var li;
  1205. return smalltalk.withContext(function($ctx1) {
  1206. var $1,$3,$4,$2;
  1207. li=_st(html)._li();
  1208. self._registerMappingFrom_to_(aClass,li);
  1209. $1=li;
  1210. _st($1)._at_put_("list-data",_st(self._items())._indexOf_(aClass));
  1211. _st($1)._class_(self._listCssClassForItem_(aClass));
  1212. $2=_st($1)._with_((function(){
  1213. return smalltalk.withContext(function($ctx2) {
  1214. $3=_st(html)._a();
  1215. _st($3)._with_((function(){
  1216. return smalltalk.withContext(function($ctx3) {
  1217. _st(_st(html)._tag_("i"))._class_(self._cssClassForItem_(aClass));
  1218. return self._renderItemLabel_level_on_(aClass,anInteger,html);
  1219. }, function($ctx3) {$ctx3.fillBlock({},$ctx2)})}));
  1220. $4=_st($3)._onClick_((function(){
  1221. return smalltalk.withContext(function($ctx3) {
  1222. return self._activateListItem_(_st(li)._asJQuery());
  1223. }, function($ctx3) {$ctx3.fillBlock({},$ctx2)})}));
  1224. return $4;
  1225. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  1226. _st(self._getChildrenOf_(aClass))._do_((function(each){
  1227. return smalltalk.withContext(function($ctx2) {
  1228. return self._renderItem_level_on_(each,_st(anInteger).__plus((1)),html);
  1229. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})}));
  1230. return self}, function($ctx1) {$ctx1.fill(self,"renderItem:level:on:",{aClass:aClass,anInteger:anInteger,html:html,li:li},smalltalk.HLClassesListWidget)})},
  1231. messageSends: ["li", "registerMappingFrom:to:", "at:put:", "indexOf:", "items", "class:", "listCssClassForItem:", "with:", "cssClassForItem:", "tag:", "renderItemLabel:level:on:", "a", "onClick:", "activateListItem:", "asJQuery", "do:", "renderItem:level:on:", "+", "getChildrenOf:"]}),
  1232. smalltalk.HLClassesListWidget);
  1233. smalltalk.addMethod(
  1234. smalltalk.method({
  1235. selector: "renderItem:on:",
  1236. fn: function (aClass,html){
  1237. var self=this;
  1238. return smalltalk.withContext(function($ctx1) {
  1239. smalltalk.HLClassesListWidget.superclass.fn.prototype._renderItem_on_.apply(_st(self), [aClass,html]);
  1240. _st(self._getChildrenOf_(aClass))._do_((function(each){
  1241. return smalltalk.withContext(function($ctx2) {
  1242. return self._renderItem_level_on_(each,(1),html);
  1243. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})}));
  1244. return self}, function($ctx1) {$ctx1.fill(self,"renderItem:on:",{aClass:aClass,html:html},smalltalk.HLClassesListWidget)})},
  1245. messageSends: ["renderItem:on:", "do:", "renderItem:level:on:", "getChildrenOf:"]}),
  1246. smalltalk.HLClassesListWidget);
  1247. smalltalk.addMethod(
  1248. smalltalk.method({
  1249. selector: "renderItemLabel:level:on:",
  1250. fn: function (aClass,anInteger,html){
  1251. var self=this;
  1252. function $String(){return smalltalk.String||(typeof String=="undefined"?nil:String)}
  1253. return smalltalk.withContext(function($ctx1) {
  1254. _st(_st(_st(html)._span())._asJQuery())._html_(_st($String())._streamContents_((function(str){
  1255. return smalltalk.withContext(function($ctx2) {
  1256. _st(anInteger)._timesRepeat_((function(){
  1257. return smalltalk.withContext(function($ctx3) {
  1258. return _st(str)._nextPutAll_("    ");
  1259. }, function($ctx3) {$ctx3.fillBlock({},$ctx2)})}));
  1260. return _st(str)._nextPutAll_(_st(aClass)._name());
  1261. }, function($ctx2) {$ctx2.fillBlock({str:str},$ctx1)})})));
  1262. return self}, function($ctx1) {$ctx1.fill(self,"renderItemLabel:level:on:",{aClass:aClass,anInteger:anInteger,html:html},smalltalk.HLClassesListWidget)})},
  1263. messageSends: ["html:", "streamContents:", "timesRepeat:", "nextPutAll:", "name", "asJQuery", "span"]}),
  1264. smalltalk.HLClassesListWidget);
  1265. smalltalk.addMethod(
  1266. smalltalk.method({
  1267. selector: "renderItemLabel:on:",
  1268. fn: function (aClass,html){
  1269. var self=this;
  1270. return smalltalk.withContext(function($ctx1) {
  1271. self._renderItemLabel_level_on_(aClass,(0),html);
  1272. return self}, function($ctx1) {$ctx1.fill(self,"renderItemLabel:on:",{aClass:aClass,html:html},smalltalk.HLClassesListWidget)})},
  1273. messageSends: ["renderItemLabel:level:on:"]}),
  1274. smalltalk.HLClassesListWidget);
  1275. smalltalk.addMethod(
  1276. smalltalk.method({
  1277. selector: "renderListOn:",
  1278. fn: function (html){
  1279. var self=this;
  1280. return smalltalk.withContext(function($ctx1) {
  1281. _st(self._getRootClassesOf_(self._items()))._do_((function(each){
  1282. return smalltalk.withContext(function($ctx2) {
  1283. return self._renderItem_on_(each,html);
  1284. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})}));
  1285. return self}, function($ctx1) {$ctx1.fill(self,"renderListOn:",{html:html},smalltalk.HLClassesListWidget)})},
  1286. messageSends: ["do:", "renderItem:on:", "getRootClassesOf:", "items"]}),
  1287. smalltalk.HLClassesListWidget);
  1288. smalltalk.addMethod(
  1289. smalltalk.method({
  1290. selector: "selectItem:",
  1291. fn: function (aClass){
  1292. var self=this;
  1293. return smalltalk.withContext(function($ctx1) {
  1294. _st(self._model())._selectedClass_(aClass);
  1295. return self}, function($ctx1) {$ctx1.fill(self,"selectItem:",{aClass:aClass},smalltalk.HLClassesListWidget)})},
  1296. messageSends: ["selectedClass:", "model"]}),
  1297. smalltalk.HLClassesListWidget);
  1298. smalltalk.addMethod(
  1299. smalltalk.method({
  1300. selector: "setItemsForPackage:",
  1301. fn: function (aPackage){
  1302. var self=this;
  1303. return smalltalk.withContext(function($ctx1) {
  1304. var $1,$3,$2;
  1305. $1=self;
  1306. $3=aPackage;
  1307. if(($receiver = $3) == nil || $receiver == undefined){
  1308. $2=[];
  1309. } else {
  1310. $2=_st(_st(_st(_st(_st(aPackage)._classes())._collect_((function(each){
  1311. return smalltalk.withContext(function($ctx2) {
  1312. return _st(each)._theNonMetaClass();
  1313. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})})))._asSet())._asArray())._sort_((function(a,b){
  1314. return smalltalk.withContext(function($ctx2) {
  1315. return _st(_st(a)._name()).__lt(_st(b)._name());
  1316. }, function($ctx2) {$ctx2.fillBlock({a:a,b:b},$ctx1)})}));
  1317. };
  1318. _st($1)._items_($2);
  1319. return self}, function($ctx1) {$ctx1.fill(self,"setItemsForPackage:",{aPackage:aPackage},smalltalk.HLClassesListWidget)})},
  1320. messageSends: ["items:", "ifNil:ifNotNil:", "sort:", "<", "name", "asArray", "asSet", "collect:", "theNonMetaClass", "classes"]}),
  1321. smalltalk.HLClassesListWidget);
  1322. smalltalk.addMethod(
  1323. smalltalk.method({
  1324. selector: "setItemsForSelectedPackage",
  1325. fn: function (){
  1326. var self=this;
  1327. return smalltalk.withContext(function($ctx1) {
  1328. self._setItemsForPackage_(_st(self._model())._selectedPackage());
  1329. return self}, function($ctx1) {$ctx1.fill(self,"setItemsForSelectedPackage",{},smalltalk.HLClassesListWidget)})},
  1330. messageSends: ["setItemsForPackage:", "selectedPackage", "model"]}),
  1331. smalltalk.HLClassesListWidget);
  1332. smalltalk.addMethod(
  1333. smalltalk.method({
  1334. selector: "showClass",
  1335. fn: function (){
  1336. var self=this;
  1337. return smalltalk.withContext(function($ctx1) {
  1338. var $1;
  1339. $1=_st(_st(self._model())._showInstance())._not();
  1340. return $1;
  1341. }, function($ctx1) {$ctx1.fill(self,"showClass",{},smalltalk.HLClassesListWidget)})},
  1342. messageSends: ["not", "showInstance", "model"]}),
  1343. smalltalk.HLClassesListWidget);
  1344. smalltalk.addMethod(
  1345. smalltalk.method({
  1346. selector: "showComment",
  1347. fn: function (){
  1348. var self=this;
  1349. return smalltalk.withContext(function($ctx1) {
  1350. var $1;
  1351. $1=_st(self._model())._showComment();
  1352. return $1;
  1353. }, function($ctx1) {$ctx1.fill(self,"showComment",{},smalltalk.HLClassesListWidget)})},
  1354. messageSends: ["showComment", "model"]}),
  1355. smalltalk.HLClassesListWidget);
  1356. smalltalk.addMethod(
  1357. smalltalk.method({
  1358. selector: "showComment:",
  1359. fn: function (aBoolean){
  1360. var self=this;
  1361. return smalltalk.withContext(function($ctx1) {
  1362. _st(self._model())._showComment_(aBoolean);
  1363. return self}, function($ctx1) {$ctx1.fill(self,"showComment:",{aBoolean:aBoolean},smalltalk.HLClassesListWidget)})},
  1364. messageSends: ["showComment:", "model"]}),
  1365. smalltalk.HLClassesListWidget);
  1366. smalltalk.addMethod(
  1367. smalltalk.method({
  1368. selector: "showInstance",
  1369. fn: function (){
  1370. var self=this;
  1371. return smalltalk.withContext(function($ctx1) {
  1372. var $1;
  1373. $1=_st(self._model())._showInstance();
  1374. return $1;
  1375. }, function($ctx1) {$ctx1.fill(self,"showInstance",{},smalltalk.HLClassesListWidget)})},
  1376. messageSends: ["showInstance", "model"]}),
  1377. smalltalk.HLClassesListWidget);
  1378. smalltalk.addMethod(
  1379. smalltalk.method({
  1380. selector: "showInstance:",
  1381. fn: function (aBoolean){
  1382. var self=this;
  1383. return smalltalk.withContext(function($ctx1) {
  1384. _st(self._model())._showInstance_(aBoolean);
  1385. return self}, function($ctx1) {$ctx1.fill(self,"showInstance:",{aBoolean:aBoolean},smalltalk.HLClassesListWidget)})},
  1386. messageSends: ["showInstance:", "model"]}),
  1387. smalltalk.HLClassesListWidget);
  1388. smalltalk.addMethod(
  1389. smalltalk.method({
  1390. selector: "toggleShowComment",
  1391. fn: function (){
  1392. var self=this;
  1393. return smalltalk.withContext(function($ctx1) {
  1394. _st(self._model())._showComment_(_st(self._showComment())._not());
  1395. return self}, function($ctx1) {$ctx1.fill(self,"toggleShowComment",{},smalltalk.HLClassesListWidget)})},
  1396. messageSends: ["showComment:", "not", "showComment", "model"]}),
  1397. smalltalk.HLClassesListWidget);
  1398. smalltalk.addClass('HLDocumentationWidget', smalltalk.HLFocusableWidget, ['model'], 'Helios-Browser');
  1399. smalltalk.addMethod(
  1400. smalltalk.method({
  1401. selector: "defaultDocumentation",
  1402. fn: function (){
  1403. var self=this;
  1404. return smalltalk.withContext(function($ctx1) {
  1405. return "No documentation available. \x0a**That's bad. Seriously.**";
  1406. }, function($ctx1) {$ctx1.fill(self,"defaultDocumentation",{},smalltalk.HLDocumentationWidget)})},
  1407. messageSends: []}),
  1408. smalltalk.HLDocumentationWidget);
  1409. smalltalk.addMethod(
  1410. smalltalk.method({
  1411. selector: "defaultHead",
  1412. fn: function (){
  1413. var self=this;
  1414. return smalltalk.withContext(function($ctx1) {
  1415. return "No class selected";
  1416. }, function($ctx1) {$ctx1.fill(self,"defaultHead",{},smalltalk.HLDocumentationWidget)})},
  1417. messageSends: []}),
  1418. smalltalk.HLDocumentationWidget);
  1419. smalltalk.addMethod(
  1420. smalltalk.method({
  1421. selector: "documentation",
  1422. fn: function (){
  1423. var self=this;
  1424. return smalltalk.withContext(function($ctx1) {
  1425. var $2,$1;
  1426. $2=self._selectedItem();
  1427. if(($receiver = $2) == nil || $receiver == undefined){
  1428. $1="";
  1429. } else {
  1430. var item;
  1431. item=$receiver;
  1432. $1=_st(_st(item)._comment())._ifEmpty_((function(){
  1433. return smalltalk.withContext(function($ctx2) {
  1434. return self._defaultDocumentation();
  1435. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  1436. };
  1437. return $1;
  1438. }, function($ctx1) {$ctx1.fill(self,"documentation",{},smalltalk.HLDocumentationWidget)})},
  1439. messageSends: ["ifNil:ifNotNil:", "ifEmpty:", "defaultDocumentation", "comment", "selectedItem"]}),
  1440. smalltalk.HLDocumentationWidget);
  1441. smalltalk.addMethod(
  1442. smalltalk.method({
  1443. selector: "editDocumentation",
  1444. fn: function (){
  1445. var self=this;
  1446. return smalltalk.withContext(function($ctx1) {
  1447. _st(self._model())._editComment();
  1448. return self}, function($ctx1) {$ctx1.fill(self,"editDocumentation",{},smalltalk.HLDocumentationWidget)})},
  1449. messageSends: ["editComment", "model"]}),
  1450. smalltalk.HLDocumentationWidget);
  1451. smalltalk.addMethod(
  1452. smalltalk.method({
  1453. selector: "head",
  1454. fn: function (){
  1455. var self=this;
  1456. return smalltalk.withContext(function($ctx1) {
  1457. var $2,$1;
  1458. $2=self._selectedItem();
  1459. if(($receiver = $2) == nil || $receiver == undefined){
  1460. $1=self._defaultHead();
  1461. } else {
  1462. var item;
  1463. item=$receiver;
  1464. $1=_st(item)._name();
  1465. };
  1466. return $1;
  1467. }, function($ctx1) {$ctx1.fill(self,"head",{},smalltalk.HLDocumentationWidget)})},
  1468. messageSends: ["ifNil:ifNotNil:", "defaultHead", "name", "selectedItem"]}),
  1469. smalltalk.HLDocumentationWidget);
  1470. smalltalk.addMethod(
  1471. smalltalk.method({
  1472. selector: "model",
  1473. fn: function (){
  1474. var self=this;
  1475. return smalltalk.withContext(function($ctx1) {
  1476. var $1;
  1477. $1=self["@model"];
  1478. return $1;
  1479. }, function($ctx1) {$ctx1.fill(self,"model",{},smalltalk.HLDocumentationWidget)})},
  1480. messageSends: []}),
  1481. smalltalk.HLDocumentationWidget);
  1482. smalltalk.addMethod(
  1483. smalltalk.method({
  1484. selector: "model:",
  1485. fn: function (aModel){
  1486. var self=this;
  1487. return smalltalk.withContext(function($ctx1) {
  1488. var $1,$2;
  1489. self["@model"]=aModel;
  1490. $1=self;
  1491. _st($1)._observeSystem();
  1492. $2=_st($1)._observeModel();
  1493. return self}, function($ctx1) {$ctx1.fill(self,"model:",{aModel:aModel},smalltalk.HLDocumentationWidget)})},
  1494. messageSends: ["observeSystem", "observeModel"]}),
  1495. smalltalk.HLDocumentationWidget);
  1496. smalltalk.addMethod(
  1497. smalltalk.method({
  1498. selector: "observeModel",
  1499. fn: function (){
  1500. var self=this;
  1501. function $HLClassSelected(){return smalltalk.HLClassSelected||(typeof HLClassSelected=="undefined"?nil:HLClassSelected)}
  1502. function $HLEditComment(){return smalltalk.HLEditComment||(typeof HLEditComment=="undefined"?nil:HLEditComment)}
  1503. return smalltalk.withContext(function($ctx1) {
  1504. var $1,$2;
  1505. $1=_st(self._model())._announcer();
  1506. _st($1)._on_send_to_($HLClassSelected(),"onClassSelected:",self);
  1507. $2=_st($1)._on_send_to_($HLEditComment(),"onEditDocumentation",self);
  1508. return self}, function($ctx1) {$ctx1.fill(self,"observeModel",{},smalltalk.HLDocumentationWidget)})},
  1509. messageSends: ["on:send:to:", "announcer", "model"]}),
  1510. smalltalk.HLDocumentationWidget);
  1511. smalltalk.addMethod(
  1512. smalltalk.method({
  1513. selector: "observeSystem",
  1514. fn: function (){
  1515. var self=this;
  1516. function $ClassCommentChanged(){return smalltalk.ClassCommentChanged||(typeof ClassCommentChanged=="undefined"?nil:ClassCommentChanged)}
  1517. return smalltalk.withContext(function($ctx1) {
  1518. _st(_st(self._model())._systemAnnouncer())._on_send_to_($ClassCommentChanged(),"onClassCommentChanged:",self);
  1519. return self}, function($ctx1) {$ctx1.fill(self,"observeSystem",{},smalltalk.HLDocumentationWidget)})},
  1520. messageSends: ["on:send:to:", "systemAnnouncer", "model"]}),
  1521. smalltalk.HLDocumentationWidget);
  1522. smalltalk.addMethod(
  1523. smalltalk.method({
  1524. selector: "onClassCommentChanged:",
  1525. fn: function (anAnnouncement){
  1526. var self=this;
  1527. return smalltalk.withContext(function($ctx1) {
  1528. var $1;
  1529. $1=_st(_st(anAnnouncement)._theClass()).__eq(_st(_st(self._model())._selectedClass())._theNonMetaClass());
  1530. if(smalltalk.assert($1)){
  1531. self._refresh();
  1532. };
  1533. return self}, function($ctx1) {$ctx1.fill(self,"onClassCommentChanged:",{anAnnouncement:anAnnouncement},smalltalk.HLDocumentationWidget)})},
  1534. messageSends: ["ifTrue:", "refresh", "=", "theNonMetaClass", "selectedClass", "model", "theClass"]}),
  1535. smalltalk.HLDocumentationWidget);
  1536. smalltalk.addMethod(
  1537. smalltalk.method({
  1538. selector: "onClassSelected:",
  1539. fn: function (anAnnouncement){
  1540. var self=this;
  1541. return smalltalk.withContext(function($ctx1) {
  1542. self._refresh();
  1543. return self}, function($ctx1) {$ctx1.fill(self,"onClassSelected:",{anAnnouncement:anAnnouncement},smalltalk.HLDocumentationWidget)})},
  1544. messageSends: ["refresh"]}),
  1545. smalltalk.HLDocumentationWidget);
  1546. smalltalk.addMethod(
  1547. smalltalk.method({
  1548. selector: "onEditDocumentation",
  1549. fn: function (){
  1550. var self=this;
  1551. return smalltalk.withContext(function($ctx1) {
  1552. self._request_value_do_(_st(_st(_st(_st(self._model())._selectedClass())._theNonMetaClass())._name()).__comma(" comment"),_st(_st(_st(self._model())._selectedClass())._theNonMetaClass())._comment(),(function(comment){
  1553. return smalltalk.withContext(function($ctx2) {
  1554. return self._setClassComment_(comment);
  1555. }, function($ctx2) {$ctx2.fillBlock({comment:comment},$ctx1)})}));
  1556. return self}, function($ctx1) {$ctx1.fill(self,"onEditDocumentation",{},smalltalk.HLDocumentationWidget)})},
  1557. messageSends: ["request:value:do:", ",", "name", "theNonMetaClass", "selectedClass", "model", "comment", "setClassComment:"]}),
  1558. smalltalk.HLDocumentationWidget);
  1559. smalltalk.addMethod(
  1560. smalltalk.method({
  1561. selector: "renderContentOn:",
  1562. fn: function (html){
  1563. var self=this;
  1564. return smalltalk.withContext(function($ctx1) {
  1565. var $1,$3,$4,$2;
  1566. $1=_st(html)._div();
  1567. _st($1)._class_("doc");
  1568. $2=_st($1)._with_((function(){
  1569. return smalltalk.withContext(function($ctx2) {
  1570. $3=self;
  1571. _st($3)._renderHeadOn_(html);
  1572. $4=_st($3)._renderDocOn_(html);
  1573. return $4;
  1574. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  1575. return self}, function($ctx1) {$ctx1.fill(self,"renderContentOn:",{html:html},smalltalk.HLDocumentationWidget)})},
  1576. messageSends: ["class:", "div", "with:", "renderHeadOn:", "renderDocOn:"]}),
  1577. smalltalk.HLDocumentationWidget);
  1578. smalltalk.addMethod(
  1579. smalltalk.method({
  1580. selector: "renderDocOn:",
  1581. fn: function (html){
  1582. var self=this;
  1583. function $Showdown(){return smalltalk.Showdown||(typeof Showdown=="undefined"?nil:Showdown)}
  1584. return smalltalk.withContext(function($ctx1) {
  1585. var $1,$2,$4,$5,$3,$6,$7;
  1586. $1=self._selectedItem();
  1587. if(($receiver = $1) == nil || $receiver == undefined){
  1588. $1;
  1589. } else {
  1590. self._renderInheritanceOn_(html);
  1591. $2=_st(html)._h1();
  1592. _st($2)._with_("Overview");
  1593. $3=_st($2)._with_((function(){
  1594. return smalltalk.withContext(function($ctx2) {
  1595. $4=_st(html)._button();
  1596. _st($4)._class_("button default");
  1597. _st($4)._with_("Edit");
  1598. $5=_st($4)._onClick_((function(){
  1599. return smalltalk.withContext(function($ctx3) {
  1600. return self._editDocumentation();
  1601. }, function($ctx3) {$ctx3.fillBlock({},$ctx2)})}));
  1602. return $5;
  1603. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  1604. $3;
  1605. $6=_st(html)._div();
  1606. _st($6)._class_("markdown");
  1607. $7=_st($6)._asJQuery();
  1608. _st($7)._html_(_st(_st(_st($Showdown())._at_("converter"))._new())._makeHtml_(self._documentation()));
  1609. };
  1610. return self}, function($ctx1) {$ctx1.fill(self,"renderDocOn:",{html:html},smalltalk.HLDocumentationWidget)})},
  1611. messageSends: ["ifNotNil:", "renderInheritanceOn:", "with:", "h1", "class:", "button", "onClick:", "editDocumentation", "html:", "makeHtml:", "documentation", "new", "at:", "div", "asJQuery", "selectedItem"]}),
  1612. smalltalk.HLDocumentationWidget);
  1613. smalltalk.addMethod(
  1614. smalltalk.method({
  1615. selector: "renderHeadOn:",
  1616. fn: function (html){
  1617. var self=this;
  1618. return smalltalk.withContext(function($ctx1) {
  1619. var $1,$2;
  1620. $1=_st(html)._div();
  1621. _st($1)._class_("head");
  1622. $2=_st($1)._with_(self._head());
  1623. return self}, function($ctx1) {$ctx1.fill(self,"renderHeadOn:",{html:html},smalltalk.HLDocumentationWidget)})},
  1624. messageSends: ["class:", "div", "with:", "head"]}),
  1625. smalltalk.HLDocumentationWidget);
  1626. smalltalk.addMethod(
  1627. smalltalk.method({
  1628. selector: "renderInheritanceOn:",
  1629. fn: function (html){
  1630. var self=this;
  1631. return smalltalk.withContext(function($ctx1) {
  1632. var $1,$3,$4,$5,$2;
  1633. $1=_st(html)._div();
  1634. _st($1)._class_("inheritance");
  1635. $2=_st($1)._with_((function(){
  1636. return smalltalk.withContext(function($ctx2) {
  1637. _st(html)._with_("Subclass of ");
  1638. $3=_st(self._selectedItem())._superclass();
  1639. if(($receiver = $3) == nil || $receiver == undefined){
  1640. return _st(_st(html)._em())._with_("nil");
  1641. } else {
  1642. $4=_st(html)._a();
  1643. _st($4)._with_(_st(_st(self._selectedItem())._superclass())._name());
  1644. $5=_st($4)._onClick_((function(){
  1645. return smalltalk.withContext(function($ctx3) {
  1646. return self._selectClass_(_st(self._selectedItem())._superclass());
  1647. }, function($ctx3) {$ctx3.fillBlock({},$ctx2)})}));
  1648. return $5;
  1649. };
  1650. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  1651. return self}, function($ctx1) {$ctx1.fill(self,"renderInheritanceOn:",{html:html},smalltalk.HLDocumentationWidget)})},
  1652. messageSends: ["class:", "div", "with:", "ifNil:ifNotNil:", "em", "name", "superclass", "selectedItem", "a", "onClick:", "selectClass:"]}),
  1653. smalltalk.HLDocumentationWidget);
  1654. smalltalk.addMethod(
  1655. smalltalk.method({
  1656. selector: "selectClass:",
  1657. fn: function (aClass){
  1658. var self=this;
  1659. return smalltalk.withContext(function($ctx1) {
  1660. _st(self._model())._selectedClass_(aClass);
  1661. return self}, function($ctx1) {$ctx1.fill(self,"selectClass:",{aClass:aClass},smalltalk.HLDocumentationWidget)})},
  1662. messageSends: ["selectedClass:", "model"]}),
  1663. smalltalk.HLDocumentationWidget);
  1664. smalltalk.addMethod(
  1665. smalltalk.method({
  1666. selector: "selectedItem",
  1667. fn: function (){
  1668. var self=this;
  1669. return smalltalk.withContext(function($ctx1) {
  1670. var $2,$1;
  1671. $2=_st(self._model())._selectedClass();
  1672. if(($receiver = $2) == nil || $receiver == undefined){
  1673. $1=$2;
  1674. } else {
  1675. var class_;
  1676. class_=$receiver;
  1677. $1=_st(class_)._theNonMetaClass();
  1678. };
  1679. return $1;
  1680. }, function($ctx1) {$ctx1.fill(self,"selectedItem",{},smalltalk.HLDocumentationWidget)})},
  1681. messageSends: ["ifNotNil:", "theNonMetaClass", "selectedClass", "model"]}),
  1682. smalltalk.HLDocumentationWidget);
  1683. smalltalk.addMethod(
  1684. smalltalk.method({
  1685. selector: "setClassComment:",
  1686. fn: function (aString){
  1687. var self=this;
  1688. return smalltalk.withContext(function($ctx1) {
  1689. _st(self._model())._setClassComment_(aString);
  1690. return self}, function($ctx1) {$ctx1.fill(self,"setClassComment:",{aString:aString},smalltalk.HLDocumentationWidget)})},
  1691. messageSends: ["setClassComment:", "model"]}),
  1692. smalltalk.HLDocumentationWidget);
  1693. smalltalk.addMethod(
  1694. smalltalk.method({
  1695. selector: "unregister",
  1696. fn: function (){
  1697. var self=this;
  1698. return smalltalk.withContext(function($ctx1) {
  1699. smalltalk.HLDocumentationWidget.superclass.fn.prototype._unregister.apply(_st(self), []);
  1700. _st(_st(self._model())._announcer())._unregister_(self);
  1701. return self}, function($ctx1) {$ctx1.fill(self,"unregister",{},smalltalk.HLDocumentationWidget)})},
  1702. messageSends: ["unregister", "unregister:", "announcer", "model"]}),
  1703. smalltalk.HLDocumentationWidget);
  1704. smalltalk.addClass('HLMethodsListWidget', smalltalk.HLToolListWidget, ['selectorsCache'], 'Helios-Browser');
  1705. smalltalk.addMethod(
  1706. smalltalk.method({
  1707. selector: "allProtocol",
  1708. fn: function (){
  1709. var self=this;
  1710. return smalltalk.withContext(function($ctx1) {
  1711. var $1;
  1712. $1=_st(self._model())._allProtocol();
  1713. return $1;
  1714. }, function($ctx1) {$ctx1.fill(self,"allProtocol",{},smalltalk.HLMethodsListWidget)})},
  1715. messageSends: ["allProtocol", "model"]}),
  1716. smalltalk.HLMethodsListWidget);
  1717. smalltalk.addMethod(
  1718. smalltalk.method({
  1719. selector: "cssClassForItem:",
  1720. fn: function (aSelector){
  1721. var self=this;
  1722. var override,overriden,method;
  1723. return smalltalk.withContext(function($ctx1) {
  1724. var $2,$3,$4,$1;
  1725. method=self._methodForSelector_(aSelector);
  1726. override=self._isOverride_(method);
  1727. overriden=self._isOverridden_(method);
  1728. $2=override;
  1729. if(smalltalk.assert($2)){
  1730. $3=overriden;
  1731. if(smalltalk.assert($3)){
  1732. $1="override-overridden";
  1733. } else {
  1734. $1="override";
  1735. };
  1736. } else {
  1737. $4=overriden;
  1738. if(smalltalk.assert($4)){
  1739. $1="overridden";
  1740. } else {
  1741. $1="";
  1742. };
  1743. };
  1744. return $1;
  1745. }, function($ctx1) {$ctx1.fill(self,"cssClassForItem:",{aSelector:aSelector,override:override,overriden:overriden,method:method},smalltalk.HLMethodsListWidget)})},
  1746. messageSends: ["methodForSelector:", "isOverride:", "isOverridden:", "ifTrue:ifFalse:"]}),
  1747. smalltalk.HLMethodsListWidget);
  1748. smalltalk.addMethod(
  1749. smalltalk.method({
  1750. selector: "isOverridden:",
  1751. fn: function (aMethod){
  1752. var self=this;
  1753. return smalltalk.withContext(function($ctx1) {
  1754. var $1;
  1755. $1=_st(self._selectorsCache())._isOverridden_(aMethod);
  1756. return $1;
  1757. }, function($ctx1) {$ctx1.fill(self,"isOverridden:",{aMethod:aMethod},smalltalk.HLMethodsListWidget)})},
  1758. messageSends: ["isOverridden:", "selectorsCache"]}),
  1759. smalltalk.HLMethodsListWidget);
  1760. smalltalk.addMethod(
  1761. smalltalk.method({
  1762. selector: "isOverride:",
  1763. fn: function (aMethod){
  1764. var self=this;
  1765. return smalltalk.withContext(function($ctx1) {
  1766. var $1;
  1767. $1=_st(self._selectorsCache())._isOverride_(aMethod);
  1768. return $1;
  1769. }, function($ctx1) {$ctx1.fill(self,"isOverride:",{aMethod:aMethod},smalltalk.HLMethodsListWidget)})},
  1770. messageSends: ["isOverride:", "selectorsCache"]}),
  1771. smalltalk.HLMethodsListWidget);
  1772. smalltalk.addMethod(
  1773. smalltalk.method({
  1774. selector: "label",
  1775. fn: function (){
  1776. var self=this;
  1777. return smalltalk.withContext(function($ctx1) {
  1778. return "Methods";
  1779. }, function($ctx1) {$ctx1.fill(self,"label",{},smalltalk.HLMethodsListWidget)})},
  1780. messageSends: []}),
  1781. smalltalk.HLMethodsListWidget);
  1782. smalltalk.addMethod(
  1783. smalltalk.method({
  1784. selector: "methodForSelector:",
  1785. fn: function (aSelector){
  1786. var self=this;
  1787. return smalltalk.withContext(function($ctx1) {
  1788. var $1;
  1789. $1=_st(_st(_st(self._model())._selectedClass())._methodDictionary())._at_(aSelector);
  1790. return $1;
  1791. }, function($ctx1) {$ctx1.fill(self,"methodForSelector:",{aSelector:aSelector},smalltalk.HLMethodsListWidget)})},
  1792. messageSends: ["at:", "methodDictionary", "selectedClass", "model"]}),
  1793. smalltalk.HLMethodsListWidget);
  1794. smalltalk.addMethod(
  1795. smalltalk.method({
  1796. selector: "methodsInProtocol:",
  1797. fn: function (aString){
  1798. var self=this;
  1799. return smalltalk.withContext(function($ctx1) {
  1800. var $1,$2,$4,$3;
  1801. $1=_st(self._model())._selectedClass();
  1802. if(($receiver = $1) == nil || $receiver == undefined){
  1803. $2=[];
  1804. return $2;
  1805. } else {
  1806. $1;
  1807. };
  1808. $4=_st(aString).__eq(self._allProtocol());
  1809. if(smalltalk.assert($4)){
  1810. $3=_st(_st(self._model())._selectedClass())._methods();
  1811. } else {
  1812. $3=_st(_st(self._model())._selectedClass())._methodsInProtocol_(aString);
  1813. };
  1814. return $3;
  1815. }, function($ctx1) {$ctx1.fill(self,"methodsInProtocol:",{aString:aString},smalltalk.HLMethodsListWidget)})},
  1816. messageSends: ["ifNil:", "selectedClass", "model", "ifTrue:ifFalse:", "methods", "methodsInProtocol:", "=", "allProtocol"]}),
  1817. smalltalk.HLMethodsListWidget);
  1818. smalltalk.addMethod(
  1819. smalltalk.method({
  1820. selector: "observeModel",
  1821. fn: function (){
  1822. var self=this;
  1823. function $HLProtocolSelected(){return smalltalk.HLProtocolSelected||(typeof HLProtocolSelected=="undefined"?nil:HLProtocolSelected)}
  1824. function $HLShowInstanceToggled(){return smalltalk.HLShowInstanceToggled||(typeof HLShowInstanceToggled=="undefined"?nil:HLShowInstanceToggled)}
  1825. function $HLMethodSelected(){return smalltalk.HLMethodSelected||(typeof HLMethodSelected=="undefined"?nil:HLMethodSelected)}
  1826. function $HLMethodsFocusRequested(){return smalltalk.HLMethodsFocusRequested||(typeof HLMethodsFocusRequested=="undefined"?nil:HLMethodsFocusRequested)}
  1827. return smalltalk.withContext(function($ctx1) {
  1828. var $1,$2;
  1829. $1=_st(self._model())._announcer();
  1830. _st($1)._on_send_to_($HLProtocolSelected(),"onProtocolSelected:",self);
  1831. _st($1)._on_send_to_($HLShowInstanceToggled(),"onShowInstanceToggled",self);
  1832. _st($1)._on_send_to_($HLMethodSelected(),"onMethodSelected:",self);
  1833. $2=_st($1)._on_send_to_($HLMethodsFocusRequested(),"onMethodsFocusRequested",self);
  1834. return self}, function($ctx1) {$ctx1.fill(self,"observeModel",{},smalltalk.HLMethodsListWidget)})},
  1835. messageSends: ["on:send:to:", "announcer", "model"]}),
  1836. smalltalk.HLMethodsListWidget);
  1837. smalltalk.addMethod(
  1838. smalltalk.method({
  1839. selector: "observeSystem",
  1840. fn: function (){
  1841. var self=this;
  1842. function $ProtocolAdded(){return smalltalk.ProtocolAdded||(typeof ProtocolAdded=="undefined"?nil:ProtocolAdded)}
  1843. function $ProtocolRemoved(){return smalltalk.ProtocolRemoved||(typeof ProtocolRemoved=="undefined"?nil:ProtocolRemoved)}
  1844. function $MethodAdded(){return smalltalk.MethodAdded||(typeof MethodAdded=="undefined"?nil:MethodAdded)}
  1845. function $MethodRemoved(){return smalltalk.MethodRemoved||(typeof MethodRemoved=="undefined"?nil:MethodRemoved)}
  1846. function $MethodMoved(){return smalltalk.MethodMoved||(typeof MethodMoved=="undefined"?nil:MethodMoved)}
  1847. return smalltalk.withContext(function($ctx1) {
  1848. var $1,$2;
  1849. $1=_st(self._model())._systemAnnouncer();
  1850. _st($1)._on_send_to_($ProtocolAdded(),"onProtocolAdded:",self);
  1851. _st($1)._on_send_to_($ProtocolRemoved(),"onProtocolRemoved:",self);
  1852. _st($1)._on_send_to_($MethodAdded(),"onMethodAdded:",self);
  1853. _st($1)._on_send_to_($MethodRemoved(),"onMethodRemoved:",self);
  1854. $2=_st($1)._on_send_to_($MethodMoved(),"onMethodMoved:",self);
  1855. return self}, function($ctx1) {$ctx1.fill(self,"observeSystem",{},smalltalk.HLMethodsListWidget)})},
  1856. messageSends: ["on:send:to:", "systemAnnouncer", "model"]}),
  1857. smalltalk.HLMethodsListWidget);
  1858. smalltalk.addMethod(
  1859. smalltalk.method({
  1860. selector: "onMethodAdded:",
  1861. fn: function (anAnnouncement){
  1862. var self=this;
  1863. return smalltalk.withContext(function($ctx1) {
  1864. var $1,$2;
  1865. $1=_st(_st(self._model())._selectedClass()).__eq(_st(_st(anAnnouncement)._method())._methodClass());
  1866. if(! smalltalk.assert($1)){
  1867. $2=self;
  1868. return $2;
  1869. };
  1870. self._setItemsForSelectedProtocol();
  1871. self._refresh();
  1872. return self}, function($ctx1) {$ctx1.fill(self,"onMethodAdded:",{anAnnouncement:anAnnouncement},smalltalk.HLMethodsListWidget)})},
  1873. messageSends: ["ifFalse:", "=", "methodClass", "method", "selectedClass", "model", "setItemsForSelectedProtocol", "refresh"]}),
  1874. smalltalk.HLMethodsListWidget);
  1875. smalltalk.addMethod(
  1876. smalltalk.method({
  1877. selector: "onMethodMoved:",
  1878. fn: function (anAnnouncement){
  1879. var self=this;
  1880. return smalltalk.withContext(function($ctx1) {
  1881. var $1,$2,$3,$4,$5;
  1882. $1=_st(_st(self._model())._selectedMethod()).__eq(_st(anAnnouncement)._method());
  1883. if(! smalltalk.assert($1)){
  1884. $2=self;
  1885. return $2;
  1886. };
  1887. $3=_st(_st(self._model())._selectedProtocol()).__eq(_st(self._model())._allProtocol());
  1888. if(! smalltalk.assert($3)){
  1889. $4=self;
  1890. _st($4)._selectedItem_(nil);
  1891. _st($4)._selectItem_(nil);
  1892. _st($4)._setItemsForSelectedProtocol();
  1893. $5=_st($4)._refresh();
  1894. $5;
  1895. };
  1896. return self}, function($ctx1) {$ctx1.fill(self,"onMethodMoved:",{anAnnouncement:anAnnouncement},smalltalk.HLMethodsListWidget)})},
  1897. messageSends: ["ifFalse:", "=", "method", "selectedMethod", "model", "selectedItem:", "selectItem:", "setItemsForSelectedProtocol", "refresh", "allProtocol", "selectedProtocol"]}),
  1898. smalltalk.HLMethodsListWidget);
  1899. smalltalk.addMethod(
  1900. smalltalk.method({
  1901. selector: "onMethodRemoved:",
  1902. fn: function (anAnnouncement){
  1903. var self=this;
  1904. var method;
  1905. return smalltalk.withContext(function($ctx1) {
  1906. var $1,$2,$3,$4,$5;
  1907. var $early={};
  1908. try {
  1909. method=_st(anAnnouncement)._method();
  1910. _st(self._items())._detect_ifNone_((function(each){
  1911. return smalltalk.withContext(function($ctx2) {
  1912. return _st(each).__eq(_st(method)._selector());
  1913. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})}),(function(){
  1914. return smalltalk.withContext(function($ctx2) {
  1915. $1=self;
  1916. throw $early=[$1];
  1917. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  1918. $2=self._selectedItem();
  1919. if(($receiver = $2) == nil || $receiver == undefined){
  1920. $2;
  1921. } else {
  1922. $3=_st(_st(_st(method)._methodClass()).__eq(_st(self._model())._selectedClass()))._and_((function(){
  1923. return smalltalk.withContext(function($ctx2) {
  1924. return _st(_st(method)._selector()).__eq(self._selectedItem());
  1925. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  1926. if(smalltalk.assert($3)){
  1927. $4=self;
  1928. _st($4)._selectedItem_(nil);
  1929. $5=_st($4)._selectItem_(nil);
  1930. $5;
  1931. };
  1932. };
  1933. self._setItemsForSelectedProtocol();
  1934. self._refresh();
  1935. return self}
  1936. catch(e) {if(e===$early)return e[0]; throw e}
  1937. }, function($ctx1) {$ctx1.fill(self,"onMethodRemoved:",{anAnnouncement:anAnnouncement,method:method},smalltalk.HLMethodsListWidget)})},
  1938. messageSends: ["method", "detect:ifNone:", "=", "selector", "items", "ifNotNil:", "ifTrue:", "selectedItem:", "selectItem:", "and:", "selectedItem", "selectedClass", "model", "methodClass", "setItemsForSelectedProtocol", "refresh"]}),
  1939. smalltalk.HLMethodsListWidget);
  1940. smalltalk.addMethod(
  1941. smalltalk.method({
  1942. selector: "onMethodSelected:",
  1943. fn: function (anAnnouncement){
  1944. var self=this;
  1945. var selector,method;
  1946. return smalltalk.withContext(function($ctx1) {
  1947. var $1,$2,$3;
  1948. method=_st(anAnnouncement)._item();
  1949. $1=_st(method)._isCompiledMethod();
  1950. if(smalltalk.assert($1)){
  1951. selector=_st(method)._selector();
  1952. } else {
  1953. selector=nil;
  1954. };
  1955. $2=self;
  1956. _st($2)._selectedItem_(selector);
  1957. $3=_st($2)._activateItem_(selector);
  1958. return self}, function($ctx1) {$ctx1.fill(self,"onMethodSelected:",{anAnnouncement:anAnnouncement,selector:selector,method:method},smalltalk.HLMethodsListWidget)})},
  1959. messageSends: ["item", "ifTrue:ifFalse:", "selector", "isCompiledMethod", "selectedItem:", "activateItem:"]}),
  1960. smalltalk.HLMethodsListWidget);
  1961. smalltalk.addMethod(
  1962. smalltalk.method({
  1963. selector: "onMethodsFocusRequested",
  1964. fn: function (){
  1965. var self=this;
  1966. return smalltalk.withContext(function($ctx1) {
  1967. self._focus();
  1968. return self}, function($ctx1) {$ctx1.fill(self,"onMethodsFocusRequested",{},smalltalk.HLMethodsListWidget)})},
  1969. messageSends: ["focus"]}),
  1970. smalltalk.HLMethodsListWidget);
  1971. smalltalk.addMethod(
  1972. smalltalk.method({
  1973. selector: "onProtocolAdded:",
  1974. fn: function (anAnnouncement){
  1975. var self=this;
  1976. return smalltalk.withContext(function($ctx1) {
  1977. var $1,$2;
  1978. $1=_st(_st(self._model())._selectedClass()).__eq(_st(anAnnouncement)._theClass());
  1979. if(! smalltalk.assert($1)){
  1980. $2=self;
  1981. return $2;
  1982. };
  1983. self._setItemsForSelectedProtocol();
  1984. self._refresh();
  1985. self._focus();
  1986. return self}, function($ctx1) {$ctx1.fill(self,"onProtocolAdded:",{anAnnouncement:anAnnouncement},smalltalk.HLMethodsListWidget)})},
  1987. messageSends: ["ifFalse:", "=", "theClass", "selectedClass", "model", "setItemsForSelectedProtocol", "refresh", "focus"]}),
  1988. smalltalk.HLMethodsListWidget);
  1989. smalltalk.addMethod(
  1990. smalltalk.method({
  1991. selector: "onProtocolRemoved:",
  1992. fn: function (anAnnouncement){
  1993. var self=this;
  1994. return smalltalk.withContext(function($ctx1) {
  1995. var $1,$2;
  1996. $1=_st(_st(self._model())._selectedClass()).__eq(_st(anAnnouncement)._theClass());
  1997. if(! smalltalk.assert($1)){
  1998. $2=self;
  1999. return $2;
  2000. };
  2001. self._setItemsForSelectedProtocol();
  2002. self._refresh();
  2003. self._focus();
  2004. return self}, function($ctx1) {$ctx1.fill(self,"onProtocolRemoved:",{anAnnouncement:anAnnouncement},smalltalk.HLMethodsListWidget)})},
  2005. messageSends: ["ifFalse:", "=", "theClass", "selectedClass", "model", "setItemsForSelectedProtocol", "refresh", "focus"]}),
  2006. smalltalk.HLMethodsListWidget);
  2007. smalltalk.addMethod(
  2008. smalltalk.method({
  2009. selector: "onProtocolSelected:",
  2010. fn: function (anAnnouncement){
  2011. var self=this;
  2012. return smalltalk.withContext(function($ctx1) {
  2013. self._selectedItem_(nil);
  2014. self._setItemsForSelectedProtocol();
  2015. self._refresh();
  2016. return self}, function($ctx1) {$ctx1.fill(self,"onProtocolSelected:",{anAnnouncement:anAnnouncement},smalltalk.HLMethodsListWidget)})},
  2017. messageSends: ["selectedItem:", "setItemsForSelectedProtocol", "refresh"]}),
  2018. smalltalk.HLMethodsListWidget);
  2019. smalltalk.addMethod(
  2020. smalltalk.method({
  2021. selector: "onShowInstanceToggled",
  2022. fn: function (){
  2023. var self=this;
  2024. return smalltalk.withContext(function($ctx1) {
  2025. self._onProtocolSelected_(nil);
  2026. return self}, function($ctx1) {$ctx1.fill(self,"onShowInstanceToggled",{},smalltalk.HLMethodsListWidget)})},
  2027. messageSends: ["onProtocolSelected:"]}),
  2028. smalltalk.HLMethodsListWidget);
  2029. smalltalk.addMethod(
  2030. smalltalk.method({
  2031. selector: "overrideSelectors",
  2032. fn: function (){
  2033. var self=this;
  2034. function $Set(){return smalltalk.Set||(typeof Set=="undefined"?nil:Set)}
  2035. return smalltalk.withContext(function($ctx1) {
  2036. var $2,$3,$1;
  2037. $1=_st(self._selectorsCache())._at_ifAbsentPut_("override",(function(){
  2038. return smalltalk.withContext(function($ctx2) {
  2039. return _st(_st(_st(self._model())._selectedClass())._allSuperclasses())._inject_into_(_st($Set())._new(),(function(acc,each){
  2040. return smalltalk.withContext(function($ctx3) {
  2041. $2=acc;
  2042. _st($2)._addAll_(_st(each)._selectors());
  2043. $3=_st($2)._yourself();
  2044. return $3;
  2045. }, function($ctx3) {$ctx3.fillBlock({acc:acc,each:each},$ctx2)})}));
  2046. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  2047. return $1;
  2048. }, function($ctx1) {$ctx1.fill(self,"overrideSelectors",{},smalltalk.HLMethodsListWidget)})},
  2049. messageSends: ["at:ifAbsentPut:", "inject:into:", "new", "addAll:", "selectors", "yourself", "allSuperclasses", "selectedClass", "model", "selectorsCache"]}),
  2050. smalltalk.HLMethodsListWidget);
  2051. smalltalk.addMethod(
  2052. smalltalk.method({
  2053. selector: "overridenSelectors",
  2054. fn: function (){
  2055. var self=this;
  2056. function $Set(){return smalltalk.Set||(typeof Set=="undefined"?nil:Set)}
  2057. return smalltalk.withContext(function($ctx1) {
  2058. var $2,$3,$1;
  2059. $1=_st(self._selectorsCache())._at_ifAbsentPut_("overriden",(function(){
  2060. return smalltalk.withContext(function($ctx2) {
  2061. return _st(_st(_st(self._model())._selectedClass())._allSubclasses())._inject_into_(_st($Set())._new(),(function(acc,each){
  2062. return smalltalk.withContext(function($ctx3) {
  2063. $2=acc;
  2064. _st($2)._addAll_(_st(each)._selectors());
  2065. $3=_st($2)._yourself();
  2066. return $3;
  2067. }, function($ctx3) {$ctx3.fillBlock({acc:acc,each:each},$ctx2)})}));
  2068. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  2069. return $1;
  2070. }, function($ctx1) {$ctx1.fill(self,"overridenSelectors",{},smalltalk.HLMethodsListWidget)})},
  2071. messageSends: ["at:ifAbsentPut:", "inject:into:", "new", "addAll:", "selectors", "yourself", "allSubclasses", "selectedClass", "model", "selectorsCache"]}),
  2072. smalltalk.HLMethodsListWidget);
  2073. smalltalk.addMethod(
  2074. smalltalk.method({
  2075. selector: "renderContentOn:",
  2076. fn: function (html){
  2077. var self=this;
  2078. return smalltalk.withContext(function($ctx1) {
  2079. var $1,$2,$3;
  2080. $1=_st(self._model())._showInstance();
  2081. if(smalltalk.assert($1)){
  2082. smalltalk.HLMethodsListWidget.superclass.fn.prototype._renderContentOn_.apply(_st(self), [html]);
  2083. } else {
  2084. $2=_st(html)._div();
  2085. _st($2)._class_("class_side");
  2086. $3=_st($2)._with_((function(){
  2087. return smalltalk.withContext(function($ctx2) {
  2088. return smalltalk.HLMethodsListWidget.superclass.fn.prototype._renderContentOn_.apply(_st(self), [html]);
  2089. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  2090. $3;
  2091. };
  2092. return self}, function($ctx1) {$ctx1.fill(self,"renderContentOn:",{html:html},smalltalk.HLMethodsListWidget)})},
  2093. messageSends: ["ifFalse:ifTrue:", "class:", "div", "with:", "renderContentOn:", "showInstance", "model"]}),
  2094. smalltalk.HLMethodsListWidget);
  2095. smalltalk.addMethod(
  2096. smalltalk.method({
  2097. selector: "renderItemLabel:on:",
  2098. fn: function (aSelector,html){
  2099. var self=this;
  2100. return smalltalk.withContext(function($ctx1) {
  2101. _st(html)._with_(aSelector);
  2102. return self}, function($ctx1) {$ctx1.fill(self,"renderItemLabel:on:",{aSelector:aSelector,html:html},smalltalk.HLMethodsListWidget)})},
  2103. messageSends: ["with:"]}),
  2104. smalltalk.HLMethodsListWidget);
  2105. smalltalk.addMethod(
  2106. smalltalk.method({
  2107. selector: "selectItem:",
  2108. fn: function (aSelector){
  2109. var self=this;
  2110. return smalltalk.withContext(function($ctx1) {
  2111. var $1,$2;
  2112. $1=aSelector;
  2113. if(($receiver = $1) == nil || $receiver == undefined){
  2114. $2=_st(self._model())._selectedMethod_(nil);
  2115. return $2;
  2116. } else {
  2117. $1;
  2118. };
  2119. _st(self._model())._selectedMethod_(self._methodForSelector_(aSelector));
  2120. return self}, function($ctx1) {$ctx1.fill(self,"selectItem:",{aSelector:aSelector},smalltalk.HLMethodsListWidget)})},
  2121. messageSends: ["ifNil:", "selectedMethod:", "model", "methodForSelector:"]}),
  2122. smalltalk.HLMethodsListWidget);
  2123. smalltalk.addMethod(
  2124. smalltalk.method({
  2125. selector: "selectorsCache",
  2126. fn: function (){
  2127. var self=this;
  2128. return smalltalk.withContext(function($ctx1) {
  2129. var $1;
  2130. $1=_st(self._class())._selectorsCache();
  2131. return $1;
  2132. }, function($ctx1) {$ctx1.fill(self,"selectorsCache",{},smalltalk.HLMethodsListWidget)})},
  2133. messageSends: ["selectorsCache", "class"]}),
  2134. smalltalk.HLMethodsListWidget);
  2135. smalltalk.addMethod(
  2136. smalltalk.method({
  2137. selector: "selectorsInProtocol:",
  2138. fn: function (aString){
  2139. var self=this;
  2140. return smalltalk.withContext(function($ctx1) {
  2141. var $1;
  2142. $1=_st(_st(self._methodsInProtocol_(aString))._collect_((function(each){
  2143. return smalltalk.withContext(function($ctx2) {
  2144. return _st(each)._selector();
  2145. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})})))._sorted();
  2146. return $1;
  2147. }, function($ctx1) {$ctx1.fill(self,"selectorsInProtocol:",{aString:aString},smalltalk.HLMethodsListWidget)})},
  2148. messageSends: ["sorted", "collect:", "selector", "methodsInProtocol:"]}),
  2149. smalltalk.HLMethodsListWidget);
  2150. smalltalk.addMethod(
  2151. smalltalk.method({
  2152. selector: "setItemsForProtocol:",
  2153. fn: function (aString){
  2154. var self=this;
  2155. return smalltalk.withContext(function($ctx1) {
  2156. var $2,$4,$3,$1;
  2157. $2=self;
  2158. $4=aString;
  2159. if(($receiver = $4) == nil || $receiver == undefined){
  2160. $3=[];
  2161. } else {
  2162. $3=self._selectorsInProtocol_(aString);
  2163. };
  2164. $1=_st($2)._items_($3);
  2165. return $1;
  2166. }, function($ctx1) {$ctx1.fill(self,"setItemsForProtocol:",{aString:aString},smalltalk.HLMethodsListWidget)})},
  2167. messageSends: ["items:", "ifNil:ifNotNil:", "selectorsInProtocol:"]}),
  2168. smalltalk.HLMethodsListWidget);
  2169. smalltalk.addMethod(
  2170. smalltalk.method({
  2171. selector: "setItemsForSelectedProtocol",
  2172. fn: function (){
  2173. var self=this;
  2174. return smalltalk.withContext(function($ctx1) {
  2175. self._setItemsForProtocol_(_st(self._model())._selectedProtocol());
  2176. return self}, function($ctx1) {$ctx1.fill(self,"setItemsForSelectedProtocol",{},smalltalk.HLMethodsListWidget)})},
  2177. messageSends: ["setItemsForProtocol:", "selectedProtocol", "model"]}),
  2178. smalltalk.HLMethodsListWidget);
  2179. smalltalk.HLMethodsListWidget.klass.iVarNames = ['selectorsCache'];
  2180. smalltalk.addMethod(
  2181. smalltalk.method({
  2182. selector: "selectorsCache",
  2183. fn: function (){
  2184. var self=this;
  2185. function $HLSelectorsCache(){return smalltalk.HLSelectorsCache||(typeof HLSelectorsCache=="undefined"?nil:HLSelectorsCache)}
  2186. return smalltalk.withContext(function($ctx1) {
  2187. var $1;
  2188. $1=_st($HLSelectorsCache())._current();
  2189. return $1;
  2190. }, function($ctx1) {$ctx1.fill(self,"selectorsCache",{},smalltalk.HLMethodsListWidget.klass)})},
  2191. messageSends: ["current"]}),
  2192. smalltalk.HLMethodsListWidget.klass);
  2193. smalltalk.addClass('HLPackagesListWidget', smalltalk.HLToolListWidget, [], 'Helios-Browser');
  2194. smalltalk.addMethod(
  2195. smalltalk.method({
  2196. selector: "commitPackage",
  2197. fn: function (){
  2198. var self=this;
  2199. return smalltalk.withContext(function($ctx1) {
  2200. _st(self._model())._commitPackage();
  2201. return self}, function($ctx1) {$ctx1.fill(self,"commitPackage",{},smalltalk.HLPackagesListWidget)})},
  2202. messageSends: ["commitPackage", "model"]}),
  2203. smalltalk.HLPackagesListWidget);
  2204. smalltalk.addMethod(
  2205. smalltalk.method({
  2206. selector: "cssClassForItem:",
  2207. fn: function (anItem){
  2208. var self=this;
  2209. return smalltalk.withContext(function($ctx1) {
  2210. return "package";
  2211. }, function($ctx1) {$ctx1.fill(self,"cssClassForItem:",{anItem:anItem},smalltalk.HLPackagesListWidget)})},
  2212. messageSends: []}),
  2213. smalltalk.HLPackagesListWidget);
  2214. smalltalk.addMethod(
  2215. smalltalk.method({
  2216. selector: "focusClassesListWidget",
  2217. fn: function (){
  2218. var self=this;
  2219. function $HLClassesListFocus(){return smalltalk.HLClassesListFocus||(typeof HLClassesListFocus=="undefined"?nil:HLClassesListFocus)}
  2220. return smalltalk.withContext(function($ctx1) {
  2221. _st(_st(self._model())._announcer())._announce_(_st($HLClassesListFocus())._new());
  2222. return self}, function($ctx1) {$ctx1.fill(self,"focusClassesListWidget",{},smalltalk.HLPackagesListWidget)})},
  2223. messageSends: ["announce:", "new", "announcer", "model"]}),
  2224. smalltalk.HLPackagesListWidget);
  2225. smalltalk.addMethod(
  2226. smalltalk.method({
  2227. selector: "initializeItems",
  2228. fn: function (){
  2229. var self=this;
  2230. return smalltalk.withContext(function($ctx1) {
  2231. var $1;
  2232. self["@items"]=_st(_st(self._model())._packages())._sort_((function(a,b){
  2233. return smalltalk.withContext(function($ctx2) {
  2234. return _st(_st(a)._name()).__lt(_st(b)._name());
  2235. }, function($ctx2) {$ctx2.fillBlock({a:a,b:b},$ctx1)})}));
  2236. $1=self["@items"];
  2237. return $1;
  2238. }, function($ctx1) {$ctx1.fill(self,"initializeItems",{},smalltalk.HLPackagesListWidget)})},
  2239. messageSends: ["sort:", "<", "name", "packages", "model"]}),
  2240. smalltalk.HLPackagesListWidget);
  2241. smalltalk.addMethod(
  2242. smalltalk.method({
  2243. selector: "items",
  2244. fn: function (){
  2245. var self=this;
  2246. return smalltalk.withContext(function($ctx1) {
  2247. var $2,$1;
  2248. $2=self["@items"];
  2249. if(($receiver = $2) == nil || $receiver == undefined){
  2250. $1=self._initializeItems();
  2251. } else {
  2252. $1=$2;
  2253. };
  2254. return $1;
  2255. }, function($ctx1) {$ctx1.fill(self,"items",{},smalltalk.HLPackagesListWidget)})},
  2256. messageSends: ["ifNil:", "initializeItems"]}),
  2257. smalltalk.HLPackagesListWidget);
  2258. smalltalk.addMethod(
  2259. smalltalk.method({
  2260. selector: "label",
  2261. fn: function (){
  2262. var self=this;
  2263. return smalltalk.withContext(function($ctx1) {
  2264. return "Packages";
  2265. }, function($ctx1) {$ctx1.fill(self,"label",{},smalltalk.HLPackagesListWidget)})},
  2266. messageSends: []}),
  2267. smalltalk.HLPackagesListWidget);
  2268. smalltalk.addMethod(
  2269. smalltalk.method({
  2270. selector: "observeModel",
  2271. fn: function (){
  2272. var self=this;
  2273. function $HLPackageSelected(){return smalltalk.HLPackageSelected||(typeof HLPackageSelected=="undefined"?nil:HLPackageSelected)}
  2274. function $HLPackagesFocusRequested(){return smalltalk.HLPackagesFocusRequested||(typeof HLPackagesFocusRequested=="undefined"?nil:HLPackagesFocusRequested)}
  2275. return smalltalk.withContext(function($ctx1) {
  2276. var $1,$2;
  2277. $1=_st(self._model())._announcer();
  2278. _st($1)._on_send_to_($HLPackageSelected(),"onPackageSelected:",self);
  2279. $2=_st($1)._on_send_to_($HLPackagesFocusRequested(),"onPackagesFocusRequested",self);
  2280. return self}, function($ctx1) {$ctx1.fill(self,"observeModel",{},smalltalk.HLPackagesListWidget)})},
  2281. messageSends: ["on:send:to:", "announcer", "model"]}),
  2282. smalltalk.HLPackagesListWidget);
  2283. smalltalk.addMethod(
  2284. smalltalk.method({
  2285. selector: "observeSystem",
  2286. fn: function (){
  2287. var self=this;
  2288. function $ClassAdded(){return smalltalk.ClassAdded||(typeof ClassAdded=="undefined"?nil:ClassAdded)}
  2289. return smalltalk.withContext(function($ctx1) {
  2290. _st(_st(self._model())._systemAnnouncer())._on_send_to_($ClassAdded(),"onClassAdded:",self);
  2291. return self}, function($ctx1) {$ctx1.fill(self,"observeSystem",{},smalltalk.HLPackagesListWidget)})},
  2292. messageSends: ["on:send:to:", "systemAnnouncer", "model"]}),
  2293. smalltalk.HLPackagesListWidget);
  2294. smalltalk.addMethod(
  2295. smalltalk.method({
  2296. selector: "onClassAdded:",
  2297. fn: function (anAnnouncement){
  2298. var self=this;
  2299. return smalltalk.withContext(function($ctx1) {
  2300. var $1,$2,$3;
  2301. $1=_st(self._items())._includes_(_st(_st(anAnnouncement)._theClass())._package());
  2302. if(! smalltalk.assert($1)){
  2303. $2=self;
  2304. _st($2)._initializeItems();
  2305. $3=_st($2)._refresh();
  2306. $3;
  2307. };
  2308. return self}, function($ctx1) {$ctx1.fill(self,"onClassAdded:",{anAnnouncement:anAnnouncement},smalltalk.HLPackagesListWidget)})},
  2309. messageSends: ["ifFalse:", "initializeItems", "refresh", "includes:", "package", "theClass", "items"]}),
  2310. smalltalk.HLPackagesListWidget);
  2311. smalltalk.addMethod(
  2312. smalltalk.method({
  2313. selector: "onPackageSelected:",
  2314. fn: function (anAnnouncement){
  2315. var self=this;
  2316. var package_;
  2317. return smalltalk.withContext(function($ctx1) {
  2318. var $1,$2,$3;
  2319. package_=_st(anAnnouncement)._item();
  2320. self._selectedItem_(package_);
  2321. $1=self._hasFocus();
  2322. if(! smalltalk.assert($1)){
  2323. $2=self;
  2324. _st($2)._activateItem_(package_);
  2325. $3=_st($2)._focus();
  2326. $3;
  2327. };
  2328. return self}, function($ctx1) {$ctx1.fill(self,"onPackageSelected:",{anAnnouncement:anAnnouncement,package_:package_},smalltalk.HLPackagesListWidget)})},
  2329. messageSends: ["item", "selectedItem:", "ifFalse:", "activateItem:", "focus", "hasFocus"]}),
  2330. smalltalk.HLPackagesListWidget);
  2331. smalltalk.addMethod(
  2332. smalltalk.method({
  2333. selector: "onPackagesFocusRequested",
  2334. fn: function (){
  2335. var self=this;
  2336. return smalltalk.withContext(function($ctx1) {
  2337. self._focus();
  2338. return self}, function($ctx1) {$ctx1.fill(self,"onPackagesFocusRequested",{},smalltalk.HLPackagesListWidget)})},
  2339. messageSends: ["focus"]}),
  2340. smalltalk.HLPackagesListWidget);
  2341. smalltalk.addMethod(
  2342. smalltalk.method({
  2343. selector: "renderItemLabel:on:",
  2344. fn: function (aPackage,html){
  2345. var self=this;
  2346. return smalltalk.withContext(function($ctx1) {
  2347. _st(html)._with_(_st(aPackage)._name());
  2348. return self}, function($ctx1) {$ctx1.fill(self,"renderItemLabel:on:",{aPackage:aPackage,html:html},smalltalk.HLPackagesListWidget)})},
  2349. messageSends: ["with:", "name"]}),
  2350. smalltalk.HLPackagesListWidget);
  2351. smalltalk.addMethod(
  2352. smalltalk.method({
  2353. selector: "selectItem:",
  2354. fn: function (aPackage){
  2355. var self=this;
  2356. return smalltalk.withContext(function($ctx1) {
  2357. _st(self._model())._selectedPackage_(aPackage);
  2358. return self}, function($ctx1) {$ctx1.fill(self,"selectItem:",{aPackage:aPackage},smalltalk.HLPackagesListWidget)})},
  2359. messageSends: ["selectedPackage:", "model"]}),
  2360. smalltalk.HLPackagesListWidget);
  2361. smalltalk.addClass('HLProtocolsListWidget', smalltalk.HLToolListWidget, [], 'Helios-Browser');
  2362. smalltalk.addMethod(
  2363. smalltalk.method({
  2364. selector: "allProtocol",
  2365. fn: function (){
  2366. var self=this;
  2367. return smalltalk.withContext(function($ctx1) {
  2368. var $1;
  2369. $1=_st(self._model())._allProtocol();
  2370. return $1;
  2371. }, function($ctx1) {$ctx1.fill(self,"allProtocol",{},smalltalk.HLProtocolsListWidget)})},
  2372. messageSends: ["allProtocol", "model"]}),
  2373. smalltalk.HLProtocolsListWidget);
  2374. smalltalk.addMethod(
  2375. smalltalk.method({
  2376. selector: "cssClassForItem:",
  2377. fn: function (anItem){
  2378. var self=this;
  2379. return smalltalk.withContext(function($ctx1) {
  2380. var $1,$2,$3,$4;
  2381. $1=_st(anItem).__eq(self._allProtocol());
  2382. if(smalltalk.assert($1)){
  2383. return "";
  2384. };
  2385. $2=_st(anItem).__eq("private");
  2386. if(smalltalk.assert($2)){
  2387. return "private";
  2388. };
  2389. $3=_st(anItem).__eq("initialization");
  2390. if(smalltalk.assert($3)){
  2391. return "initialization";
  2392. };
  2393. $4=_st(anItem)._match_("^\x5c*");
  2394. if(smalltalk.assert($4)){
  2395. return "extension";
  2396. };
  2397. return "";
  2398. }, function($ctx1) {$ctx1.fill(self,"cssClassForItem:",{anItem:anItem},smalltalk.HLProtocolsListWidget)})},
  2399. messageSends: ["ifTrue:", "=", "allProtocol", "match:"]}),
  2400. smalltalk.HLProtocolsListWidget);
  2401. smalltalk.addMethod(
  2402. smalltalk.method({
  2403. selector: "label",
  2404. fn: function (){
  2405. var self=this;
  2406. return smalltalk.withContext(function($ctx1) {
  2407. return "Protocols";
  2408. }, function($ctx1) {$ctx1.fill(self,"label",{},smalltalk.HLProtocolsListWidget)})},
  2409. messageSends: []}),
  2410. smalltalk.HLProtocolsListWidget);
  2411. smalltalk.addMethod(
  2412. smalltalk.method({
  2413. selector: "observeModel",
  2414. fn: function (){
  2415. var self=this;
  2416. function $HLClassSelected(){return smalltalk.HLClassSelected||(typeof HLClassSelected=="undefined"?nil:HLClassSelected)}
  2417. function $HLShowInstanceToggled(){return smalltalk.HLShowInstanceToggled||(typeof HLShowInstanceToggled=="undefined"?nil:HLShowInstanceToggled)}
  2418. function $HLProtocolSelected(){return smalltalk.HLProtocolSelected||(typeof HLProtocolSelected=="undefined"?nil:HLProtocolSelected)}
  2419. function $HLProtocolsFocusRequested(){return smalltalk.HLProtocolsFocusRequested||(typeof HLProtocolsFocusRequested=="undefined"?nil:HLProtocolsFocusRequested)}
  2420. return smalltalk.withContext(function($ctx1) {
  2421. var $1,$2;
  2422. $1=_st(self._model())._announcer();
  2423. _st($1)._on_send_to_($HLClassSelected(),"onClassSelected:",self);
  2424. _st($1)._on_send_to_($HLShowInstanceToggled(),"onClassSelected:",self);
  2425. _st($1)._on_send_to_($HLProtocolSelected(),"onProtocolSelected:",self);
  2426. $2=_st($1)._on_send_to_($HLProtocolsFocusRequested(),"onProtocolsFocusRequested",self);
  2427. return self}, function($ctx1) {$ctx1.fill(self,"observeModel",{},smalltalk.HLProtocolsListWidget)})},
  2428. messageSends: ["on:send:to:", "announcer", "model"]}),
  2429. smalltalk.HLProtocolsListWidget);
  2430. smalltalk.addMethod(
  2431. smalltalk.method({
  2432. selector: "observeSystem",
  2433. fn: function (){
  2434. var self=this;
  2435. function $ProtocolAdded(){return smalltalk.ProtocolAdded||(typeof ProtocolAdded=="undefined"?nil:ProtocolAdded)}
  2436. function $ProtocolRemoved(){return smalltalk.ProtocolRemoved||(typeof ProtocolRemoved=="undefined"?nil:ProtocolRemoved)}
  2437. return smalltalk.withContext(function($ctx1) {
  2438. var $1,$2;
  2439. $1=_st(self._model())._systemAnnouncer();
  2440. _st($1)._on_send_to_($ProtocolAdded(),"onProtocolAdded:",self);
  2441. $2=_st($1)._on_send_to_($ProtocolRemoved(),"onProtocolRemoved:",self);
  2442. return self}, function($ctx1) {$ctx1.fill(self,"observeSystem",{},smalltalk.HLProtocolsListWidget)})},
  2443. messageSends: ["on:send:to:", "systemAnnouncer", "model"]}),
  2444. smalltalk.HLProtocolsListWidget);
  2445. smalltalk.addMethod(
  2446. smalltalk.method({
  2447. selector: "onClassSelected:",
  2448. fn: function (anAnnouncement){
  2449. var self=this;
  2450. return smalltalk.withContext(function($ctx1) {
  2451. self._selectedItem_(nil);
  2452. self._setItemsForSelectedClass();
  2453. self._refresh();
  2454. return self}, function($ctx1) {$ctx1.fill(self,"onClassSelected:",{anAnnouncement:anAnnouncement},smalltalk.HLProtocolsListWidget)})},
  2455. messageSends: ["selectedItem:", "setItemsForSelectedClass", "refresh"]}),
  2456. smalltalk.HLProtocolsListWidget);
  2457. smalltalk.addMethod(
  2458. smalltalk.method({
  2459. selector: "onProtocolAdded:",
  2460. fn: function (anAnnouncement){
  2461. var self=this;
  2462. var class_;
  2463. return smalltalk.withContext(function($ctx1) {
  2464. var $1,$2;
  2465. class_=_st(anAnnouncement)._theClass();
  2466. $1=_st(class_).__eq(_st(self._model())._selectedClass());
  2467. if(! smalltalk.assert($1)){
  2468. $2=self;
  2469. return $2;
  2470. };
  2471. self._setItemsForSelectedClass();
  2472. self._refresh();
  2473. return self}, function($ctx1) {$ctx1.fill(self,"onProtocolAdded:",{anAnnouncement:anAnnouncement,class_:class_},smalltalk.HLProtocolsListWidget)})},
  2474. messageSends: ["theClass", "ifFalse:", "=", "selectedClass", "model", "setItemsForSelectedClass", "refresh"]}),
  2475. smalltalk.HLProtocolsListWidget);
  2476. smalltalk.addMethod(
  2477. smalltalk.method({
  2478. selector: "onProtocolRemoved:",
  2479. fn: function (anAnnouncement){
  2480. var self=this;
  2481. var class_,protocol;
  2482. return smalltalk.withContext(function($ctx1) {
  2483. var $1,$2,$3,$4,$5;
  2484. class_=_st(anAnnouncement)._theClass();
  2485. protocol=_st(anAnnouncement)._protocol();
  2486. $1=_st(class_).__eq(_st(self._model())._selectedClass());
  2487. if(! smalltalk.assert($1)){
  2488. $2=self;
  2489. return $2;
  2490. };
  2491. $3=_st(_st(self._model())._selectedProtocol()).__eq(protocol);
  2492. if(smalltalk.assert($3)){
  2493. $4=self;
  2494. _st($4)._selectedItem_(nil);
  2495. $5=_st($4)._selectItem_(nil);
  2496. $5;
  2497. };
  2498. self._setItemsForSelectedClass();
  2499. self._refresh();
  2500. return self}, function($ctx1) {$ctx1.fill(self,"onProtocolRemoved:",{anAnnouncement:anAnnouncement,class_:class_,protocol:protocol},smalltalk.HLProtocolsListWidget)})},
  2501. messageSends: ["theClass", "protocol", "ifFalse:", "=", "selectedClass", "model", "ifTrue:", "selectedItem:", "selectItem:", "selectedProtocol", "setItemsForSelectedClass", "refresh"]}),
  2502. smalltalk.HLProtocolsListWidget);
  2503. smalltalk.addMethod(
  2504. smalltalk.method({
  2505. selector: "onProtocolSelected:",
  2506. fn: function (anAnnouncement){
  2507. var self=this;
  2508. var protocol;
  2509. return smalltalk.withContext(function($ctx1) {
  2510. var $1,$2,$3,$4,$5;
  2511. protocol=_st(anAnnouncement)._item();
  2512. self._selectedItem_(protocol);
  2513. $1=protocol;
  2514. if(($receiver = $1) == nil || $receiver == undefined){
  2515. $2=self;
  2516. return $2;
  2517. } else {
  2518. $1;
  2519. };
  2520. $3=self._hasFocus();
  2521. if(! smalltalk.assert($3)){
  2522. $4=self;
  2523. _st($4)._activateItem_(protocol);
  2524. $5=_st($4)._focus();
  2525. $5;
  2526. };
  2527. return self}, function($ctx1) {$ctx1.fill(self,"onProtocolSelected:",{anAnnouncement:anAnnouncement,protocol:protocol},smalltalk.HLProtocolsListWidget)})},
  2528. messageSends: ["item", "selectedItem:", "ifNil:", "ifFalse:", "activateItem:", "focus", "hasFocus"]}),
  2529. smalltalk.HLProtocolsListWidget);
  2530. smalltalk.addMethod(
  2531. smalltalk.method({
  2532. selector: "onProtocolsFocusRequested",
  2533. fn: function (){
  2534. var self=this;
  2535. return smalltalk.withContext(function($ctx1) {
  2536. self._focus();
  2537. return self}, function($ctx1) {$ctx1.fill(self,"onProtocolsFocusRequested",{},smalltalk.HLProtocolsListWidget)})},
  2538. messageSends: ["focus"]}),
  2539. smalltalk.HLProtocolsListWidget);
  2540. smalltalk.addMethod(
  2541. smalltalk.method({
  2542. selector: "renderContentOn:",
  2543. fn: function (html){
  2544. var self=this;
  2545. return smalltalk.withContext(function($ctx1) {
  2546. var $1,$2,$3;
  2547. $1=_st(self._model())._showInstance();
  2548. if(smalltalk.assert($1)){
  2549. smalltalk.HLProtocolsListWidget.superclass.fn.prototype._renderContentOn_.apply(_st(self), [html]);
  2550. } else {
  2551. $2=_st(html)._div();
  2552. _st($2)._class_("class_side");
  2553. $3=_st($2)._with_((function(){
  2554. return smalltalk.withContext(function($ctx2) {
  2555. return smalltalk.HLProtocolsListWidget.superclass.fn.prototype._renderContentOn_.apply(_st(self), [html]);
  2556. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  2557. $3;
  2558. };
  2559. return self}, function($ctx1) {$ctx1.fill(self,"renderContentOn:",{html:html},smalltalk.HLProtocolsListWidget)})},
  2560. messageSends: ["ifFalse:ifTrue:", "class:", "div", "with:", "renderContentOn:", "showInstance", "model"]}),
  2561. smalltalk.HLProtocolsListWidget);
  2562. smalltalk.addMethod(
  2563. smalltalk.method({
  2564. selector: "selectItem:",
  2565. fn: function (aString){
  2566. var self=this;
  2567. return smalltalk.withContext(function($ctx1) {
  2568. _st(self._model())._selectedProtocol_(aString);
  2569. return self}, function($ctx1) {$ctx1.fill(self,"selectItem:",{aString:aString},smalltalk.HLProtocolsListWidget)})},
  2570. messageSends: ["selectedProtocol:", "model"]}),
  2571. smalltalk.HLProtocolsListWidget);
  2572. smalltalk.addMethod(
  2573. smalltalk.method({
  2574. selector: "selectedItem",
  2575. fn: function (){
  2576. var self=this;
  2577. return smalltalk.withContext(function($ctx1) {
  2578. var $1;
  2579. $1=smalltalk.HLProtocolsListWidget.superclass.fn.prototype._selectedItem.apply(_st(self), []);
  2580. return $1;
  2581. }, function($ctx1) {$ctx1.fill(self,"selectedItem",{},smalltalk.HLProtocolsListWidget)})},
  2582. messageSends: ["selectedItem"]}),
  2583. smalltalk.HLProtocolsListWidget);
  2584. smalltalk.addMethod(
  2585. smalltalk.method({
  2586. selector: "setItemsForClass:",
  2587. fn: function (aClass){
  2588. var self=this;
  2589. function $Array(){return smalltalk.Array||(typeof Array=="undefined"?nil:Array)}
  2590. return smalltalk.withContext(function($ctx1) {
  2591. var $1,$3,$4,$5,$2;
  2592. $1=self;
  2593. $3=aClass;
  2594. if(($receiver = $3) == nil || $receiver == undefined){
  2595. $2=_st($Array())._with_(self._allProtocol());
  2596. } else {
  2597. $4=_st($Array())._with_(self._allProtocol());
  2598. _st($4)._addAll_(_st(aClass)._protocols());
  2599. $5=_st($4)._yourself();
  2600. $2=$5;
  2601. };
  2602. _st($1)._items_($2);
  2603. return self}, function($ctx1) {$ctx1.fill(self,"setItemsForClass:",{aClass:aClass},smalltalk.HLProtocolsListWidget)})},
  2604. messageSends: ["items:", "ifNil:ifNotNil:", "with:", "allProtocol", "addAll:", "protocols", "yourself"]}),
  2605. smalltalk.HLProtocolsListWidget);
  2606. smalltalk.addMethod(
  2607. smalltalk.method({
  2608. selector: "setItemsForSelectedClass",
  2609. fn: function (){
  2610. var self=this;
  2611. return smalltalk.withContext(function($ctx1) {
  2612. self._setItemsForClass_(_st(self._model())._selectedClass());
  2613. return self}, function($ctx1) {$ctx1.fill(self,"setItemsForSelectedClass",{},smalltalk.HLProtocolsListWidget)})},
  2614. messageSends: ["setItemsForClass:", "selectedClass", "model"]}),
  2615. smalltalk.HLProtocolsListWidget);
  2616. smalltalk.addClass('HLSelectorsCache', smalltalk.Object, ['classesCache'], 'Helios-Browser');
  2617. smalltalk.addMethod(
  2618. smalltalk.method({
  2619. selector: "cacheFor:",
  2620. fn: function (aClass){
  2621. var self=this;
  2622. return smalltalk.withContext(function($ctx1) {
  2623. var $1,$2;
  2624. $1=aClass;
  2625. if(($receiver = $1) == nil || $receiver == undefined){
  2626. return nil;
  2627. } else {
  2628. $1;
  2629. };
  2630. $2=_st(self._classesCache())._at_ifAbsentPut_(_st(aClass)._name(),(function(){
  2631. return smalltalk.withContext(function($ctx2) {
  2632. return self._newCacheFor_(aClass);
  2633. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  2634. return $2;
  2635. }, function($ctx1) {$ctx1.fill(self,"cacheFor:",{aClass:aClass},smalltalk.HLSelectorsCache)})},
  2636. messageSends: ["ifNil:", "at:ifAbsentPut:", "name", "newCacheFor:", "classesCache"]}),
  2637. smalltalk.HLSelectorsCache);
  2638. smalltalk.addMethod(
  2639. smalltalk.method({
  2640. selector: "classesCache",
  2641. fn: function (){
  2642. var self=this;
  2643. function $HashedCollection(){return smalltalk.HashedCollection||(typeof HashedCollection=="undefined"?nil:HashedCollection)}
  2644. return smalltalk.withContext(function($ctx1) {
  2645. var $2,$1;
  2646. $2=self["@classesCache"];
  2647. if(($receiver = $2) == nil || $receiver == undefined){
  2648. self["@classesCache"]=_st($HashedCollection())._new();
  2649. $1=self["@classesCache"];
  2650. } else {
  2651. $1=$2;
  2652. };
  2653. return $1;
  2654. }, function($ctx1) {$ctx1.fill(self,"classesCache",{},smalltalk.HLSelectorsCache)})},
  2655. messageSends: ["ifNil:", "new"]}),
  2656. smalltalk.HLSelectorsCache);
  2657. smalltalk.addMethod(
  2658. smalltalk.method({
  2659. selector: "initialize",
  2660. fn: function (){
  2661. var self=this;
  2662. return smalltalk.withContext(function($ctx1) {
  2663. smalltalk.HLSelectorsCache.superclass.fn.prototype._initialize.apply(_st(self), []);
  2664. self._observeSystem();
  2665. return self}, function($ctx1) {$ctx1.fill(self,"initialize",{},smalltalk.HLSelectorsCache)})},
  2666. messageSends: ["initialize", "observeSystem"]}),
  2667. smalltalk.HLSelectorsCache);
  2668. smalltalk.addMethod(
  2669. smalltalk.method({
  2670. selector: "invalidateCacheFor:",
  2671. fn: function (aMethod){
  2672. var self=this;
  2673. return smalltalk.withContext(function($ctx1) {
  2674. _st(self._cacheFor_(_st(aMethod)._methodClass()))._invalidateSelector_(_st(aMethod)._selector());
  2675. return self}, function($ctx1) {$ctx1.fill(self,"invalidateCacheFor:",{aMethod:aMethod},smalltalk.HLSelectorsCache)})},
  2676. messageSends: ["invalidateSelector:", "selector", "cacheFor:", "methodClass"]}),
  2677. smalltalk.HLSelectorsCache);
  2678. smalltalk.addMethod(
  2679. smalltalk.method({
  2680. selector: "isOverridden:",
  2681. fn: function (aMethod){
  2682. var self=this;
  2683. return smalltalk.withContext(function($ctx1) {
  2684. var $1;
  2685. $1=_st(self._cacheFor_(_st(aMethod)._methodClass()))._isOverridden_(aMethod);
  2686. return $1;
  2687. }, function($ctx1) {$ctx1.fill(self,"isOverridden:",{aMethod:aMethod},smalltalk.HLSelectorsCache)})},
  2688. messageSends: ["isOverridden:", "cacheFor:", "methodClass"]}),
  2689. smalltalk.HLSelectorsCache);
  2690. smalltalk.addMethod(
  2691. smalltalk.method({
  2692. selector: "isOverride:",
  2693. fn: function (aMethod){
  2694. var self=this;
  2695. return smalltalk.withContext(function($ctx1) {
  2696. var $1;
  2697. $1=_st(self._cacheFor_(_st(aMethod)._methodClass()))._isOverride_(aMethod);
  2698. return $1;
  2699. }, function($ctx1) {$ctx1.fill(self,"isOverride:",{aMethod:aMethod},smalltalk.HLSelectorsCache)})},
  2700. messageSends: ["isOverride:", "cacheFor:", "methodClass"]}),
  2701. smalltalk.HLSelectorsCache);
  2702. smalltalk.addMethod(
  2703. smalltalk.method({
  2704. selector: "newCacheFor:",
  2705. fn: function (aClass){
  2706. var self=this;
  2707. function $HLClassCache(){return smalltalk.HLClassCache||(typeof HLClassCache=="undefined"?nil:HLClassCache)}
  2708. return smalltalk.withContext(function($ctx1) {
  2709. var $1;
  2710. $1=_st($HLClassCache())._on_selectorsCache_(aClass,self);
  2711. return $1;
  2712. }, function($ctx1) {$ctx1.fill(self,"newCacheFor:",{aClass:aClass},smalltalk.HLSelectorsCache)})},
  2713. messageSends: ["on:selectorsCache:"]}),
  2714. smalltalk.HLSelectorsCache);
  2715. smalltalk.addMethod(
  2716. smalltalk.method({
  2717. selector: "observeSystem",
  2718. fn: function (){
  2719. var self=this;
  2720. function $MethodAdded(){return smalltalk.MethodAdded||(typeof MethodAdded=="undefined"?nil:MethodAdded)}
  2721. function $SystemAnnouncer(){return smalltalk.SystemAnnouncer||(typeof SystemAnnouncer=="undefined"?nil:SystemAnnouncer)}
  2722. function $MethodRemoved(){return smalltalk.MethodRemoved||(typeof MethodRemoved=="undefined"?nil:MethodRemoved)}
  2723. return smalltalk.withContext(function($ctx1) {
  2724. var $1,$2;
  2725. $1=_st($SystemAnnouncer())._current();
  2726. _st($1)._on_send_to_($MethodAdded(),"onMethodAdded:",self);
  2727. $2=_st($1)._on_send_to_($MethodRemoved(),"onMethodRemoved:",self);
  2728. return self}, function($ctx1) {$ctx1.fill(self,"observeSystem",{},smalltalk.HLSelectorsCache)})},
  2729. messageSends: ["on:send:to:", "current"]}),
  2730. smalltalk.HLSelectorsCache);
  2731. smalltalk.addMethod(
  2732. smalltalk.method({
  2733. selector: "onMethodAdded:",
  2734. fn: function (anAnnouncement){
  2735. var self=this;
  2736. return smalltalk.withContext(function($ctx1) {
  2737. self._invalidateCacheFor_(_st(anAnnouncement)._method());
  2738. return self}, function($ctx1) {$ctx1.fill(self,"onMethodAdded:",{anAnnouncement:anAnnouncement},smalltalk.HLSelectorsCache)})},
  2739. messageSends: ["invalidateCacheFor:", "method"]}),
  2740. smalltalk.HLSelectorsCache);
  2741. smalltalk.addMethod(
  2742. smalltalk.method({
  2743. selector: "onMethodRemoved:",
  2744. fn: function (anAnnouncement){
  2745. var self=this;
  2746. return smalltalk.withContext(function($ctx1) {
  2747. self._invalidateCacheFor_(_st(anAnnouncement)._method());
  2748. return self}, function($ctx1) {$ctx1.fill(self,"onMethodRemoved:",{anAnnouncement:anAnnouncement},smalltalk.HLSelectorsCache)})},
  2749. messageSends: ["invalidateCacheFor:", "method"]}),
  2750. smalltalk.HLSelectorsCache);
  2751. smalltalk.HLSelectorsCache.klass.iVarNames = ['current'];
  2752. smalltalk.addMethod(
  2753. smalltalk.method({
  2754. selector: "current",
  2755. fn: function (){
  2756. var self=this;
  2757. return smalltalk.withContext(function($ctx1) {
  2758. var $2,$1;
  2759. $2=self["@current"];
  2760. if(($receiver = $2) == nil || $receiver == undefined){
  2761. self["@current"]=smalltalk.HLSelectorsCache.klass.superclass.fn.prototype._new.apply(_st(self), []);
  2762. $1=self["@current"];
  2763. } else {
  2764. $1=$2;
  2765. };
  2766. return $1;
  2767. }, function($ctx1) {$ctx1.fill(self,"current",{},smalltalk.HLSelectorsCache.klass)})},
  2768. messageSends: ["ifNil:", "new"]}),
  2769. smalltalk.HLSelectorsCache.klass);
  2770. smalltalk.addMethod(
  2771. smalltalk.method({
  2772. selector: "flush",
  2773. fn: function (){
  2774. var self=this;
  2775. return smalltalk.withContext(function($ctx1) {
  2776. self["@current"]=nil;
  2777. return self}, function($ctx1) {$ctx1.fill(self,"flush",{},smalltalk.HLSelectorsCache.klass)})},
  2778. messageSends: []}),
  2779. smalltalk.HLSelectorsCache.klass);
  2780. smalltalk.addMethod(
  2781. smalltalk.method({
  2782. selector: "new",
  2783. fn: function (){
  2784. var self=this;
  2785. return smalltalk.withContext(function($ctx1) {
  2786. self._shouldNotImplement();
  2787. return self}, function($ctx1) {$ctx1.fill(self,"new",{},smalltalk.HLSelectorsCache.klass)})},
  2788. messageSends: ["shouldNotImplement"]}),
  2789. smalltalk.HLSelectorsCache.klass);
  2790. })(global_smalltalk,global_nil,global__st);