Helios-Browser.js 134 KB

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