Helios-Browser.deploy.js 127 KB

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