Helios-Browser.deploy.js 108 KB

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