Helios-Browser.deploy.js 121 KB

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