1
0

Helios-Browser.deploy.js 87 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384
  1. smalltalk.addPackage('Helios-Browser');
  2. smalltalk.addClass('HLBrowser', smalltalk.HLWidget, ['model', 'packagesListWidget', 'classesListWidget', 'protocolsListWidget', 'methodsListWidget', 'sourceWidget'], 'Helios-Browser');
  3. smalltalk.addMethod(
  4. "_announcer",
  5. smalltalk.method({
  6. selector: "announcer",
  7. fn: function (){
  8. var self=this;
  9. return smalltalk.withContext(function($ctx1) { var $1;
  10. $1=_st(_st(self)._model())._announcer();
  11. return $1;
  12. }, function($ctx1) {$ctx1.fill(self,"announcer",{}, smalltalk.HLBrowser)})},
  13. messageSends: ["announcer", "model"]}),
  14. smalltalk.HLBrowser);
  15. smalltalk.addMethod(
  16. "_classesListWidget",
  17. smalltalk.method({
  18. selector: "classesListWidget",
  19. fn: function (){
  20. var self=this;
  21. return smalltalk.withContext(function($ctx1) { var $2,$1;
  22. $2=self["@classesListWidget"];
  23. if(($receiver = $2) == nil || $receiver == undefined){
  24. self["@classesListWidget"]=_st((smalltalk.HLClassesListWidget || HLClassesListWidget))._on_(_st(self)._model());
  25. self["@classesListWidget"];
  26. $1=_st(self["@classesListWidget"])._next_(_st(self)._protocolsListWidget());
  27. } else {
  28. $1=$2;
  29. };
  30. return $1;
  31. }, function($ctx1) {$ctx1.fill(self,"classesListWidget",{}, smalltalk.HLBrowser)})},
  32. messageSends: ["ifNil:", "on:", "model", "next:", "protocolsListWidget"]}),
  33. smalltalk.HLBrowser);
  34. smalltalk.addMethod(
  35. "_environment",
  36. smalltalk.method({
  37. selector: "environment",
  38. fn: function (){
  39. var self=this;
  40. return smalltalk.withContext(function($ctx1) { var $1;
  41. $1=_st(_st(self)._model())._environment();
  42. return $1;
  43. }, function($ctx1) {$ctx1.fill(self,"environment",{}, smalltalk.HLBrowser)})},
  44. messageSends: ["environment", "model"]}),
  45. smalltalk.HLBrowser);
  46. smalltalk.addMethod(
  47. "_methodsListWidget",
  48. smalltalk.method({
  49. selector: "methodsListWidget",
  50. fn: function (){
  51. var self=this;
  52. return smalltalk.withContext(function($ctx1) { var $2,$1;
  53. $2=self["@methodsListWidget"];
  54. if(($receiver = $2) == nil || $receiver == undefined){
  55. self["@methodsListWidget"]=_st((smalltalk.HLMethodsListWidget || HLMethodsListWidget))._on_(_st(self)._model());
  56. $1=self["@methodsListWidget"];
  57. } else {
  58. $1=$2;
  59. };
  60. return $1;
  61. }, function($ctx1) {$ctx1.fill(self,"methodsListWidget",{}, smalltalk.HLBrowser)})},
  62. messageSends: ["ifNil:", "on:", "model"]}),
  63. smalltalk.HLBrowser);
  64. smalltalk.addMethod(
  65. "_model",
  66. smalltalk.method({
  67. selector: "model",
  68. fn: function (){
  69. var self=this;
  70. return smalltalk.withContext(function($ctx1) { var $2,$1;
  71. $2=self["@model"];
  72. if(($receiver = $2) == nil || $receiver == undefined){
  73. self["@model"]=_st((smalltalk.HLBrowserModel || HLBrowserModel))._new();
  74. $1=self["@model"];
  75. } else {
  76. $1=$2;
  77. };
  78. return $1;
  79. }, function($ctx1) {$ctx1.fill(self,"model",{}, smalltalk.HLBrowser)})},
  80. messageSends: ["ifNil:", "new"]}),
  81. smalltalk.HLBrowser);
  82. smalltalk.addMethod(
  83. "_model_",
  84. smalltalk.method({
  85. selector: "model:",
  86. fn: function (aModel){
  87. var self=this;
  88. return smalltalk.withContext(function($ctx1) { self["@model"]=aModel;
  89. return self}, function($ctx1) {$ctx1.fill(self,"model:",{aModel:aModel}, smalltalk.HLBrowser)})},
  90. messageSends: []}),
  91. smalltalk.HLBrowser);
  92. smalltalk.addMethod(
  93. "_packagesListWidget",
  94. smalltalk.method({
  95. selector: "packagesListWidget",
  96. fn: function (){
  97. var self=this;
  98. return smalltalk.withContext(function($ctx1) { var $2,$1;
  99. $2=self["@packagesListWidget"];
  100. if(($receiver = $2) == nil || $receiver == undefined){
  101. self["@packagesListWidget"]=_st((smalltalk.HLPackagesListWidget || HLPackagesListWidget))._on_(_st(self)._model());
  102. self["@packagesListWidget"];
  103. $1=_st(self["@packagesListWidget"])._next_(_st(self)._classesListWidget());
  104. } else {
  105. $1=$2;
  106. };
  107. return $1;
  108. }, function($ctx1) {$ctx1.fill(self,"packagesListWidget",{}, smalltalk.HLBrowser)})},
  109. messageSends: ["ifNil:", "on:", "model", "next:", "classesListWidget"]}),
  110. smalltalk.HLBrowser);
  111. smalltalk.addMethod(
  112. "_protocolsListWidget",
  113. smalltalk.method({
  114. selector: "protocolsListWidget",
  115. fn: function (){
  116. var self=this;
  117. return smalltalk.withContext(function($ctx1) { var $2,$1;
  118. $2=self["@protocolsListWidget"];
  119. if(($receiver = $2) == nil || $receiver == undefined){
  120. self["@protocolsListWidget"]=_st((smalltalk.HLProtocolsListWidget || HLProtocolsListWidget))._on_(_st(self)._model());
  121. self["@protocolsListWidget"];
  122. $1=_st(self["@protocolsListWidget"])._next_(_st(self)._methodsListWidget());
  123. } else {
  124. $1=$2;
  125. };
  126. return $1;
  127. }, function($ctx1) {$ctx1.fill(self,"protocolsListWidget",{}, smalltalk.HLBrowser)})},
  128. messageSends: ["ifNil:", "on:", "model", "next:", "methodsListWidget"]}),
  129. smalltalk.HLBrowser);
  130. smalltalk.addMethod(
  131. "_registerBindingsOn_",
  132. smalltalk.method({
  133. selector: "registerBindingsOn:",
  134. fn: function (aBindingGroup){
  135. var self=this;
  136. return smalltalk.withContext(function($ctx1) { var $1,$2,$3;
  137. $1=aBindingGroup;
  138. _st($1)._addGroupKey_labelled_((66),"Browse");
  139. _st($1)._addGroupKey_labelled_((71),"Go to");
  140. $2=_st($1)._addGroupKey_labelled_((84),"Toggle");
  141. _st(_st((smalltalk.HLBrowserCommand || HLBrowserCommand))._withAllSubclasses())._do_((function(each){
  142. return smalltalk.withContext(function($ctx2) { $3=_st(each)._key();
  143. if(($receiver = $3) == nil || $receiver == undefined){
  144. return $3;
  145. } else {
  146. return _st(_st(aBindingGroup)._at_(_st(each)._bindingGroup()))._add_(_st(_st(each)._on_(_st(self)._model()))._asBinding());
  147. };
  148. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})}));
  149. return self}, function($ctx1) {$ctx1.fill(self,"registerBindingsOn:",{aBindingGroup:aBindingGroup}, smalltalk.HLBrowser)})},
  150. messageSends: ["addGroupKey:labelled:", "do:", "ifNotNil:", "add:", "asBinding", "on:", "model", "at:", "bindingGroup", "key", "withAllSubclasses"]}),
  151. smalltalk.HLBrowser);
  152. smalltalk.addMethod(
  153. "_renderContentOn_",
  154. smalltalk.method({
  155. selector: "renderContentOn:",
  156. fn: function (html){
  157. var self=this;
  158. return smalltalk.withContext(function($ctx1) { _st(html)._with_(_st((smalltalk.HLContainer || HLContainer))._with_(_st((smalltalk.HLHorizontalSplitter || HLHorizontalSplitter))._with_with_(_st((smalltalk.HLVerticalSplitter || HLVerticalSplitter))._with_with_(_st((smalltalk.HLVerticalSplitter || HLVerticalSplitter))._with_with_(_st(self)._packagesListWidget(),_st(self)._classesListWidget()),_st((smalltalk.HLVerticalSplitter || HLVerticalSplitter))._with_with_(_st(self)._protocolsListWidget(),_st(self)._methodsListWidget())),_st(self)._sourceWidget())));
  159. return self}, function($ctx1) {$ctx1.fill(self,"renderContentOn:",{html:html}, smalltalk.HLBrowser)})},
  160. messageSends: ["with:", "with:with:", "packagesListWidget", "classesListWidget", "protocolsListWidget", "methodsListWidget", "sourceWidget"]}),
  161. smalltalk.HLBrowser);
  162. smalltalk.addMethod(
  163. "_sourceWidget",
  164. smalltalk.method({
  165. selector: "sourceWidget",
  166. fn: function (){
  167. var self=this;
  168. return smalltalk.withContext(function($ctx1) { var $2,$1;
  169. $2=self["@sourceWidget"];
  170. if(($receiver = $2) == nil || $receiver == undefined){
  171. self["@sourceWidget"]=_st((smalltalk.HLBrowserSourceWidget || HLBrowserSourceWidget))._on_(_st(self)._model());
  172. $1=self["@sourceWidget"];
  173. } else {
  174. $1=$2;
  175. };
  176. return $1;
  177. }, function($ctx1) {$ctx1.fill(self,"sourceWidget",{}, smalltalk.HLBrowser)})},
  178. messageSends: ["ifNil:", "on:", "model"]}),
  179. smalltalk.HLBrowser);
  180. smalltalk.HLBrowser.klass.iVarNames = ['nextId'];
  181. smalltalk.addMethod(
  182. "_canBeOpenAsTab",
  183. smalltalk.method({
  184. selector: "canBeOpenAsTab",
  185. fn: function (){
  186. var self=this;
  187. return smalltalk.withContext(function($ctx1) { return true;
  188. }, function($ctx1) {$ctx1.fill(self,"canBeOpenAsTab",{}, smalltalk.HLBrowser.klass)})},
  189. messageSends: []}),
  190. smalltalk.HLBrowser.klass);
  191. smalltalk.addMethod(
  192. "_nextId",
  193. smalltalk.method({
  194. selector: "nextId",
  195. fn: function (){
  196. var self=this;
  197. return smalltalk.withContext(function($ctx1) { var $1,$2;
  198. $1=self["@nextId"];
  199. if(($receiver = $1) == nil || $receiver == undefined){
  200. self["@nextId"]=(0);
  201. self["@nextId"];
  202. } else {
  203. $1;
  204. };
  205. $2=_st("browser_").__comma(_st(_st(self["@nextId"]).__plus((1)))._asString());
  206. return $2;
  207. }, function($ctx1) {$ctx1.fill(self,"nextId",{}, smalltalk.HLBrowser.klass)})},
  208. messageSends: ["ifNil:", ",", "asString", "+"]}),
  209. smalltalk.HLBrowser.klass);
  210. smalltalk.addMethod(
  211. "_tabLabel",
  212. smalltalk.method({
  213. selector: "tabLabel",
  214. fn: function (){
  215. var self=this;
  216. return smalltalk.withContext(function($ctx1) { return "Browser";
  217. }, function($ctx1) {$ctx1.fill(self,"tabLabel",{}, smalltalk.HLBrowser.klass)})},
  218. messageSends: []}),
  219. smalltalk.HLBrowser.klass);
  220. smalltalk.addMethod(
  221. "_tabPriority",
  222. smalltalk.method({
  223. selector: "tabPriority",
  224. fn: function (){
  225. var self=this;
  226. return smalltalk.withContext(function($ctx1) { return (0);
  227. }, function($ctx1) {$ctx1.fill(self,"tabPriority",{}, smalltalk.HLBrowser.klass)})},
  228. messageSends: []}),
  229. smalltalk.HLBrowser.klass);
  230. smalltalk.addClass('HLBrowserListWidget', smalltalk.HLNavigationListWidget, ['model'], 'Helios-Browser');
  231. smalltalk.addMethod(
  232. "_initialize",
  233. smalltalk.method({
  234. selector: "initialize",
  235. fn: function (){
  236. var self=this;
  237. return smalltalk.withContext(function($ctx1) { smalltalk.HLNavigationListWidget.fn.prototype._initialize.apply(_st(self), []);
  238. _st(self)._observeSystem();
  239. return self}, function($ctx1) {$ctx1.fill(self,"initialize",{}, smalltalk.HLBrowserListWidget)})},
  240. messageSends: ["initialize", "observeSystem"]}),
  241. smalltalk.HLBrowserListWidget);
  242. smalltalk.addMethod(
  243. "_model",
  244. smalltalk.method({
  245. selector: "model",
  246. fn: function (){
  247. var self=this;
  248. return smalltalk.withContext(function($ctx1) { var $1;
  249. $1=self["@model"];
  250. return $1;
  251. }, function($ctx1) {$ctx1.fill(self,"model",{}, smalltalk.HLBrowserListWidget)})},
  252. messageSends: []}),
  253. smalltalk.HLBrowserListWidget);
  254. smalltalk.addMethod(
  255. "_model_",
  256. smalltalk.method({
  257. selector: "model:",
  258. fn: function (aBrowserModel){
  259. var self=this;
  260. return smalltalk.withContext(function($ctx1) { self["@model"]=aBrowserModel;
  261. _st(self)._observeModel();
  262. return self}, function($ctx1) {$ctx1.fill(self,"model:",{aBrowserModel:aBrowserModel}, smalltalk.HLBrowserListWidget)})},
  263. messageSends: ["observeModel"]}),
  264. smalltalk.HLBrowserListWidget);
  265. smalltalk.addMethod(
  266. "_observeModel",
  267. smalltalk.method({
  268. selector: "observeModel",
  269. fn: function (){
  270. var self=this;
  271. return smalltalk.withContext(function($ctx1) { return self}, function($ctx1) {$ctx1.fill(self,"observeModel",{}, smalltalk.HLBrowserListWidget)})},
  272. messageSends: []}),
  273. smalltalk.HLBrowserListWidget);
  274. smalltalk.addMethod(
  275. "_observeSystem",
  276. smalltalk.method({
  277. selector: "observeSystem",
  278. fn: function (){
  279. var self=this;
  280. return smalltalk.withContext(function($ctx1) { return self}, function($ctx1) {$ctx1.fill(self,"observeSystem",{}, smalltalk.HLBrowserListWidget)})},
  281. messageSends: []}),
  282. smalltalk.HLBrowserListWidget);
  283. smalltalk.addMethod(
  284. "_on_",
  285. smalltalk.method({
  286. selector: "on:",
  287. fn: function (aModel){
  288. var self=this;
  289. return smalltalk.withContext(function($ctx1) { var $2,$3,$1;
  290. $2=_st(self)._new();
  291. _st($2)._model_(aModel);
  292. $3=_st($2)._yourself();
  293. $1=$3;
  294. return $1;
  295. }, function($ctx1) {$ctx1.fill(self,"on:",{aModel:aModel}, smalltalk.HLBrowserListWidget.klass)})},
  296. messageSends: ["model:", "new", "yourself"]}),
  297. smalltalk.HLBrowserListWidget.klass);
  298. smalltalk.addClass('HLClassesListWidget', smalltalk.HLBrowserListWidget, [], 'Helios-Browser');
  299. smalltalk.addMethod(
  300. "_focusMethodsListWidget",
  301. smalltalk.method({
  302. selector: "focusMethodsListWidget",
  303. fn: function (){
  304. var self=this;
  305. return smalltalk.withContext(function($ctx1) { _st(_st(_st(self)._model())._announcer())._announce_(_st((smalltalk.HLMethodsListFocus || HLMethodsListFocus))._new());
  306. return self}, function($ctx1) {$ctx1.fill(self,"focusMethodsListWidget",{}, smalltalk.HLClassesListWidget)})},
  307. messageSends: ["announce:", "new", "announcer", "model"]}),
  308. smalltalk.HLClassesListWidget);
  309. smalltalk.addMethod(
  310. "_focusProtocolsListWidget",
  311. smalltalk.method({
  312. selector: "focusProtocolsListWidget",
  313. fn: function (){
  314. var self=this;
  315. return smalltalk.withContext(function($ctx1) { _st(_st(_st(self)._model())._announcer())._announce_(_st((smalltalk.HLProtocolsListFocus || HLProtocolsListFocus))._new());
  316. return self}, function($ctx1) {$ctx1.fill(self,"focusProtocolsListWidget",{}, smalltalk.HLClassesListWidget)})},
  317. messageSends: ["announce:", "new", "announcer", "model"]}),
  318. smalltalk.HLClassesListWidget);
  319. smalltalk.addMethod(
  320. "_getChildrenOf_",
  321. smalltalk.method({
  322. selector: "getChildrenOf:",
  323. fn: function (aClass){
  324. var self=this;
  325. return smalltalk.withContext(function($ctx1) { var $1;
  326. $1=_st(_st(self)._items())._select_((function(each){
  327. return smalltalk.withContext(function($ctx2) { return _st(_st(each)._superclass()).__eq(aClass);
  328. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})}));
  329. return $1;
  330. }, function($ctx1) {$ctx1.fill(self,"getChildrenOf:",{aClass:aClass}, smalltalk.HLClassesListWidget)})},
  331. messageSends: ["select:", "=", "superclass", "items"]}),
  332. smalltalk.HLClassesListWidget);
  333. smalltalk.addMethod(
  334. "_getRootClassesOf_",
  335. smalltalk.method({
  336. selector: "getRootClassesOf:",
  337. fn: function (aCollection){
  338. var self=this;
  339. return smalltalk.withContext(function($ctx1) { var $1;
  340. $1=_st(aCollection)._select_((function(each){
  341. return smalltalk.withContext(function($ctx2) { return _st(_st(aCollection)._includes_(_st(each)._superclass()))._not();
  342. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})}));
  343. return $1;
  344. }, function($ctx1) {$ctx1.fill(self,"getRootClassesOf:",{aCollection:aCollection}, smalltalk.HLClassesListWidget)})},
  345. messageSends: ["select:", "not", "includes:", "superclass"]}),
  346. smalltalk.HLClassesListWidget);
  347. smalltalk.addMethod(
  348. "_iconForItem_",
  349. smalltalk.method({
  350. selector: "iconForItem:",
  351. fn: function (aClass){
  352. var self=this;
  353. return smalltalk.withContext(function($ctx1) { var $2,$1;
  354. $2=_st(_st(_st(aClass)._theNonMetaClass())._comment())._isEmpty();
  355. if(smalltalk.assert($2)){
  356. $1="icon-question-sign";
  357. } else {
  358. $1="icon-none";
  359. };
  360. return $1;
  361. }, function($ctx1) {$ctx1.fill(self,"iconForItem:",{aClass:aClass}, smalltalk.HLClassesListWidget)})},
  362. messageSends: ["ifFalse:ifTrue:", "isEmpty", "comment", "theNonMetaClass"]}),
  363. smalltalk.HLClassesListWidget);
  364. smalltalk.addMethod(
  365. "_observeModel",
  366. smalltalk.method({
  367. selector: "observeModel",
  368. fn: function (){
  369. var self=this;
  370. return smalltalk.withContext(function($ctx1) { var $1,$2;
  371. $1=_st(_st(self)._model())._announcer();
  372. _st($1)._on_do_((smalltalk.HLPackageSelected || HLPackageSelected),(function(ann){
  373. return smalltalk.withContext(function($ctx2) { return _st(self)._onPackageSelected_(_st(ann)._item());
  374. }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1)})}));
  375. _st($1)._on_do_((smalltalk.HLShowInstanceToggled || HLShowInstanceToggled),(function(ann){
  376. return smalltalk.withContext(function($ctx2) { return _st(self)._onShowInstanceToggled();
  377. }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1)})}));
  378. $2=_st($1)._on_do_((smalltalk.HLClassSelected || HLClassSelected),(function(ann){
  379. return smalltalk.withContext(function($ctx2) { return _st(self)._onClassSelected_(_st(ann)._item());
  380. }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1)})}));
  381. return self}, function($ctx1) {$ctx1.fill(self,"observeModel",{}, smalltalk.HLClassesListWidget)})},
  382. messageSends: ["on:do:", "onPackageSelected:", "item", "announcer", "model", "onShowInstanceToggled", "onClassSelected:"]}),
  383. smalltalk.HLClassesListWidget);
  384. smalltalk.addMethod(
  385. "_observeSystem",
  386. smalltalk.method({
  387. selector: "observeSystem",
  388. fn: function (){
  389. var self=this;
  390. return smalltalk.withContext(function($ctx1) { var $1,$2;
  391. $1=_st((smalltalk.SystemAnnouncer || SystemAnnouncer))._current();
  392. _st($1)._on_do_((smalltalk.ClassAdded || ClassAdded),(function(ann){
  393. return smalltalk.withContext(function($ctx2) { return _st(self)._onClassAdded_(_st(ann)._theClass());
  394. }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1)})}));
  395. $2=_st($1)._on_do_((smalltalk.ClassRemoved || ClassRemoved),(function(ann){
  396. return smalltalk.withContext(function($ctx2) { return _st(self)._onClassRemoved_(_st(ann)._theClass());
  397. }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1)})}));
  398. return self}, function($ctx1) {$ctx1.fill(self,"observeSystem",{}, smalltalk.HLClassesListWidget)})},
  399. messageSends: ["on:do:", "onClassAdded:", "theClass", "current", "onClassRemoved:"]}),
  400. smalltalk.HLClassesListWidget);
  401. smalltalk.addMethod(
  402. "_onClassAdded_",
  403. smalltalk.method({
  404. selector: "onClassAdded:",
  405. fn: function (aClass){
  406. var self=this;
  407. return smalltalk.withContext(function($ctx1) { var $1,$2;
  408. $1=_st(_st(aClass)._package()).__eq(_st(_st(self)._model())._selectedPackage());
  409. if(! smalltalk.assert($1)){
  410. $2=self;
  411. return $2;
  412. };
  413. _st(self)._setItemsForSelectedPackage();
  414. _st(self)._refresh();
  415. return self}, function($ctx1) {$ctx1.fill(self,"onClassAdded:",{aClass:aClass}, smalltalk.HLClassesListWidget)})},
  416. messageSends: ["ifFalse:", "=", "selectedPackage", "model", "package", "setItemsForSelectedPackage", "refresh"]}),
  417. smalltalk.HLClassesListWidget);
  418. smalltalk.addMethod(
  419. "_onClassRemoved_",
  420. smalltalk.method({
  421. selector: "onClassRemoved:",
  422. fn: function (aClass){
  423. var self=this;
  424. return smalltalk.withContext(function($ctx1) { var $1,$2,$3;
  425. $1=_st(_st(aClass)._package()).__eq(_st(_st(self)._model())._selectedPackage());
  426. if(! smalltalk.assert($1)){
  427. $2=self;
  428. return $2;
  429. };
  430. $3=_st(aClass).__eq(_st(_st(self)._model())._selectedClass());
  431. if(smalltalk.assert($3)){
  432. _st(self)._selectItem_(nil);
  433. };
  434. _st(self)._setItemsForSelectedPackage();
  435. _st(self)._refresh();
  436. return self}, function($ctx1) {$ctx1.fill(self,"onClassRemoved:",{aClass:aClass}, smalltalk.HLClassesListWidget)})},
  437. messageSends: ["ifFalse:", "=", "selectedPackage", "model", "package", "ifTrue:", "selectItem:", "selectedClass", "setItemsForSelectedPackage", "refresh"]}),
  438. smalltalk.HLClassesListWidget);
  439. smalltalk.addMethod(
  440. "_onClassSelected_",
  441. smalltalk.method({
  442. selector: "onClassSelected:",
  443. fn: function (aClass){
  444. var self=this;
  445. return smalltalk.withContext(function($ctx1) { var $1,$2;
  446. _st(self)._selectedItem_(aClass);
  447. $1=aClass;
  448. if(($receiver = $1) == nil || $receiver == undefined){
  449. $2=self;
  450. return $2;
  451. } else {
  452. $1;
  453. };
  454. _st(self)._focus();
  455. return self}, function($ctx1) {$ctx1.fill(self,"onClassSelected:",{aClass:aClass}, smalltalk.HLClassesListWidget)})},
  456. messageSends: ["selectedItem:", "ifNil:", "focus"]}),
  457. smalltalk.HLClassesListWidget);
  458. smalltalk.addMethod(
  459. "_onPackageSelected_",
  460. smalltalk.method({
  461. selector: "onPackageSelected:",
  462. fn: function (aPackage){
  463. var self=this;
  464. return smalltalk.withContext(function($ctx1) { _st(self)._selectedItem_(nil);
  465. _st(self)._setItemsForSelectedPackage();
  466. _st(self)._refresh();
  467. return self}, function($ctx1) {$ctx1.fill(self,"onPackageSelected:",{aPackage:aPackage}, smalltalk.HLClassesListWidget)})},
  468. messageSends: ["selectedItem:", "setItemsForSelectedPackage", "refresh"]}),
  469. smalltalk.HLClassesListWidget);
  470. smalltalk.addMethod(
  471. "_onShowInstanceToggled",
  472. smalltalk.method({
  473. selector: "onShowInstanceToggled",
  474. fn: function (){
  475. var self=this;
  476. return smalltalk.withContext(function($ctx1) { _st(self)._refresh();
  477. return self}, function($ctx1) {$ctx1.fill(self,"onShowInstanceToggled",{}, smalltalk.HLClassesListWidget)})},
  478. messageSends: ["refresh"]}),
  479. smalltalk.HLClassesListWidget);
  480. smalltalk.addMethod(
  481. "_renderButtonsOn_",
  482. smalltalk.method({
  483. selector: "renderButtonsOn:",
  484. fn: function (html){
  485. var self=this;
  486. return smalltalk.withContext(function($ctx1) { var $1,$3,$4,$5,$6,$7,$8,$2,$9,$10;
  487. $1=_st(html)._div();
  488. _st($1)._class_("btn-group");
  489. _st($1)._at_put_("data-toggle","buttons-radio");
  490. $2=_st($1)._with_((function(){
  491. return smalltalk.withContext(function($ctx2) { $3=_st(html)._button();
  492. _st($3)._class_(_st((smalltalk.String || String))._streamContents_((function(str){
  493. return smalltalk.withContext(function($ctx3) { _st(str)._nextPutAll_("btn");
  494. $4=_st(self)._showInstance();
  495. if(smalltalk.assert($4)){
  496. return _st(str)._nextPutAll_(" active");
  497. };
  498. }, function($ctx3) {$ctx3.fillBlock({str:str},$ctx1)})})));
  499. _st($3)._with_("Instance");
  500. $5=_st($3)._onClick_((function(){
  501. return smalltalk.withContext(function($ctx3) { return _st(self)._showInstance_(true);
  502. }, function($ctx3) {$ctx3.fillBlock({},$ctx1)})}));
  503. $5;
  504. $6=_st(html)._button();
  505. _st($6)._class_(_st((smalltalk.String || String))._streamContents_((function(str){
  506. return smalltalk.withContext(function($ctx3) { _st(str)._nextPutAll_("btn");
  507. $7=_st(_st(self)._model())._showInstance();
  508. if(! smalltalk.assert($7)){
  509. return _st(str)._nextPutAll_(" active");
  510. };
  511. }, function($ctx3) {$ctx3.fillBlock({str:str},$ctx1)})})));
  512. _st($6)._with_("Class");
  513. $8=_st($6)._onClick_((function(){
  514. return smalltalk.withContext(function($ctx3) { return _st(_st(self)._model())._showInstance_(false);
  515. }, function($ctx3) {$ctx3.fillBlock({},$ctx1)})}));
  516. return $8;
  517. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  518. $9=_st(html)._button();
  519. _st($9)._class_("btn");
  520. _st($9)._at_put_("data-toggle","button");
  521. $10=_st($9)._with_("Comment");
  522. return self}, function($ctx1) {$ctx1.fill(self,"renderButtonsOn:",{html:html}, smalltalk.HLClassesListWidget)})},
  523. messageSends: ["class:", "div", "at:put:", "with:", "streamContents:", "nextPutAll:", "ifTrue:", "showInstance", "button", "onClick:", "showInstance:", "ifFalse:", "model"]}),
  524. smalltalk.HLClassesListWidget);
  525. smalltalk.addMethod(
  526. "_renderItem_level_on_",
  527. smalltalk.method({
  528. selector: "renderItem:level:on:",
  529. fn: function (aClass,anInteger,html){
  530. var self=this;
  531. var li;
  532. return smalltalk.withContext(function($ctx1) { var $1,$3,$4,$2;
  533. li=_st(html)._li();
  534. $1=li;
  535. _st($1)._at_put_("list-data",_st(_st(self)._items())._indexOf_(aClass));
  536. _st($1)._class_(_st(self)._cssClassForItem_(aClass));
  537. $2=_st($1)._with_((function(){
  538. return smalltalk.withContext(function($ctx2) { $3=_st(html)._a();
  539. _st($3)._with_((function(){
  540. return smalltalk.withContext(function($ctx3) { _st(_st(html)._tag_("i"))._class_(_st(self)._iconForItem_(aClass));
  541. return _st(self)._renderItemLabel_level_on_(aClass,anInteger,html);
  542. }, function($ctx3) {$ctx3.fillBlock({},$ctx1)})}));
  543. $4=_st($3)._onClick_((function(){
  544. return smalltalk.withContext(function($ctx3) { return _st(self)._activateListItem_(_st(li)._asJQuery());
  545. }, function($ctx3) {$ctx3.fillBlock({},$ctx1)})}));
  546. return $4;
  547. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  548. _st(_st(self)._getChildrenOf_(aClass))._do_((function(each){
  549. return smalltalk.withContext(function($ctx2) { return _st(self)._renderItem_level_on_(each,_st(anInteger).__plus((1)),html);
  550. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})}));
  551. return self}, function($ctx1) {$ctx1.fill(self,"renderItem:level:on:",{aClass:aClass,anInteger:anInteger,html:html,li:li}, smalltalk.HLClassesListWidget)})},
  552. messageSends: ["li", "at:put:", "indexOf:", "items", "class:", "cssClassForItem:", "with:", "iconForItem:", "tag:", "renderItemLabel:level:on:", "a", "onClick:", "activateListItem:", "asJQuery", "do:", "renderItem:level:on:", "+", "getChildrenOf:"]}),
  553. smalltalk.HLClassesListWidget);
  554. smalltalk.addMethod(
  555. "_renderItem_on_",
  556. smalltalk.method({
  557. selector: "renderItem:on:",
  558. fn: function (aClass,html){
  559. var self=this;
  560. return smalltalk.withContext(function($ctx1) { smalltalk.HLBrowserListWidget.fn.prototype._renderItem_on_.apply(_st(self), [aClass,html]);
  561. _st(_st(self)._getChildrenOf_(aClass))._do_((function(each){
  562. return smalltalk.withContext(function($ctx2) { return _st(self)._renderItem_level_on_(each,(1),html);
  563. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})}));
  564. return self}, function($ctx1) {$ctx1.fill(self,"renderItem:on:",{aClass:aClass,html:html}, smalltalk.HLClassesListWidget)})},
  565. messageSends: ["renderItem:on:", "do:", "renderItem:level:on:", "getChildrenOf:"]}),
  566. smalltalk.HLClassesListWidget);
  567. smalltalk.addMethod(
  568. "_renderItemLabel_level_on_",
  569. smalltalk.method({
  570. selector: "renderItemLabel:level:on:",
  571. fn: function (aClass,anInteger,html){
  572. var self=this;
  573. return smalltalk.withContext(function($ctx1) { _st(_st(_st(html)._span())._asJQuery())._html_(_st((smalltalk.String || String))._streamContents_((function(str){
  574. return smalltalk.withContext(function($ctx2) { _st(anInteger)._timesRepeat_((function(){
  575. return smalltalk.withContext(function($ctx3) { return _st(str)._nextPutAll_("    ");
  576. }, function($ctx3) {$ctx3.fillBlock({},$ctx1)})}));
  577. return _st(str)._nextPutAll_(_st(aClass)._name());
  578. }, function($ctx2) {$ctx2.fillBlock({str:str},$ctx1)})})));
  579. return self}, function($ctx1) {$ctx1.fill(self,"renderItemLabel:level:on:",{aClass:aClass,anInteger:anInteger,html:html}, smalltalk.HLClassesListWidget)})},
  580. messageSends: ["html:", "streamContents:", "timesRepeat:", "nextPutAll:", "name", "asJQuery", "span"]}),
  581. smalltalk.HLClassesListWidget);
  582. smalltalk.addMethod(
  583. "_renderItemLabel_on_",
  584. smalltalk.method({
  585. selector: "renderItemLabel:on:",
  586. fn: function (aClass,html){
  587. var self=this;
  588. return smalltalk.withContext(function($ctx1) { _st(self)._renderItemLabel_level_on_(aClass,(0),html);
  589. return self}, function($ctx1) {$ctx1.fill(self,"renderItemLabel:on:",{aClass:aClass,html:html}, smalltalk.HLClassesListWidget)})},
  590. messageSends: ["renderItemLabel:level:on:"]}),
  591. smalltalk.HLClassesListWidget);
  592. smalltalk.addMethod(
  593. "_renderListOn_",
  594. smalltalk.method({
  595. selector: "renderListOn:",
  596. fn: function (html){
  597. var self=this;
  598. return smalltalk.withContext(function($ctx1) { _st(_st(self)._getRootClassesOf_(_st(self)._items()))._do_((function(each){
  599. return smalltalk.withContext(function($ctx2) { return _st(self)._renderItem_on_(each,html);
  600. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})}));
  601. return self}, function($ctx1) {$ctx1.fill(self,"renderListOn:",{html:html}, smalltalk.HLClassesListWidget)})},
  602. messageSends: ["do:", "renderItem:on:", "getRootClassesOf:", "items"]}),
  603. smalltalk.HLClassesListWidget);
  604. smalltalk.addMethod(
  605. "_selectItem_",
  606. smalltalk.method({
  607. selector: "selectItem:",
  608. fn: function (aClass){
  609. var self=this;
  610. return smalltalk.withContext(function($ctx1) { _st(_st(self)._model())._selectedClass_(aClass);
  611. return self}, function($ctx1) {$ctx1.fill(self,"selectItem:",{aClass:aClass}, smalltalk.HLClassesListWidget)})},
  612. messageSends: ["selectedClass:", "model"]}),
  613. smalltalk.HLClassesListWidget);
  614. smalltalk.addMethod(
  615. "_setItemsForPackage_",
  616. smalltalk.method({
  617. selector: "setItemsForPackage:",
  618. fn: function (aPackage){
  619. var self=this;
  620. return smalltalk.withContext(function($ctx1) { var $1,$3,$2;
  621. $1=self;
  622. $3=aPackage;
  623. if(($receiver = $3) == nil || $receiver == undefined){
  624. $2=[];
  625. } else {
  626. $2=_st(_st(_st(_st(aPackage)._classes())._collect_((function(each){
  627. return smalltalk.withContext(function($ctx2) { return _st(each)._theNonMetaClass();
  628. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})})))._asSet())._asArray();
  629. };
  630. _st($1)._items_($2);
  631. return self}, function($ctx1) {$ctx1.fill(self,"setItemsForPackage:",{aPackage:aPackage}, smalltalk.HLClassesListWidget)})},
  632. messageSends: ["items:", "ifNil:ifNotNil:", "asArray", "asSet", "collect:", "theNonMetaClass", "classes"]}),
  633. smalltalk.HLClassesListWidget);
  634. smalltalk.addMethod(
  635. "_setItemsForSelectedPackage",
  636. smalltalk.method({
  637. selector: "setItemsForSelectedPackage",
  638. fn: function (){
  639. var self=this;
  640. return smalltalk.withContext(function($ctx1) { _st(self)._setItemsForPackage_(_st(_st(self)._model())._selectedPackage());
  641. return self}, function($ctx1) {$ctx1.fill(self,"setItemsForSelectedPackage",{}, smalltalk.HLClassesListWidget)})},
  642. messageSends: ["setItemsForPackage:", "selectedPackage", "model"]}),
  643. smalltalk.HLClassesListWidget);
  644. smalltalk.addMethod(
  645. "_showInstance",
  646. smalltalk.method({
  647. selector: "showInstance",
  648. fn: function (){
  649. var self=this;
  650. return smalltalk.withContext(function($ctx1) { var $1;
  651. $1=_st(_st(self)._model())._showInstance();
  652. return $1;
  653. }, function($ctx1) {$ctx1.fill(self,"showInstance",{}, smalltalk.HLClassesListWidget)})},
  654. messageSends: ["showInstance", "model"]}),
  655. smalltalk.HLClassesListWidget);
  656. smalltalk.addMethod(
  657. "_showInstance_",
  658. smalltalk.method({
  659. selector: "showInstance:",
  660. fn: function (aBoolean){
  661. var self=this;
  662. return smalltalk.withContext(function($ctx1) { _st(_st(self)._model())._showInstance_(aBoolean);
  663. return self}, function($ctx1) {$ctx1.fill(self,"showInstance:",{aBoolean:aBoolean}, smalltalk.HLClassesListWidget)})},
  664. messageSends: ["showInstance:", "model"]}),
  665. smalltalk.HLClassesListWidget);
  666. smalltalk.addClass('HLMethodsListWidget', smalltalk.HLBrowserListWidget, [], 'Helios-Browser');
  667. smalltalk.addMethod(
  668. "_allProtocol",
  669. smalltalk.method({
  670. selector: "allProtocol",
  671. fn: function (){
  672. var self=this;
  673. return smalltalk.withContext(function($ctx1) { var $1;
  674. $1=_st(_st(self)._model())._allProtocol();
  675. return $1;
  676. }, function($ctx1) {$ctx1.fill(self,"allProtocol",{}, smalltalk.HLMethodsListWidget)})},
  677. messageSends: ["allProtocol", "model"]}),
  678. smalltalk.HLMethodsListWidget);
  679. smalltalk.addMethod(
  680. "_flushSelectorsCache",
  681. smalltalk.method({
  682. selector: "flushSelectorsCache",
  683. fn: function (){
  684. var self=this;
  685. return smalltalk.withContext(function($ctx1) { self["@selectorsCache"]=_st((smalltalk.Dictionary || Dictionary))._new();
  686. return self}, function($ctx1) {$ctx1.fill(self,"flushSelectorsCache",{}, smalltalk.HLMethodsListWidget)})},
  687. messageSends: ["new"]}),
  688. smalltalk.HLMethodsListWidget);
  689. smalltalk.addMethod(
  690. "_iconForItem_",
  691. smalltalk.method({
  692. selector: "iconForItem:",
  693. fn: function (aSelector){
  694. var self=this;
  695. var override,overriden,method;
  696. return smalltalk.withContext(function($ctx1) { var $2,$3,$4,$1;
  697. method=_st(self)._methodForSelector_(aSelector);
  698. override=_st(self)._isOverride_(method);
  699. overriden=_st(self)._isOverridden_(method);
  700. $2=override;
  701. if(smalltalk.assert($2)){
  702. $3=overriden;
  703. if(smalltalk.assert($3)){
  704. $1="icon-resize-vertical";
  705. } else {
  706. $1="icon-arrow-up";
  707. };
  708. } else {
  709. $4=overriden;
  710. if(smalltalk.assert($4)){
  711. $1="icon-arrow-down";
  712. } else {
  713. $1="icon-none";
  714. };
  715. };
  716. return $1;
  717. }, function($ctx1) {$ctx1.fill(self,"iconForItem:",{aSelector:aSelector,override:override,overriden:overriden,method:method}, smalltalk.HLMethodsListWidget)})},
  718. messageSends: ["methodForSelector:", "isOverride:", "isOverridden:", "ifTrue:ifFalse:"]}),
  719. smalltalk.HLMethodsListWidget);
  720. smalltalk.addMethod(
  721. "_initialize",
  722. smalltalk.method({
  723. selector: "initialize",
  724. fn: function (){
  725. var self=this;
  726. return smalltalk.withContext(function($ctx1) { smalltalk.HLBrowserListWidget.fn.prototype._initialize.apply(_st(self), []);
  727. _st(self)._flushSelectorsCache();
  728. return self}, function($ctx1) {$ctx1.fill(self,"initialize",{}, smalltalk.HLMethodsListWidget)})},
  729. messageSends: ["initialize", "flushSelectorsCache"]}),
  730. smalltalk.HLMethodsListWidget);
  731. smalltalk.addMethod(
  732. "_isOverridden_",
  733. smalltalk.method({
  734. selector: "isOverridden:",
  735. fn: function (aMethod){
  736. var self=this;
  737. return smalltalk.withContext(function($ctx1) { var $1;
  738. $1=_st(_st(self)._selectorsCache())._isOverridden_(aMethod);
  739. return $1;
  740. }, function($ctx1) {$ctx1.fill(self,"isOverridden:",{aMethod:aMethod}, smalltalk.HLMethodsListWidget)})},
  741. messageSends: ["isOverridden:", "selectorsCache"]}),
  742. smalltalk.HLMethodsListWidget);
  743. smalltalk.addMethod(
  744. "_isOverride_",
  745. smalltalk.method({
  746. selector: "isOverride:",
  747. fn: function (aMethod){
  748. var self=this;
  749. return smalltalk.withContext(function($ctx1) { var $1;
  750. $1=_st(_st(self)._selectorsCache())._isOverride_(aMethod);
  751. return $1;
  752. }, function($ctx1) {$ctx1.fill(self,"isOverride:",{aMethod:aMethod}, smalltalk.HLMethodsListWidget)})},
  753. messageSends: ["isOverride:", "selectorsCache"]}),
  754. smalltalk.HLMethodsListWidget);
  755. smalltalk.addMethod(
  756. "_methodForSelector_",
  757. smalltalk.method({
  758. selector: "methodForSelector:",
  759. fn: function (aSelector){
  760. var self=this;
  761. return smalltalk.withContext(function($ctx1) { var $1;
  762. $1=_st(_st(_st(_st(self)._model())._selectedClass())._methodDictionary())._at_(aSelector);
  763. return $1;
  764. }, function($ctx1) {$ctx1.fill(self,"methodForSelector:",{aSelector:aSelector}, smalltalk.HLMethodsListWidget)})},
  765. messageSends: ["at:", "methodDictionary", "selectedClass", "model"]}),
  766. smalltalk.HLMethodsListWidget);
  767. smalltalk.addMethod(
  768. "_methodsInProtocol_",
  769. smalltalk.method({
  770. selector: "methodsInProtocol:",
  771. fn: function (aString){
  772. var self=this;
  773. return smalltalk.withContext(function($ctx1) { var $2,$1;
  774. $2=_st(aString).__eq(_st(self)._allProtocol());
  775. if(smalltalk.assert($2)){
  776. $1=_st(_st(_st(self)._model())._selectedClass())._methods();
  777. } else {
  778. $1=_st(_st(_st(self)._model())._selectedClass())._methodsInProtocol_(aString);
  779. };
  780. return $1;
  781. }, function($ctx1) {$ctx1.fill(self,"methodsInProtocol:",{aString:aString}, smalltalk.HLMethodsListWidget)})},
  782. messageSends: ["ifTrue:ifFalse:", "methods", "selectedClass", "model", "methodsInProtocol:", "=", "allProtocol"]}),
  783. smalltalk.HLMethodsListWidget);
  784. smalltalk.addMethod(
  785. "_observeModel",
  786. smalltalk.method({
  787. selector: "observeModel",
  788. fn: function (){
  789. var self=this;
  790. return smalltalk.withContext(function($ctx1) { _st(_st(_st(self)._model())._announcer())._on_do_((smalltalk.HLProtocolSelected || HLProtocolSelected),(function(ann){
  791. return smalltalk.withContext(function($ctx2) { return _st(self)._onProtocolSelected_(_st(ann)._item());
  792. }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1)})}));
  793. _st(_st(_st(self)._model())._announcer())._on_do_((smalltalk.HLShowInstanceToggled || HLShowInstanceToggled),(function(ann){
  794. return smalltalk.withContext(function($ctx2) { return _st(self)._onProtocolSelected_(nil);
  795. }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1)})}));
  796. _st(_st(_st(self)._model())._announcer())._on_do_((smalltalk.HLMethodSelected || HLMethodSelected),(function(ann){
  797. return smalltalk.withContext(function($ctx2) { return _st(self)._onMethodSelected_(_st(ann)._item());
  798. }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1)})}));
  799. return self}, function($ctx1) {$ctx1.fill(self,"observeModel",{}, smalltalk.HLMethodsListWidget)})},
  800. messageSends: ["on:do:", "onProtocolSelected:", "item", "announcer", "model", "onMethodSelected:"]}),
  801. smalltalk.HLMethodsListWidget);
  802. smalltalk.addMethod(
  803. "_observeSystem",
  804. smalltalk.method({
  805. selector: "observeSystem",
  806. fn: function (){
  807. var self=this;
  808. return smalltalk.withContext(function($ctx1) { var $1,$2;
  809. $1=_st((smalltalk.SystemAnnouncer || SystemAnnouncer))._current();
  810. _st($1)._on_do_((smalltalk.MethodAdded || MethodAdded),(function(ann){
  811. return smalltalk.withContext(function($ctx2) { return _st(self)._onMethodAdded_(_st(ann)._method());
  812. }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1)})}));
  813. $2=_st($1)._on_do_((smalltalk.MethodRemoved || MethodRemoved),(function(ann){
  814. return smalltalk.withContext(function($ctx2) { return _st(self)._onMethodRemoved_(_st(ann)._method());
  815. }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1)})}));
  816. return self}, function($ctx1) {$ctx1.fill(self,"observeSystem",{}, smalltalk.HLMethodsListWidget)})},
  817. messageSends: ["on:do:", "onMethodAdded:", "method", "current", "onMethodRemoved:"]}),
  818. smalltalk.HLMethodsListWidget);
  819. smalltalk.addMethod(
  820. "_onMethodAdded_",
  821. smalltalk.method({
  822. selector: "onMethodAdded:",
  823. fn: function (aMethod){
  824. var self=this;
  825. return smalltalk.withContext(function($ctx1) { var $1;
  826. var $early={};
  827. try {
  828. _st(_st(self)._items())._detect_ifNone_((function(each){
  829. return smalltalk.withContext(function($ctx2) { return _st(each).__eq(_st(aMethod)._selector());
  830. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})}),(function(){
  831. return smalltalk.withContext(function($ctx2) { $1=self;
  832. throw $early=[$1];
  833. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  834. _st(self)._refresh();
  835. return self}
  836. catch(e) {if(e===$early)return e[0]; throw e}
  837. }, function($ctx1) {$ctx1.fill(self,"onMethodAdded:",{aMethod:aMethod}, smalltalk.HLMethodsListWidget)})},
  838. messageSends: ["detect:ifNone:", "=", "selector", "items", "refresh"]}),
  839. smalltalk.HLMethodsListWidget);
  840. smalltalk.addMethod(
  841. "_onMethodRemoved_",
  842. smalltalk.method({
  843. selector: "onMethodRemoved:",
  844. fn: function (aMethod){
  845. var self=this;
  846. return smalltalk.withContext(function($ctx1) { var $1,$2;
  847. var $early={};
  848. try {
  849. _st(_st(self)._items())._detect_ifNone_((function(each){
  850. return smalltalk.withContext(function($ctx2) { return _st(each).__eq(_st(aMethod)._selector());
  851. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})}),(function(){
  852. return smalltalk.withContext(function($ctx2) { $1=self;
  853. throw $early=[$1];
  854. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  855. $2=_st(_st(_st(aMethod)._methodClass()).__eq(_st(_st(self)._model())._selectedClass()))._and_((function(){
  856. return smalltalk.withContext(function($ctx2) { return _st(_st(aMethod)._selector()).__eq(_st(self)._selectedItem());
  857. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  858. if(smalltalk.assert($2)){
  859. _st(self)._selectItem_(nil);
  860. };
  861. _st(self)._refresh();
  862. return self}
  863. catch(e) {if(e===$early)return e[0]; throw e}
  864. }, function($ctx1) {$ctx1.fill(self,"onMethodRemoved:",{aMethod:aMethod}, smalltalk.HLMethodsListWidget)})},
  865. messageSends: ["detect:ifNone:", "=", "selector", "items", "ifTrue:", "selectItem:", "and:", "selectedItem", "selectedClass", "model", "methodClass", "refresh"]}),
  866. smalltalk.HLMethodsListWidget);
  867. smalltalk.addMethod(
  868. "_onMethodSelected_",
  869. smalltalk.method({
  870. selector: "onMethodSelected:",
  871. fn: function (aMethod){
  872. var self=this;
  873. return smalltalk.withContext(function($ctx1) { var $1,$2;
  874. _st(self)._selectedItem_(aMethod);
  875. $1=aMethod;
  876. if(($receiver = $1) == nil || $receiver == undefined){
  877. $2=self;
  878. return $2;
  879. } else {
  880. $1;
  881. };
  882. _st(self)._focus();
  883. return self}, function($ctx1) {$ctx1.fill(self,"onMethodSelected:",{aMethod:aMethod}, smalltalk.HLMethodsListWidget)})},
  884. messageSends: ["selectedItem:", "ifNil:", "focus"]}),
  885. smalltalk.HLMethodsListWidget);
  886. smalltalk.addMethod(
  887. "_onProtocolSelected_",
  888. smalltalk.method({
  889. selector: "onProtocolSelected:",
  890. fn: function (aString){
  891. var self=this;
  892. return smalltalk.withContext(function($ctx1) { var $1,$3,$4,$2;
  893. _st(self)._selectedItem_(nil);
  894. $1=self;
  895. $3=_st(_st(self)._model())._selectedClass();
  896. if(($receiver = $3) == nil || $receiver == undefined){
  897. $2=[];
  898. } else {
  899. $4=aString;
  900. if(($receiver = $4) == nil || $receiver == undefined){
  901. $2=[];
  902. } else {
  903. $2=_st(self)._selectorsInProtocol_(aString);
  904. };
  905. };
  906. _st($1)._items_($2);
  907. _st(self)._refresh();
  908. return self}, function($ctx1) {$ctx1.fill(self,"onProtocolSelected:",{aString:aString}, smalltalk.HLMethodsListWidget)})},
  909. messageSends: ["selectedItem:", "items:", "ifNil:ifNotNil:", "selectorsInProtocol:", "selectedClass", "model", "refresh"]}),
  910. smalltalk.HLMethodsListWidget);
  911. smalltalk.addMethod(
  912. "_overrideSelectors",
  913. smalltalk.method({
  914. selector: "overrideSelectors",
  915. fn: function (){
  916. var self=this;
  917. return smalltalk.withContext(function($ctx1) { var $2,$3,$1;
  918. $1=_st(_st(self)._selectorsCache())._at_ifAbsentPut_("override",(function(){
  919. return smalltalk.withContext(function($ctx2) { return _st(_st(_st(_st(self)._model())._selectedClass())._allSuperclasses())._inject_into_(_st((smalltalk.Set || Set))._new(),(function(acc,each){
  920. return smalltalk.withContext(function($ctx3) { $2=acc;
  921. _st($2)._addAll_(_st(each)._selectors());
  922. $3=_st($2)._yourself();
  923. return $3;
  924. }, function($ctx3) {$ctx3.fillBlock({acc:acc,each:each},$ctx1)})}));
  925. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  926. return $1;
  927. }, function($ctx1) {$ctx1.fill(self,"overrideSelectors",{}, smalltalk.HLMethodsListWidget)})},
  928. messageSends: ["at:ifAbsentPut:", "inject:into:", "new", "addAll:", "selectors", "yourself", "allSuperclasses", "selectedClass", "model", "selectorsCache"]}),
  929. smalltalk.HLMethodsListWidget);
  930. smalltalk.addMethod(
  931. "_overridenSelectors",
  932. smalltalk.method({
  933. selector: "overridenSelectors",
  934. fn: function (){
  935. var self=this;
  936. return smalltalk.withContext(function($ctx1) { var $2,$3,$1;
  937. $1=_st(_st(self)._selectorsCache())._at_ifAbsentPut_("overriden",(function(){
  938. return smalltalk.withContext(function($ctx2) { return _st(_st(_st(_st(self)._model())._selectedClass())._allSubclasses())._inject_into_(_st((smalltalk.Set || Set))._new(),(function(acc,each){
  939. return smalltalk.withContext(function($ctx3) { $2=acc;
  940. _st($2)._addAll_(_st(each)._selectors());
  941. $3=_st($2)._yourself();
  942. return $3;
  943. }, function($ctx3) {$ctx3.fillBlock({acc:acc,each:each},$ctx1)})}));
  944. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  945. return $1;
  946. }, function($ctx1) {$ctx1.fill(self,"overridenSelectors",{}, smalltalk.HLMethodsListWidget)})},
  947. messageSends: ["at:ifAbsentPut:", "inject:into:", "new", "addAll:", "selectors", "yourself", "allSubclasses", "selectedClass", "model", "selectorsCache"]}),
  948. smalltalk.HLMethodsListWidget);
  949. smalltalk.addMethod(
  950. "_renderContentOn_",
  951. smalltalk.method({
  952. selector: "renderContentOn:",
  953. fn: function (html){
  954. var self=this;
  955. return smalltalk.withContext(function($ctx1) { var $1,$2,$3;
  956. $1=_st(_st(self)._model())._showInstance();
  957. if(smalltalk.assert($1)){
  958. smalltalk.HLBrowserListWidget.fn.prototype._renderContentOn_.apply(_st(self), [html]);
  959. } else {
  960. $2=_st(html)._div();
  961. _st($2)._class_("class_side");
  962. $3=_st($2)._with_((function(){
  963. return smalltalk.withContext(function($ctx2) { return smalltalk.HLBrowserListWidget.fn.prototype._renderContentOn_.apply(_st(self), [html]);
  964. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  965. $3;
  966. };
  967. return self}, function($ctx1) {$ctx1.fill(self,"renderContentOn:",{html:html}, smalltalk.HLMethodsListWidget)})},
  968. messageSends: ["ifFalse:ifTrue:", "class:", "div", "with:", "renderContentOn:", "showInstance", "model"]}),
  969. smalltalk.HLMethodsListWidget);
  970. smalltalk.addMethod(
  971. "_renderItemLabel_on_",
  972. smalltalk.method({
  973. selector: "renderItemLabel:on:",
  974. fn: function (aSelector,html){
  975. var self=this;
  976. return smalltalk.withContext(function($ctx1) { _st(html)._with_(aSelector);
  977. return self}, function($ctx1) {$ctx1.fill(self,"renderItemLabel:on:",{aSelector:aSelector,html:html}, smalltalk.HLMethodsListWidget)})},
  978. messageSends: ["with:"]}),
  979. smalltalk.HLMethodsListWidget);
  980. smalltalk.addMethod(
  981. "_selectItem_",
  982. smalltalk.method({
  983. selector: "selectItem:",
  984. fn: function (aSelector){
  985. var self=this;
  986. return smalltalk.withContext(function($ctx1) { _st(_st(self)._model())._selectedMethod_(_st(self)._methodForSelector_(aSelector));
  987. return self}, function($ctx1) {$ctx1.fill(self,"selectItem:",{aSelector:aSelector}, smalltalk.HLMethodsListWidget)})},
  988. messageSends: ["selectedMethod:", "methodForSelector:", "model"]}),
  989. smalltalk.HLMethodsListWidget);
  990. smalltalk.addMethod(
  991. "_selectorsCache",
  992. smalltalk.method({
  993. selector: "selectorsCache",
  994. fn: function (){
  995. var self=this;
  996. return smalltalk.withContext(function($ctx1) { var $1;
  997. $1=_st(_st(self)._class())._selectorsCache();
  998. return $1;
  999. }, function($ctx1) {$ctx1.fill(self,"selectorsCache",{}, smalltalk.HLMethodsListWidget)})},
  1000. messageSends: ["selectorsCache", "class"]}),
  1001. smalltalk.HLMethodsListWidget);
  1002. smalltalk.addMethod(
  1003. "_selectorsInProtocol_",
  1004. smalltalk.method({
  1005. selector: "selectorsInProtocol:",
  1006. fn: function (aString){
  1007. var self=this;
  1008. return smalltalk.withContext(function($ctx1) { var $1;
  1009. $1=_st(_st(self)._methodsInProtocol_(aString))._collect_((function(each){
  1010. return smalltalk.withContext(function($ctx2) { return _st(each)._selector();
  1011. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})}));
  1012. return $1;
  1013. }, function($ctx1) {$ctx1.fill(self,"selectorsInProtocol:",{aString:aString}, smalltalk.HLMethodsListWidget)})},
  1014. messageSends: ["collect:", "selector", "methodsInProtocol:"]}),
  1015. smalltalk.HLMethodsListWidget);
  1016. smalltalk.HLMethodsListWidget.klass.iVarNames = ['selectorsCache'];
  1017. smalltalk.addMethod(
  1018. "_selectorsCache",
  1019. smalltalk.method({
  1020. selector: "selectorsCache",
  1021. fn: function (){
  1022. var self=this;
  1023. return smalltalk.withContext(function($ctx1) { var $1;
  1024. $1=_st((smalltalk.HLSelectorsCache || HLSelectorsCache))._current();
  1025. return $1;
  1026. }, function($ctx1) {$ctx1.fill(self,"selectorsCache",{}, smalltalk.HLMethodsListWidget.klass)})},
  1027. messageSends: ["current"]}),
  1028. smalltalk.HLMethodsListWidget.klass);
  1029. smalltalk.addClass('HLPackagesListWidget', smalltalk.HLBrowserListWidget, [], 'Helios-Browser');
  1030. smalltalk.addMethod(
  1031. "_focusClassesListWidget",
  1032. smalltalk.method({
  1033. selector: "focusClassesListWidget",
  1034. fn: function (){
  1035. var self=this;
  1036. return smalltalk.withContext(function($ctx1) { _st(_st(_st(self)._model())._announcer())._announce_(_st((smalltalk.HLClassesListFocus || HLClassesListFocus))._new());
  1037. return self}, function($ctx1) {$ctx1.fill(self,"focusClassesListWidget",{}, smalltalk.HLPackagesListWidget)})},
  1038. messageSends: ["announce:", "new", "announcer", "model"]}),
  1039. smalltalk.HLPackagesListWidget);
  1040. smalltalk.addMethod(
  1041. "_initializeItems",
  1042. smalltalk.method({
  1043. selector: "initializeItems",
  1044. fn: function (){
  1045. var self=this;
  1046. return smalltalk.withContext(function($ctx1) { var $1;
  1047. self["@items"]=_st(_st(_st(self)._model())._packages())._sort_((function(a,b){
  1048. return smalltalk.withContext(function($ctx2) { return _st(_st(a)._name()).__lt(_st(b)._name());
  1049. }, function($ctx2) {$ctx2.fillBlock({a:a,b:b},$ctx1)})}));
  1050. $1=self["@items"];
  1051. return $1;
  1052. }, function($ctx1) {$ctx1.fill(self,"initializeItems",{}, smalltalk.HLPackagesListWidget)})},
  1053. messageSends: ["sort:", "<", "name", "packages", "model"]}),
  1054. smalltalk.HLPackagesListWidget);
  1055. smalltalk.addMethod(
  1056. "_items",
  1057. smalltalk.method({
  1058. selector: "items",
  1059. fn: function (){
  1060. var self=this;
  1061. return smalltalk.withContext(function($ctx1) { var $2,$1;
  1062. $2=self["@items"];
  1063. if(($receiver = $2) == nil || $receiver == undefined){
  1064. $1=_st(self)._initializeItems();
  1065. } else {
  1066. $1=$2;
  1067. };
  1068. return $1;
  1069. }, function($ctx1) {$ctx1.fill(self,"items",{}, smalltalk.HLPackagesListWidget)})},
  1070. messageSends: ["ifNil:", "initializeItems"]}),
  1071. smalltalk.HLPackagesListWidget);
  1072. smalltalk.addMethod(
  1073. "_observeModel",
  1074. smalltalk.method({
  1075. selector: "observeModel",
  1076. fn: function (){
  1077. var self=this;
  1078. return smalltalk.withContext(function($ctx1) { _st(_st(_st(self)._model())._announcer())._on_do_((smalltalk.HLPackageSelected || HLPackageSelected),(function(ann){
  1079. return smalltalk.withContext(function($ctx2) { return _st(self)._onPackageSelected_(_st(ann)._item());
  1080. }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1)})}));
  1081. return self}, function($ctx1) {$ctx1.fill(self,"observeModel",{}, smalltalk.HLPackagesListWidget)})},
  1082. messageSends: ["on:do:", "onPackageSelected:", "item", "announcer", "model"]}),
  1083. smalltalk.HLPackagesListWidget);
  1084. smalltalk.addMethod(
  1085. "_onPackageSelected_",
  1086. smalltalk.method({
  1087. selector: "onPackageSelected:",
  1088. fn: function (aPackage){
  1089. var self=this;
  1090. return smalltalk.withContext(function($ctx1) { _st(self)._selectedItem_(aPackage);
  1091. _st(self)._focus();
  1092. return self}, function($ctx1) {$ctx1.fill(self,"onPackageSelected:",{aPackage:aPackage}, smalltalk.HLPackagesListWidget)})},
  1093. messageSends: ["selectedItem:", "focus"]}),
  1094. smalltalk.HLPackagesListWidget);
  1095. smalltalk.addMethod(
  1096. "_renderButtonsOn_",
  1097. smalltalk.method({
  1098. selector: "renderButtonsOn:",
  1099. fn: function (html){
  1100. var self=this;
  1101. return smalltalk.withContext(function($ctx1) { var $1,$2,$3,$5,$6,$7,$8,$4,$9,$10;
  1102. $1=_st(html)._span();
  1103. _st($1)._class_("info");
  1104. $2=_st($1)._with_("Auto commit");
  1105. $3=_st(html)._div();
  1106. _st($3)._class_("btn-group switch");
  1107. _st($3)._at_put_("data-toggle","buttons-radio");
  1108. $4=_st($3)._with_((function(){
  1109. return smalltalk.withContext(function($ctx2) { $5=_st(html)._button();
  1110. _st($5)._class_(_st((smalltalk.String || String))._streamContents_((function(str){
  1111. return smalltalk.withContext(function($ctx3) { return _st(str)._nextPutAll_("btn");
  1112. }, function($ctx3) {$ctx3.fillBlock({str:str},$ctx1)})})));
  1113. $6=_st($5)._with_("On");
  1114. $6;
  1115. $7=_st(html)._button();
  1116. _st($7)._class_(_st((smalltalk.String || String))._streamContents_((function(str){
  1117. return smalltalk.withContext(function($ctx3) { return _st(str)._nextPutAll_("btn active");
  1118. }, function($ctx3) {$ctx3.fillBlock({str:str},$ctx1)})})));
  1119. $8=_st($7)._with_("Off");
  1120. return $8;
  1121. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  1122. $9=_st(html)._a();
  1123. _st($9)._class_("btn");
  1124. $10=_st($9)._with_("Commit");
  1125. return self}, function($ctx1) {$ctx1.fill(self,"renderButtonsOn:",{html:html}, smalltalk.HLPackagesListWidget)})},
  1126. messageSends: ["class:", "span", "with:", "div", "at:put:", "streamContents:", "nextPutAll:", "button", "a"]}),
  1127. smalltalk.HLPackagesListWidget);
  1128. smalltalk.addMethod(
  1129. "_selectItem_",
  1130. smalltalk.method({
  1131. selector: "selectItem:",
  1132. fn: function (aPackage){
  1133. var self=this;
  1134. return smalltalk.withContext(function($ctx1) { _st(_st(self)._model())._selectedPackage_(aPackage);
  1135. return self}, function($ctx1) {$ctx1.fill(self,"selectItem:",{aPackage:aPackage}, smalltalk.HLPackagesListWidget)})},
  1136. messageSends: ["selectedPackage:", "model"]}),
  1137. smalltalk.HLPackagesListWidget);
  1138. smalltalk.addClass('HLProtocolsListWidget', smalltalk.HLBrowserListWidget, [], 'Helios-Browser');
  1139. smalltalk.addMethod(
  1140. "_allProtocol",
  1141. smalltalk.method({
  1142. selector: "allProtocol",
  1143. fn: function (){
  1144. var self=this;
  1145. return smalltalk.withContext(function($ctx1) { var $1;
  1146. $1=_st(_st(self)._model())._allProtocol();
  1147. return $1;
  1148. }, function($ctx1) {$ctx1.fill(self,"allProtocol",{}, smalltalk.HLProtocolsListWidget)})},
  1149. messageSends: ["allProtocol", "model"]}),
  1150. smalltalk.HLProtocolsListWidget);
  1151. smalltalk.addMethod(
  1152. "_observeModel",
  1153. smalltalk.method({
  1154. selector: "observeModel",
  1155. fn: function (){
  1156. var self=this;
  1157. return smalltalk.withContext(function($ctx1) { _st(_st(_st(self)._model())._announcer())._on_do_((smalltalk.HLClassSelected || HLClassSelected),(function(ann){
  1158. return smalltalk.withContext(function($ctx2) { return _st(self)._onClassSelected_(_st(ann)._item());
  1159. }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1)})}));
  1160. _st(_st(_st(self)._model())._announcer())._on_do_((smalltalk.HLShowInstanceToggled || HLShowInstanceToggled),(function(ann){
  1161. return smalltalk.withContext(function($ctx2) { return _st(self)._onClassSelected_(_st(_st(self)._model())._selectedClass());
  1162. }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1)})}));
  1163. _st(_st(_st(self)._model())._announcer())._on_do_((smalltalk.HLProtocolSelected || HLProtocolSelected),(function(ann){
  1164. return smalltalk.withContext(function($ctx2) { return _st(self)._onProtocolSelected_(_st(ann)._item());
  1165. }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1)})}));
  1166. return self}, function($ctx1) {$ctx1.fill(self,"observeModel",{}, smalltalk.HLProtocolsListWidget)})},
  1167. messageSends: ["on:do:", "onClassSelected:", "item", "announcer", "model", "selectedClass", "onProtocolSelected:"]}),
  1168. smalltalk.HLProtocolsListWidget);
  1169. smalltalk.addMethod(
  1170. "_onClassSelected_",
  1171. smalltalk.method({
  1172. selector: "onClassSelected:",
  1173. fn: function (aClass){
  1174. var self=this;
  1175. return smalltalk.withContext(function($ctx1) { var $1,$3,$4,$5,$2;
  1176. _st(self)._selectedItem_(nil);
  1177. $1=self;
  1178. $3=aClass;
  1179. if(($receiver = $3) == nil || $receiver == undefined){
  1180. $2=_st((smalltalk.Array || Array))._with_(_st(self)._allProtocol());
  1181. } else {
  1182. $4=_st((smalltalk.Array || Array))._with_(_st(self)._allProtocol());
  1183. _st($4)._addAll_(_st(aClass)._protocols());
  1184. $5=_st($4)._yourself();
  1185. $2=$5;
  1186. };
  1187. _st($1)._items_($2);
  1188. _st(self)._refresh();
  1189. return self}, function($ctx1) {$ctx1.fill(self,"onClassSelected:",{aClass:aClass}, smalltalk.HLProtocolsListWidget)})},
  1190. messageSends: ["selectedItem:", "items:", "ifNil:ifNotNil:", "with:", "allProtocol", "addAll:", "protocols", "yourself", "refresh"]}),
  1191. smalltalk.HLProtocolsListWidget);
  1192. smalltalk.addMethod(
  1193. "_onProtocolSelected_",
  1194. smalltalk.method({
  1195. selector: "onProtocolSelected:",
  1196. fn: function (aString){
  1197. var self=this;
  1198. return smalltalk.withContext(function($ctx1) { var $1,$2;
  1199. _st(self)._selectedItem_(aString);
  1200. $1=aString;
  1201. if(($receiver = $1) == nil || $receiver == undefined){
  1202. $2=self;
  1203. return $2;
  1204. } else {
  1205. $1;
  1206. };
  1207. _st(self)._focus();
  1208. return self}, function($ctx1) {$ctx1.fill(self,"onProtocolSelected:",{aString:aString}, smalltalk.HLProtocolsListWidget)})},
  1209. messageSends: ["selectedItem:", "ifNil:", "focus"]}),
  1210. smalltalk.HLProtocolsListWidget);
  1211. smalltalk.addMethod(
  1212. "_renderContentOn_",
  1213. smalltalk.method({
  1214. selector: "renderContentOn:",
  1215. fn: function (html){
  1216. var self=this;
  1217. return smalltalk.withContext(function($ctx1) { var $1,$2,$3;
  1218. $1=_st(_st(self)._model())._showInstance();
  1219. if(smalltalk.assert($1)){
  1220. smalltalk.HLBrowserListWidget.fn.prototype._renderContentOn_.apply(_st(self), [html]);
  1221. } else {
  1222. $2=_st(html)._div();
  1223. _st($2)._class_("class_side");
  1224. $3=_st($2)._with_((function(){
  1225. return smalltalk.withContext(function($ctx2) { return smalltalk.HLBrowserListWidget.fn.prototype._renderContentOn_.apply(_st(self), [html]);
  1226. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  1227. $3;
  1228. };
  1229. return self}, function($ctx1) {$ctx1.fill(self,"renderContentOn:",{html:html}, smalltalk.HLProtocolsListWidget)})},
  1230. messageSends: ["ifFalse:ifTrue:", "class:", "div", "with:", "renderContentOn:", "showInstance", "model"]}),
  1231. smalltalk.HLProtocolsListWidget);
  1232. smalltalk.addMethod(
  1233. "_selectItem_",
  1234. smalltalk.method({
  1235. selector: "selectItem:",
  1236. fn: function (aString){
  1237. var self=this;
  1238. return smalltalk.withContext(function($ctx1) { _st(_st(self)._model())._selectedProtocol_(aString);
  1239. return self}, function($ctx1) {$ctx1.fill(self,"selectItem:",{aString:aString}, smalltalk.HLProtocolsListWidget)})},
  1240. messageSends: ["selectedProtocol:", "model"]}),
  1241. smalltalk.HLProtocolsListWidget);
  1242. smalltalk.addMethod(
  1243. "_selectedItem",
  1244. smalltalk.method({
  1245. selector: "selectedItem",
  1246. fn: function (){
  1247. var self=this;
  1248. return smalltalk.withContext(function($ctx1) { var $1;
  1249. $1=smalltalk.HLBrowserListWidget.fn.prototype._selectedItem.apply(_st(self), []);
  1250. return $1;
  1251. }, function($ctx1) {$ctx1.fill(self,"selectedItem",{}, smalltalk.HLProtocolsListWidget)})},
  1252. messageSends: ["selectedItem"]}),
  1253. smalltalk.HLProtocolsListWidget);
  1254. smalltalk.addClass('HLBrowserModel', smalltalk.Object, ['announcer', 'environment', 'selectedPackage', 'selectedClass', 'selectedProtocol', 'selectedSelector', 'showInstance', 'showComment'], 'Helios-Browser');
  1255. smalltalk.addMethod(
  1256. "_allProtocol",
  1257. smalltalk.method({
  1258. selector: "allProtocol",
  1259. fn: function (){
  1260. var self=this;
  1261. return smalltalk.withContext(function($ctx1) { return "-- All --";
  1262. }, function($ctx1) {$ctx1.fill(self,"allProtocol",{}, smalltalk.HLBrowserModel)})},
  1263. messageSends: []}),
  1264. smalltalk.HLBrowserModel);
  1265. smalltalk.addMethod(
  1266. "_announcer",
  1267. smalltalk.method({
  1268. selector: "announcer",
  1269. fn: function (){
  1270. var self=this;
  1271. return smalltalk.withContext(function($ctx1) { var $2,$1;
  1272. $2=self["@announcer"];
  1273. if(($receiver = $2) == nil || $receiver == undefined){
  1274. self["@announcer"]=_st((smalltalk.Announcer || Announcer))._new();
  1275. $1=self["@announcer"];
  1276. } else {
  1277. $1=$2;
  1278. };
  1279. return $1;
  1280. }, function($ctx1) {$ctx1.fill(self,"announcer",{}, smalltalk.HLBrowserModel)})},
  1281. messageSends: ["ifNil:", "new"]}),
  1282. smalltalk.HLBrowserModel);
  1283. smalltalk.addMethod(
  1284. "_environment",
  1285. smalltalk.method({
  1286. selector: "environment",
  1287. fn: function (){
  1288. var self=this;
  1289. return smalltalk.withContext(function($ctx1) { var $2,$1;
  1290. $2=self["@environment"];
  1291. if(($receiver = $2) == nil || $receiver == undefined){
  1292. $1=_st(_st((smalltalk.HLManager || HLManager))._current())._environment();
  1293. } else {
  1294. $1=$2;
  1295. };
  1296. return $1;
  1297. }, function($ctx1) {$ctx1.fill(self,"environment",{}, smalltalk.HLBrowserModel)})},
  1298. messageSends: ["ifNil:", "environment", "current"]}),
  1299. smalltalk.HLBrowserModel);
  1300. smalltalk.addMethod(
  1301. "_environment_",
  1302. smalltalk.method({
  1303. selector: "environment:",
  1304. fn: function (anEnvironment){
  1305. var self=this;
  1306. return smalltalk.withContext(function($ctx1) { self["@environment"]=anEnvironment;
  1307. return self}, function($ctx1) {$ctx1.fill(self,"environment:",{anEnvironment:anEnvironment}, smalltalk.HLBrowserModel)})},
  1308. messageSends: []}),
  1309. smalltalk.HLBrowserModel);
  1310. smalltalk.addMethod(
  1311. "_packages",
  1312. smalltalk.method({
  1313. selector: "packages",
  1314. fn: function (){
  1315. var self=this;
  1316. return smalltalk.withContext(function($ctx1) { var $1;
  1317. $1=_st(_st(self)._environment())._packages();
  1318. return $1;
  1319. }, function($ctx1) {$ctx1.fill(self,"packages",{}, smalltalk.HLBrowserModel)})},
  1320. messageSends: ["packages", "environment"]}),
  1321. smalltalk.HLBrowserModel);
  1322. smalltalk.addMethod(
  1323. "_selectedClass",
  1324. smalltalk.method({
  1325. selector: "selectedClass",
  1326. fn: function (){
  1327. var self=this;
  1328. return smalltalk.withContext(function($ctx1) { var $1;
  1329. $1=self["@selectedClass"];
  1330. return $1;
  1331. }, function($ctx1) {$ctx1.fill(self,"selectedClass",{}, smalltalk.HLBrowserModel)})},
  1332. messageSends: []}),
  1333. smalltalk.HLBrowserModel);
  1334. smalltalk.addMethod(
  1335. "_selectedClass_",
  1336. smalltalk.method({
  1337. selector: "selectedClass:",
  1338. fn: function (aClass){
  1339. var self=this;
  1340. return smalltalk.withContext(function($ctx1) { var $1,$2,$3,$4;
  1341. $1=_st(self["@selectedClass"]).__eq(aClass);
  1342. if(smalltalk.assert($1)){
  1343. $2=self;
  1344. return $2;
  1345. };
  1346. $3=aClass;
  1347. if(($receiver = $3) == nil || $receiver == undefined){
  1348. self["@selectedClass"]=nil;
  1349. self["@selectedClass"];
  1350. } else {
  1351. $4=_st(self)._showInstance();
  1352. if(smalltalk.assert($4)){
  1353. self["@selectedClass"]=_st(aClass)._theNonMetaClass();
  1354. self["@selectedClass"];
  1355. } else {
  1356. self["@selectedClass"]=_st(aClass)._theMetaClass();
  1357. self["@selectedClass"];
  1358. };
  1359. };
  1360. _st(self)._selectedProtocol_(nil);
  1361. _st(_st(self)._announcer())._announce_(_st((smalltalk.HLClassSelected || HLClassSelected))._on_(_st(self)._selectedClass()));
  1362. return self}, function($ctx1) {$ctx1.fill(self,"selectedClass:",{aClass:aClass}, smalltalk.HLBrowserModel)})},
  1363. messageSends: ["ifTrue:", "=", "ifNil:ifNotNil:", "ifTrue:ifFalse:", "theNonMetaClass", "theMetaClass", "showInstance", "selectedProtocol:", "announce:", "on:", "selectedClass", "announcer"]}),
  1364. smalltalk.HLBrowserModel);
  1365. smalltalk.addMethod(
  1366. "_selectedMethod",
  1367. smalltalk.method({
  1368. selector: "selectedMethod",
  1369. fn: function (){
  1370. var self=this;
  1371. return smalltalk.withContext(function($ctx1) { var $2,$1;
  1372. $2=_st(self)._selectedClass();
  1373. if(($receiver = $2) == nil || $receiver == undefined){
  1374. $1=$2;
  1375. } else {
  1376. $1=_st(_st(_st(self)._selectedClass())._methodDictionary())._at_(self["@selectedSelector"]);
  1377. };
  1378. return $1;
  1379. }, function($ctx1) {$ctx1.fill(self,"selectedMethod",{}, smalltalk.HLBrowserModel)})},
  1380. messageSends: ["ifNotNil:", "at:", "methodDictionary", "selectedClass"]}),
  1381. smalltalk.HLBrowserModel);
  1382. smalltalk.addMethod(
  1383. "_selectedMethod_",
  1384. smalltalk.method({
  1385. selector: "selectedMethod:",
  1386. fn: function (aCompiledMethod){
  1387. var self=this;
  1388. return smalltalk.withContext(function($ctx1) { var $1,$2,$3,$4,$5;
  1389. $1=_st(self["@selectedSelector"]).__eq(aCompiledMethod);
  1390. if(smalltalk.assert($1)){
  1391. $2=self;
  1392. return $2;
  1393. };
  1394. $3=aCompiledMethod;
  1395. if(($receiver = $3) == nil || $receiver == undefined){
  1396. self["@selectedSelector"]=nil;
  1397. self["@selectedSelector"];
  1398. } else {
  1399. $4=_st(self["@selectedSelector"]).__eq(_st(aCompiledMethod)._selector());
  1400. if(smalltalk.assert($4)){
  1401. $5=self;
  1402. return $5;
  1403. };
  1404. self["@selectedSelector"]=_st(aCompiledMethod)._selector();
  1405. self["@selectedSelector"];
  1406. };
  1407. _st(_st(self)._announcer())._announce_(_st((smalltalk.HLMethodSelected || HLMethodSelected))._on_(aCompiledMethod));
  1408. return self}, function($ctx1) {$ctx1.fill(self,"selectedMethod:",{aCompiledMethod:aCompiledMethod}, smalltalk.HLBrowserModel)})},
  1409. messageSends: ["ifTrue:", "=", "ifNil:ifNotNil:", "selector", "announce:", "on:", "announcer"]}),
  1410. smalltalk.HLBrowserModel);
  1411. smalltalk.addMethod(
  1412. "_selectedPackage",
  1413. smalltalk.method({
  1414. selector: "selectedPackage",
  1415. fn: function (){
  1416. var self=this;
  1417. return smalltalk.withContext(function($ctx1) { var $1;
  1418. $1=self["@selectedPackage"];
  1419. return $1;
  1420. }, function($ctx1) {$ctx1.fill(self,"selectedPackage",{}, smalltalk.HLBrowserModel)})},
  1421. messageSends: []}),
  1422. smalltalk.HLBrowserModel);
  1423. smalltalk.addMethod(
  1424. "_selectedPackage_",
  1425. smalltalk.method({
  1426. selector: "selectedPackage:",
  1427. fn: function (aPackage){
  1428. var self=this;
  1429. return smalltalk.withContext(function($ctx1) { var $1,$2;
  1430. $1=_st(self["@selectedPackage"]).__eq(aPackage);
  1431. if(smalltalk.assert($1)){
  1432. $2=self;
  1433. return $2;
  1434. };
  1435. self["@selectedPackage"]=aPackage;
  1436. _st(self)._selectedClass_(nil);
  1437. _st(_st(self)._announcer())._announce_(_st((smalltalk.HLPackageSelected || HLPackageSelected))._on_(aPackage));
  1438. return self}, function($ctx1) {$ctx1.fill(self,"selectedPackage:",{aPackage:aPackage}, smalltalk.HLBrowserModel)})},
  1439. messageSends: ["ifTrue:", "=", "selectedClass:", "announce:", "on:", "announcer"]}),
  1440. smalltalk.HLBrowserModel);
  1441. smalltalk.addMethod(
  1442. "_selectedProtocol",
  1443. smalltalk.method({
  1444. selector: "selectedProtocol",
  1445. fn: function (){
  1446. var self=this;
  1447. return smalltalk.withContext(function($ctx1) { var $1;
  1448. $1=self["@selectedProtocol"];
  1449. return $1;
  1450. }, function($ctx1) {$ctx1.fill(self,"selectedProtocol",{}, smalltalk.HLBrowserModel)})},
  1451. messageSends: []}),
  1452. smalltalk.HLBrowserModel);
  1453. smalltalk.addMethod(
  1454. "_selectedProtocol_",
  1455. smalltalk.method({
  1456. selector: "selectedProtocol:",
  1457. fn: function (aString){
  1458. var self=this;
  1459. return smalltalk.withContext(function($ctx1) { var $1,$2;
  1460. $1=_st(self["@selectedProtocol"]).__eq(aString);
  1461. if(smalltalk.assert($1)){
  1462. $2=self;
  1463. return $2;
  1464. };
  1465. self["@selectedProtocol"]=aString;
  1466. _st(self)._selectedMethod_(nil);
  1467. _st(_st(self)._announcer())._announce_(_st((smalltalk.HLProtocolSelected || HLProtocolSelected))._on_(aString));
  1468. return self}, function($ctx1) {$ctx1.fill(self,"selectedProtocol:",{aString:aString}, smalltalk.HLBrowserModel)})},
  1469. messageSends: ["ifTrue:", "=", "selectedMethod:", "announce:", "on:", "announcer"]}),
  1470. smalltalk.HLBrowserModel);
  1471. smalltalk.addMethod(
  1472. "_showComment",
  1473. smalltalk.method({
  1474. selector: "showComment",
  1475. fn: function (){
  1476. var self=this;
  1477. return smalltalk.withContext(function($ctx1) { var $2,$1;
  1478. $2=self["@showComment"];
  1479. if(($receiver = $2) == nil || $receiver == undefined){
  1480. $1=false;
  1481. } else {
  1482. $1=$2;
  1483. };
  1484. return $1;
  1485. }, function($ctx1) {$ctx1.fill(self,"showComment",{}, smalltalk.HLBrowserModel)})},
  1486. messageSends: ["ifNil:"]}),
  1487. smalltalk.HLBrowserModel);
  1488. smalltalk.addMethod(
  1489. "_showComment_",
  1490. smalltalk.method({
  1491. selector: "showComment:",
  1492. fn: function (aBoolean){
  1493. var self=this;
  1494. return smalltalk.withContext(function($ctx1) { self["@showComment"]=aBoolean;
  1495. _st(_st(self)._announcer())._announce_(_st((smalltalk.HLShowCommentToggled || HLShowCommentToggled))._new());
  1496. return self}, function($ctx1) {$ctx1.fill(self,"showComment:",{aBoolean:aBoolean}, smalltalk.HLBrowserModel)})},
  1497. messageSends: ["announce:", "new", "announcer"]}),
  1498. smalltalk.HLBrowserModel);
  1499. smalltalk.addMethod(
  1500. "_showInstance",
  1501. smalltalk.method({
  1502. selector: "showInstance",
  1503. fn: function (){
  1504. var self=this;
  1505. return smalltalk.withContext(function($ctx1) { var $2,$1;
  1506. $2=self["@showInstance"];
  1507. if(($receiver = $2) == nil || $receiver == undefined){
  1508. $1=true;
  1509. } else {
  1510. $1=$2;
  1511. };
  1512. return $1;
  1513. }, function($ctx1) {$ctx1.fill(self,"showInstance",{}, smalltalk.HLBrowserModel)})},
  1514. messageSends: ["ifNil:"]}),
  1515. smalltalk.HLBrowserModel);
  1516. smalltalk.addMethod(
  1517. "_showInstance_",
  1518. smalltalk.method({
  1519. selector: "showInstance:",
  1520. fn: function (aBoolean){
  1521. var self=this;
  1522. return smalltalk.withContext(function($ctx1) { var $1,$2,$4,$3;
  1523. self["@showInstance"]=aBoolean;
  1524. $1=_st(self)._selectedClass();
  1525. if(($receiver = $1) == nil || $receiver == undefined){
  1526. $1;
  1527. } else {
  1528. $2=self;
  1529. $4=aBoolean;
  1530. if(smalltalk.assert($4)){
  1531. $3=_st(_st(self)._selectedClass())._theNonMetaClass();
  1532. } else {
  1533. $3=_st(_st(self)._selectedClass())._theMetaClass();
  1534. };
  1535. _st($2)._selectedClass_($3);
  1536. };
  1537. _st(_st(self)._announcer())._announce_(_st((smalltalk.HLShowInstanceToggled || HLShowInstanceToggled))._new());
  1538. return self}, function($ctx1) {$ctx1.fill(self,"showInstance:",{aBoolean:aBoolean}, smalltalk.HLBrowserModel)})},
  1539. messageSends: ["ifNotNil:", "selectedClass:", "ifTrue:ifFalse:", "theNonMetaClass", "selectedClass", "theMetaClass", "announce:", "new", "announcer"]}),
  1540. smalltalk.HLBrowserModel);
  1541. smalltalk.addMethod(
  1542. "_on_",
  1543. smalltalk.method({
  1544. selector: "on:",
  1545. fn: function (anEnvironment){
  1546. var self=this;
  1547. return smalltalk.withContext(function($ctx1) { var $2,$3,$1;
  1548. $2=_st(self)._new();
  1549. _st($2)._environment_(anEnvironment);
  1550. $3=_st($2)._yourself();
  1551. $1=$3;
  1552. return $1;
  1553. }, function($ctx1) {$ctx1.fill(self,"on:",{anEnvironment:anEnvironment}, smalltalk.HLBrowserModel.klass)})},
  1554. messageSends: ["environment:", "new", "yourself"]}),
  1555. smalltalk.HLBrowserModel.klass);
  1556. smalltalk.addClass('HLBrowserSourceWidget', smalltalk.HLWidget, ['model', 'methodContents', 'codeWidget'], 'Helios-Browser');
  1557. smalltalk.addMethod(
  1558. "_codeWidget",
  1559. smalltalk.method({
  1560. selector: "codeWidget",
  1561. fn: function (){
  1562. var self=this;
  1563. return smalltalk.withContext(function($ctx1) { var $2,$1;
  1564. $2=self["@codeWidget"];
  1565. if(($receiver = $2) == nil || $receiver == undefined){
  1566. self["@codeWidget"]=_st((smalltalk.HLCodeWidget || HLCodeWidget))._new();
  1567. $1=self["@codeWidget"];
  1568. } else {
  1569. $1=$2;
  1570. };
  1571. return $1;
  1572. }, function($ctx1) {$ctx1.fill(self,"codeWidget",{}, smalltalk.HLBrowserSourceWidget)})},
  1573. messageSends: ["ifNil:", "new"]}),
  1574. smalltalk.HLBrowserSourceWidget);
  1575. smalltalk.addMethod(
  1576. "_contents",
  1577. smalltalk.method({
  1578. selector: "contents",
  1579. fn: function (){
  1580. var self=this;
  1581. return smalltalk.withContext(function($ctx1) { var $1;
  1582. $1=_st(_st(self)._codeWidget())._contents();
  1583. return $1;
  1584. }, function($ctx1) {$ctx1.fill(self,"contents",{}, smalltalk.HLBrowserSourceWidget)})},
  1585. messageSends: ["contents", "codeWidget"]}),
  1586. smalltalk.HLBrowserSourceWidget);
  1587. smalltalk.addMethod(
  1588. "_contents_",
  1589. smalltalk.method({
  1590. selector: "contents:",
  1591. fn: function (aString){
  1592. var self=this;
  1593. return smalltalk.withContext(function($ctx1) { _st(self)._methodContents_(aString);
  1594. _st(_st(self)._codeWidget())._contents_(aString);
  1595. return self}, function($ctx1) {$ctx1.fill(self,"contents:",{aString:aString}, smalltalk.HLBrowserSourceWidget)})},
  1596. messageSends: ["methodContents:", "contents:", "codeWidget"]}),
  1597. smalltalk.HLBrowserSourceWidget);
  1598. smalltalk.addMethod(
  1599. "_hasModification",
  1600. smalltalk.method({
  1601. selector: "hasModification",
  1602. fn: function (){
  1603. var self=this;
  1604. return smalltalk.withContext(function($ctx1) { var $1;
  1605. $1=_st(_st(_st(self)._methodContents()).__eq(_st(self)._contents()))._not();
  1606. return $1;
  1607. }, function($ctx1) {$ctx1.fill(self,"hasModification",{}, smalltalk.HLBrowserSourceWidget)})},
  1608. messageSends: ["not", "=", "contents", "methodContents"]}),
  1609. smalltalk.HLBrowserSourceWidget);
  1610. smalltalk.addMethod(
  1611. "_initialize",
  1612. smalltalk.method({
  1613. selector: "initialize",
  1614. fn: function (){
  1615. var self=this;
  1616. return smalltalk.withContext(function($ctx1) { smalltalk.HLWidget.fn.prototype._initialize.apply(_st(self), []);
  1617. _st(self)._observeSystem();
  1618. return self}, function($ctx1) {$ctx1.fill(self,"initialize",{}, smalltalk.HLBrowserSourceWidget)})},
  1619. messageSends: ["initialize", "observeSystem"]}),
  1620. smalltalk.HLBrowserSourceWidget);
  1621. smalltalk.addMethod(
  1622. "_methodContents",
  1623. smalltalk.method({
  1624. selector: "methodContents",
  1625. fn: function (){
  1626. var self=this;
  1627. return smalltalk.withContext(function($ctx1) { var $2,$1;
  1628. $2=self["@methodContents"];
  1629. if(($receiver = $2) == nil || $receiver == undefined){
  1630. self["@methodContents"]="";
  1631. $1=self["@methodContents"];
  1632. } else {
  1633. $1=$2;
  1634. };
  1635. return $1;
  1636. }, function($ctx1) {$ctx1.fill(self,"methodContents",{}, smalltalk.HLBrowserSourceWidget)})},
  1637. messageSends: ["ifNil:"]}),
  1638. smalltalk.HLBrowserSourceWidget);
  1639. smalltalk.addMethod(
  1640. "_methodContents_",
  1641. smalltalk.method({
  1642. selector: "methodContents:",
  1643. fn: function (aString){
  1644. var self=this;
  1645. return smalltalk.withContext(function($ctx1) { self["@methodContents"]=aString;
  1646. return self}, function($ctx1) {$ctx1.fill(self,"methodContents:",{aString:aString}, smalltalk.HLBrowserSourceWidget)})},
  1647. messageSends: []}),
  1648. smalltalk.HLBrowserSourceWidget);
  1649. smalltalk.addMethod(
  1650. "_model",
  1651. smalltalk.method({
  1652. selector: "model",
  1653. fn: function (){
  1654. var self=this;
  1655. return smalltalk.withContext(function($ctx1) { var $1;
  1656. $1=self["@model"];
  1657. return $1;
  1658. }, function($ctx1) {$ctx1.fill(self,"model",{}, smalltalk.HLBrowserSourceWidget)})},
  1659. messageSends: []}),
  1660. smalltalk.HLBrowserSourceWidget);
  1661. smalltalk.addMethod(
  1662. "_model_",
  1663. smalltalk.method({
  1664. selector: "model:",
  1665. fn: function (aBrowserModel){
  1666. var self=this;
  1667. return smalltalk.withContext(function($ctx1) { self["@model"]=aBrowserModel;
  1668. _st(self)._observeModel();
  1669. return self}, function($ctx1) {$ctx1.fill(self,"model:",{aBrowserModel:aBrowserModel}, smalltalk.HLBrowserSourceWidget)})},
  1670. messageSends: ["observeModel"]}),
  1671. smalltalk.HLBrowserSourceWidget);
  1672. smalltalk.addMethod(
  1673. "_observeModel",
  1674. smalltalk.method({
  1675. selector: "observeModel",
  1676. fn: function (){
  1677. var self=this;
  1678. return smalltalk.withContext(function($ctx1) { _st(_st(_st(self)._model())._announcer())._on_do_((smalltalk.HLMethodSelected || HLMethodSelected),(function(ann){
  1679. return smalltalk.withContext(function($ctx2) { return _st(self)._onMethodSelected_(_st(ann)._item());
  1680. }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1)})}));
  1681. _st(_st(_st(self)._model())._announcer())._on_do_((smalltalk.HLClassSelected || HLClassSelected),(function(ann){
  1682. return smalltalk.withContext(function($ctx2) { return _st(self)._onClassSelected_(_st(ann)._item());
  1683. }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1)})}));
  1684. _st(_st(_st(self)._model())._announcer())._on_do_((smalltalk.HLProtocolSelected || HLProtocolSelected),(function(ann){
  1685. return smalltalk.withContext(function($ctx2) { return _st(self)._onProtocolSelected_(_st(ann)._item());
  1686. }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1)})}));
  1687. return self}, function($ctx1) {$ctx1.fill(self,"observeModel",{}, smalltalk.HLBrowserSourceWidget)})},
  1688. messageSends: ["on:do:", "onMethodSelected:", "item", "announcer", "model", "onClassSelected:", "onProtocolSelected:"]}),
  1689. smalltalk.HLBrowserSourceWidget);
  1690. smalltalk.addMethod(
  1691. "_observeSystem",
  1692. smalltalk.method({
  1693. selector: "observeSystem",
  1694. fn: function (){
  1695. var self=this;
  1696. return smalltalk.withContext(function($ctx1) { _st(_st((smalltalk.SystemAnnouncer || SystemAnnouncer))._current())._on_do_((smalltalk.MethodModified || MethodModified),(function(ann){
  1697. return smalltalk.withContext(function($ctx2) { return _st(self)._onMethodModified_(_st(ann)._method());
  1698. }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1)})}));
  1699. return self}, function($ctx1) {$ctx1.fill(self,"observeSystem",{}, smalltalk.HLBrowserSourceWidget)})},
  1700. messageSends: ["on:do:", "onMethodModified:", "method", "current"]}),
  1701. smalltalk.HLBrowserSourceWidget);
  1702. smalltalk.addMethod(
  1703. "_onClassSelected_",
  1704. smalltalk.method({
  1705. selector: "onClassSelected:",
  1706. fn: function (aClass){
  1707. var self=this;
  1708. return smalltalk.withContext(function($ctx1) { var $1,$2;
  1709. $1=aClass;
  1710. if(($receiver = $1) == nil || $receiver == undefined){
  1711. $2=_st(self)._contents_("");
  1712. return $2;
  1713. } else {
  1714. $1;
  1715. };
  1716. _st(self)._contents_(_st(aClass)._definition());
  1717. return self}, function($ctx1) {$ctx1.fill(self,"onClassSelected:",{aClass:aClass}, smalltalk.HLBrowserSourceWidget)})},
  1718. messageSends: ["ifNil:", "contents:", "definition"]}),
  1719. smalltalk.HLBrowserSourceWidget);
  1720. smalltalk.addMethod(
  1721. "_onMethodModified_",
  1722. smalltalk.method({
  1723. selector: "onMethodModified:",
  1724. fn: function (aMethod){
  1725. var self=this;
  1726. return smalltalk.withContext(function($ctx1) { var $1,$2,$3,$4;
  1727. $1=_st(_st(_st(self)._model())._selectedClass()).__eq(_st(aMethod)._methodClass());
  1728. if(! smalltalk.assert($1)){
  1729. $2=self;
  1730. return $2;
  1731. };
  1732. $3=_st(_st(_st(_st(self)._model())._selectedMethod())._selector()).__eq(_st(aMethod)._selector());
  1733. if(! smalltalk.assert($3)){
  1734. $4=self;
  1735. return $4;
  1736. };
  1737. _st(self)._refresh();
  1738. return self}, function($ctx1) {$ctx1.fill(self,"onMethodModified:",{aMethod:aMethod}, smalltalk.HLBrowserSourceWidget)})},
  1739. messageSends: ["ifFalse:", "=", "methodClass", "selectedClass", "model", "selector", "selectedMethod", "refresh"]}),
  1740. smalltalk.HLBrowserSourceWidget);
  1741. smalltalk.addMethod(
  1742. "_onMethodSelected_",
  1743. smalltalk.method({
  1744. selector: "onMethodSelected:",
  1745. fn: function (aCompiledMethod){
  1746. var self=this;
  1747. return smalltalk.withContext(function($ctx1) { var $1,$2;
  1748. $1=aCompiledMethod;
  1749. if(($receiver = $1) == nil || $receiver == undefined){
  1750. $2=_st(self)._contents_("");
  1751. return $2;
  1752. } else {
  1753. $1;
  1754. };
  1755. _st(self)._contents_(_st(aCompiledMethod)._source());
  1756. return self}, function($ctx1) {$ctx1.fill(self,"onMethodSelected:",{aCompiledMethod:aCompiledMethod}, smalltalk.HLBrowserSourceWidget)})},
  1757. messageSends: ["ifNil:", "contents:", "source"]}),
  1758. smalltalk.HLBrowserSourceWidget);
  1759. smalltalk.addMethod(
  1760. "_onProtocolSelected_",
  1761. smalltalk.method({
  1762. selector: "onProtocolSelected:",
  1763. fn: function (aString){
  1764. var self=this;
  1765. return smalltalk.withContext(function($ctx1) { var $1,$2;
  1766. $1=_st(_st(self)._model())._selectedClass();
  1767. if(($receiver = $1) == nil || $receiver == undefined){
  1768. $2=_st(self)._contents_("");
  1769. return $2;
  1770. } else {
  1771. $1;
  1772. };
  1773. _st(self)._contents_(_st(_st(_st(self)._model())._selectedClass())._definition());
  1774. return self}, function($ctx1) {$ctx1.fill(self,"onProtocolSelected:",{aString:aString}, smalltalk.HLBrowserSourceWidget)})},
  1775. messageSends: ["ifNil:", "contents:", "selectedClass", "model", "definition"]}),
  1776. smalltalk.HLBrowserSourceWidget);
  1777. smalltalk.addMethod(
  1778. "_refresh",
  1779. smalltalk.method({
  1780. selector: "refresh",
  1781. fn: function (){
  1782. var self=this;
  1783. return smalltalk.withContext(function($ctx1) { var $1,$2;
  1784. $1=_st(self)._hasModification();
  1785. if(smalltalk.assert($1)){
  1786. $2=self;
  1787. return $2;
  1788. };
  1789. _st(self)._contents_(_st(_st(_st(self)._model())._selectedMethod())._source());
  1790. smalltalk.HLWidget.fn.prototype._refresh.apply(_st(self), []);
  1791. return self}, function($ctx1) {$ctx1.fill(self,"refresh",{}, smalltalk.HLBrowserSourceWidget)})},
  1792. messageSends: ["ifTrue:", "hasModification", "contents:", "source", "selectedMethod", "model", "refresh"]}),
  1793. smalltalk.HLBrowserSourceWidget);
  1794. smalltalk.addMethod(
  1795. "_renderContentOn_",
  1796. smalltalk.method({
  1797. selector: "renderContentOn:",
  1798. fn: function (html){
  1799. var self=this;
  1800. return smalltalk.withContext(function($ctx1) { _st(_st(self)._codeWidget())._renderOn_(html);
  1801. return self}, function($ctx1) {$ctx1.fill(self,"renderContentOn:",{html:html}, smalltalk.HLBrowserSourceWidget)})},
  1802. messageSends: ["renderOn:", "codeWidget"]}),
  1803. smalltalk.HLBrowserSourceWidget);
  1804. smalltalk.addMethod(
  1805. "_on_",
  1806. smalltalk.method({
  1807. selector: "on:",
  1808. fn: function (aBrowserModel){
  1809. var self=this;
  1810. return smalltalk.withContext(function($ctx1) { var $2,$3,$1;
  1811. $2=_st(self)._new();
  1812. _st($2)._model_(aBrowserModel);
  1813. $3=_st($2)._yourself();
  1814. $1=$3;
  1815. return $1;
  1816. }, function($ctx1) {$ctx1.fill(self,"on:",{aBrowserModel:aBrowserModel}, smalltalk.HLBrowserSourceWidget.klass)})},
  1817. messageSends: ["model:", "new", "yourself"]}),
  1818. smalltalk.HLBrowserSourceWidget.klass);
  1819. smalltalk.addClass('HLClassCache', smalltalk.Object, ['class', 'selectorsCache', 'overrideCache', 'overriddenCache'], 'Helios-Browser');
  1820. smalltalk.addMethod(
  1821. "_invalidateChildrenSelector_",
  1822. smalltalk.method({
  1823. selector: "invalidateChildrenSelector:",
  1824. fn: function (aSelector){
  1825. var self=this;
  1826. return smalltalk.withContext(function($ctx1) { var $1,$2;
  1827. _st(_st(_st(self)._theClass())._subclasses())._do_((function(each){
  1828. return smalltalk.withContext(function($ctx2) { $1=_st(_st(self)._selectorsCache())._cacheFor_(each);
  1829. _st($1)._removeSelector_(aSelector);
  1830. $2=_st($1)._invalidateChildrenSelector_(aSelector);
  1831. return $2;
  1832. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})}));
  1833. return self}, function($ctx1) {$ctx1.fill(self,"invalidateChildrenSelector:",{aSelector:aSelector}, smalltalk.HLClassCache)})},
  1834. messageSends: ["do:", "removeSelector:", "cacheFor:", "selectorsCache", "invalidateChildrenSelector:", "subclasses", "theClass"]}),
  1835. smalltalk.HLClassCache);
  1836. smalltalk.addMethod(
  1837. "_invalidateParentSelector_",
  1838. smalltalk.method({
  1839. selector: "invalidateParentSelector:",
  1840. fn: function (aSelector){
  1841. var self=this;
  1842. return smalltalk.withContext(function($ctx1) { var $1,$2,$3;
  1843. $1=_st(_st(self)._theClass())._superclass();
  1844. if(($receiver = $1) == nil || $receiver == undefined){
  1845. $1;
  1846. } else {
  1847. $2=_st(_st(self)._selectorsCache())._cacheFor_(_st(_st(self)._theClass())._superclass());
  1848. _st($2)._removeSelector_(aSelector);
  1849. $3=_st($2)._invalidateParentSelector_(aSelector);
  1850. $3;
  1851. };
  1852. return self}, function($ctx1) {$ctx1.fill(self,"invalidateParentSelector:",{aSelector:aSelector}, smalltalk.HLClassCache)})},
  1853. messageSends: ["ifNotNil:", "removeSelector:", "cacheFor:", "superclass", "theClass", "selectorsCache", "invalidateParentSelector:"]}),
  1854. smalltalk.HLClassCache);
  1855. smalltalk.addMethod(
  1856. "_invalidateSelector_",
  1857. smalltalk.method({
  1858. selector: "invalidateSelector:",
  1859. fn: function (aSelector){
  1860. var self=this;
  1861. return smalltalk.withContext(function($ctx1) { var $1,$2;
  1862. $1=self;
  1863. _st($1)._invalidateParentSelector_(aSelector);
  1864. _st($1)._invalidateChildrenSelector_(aSelector);
  1865. $2=_st($1)._removeSelector_(aSelector);
  1866. return self}, function($ctx1) {$ctx1.fill(self,"invalidateSelector:",{aSelector:aSelector}, smalltalk.HLClassCache)})},
  1867. messageSends: ["invalidateParentSelector:", "invalidateChildrenSelector:", "removeSelector:"]}),
  1868. smalltalk.HLClassCache);
  1869. smalltalk.addMethod(
  1870. "_isOverridden_",
  1871. smalltalk.method({
  1872. selector: "isOverridden:",
  1873. fn: function (aMethod){
  1874. var self=this;
  1875. return smalltalk.withContext(function($ctx1) { var $1;
  1876. $1=_st(_st(self)._overriddenCache())._at_ifAbsentPut_(_st(aMethod)._selector(),(function(){
  1877. return smalltalk.withContext(function($ctx2) { return _st(aMethod)._isOverridden();
  1878. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  1879. return $1;
  1880. }, function($ctx1) {$ctx1.fill(self,"isOverridden:",{aMethod:aMethod}, smalltalk.HLClassCache)})},
  1881. messageSends: ["at:ifAbsentPut:", "selector", "isOverridden", "overriddenCache"]}),
  1882. smalltalk.HLClassCache);
  1883. smalltalk.addMethod(
  1884. "_isOverride_",
  1885. smalltalk.method({
  1886. selector: "isOverride:",
  1887. fn: function (aMethod){
  1888. var self=this;
  1889. return smalltalk.withContext(function($ctx1) { var $1;
  1890. $1=_st(_st(self)._overrideCache())._at_ifAbsentPut_(_st(aMethod)._selector(),(function(){
  1891. return smalltalk.withContext(function($ctx2) { return _st(aMethod)._isOverride();
  1892. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  1893. return $1;
  1894. }, function($ctx1) {$ctx1.fill(self,"isOverride:",{aMethod:aMethod}, smalltalk.HLClassCache)})},
  1895. messageSends: ["at:ifAbsentPut:", "selector", "isOverride", "overrideCache"]}),
  1896. smalltalk.HLClassCache);
  1897. smalltalk.addMethod(
  1898. "_overriddenCache",
  1899. smalltalk.method({
  1900. selector: "overriddenCache",
  1901. fn: function (){
  1902. var self=this;
  1903. return smalltalk.withContext(function($ctx1) { var $2,$1;
  1904. $2=self["@overriddenCache"];
  1905. if(($receiver = $2) == nil || $receiver == undefined){
  1906. self["@overriddenCache"]=_st((smalltalk.HashedCollection || HashedCollection))._new();
  1907. $1=self["@overriddenCache"];
  1908. } else {
  1909. $1=$2;
  1910. };
  1911. return $1;
  1912. }, function($ctx1) {$ctx1.fill(self,"overriddenCache",{}, smalltalk.HLClassCache)})},
  1913. messageSends: ["ifNil:", "new"]}),
  1914. smalltalk.HLClassCache);
  1915. smalltalk.addMethod(
  1916. "_overrideCache",
  1917. smalltalk.method({
  1918. selector: "overrideCache",
  1919. fn: function (){
  1920. var self=this;
  1921. return smalltalk.withContext(function($ctx1) { var $2,$1;
  1922. $2=self["@overrideCache"];
  1923. if(($receiver = $2) == nil || $receiver == undefined){
  1924. self["@overrideCache"]=_st((smalltalk.HashedCollection || HashedCollection))._new();
  1925. $1=self["@overrideCache"];
  1926. } else {
  1927. $1=$2;
  1928. };
  1929. return $1;
  1930. }, function($ctx1) {$ctx1.fill(self,"overrideCache",{}, smalltalk.HLClassCache)})},
  1931. messageSends: ["ifNil:", "new"]}),
  1932. smalltalk.HLClassCache);
  1933. smalltalk.addMethod(
  1934. "_removeSelector_",
  1935. smalltalk.method({
  1936. selector: "removeSelector:",
  1937. fn: function (aSelector){
  1938. var self=this;
  1939. return smalltalk.withContext(function($ctx1) { _st(_st(self)._overriddenCache())._removeKey_ifAbsent_(aSelector,(function(){
  1940. return smalltalk.withContext(function($ctx2) { }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  1941. _st(_st(self)._overrideCache())._removeKey_ifAbsent_(aSelector,(function(){
  1942. return smalltalk.withContext(function($ctx2) { }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  1943. return self}, function($ctx1) {$ctx1.fill(self,"removeSelector:",{aSelector:aSelector}, smalltalk.HLClassCache)})},
  1944. messageSends: ["removeKey:ifAbsent:", "overriddenCache", "overrideCache"]}),
  1945. smalltalk.HLClassCache);
  1946. smalltalk.addMethod(
  1947. "_selectorsCache",
  1948. smalltalk.method({
  1949. selector: "selectorsCache",
  1950. fn: function (){
  1951. var self=this;
  1952. return smalltalk.withContext(function($ctx1) { var $1;
  1953. $1=self["@selectorsCache"];
  1954. return $1;
  1955. }, function($ctx1) {$ctx1.fill(self,"selectorsCache",{}, smalltalk.HLClassCache)})},
  1956. messageSends: []}),
  1957. smalltalk.HLClassCache);
  1958. smalltalk.addMethod(
  1959. "_selectorsCache_",
  1960. smalltalk.method({
  1961. selector: "selectorsCache:",
  1962. fn: function (aCache){
  1963. var self=this;
  1964. return smalltalk.withContext(function($ctx1) { self["@selectorsCache"]=aCache;
  1965. return self}, function($ctx1) {$ctx1.fill(self,"selectorsCache:",{aCache:aCache}, smalltalk.HLClassCache)})},
  1966. messageSends: []}),
  1967. smalltalk.HLClassCache);
  1968. smalltalk.addMethod(
  1969. "_theClass",
  1970. smalltalk.method({
  1971. selector: "theClass",
  1972. fn: function (){
  1973. var self=this;
  1974. return smalltalk.withContext(function($ctx1) { var $1;
  1975. $1=self["@class"];
  1976. return $1;
  1977. }, function($ctx1) {$ctx1.fill(self,"theClass",{}, smalltalk.HLClassCache)})},
  1978. messageSends: []}),
  1979. smalltalk.HLClassCache);
  1980. smalltalk.addMethod(
  1981. "_theClass_",
  1982. smalltalk.method({
  1983. selector: "theClass:",
  1984. fn: function (aClass){
  1985. var self=this;
  1986. return smalltalk.withContext(function($ctx1) { self["@class"]=aClass;
  1987. return self}, function($ctx1) {$ctx1.fill(self,"theClass:",{aClass:aClass}, smalltalk.HLClassCache)})},
  1988. messageSends: []}),
  1989. smalltalk.HLClassCache);
  1990. smalltalk.addMethod(
  1991. "_on_selectorsCache_",
  1992. smalltalk.method({
  1993. selector: "on:selectorsCache:",
  1994. fn: function (aClass,aSelectorsCache){
  1995. var self=this;
  1996. return smalltalk.withContext(function($ctx1) { var $2,$3,$1;
  1997. $2=_st(self)._new();
  1998. _st($2)._theClass_(aClass);
  1999. _st($2)._selectorsCache_(aSelectorsCache);
  2000. $3=_st($2)._yourself();
  2001. $1=$3;
  2002. return $1;
  2003. }, function($ctx1) {$ctx1.fill(self,"on:selectorsCache:",{aClass:aClass,aSelectorsCache:aSelectorsCache}, smalltalk.HLClassCache.klass)})},
  2004. messageSends: ["theClass:", "new", "selectorsCache:", "yourself"]}),
  2005. smalltalk.HLClassCache.klass);
  2006. smalltalk.addClass('HLSelectorsCache', smalltalk.Object, ['classesCache'], 'Helios-Browser');
  2007. smalltalk.addMethod(
  2008. "_cacheFor_",
  2009. smalltalk.method({
  2010. selector: "cacheFor:",
  2011. fn: function (aClass){
  2012. var self=this;
  2013. return smalltalk.withContext(function($ctx1) { var $1,$2;
  2014. $1=aClass;
  2015. if(($receiver = $1) == nil || $receiver == undefined){
  2016. return nil;
  2017. } else {
  2018. $1;
  2019. };
  2020. $2=_st(_st(self)._classesCache())._at_ifAbsentPut_(_st(aClass)._name(),(function(){
  2021. return smalltalk.withContext(function($ctx2) { return _st(self)._newCacheFor_(aClass);
  2022. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  2023. return $2;
  2024. }, function($ctx1) {$ctx1.fill(self,"cacheFor:",{aClass:aClass}, smalltalk.HLSelectorsCache)})},
  2025. messageSends: ["ifNil:", "at:ifAbsentPut:", "name", "newCacheFor:", "classesCache"]}),
  2026. smalltalk.HLSelectorsCache);
  2027. smalltalk.addMethod(
  2028. "_classesCache",
  2029. smalltalk.method({
  2030. selector: "classesCache",
  2031. fn: function (){
  2032. var self=this;
  2033. return smalltalk.withContext(function($ctx1) { var $2,$1;
  2034. $2=self["@classesCache"];
  2035. if(($receiver = $2) == nil || $receiver == undefined){
  2036. self["@classesCache"]=_st((smalltalk.HashedCollection || HashedCollection))._new();
  2037. $1=self["@classesCache"];
  2038. } else {
  2039. $1=$2;
  2040. };
  2041. return $1;
  2042. }, function($ctx1) {$ctx1.fill(self,"classesCache",{}, smalltalk.HLSelectorsCache)})},
  2043. messageSends: ["ifNil:", "new"]}),
  2044. smalltalk.HLSelectorsCache);
  2045. smalltalk.addMethod(
  2046. "_initialize",
  2047. smalltalk.method({
  2048. selector: "initialize",
  2049. fn: function (){
  2050. var self=this;
  2051. return smalltalk.withContext(function($ctx1) { smalltalk.Object.fn.prototype._initialize.apply(_st(self), []);
  2052. _st(self)._observeSystem();
  2053. return self}, function($ctx1) {$ctx1.fill(self,"initialize",{}, smalltalk.HLSelectorsCache)})},
  2054. messageSends: ["initialize", "observeSystem"]}),
  2055. smalltalk.HLSelectorsCache);
  2056. smalltalk.addMethod(
  2057. "_invalidateCacheFor_",
  2058. smalltalk.method({
  2059. selector: "invalidateCacheFor:",
  2060. fn: function (aMethod){
  2061. var self=this;
  2062. return smalltalk.withContext(function($ctx1) { _st(_st(self)._cacheFor_(_st(aMethod)._methodClass()))._invalidateSelector_(_st(aMethod)._selector());
  2063. return self}, function($ctx1) {$ctx1.fill(self,"invalidateCacheFor:",{aMethod:aMethod}, smalltalk.HLSelectorsCache)})},
  2064. messageSends: ["invalidateSelector:", "selector", "cacheFor:", "methodClass"]}),
  2065. smalltalk.HLSelectorsCache);
  2066. smalltalk.addMethod(
  2067. "_isOverridden_",
  2068. smalltalk.method({
  2069. selector: "isOverridden:",
  2070. fn: function (aMethod){
  2071. var self=this;
  2072. return smalltalk.withContext(function($ctx1) { var $1;
  2073. $1=_st(_st(self)._cacheFor_(_st(aMethod)._methodClass()))._isOverridden_(aMethod);
  2074. return $1;
  2075. }, function($ctx1) {$ctx1.fill(self,"isOverridden:",{aMethod:aMethod}, smalltalk.HLSelectorsCache)})},
  2076. messageSends: ["isOverridden:", "cacheFor:", "methodClass"]}),
  2077. smalltalk.HLSelectorsCache);
  2078. smalltalk.addMethod(
  2079. "_isOverride_",
  2080. smalltalk.method({
  2081. selector: "isOverride:",
  2082. fn: function (aMethod){
  2083. var self=this;
  2084. return smalltalk.withContext(function($ctx1) { var $1;
  2085. $1=_st(_st(self)._cacheFor_(_st(aMethod)._methodClass()))._isOverride_(aMethod);
  2086. return $1;
  2087. }, function($ctx1) {$ctx1.fill(self,"isOverride:",{aMethod:aMethod}, smalltalk.HLSelectorsCache)})},
  2088. messageSends: ["isOverride:", "cacheFor:", "methodClass"]}),
  2089. smalltalk.HLSelectorsCache);
  2090. smalltalk.addMethod(
  2091. "_newCacheFor_",
  2092. smalltalk.method({
  2093. selector: "newCacheFor:",
  2094. fn: function (aClass){
  2095. var self=this;
  2096. return smalltalk.withContext(function($ctx1) { var $1;
  2097. $1=_st((smalltalk.HLClassCache || HLClassCache))._on_selectorsCache_(aClass,self);
  2098. return $1;
  2099. }, function($ctx1) {$ctx1.fill(self,"newCacheFor:",{aClass:aClass}, smalltalk.HLSelectorsCache)})},
  2100. messageSends: ["on:selectorsCache:"]}),
  2101. smalltalk.HLSelectorsCache);
  2102. smalltalk.addMethod(
  2103. "_observeSystem",
  2104. smalltalk.method({
  2105. selector: "observeSystem",
  2106. fn: function (){
  2107. var self=this;
  2108. return smalltalk.withContext(function($ctx1) { var $1,$2;
  2109. $1=_st((smalltalk.SystemAnnouncer || SystemAnnouncer))._current();
  2110. _st($1)._on_do_((smalltalk.MethodAdded || MethodAdded),(function(ann){
  2111. return smalltalk.withContext(function($ctx2) { return _st(self)._onMethodAdded_(_st(ann)._method());
  2112. }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1)})}));
  2113. $2=_st($1)._on_do_((smalltalk.MethodRemoved || MethodRemoved),(function(ann){
  2114. return smalltalk.withContext(function($ctx2) { return _st(self)._onMethodRemoved_(_st(ann)._method());
  2115. }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1)})}));
  2116. return self}, function($ctx1) {$ctx1.fill(self,"observeSystem",{}, smalltalk.HLSelectorsCache)})},
  2117. messageSends: ["on:do:", "onMethodAdded:", "method", "current", "onMethodRemoved:"]}),
  2118. smalltalk.HLSelectorsCache);
  2119. smalltalk.addMethod(
  2120. "_onMethodAdded_",
  2121. smalltalk.method({
  2122. selector: "onMethodAdded:",
  2123. fn: function (aMethod){
  2124. var self=this;
  2125. return smalltalk.withContext(function($ctx1) { _st(self)._invalidateCacheFor_(aMethod);
  2126. return self}, function($ctx1) {$ctx1.fill(self,"onMethodAdded:",{aMethod:aMethod}, smalltalk.HLSelectorsCache)})},
  2127. messageSends: ["invalidateCacheFor:"]}),
  2128. smalltalk.HLSelectorsCache);
  2129. smalltalk.addMethod(
  2130. "_onMethodRemoved_",
  2131. smalltalk.method({
  2132. selector: "onMethodRemoved:",
  2133. fn: function (aMethod){
  2134. var self=this;
  2135. return smalltalk.withContext(function($ctx1) { _st(self)._invalidateCacheFor_(aMethod);
  2136. return self}, function($ctx1) {$ctx1.fill(self,"onMethodRemoved:",{aMethod:aMethod}, smalltalk.HLSelectorsCache)})},
  2137. messageSends: ["invalidateCacheFor:"]}),
  2138. smalltalk.HLSelectorsCache);
  2139. smalltalk.HLSelectorsCache.klass.iVarNames = ['current'];
  2140. smalltalk.addMethod(
  2141. "_current",
  2142. smalltalk.method({
  2143. selector: "current",
  2144. fn: function (){
  2145. var self=this;
  2146. return smalltalk.withContext(function($ctx1) { var $2,$1;
  2147. $2=self["@current"];
  2148. if(($receiver = $2) == nil || $receiver == undefined){
  2149. self["@current"]=smalltalk.Object.klass.fn.prototype._new.apply(_st(self), []);
  2150. $1=self["@current"];
  2151. } else {
  2152. $1=$2;
  2153. };
  2154. return $1;
  2155. }, function($ctx1) {$ctx1.fill(self,"current",{}, smalltalk.HLSelectorsCache.klass)})},
  2156. messageSends: ["ifNil:", "new"]}),
  2157. smalltalk.HLSelectorsCache.klass);
  2158. smalltalk.addMethod(
  2159. "_flush",
  2160. smalltalk.method({
  2161. selector: "flush",
  2162. fn: function (){
  2163. var self=this;
  2164. return smalltalk.withContext(function($ctx1) { self["@current"]=nil;
  2165. return self}, function($ctx1) {$ctx1.fill(self,"flush",{}, smalltalk.HLSelectorsCache.klass)})},
  2166. messageSends: []}),
  2167. smalltalk.HLSelectorsCache.klass);
  2168. smalltalk.addMethod(
  2169. "_new",
  2170. smalltalk.method({
  2171. selector: "new",
  2172. fn: function (){
  2173. var self=this;
  2174. return smalltalk.withContext(function($ctx1) { _st(self)._shouldNotImplement();
  2175. return self}, function($ctx1) {$ctx1.fill(self,"new",{}, smalltalk.HLSelectorsCache.klass)})},
  2176. messageSends: ["shouldNotImplement"]}),
  2177. smalltalk.HLSelectorsCache.klass);
  2178. smalltalk.addMethod(
  2179. "_isOverridden",
  2180. smalltalk.method({
  2181. selector: "isOverridden",
  2182. fn: function (){
  2183. var self=this;
  2184. var selector;
  2185. return smalltalk.withContext(function($ctx1) { var $1;
  2186. var $early={};
  2187. try {
  2188. selector=_st(self)._selector();
  2189. _st(_st(self)._methodClass())._allSubclassesDo_((function(each){
  2190. return smalltalk.withContext(function($ctx2) { $1=_st(each)._includesSelector_(selector);
  2191. if(smalltalk.assert($1)){
  2192. throw $early=[true];
  2193. };
  2194. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1)})}));
  2195. return false;
  2196. }
  2197. catch(e) {if(e===$early)return e[0]; throw e}
  2198. }, function($ctx1) {$ctx1.fill(self,"isOverridden",{selector:selector}, smalltalk.CompiledMethod)})},
  2199. messageSends: ["selector", "allSubclassesDo:", "ifTrue:", "includesSelector:", "methodClass"]}),
  2200. smalltalk.CompiledMethod);
  2201. smalltalk.addMethod(
  2202. "_isOverride",
  2203. smalltalk.method({
  2204. selector: "isOverride",
  2205. fn: function (){
  2206. var self=this;
  2207. var superclass;
  2208. return smalltalk.withContext(function($ctx1) { var $1,$2;
  2209. superclass=_st(_st(self)._methodClass())._superclass();
  2210. $1=superclass;
  2211. if(($receiver = $1) == nil || $receiver == undefined){
  2212. return false;
  2213. } else {
  2214. $1;
  2215. };
  2216. $2=_st(_st(_st(_st(self)._methodClass())._superclass())._lookupSelector_(_st(self)._selector()))._isNil();
  2217. return $2;
  2218. }, function($ctx1) {$ctx1.fill(self,"isOverride",{superclass:superclass}, smalltalk.CompiledMethod)})},
  2219. messageSends: ["superclass", "methodClass", "ifNil:", "isNil", "lookupSelector:", "selector"]}),
  2220. smalltalk.CompiledMethod);