1
0

Helios-Browser.deploy.js 113 KB

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