Helios-Browser.js 151 KB

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