Helios-References.js 39 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138
  1. define("helios/Helios-References", ["amber_vm/smalltalk", "amber_vm/nil", "amber_vm/_st", "amber_vm/globals", "amber_core/Kernel-Objects", "helios/Helios-Core"], function(smalltalk,nil,_st, globals){
  2. smalltalk.addPackage('Helios-References');
  3. smalltalk.packages["Helios-References"].transport = {"type":"amd","amdNamespace":"helios"};
  4. smalltalk.addClass('HLMethodReference', globals.Object, ['selector', 'methodClass'], 'Helios-References');
  5. smalltalk.addMethod(
  6. smalltalk.method({
  7. selector: "initializeFromMethod:",
  8. protocol: 'initialization',
  9. fn: function (aCompiledMethod){
  10. var self=this;
  11. return smalltalk.withContext(function($ctx1) {
  12. var $1;
  13. self._selector_(_st(aCompiledMethod)._selector());
  14. $1=self._methodClass_(_st(aCompiledMethod)._methodClass());
  15. return self}, function($ctx1) {$ctx1.fill(self,"initializeFromMethod:",{aCompiledMethod:aCompiledMethod},globals.HLMethodReference)})},
  16. args: ["aCompiledMethod"],
  17. source: "initializeFromMethod: aCompiledMethod\x0a\x09self\x0a\x09\x09selector: aCompiledMethod selector;\x0a\x09\x09methodClass: aCompiledMethod methodClass",
  18. messageSends: ["selector:", "selector", "methodClass:", "methodClass"],
  19. referencedClasses: []
  20. }),
  21. globals.HLMethodReference);
  22. smalltalk.addMethod(
  23. smalltalk.method({
  24. selector: "method",
  25. protocol: 'accessing',
  26. fn: function (){
  27. var self=this;
  28. return smalltalk.withContext(function($ctx1) {
  29. var $1;
  30. $1=_st(self._methodClass())._methodAt_(self._selector());
  31. return $1;
  32. }, function($ctx1) {$ctx1.fill(self,"method",{},globals.HLMethodReference)})},
  33. args: [],
  34. source: "method\x0a\x09^ self methodClass methodAt: self selector",
  35. messageSends: ["methodAt:", "methodClass", "selector"],
  36. referencedClasses: []
  37. }),
  38. globals.HLMethodReference);
  39. smalltalk.addMethod(
  40. smalltalk.method({
  41. selector: "methodClass",
  42. protocol: 'accessing',
  43. fn: function (){
  44. var self=this;
  45. var $1;
  46. $1=self["@methodClass"];
  47. return $1;
  48. },
  49. args: [],
  50. source: "methodClass\x0a\x09^ methodClass",
  51. messageSends: [],
  52. referencedClasses: []
  53. }),
  54. globals.HLMethodReference);
  55. smalltalk.addMethod(
  56. smalltalk.method({
  57. selector: "methodClass:",
  58. protocol: 'accessing',
  59. fn: function (aClass){
  60. var self=this;
  61. self["@methodClass"]=aClass;
  62. return self},
  63. args: ["aClass"],
  64. source: "methodClass: aClass\x0a\x09methodClass := aClass",
  65. messageSends: [],
  66. referencedClasses: []
  67. }),
  68. globals.HLMethodReference);
  69. smalltalk.addMethod(
  70. smalltalk.method({
  71. selector: "selector",
  72. protocol: 'accessing',
  73. fn: function (){
  74. var self=this;
  75. var $1;
  76. $1=self["@selector"];
  77. return $1;
  78. },
  79. args: [],
  80. source: "selector\x0a\x09^ selector",
  81. messageSends: [],
  82. referencedClasses: []
  83. }),
  84. globals.HLMethodReference);
  85. smalltalk.addMethod(
  86. smalltalk.method({
  87. selector: "selector:",
  88. protocol: 'accessing',
  89. fn: function (aString){
  90. var self=this;
  91. self["@selector"]=aString;
  92. return self},
  93. args: ["aString"],
  94. source: "selector: aString\x0a\x09selector := aString",
  95. messageSends: [],
  96. referencedClasses: []
  97. }),
  98. globals.HLMethodReference);
  99. smalltalk.addMethod(
  100. smalltalk.method({
  101. selector: "source",
  102. protocol: 'accessing',
  103. fn: function (){
  104. var self=this;
  105. return smalltalk.withContext(function($ctx1) {
  106. var $1;
  107. $1=_st(self._method())._source();
  108. return $1;
  109. }, function($ctx1) {$ctx1.fill(self,"source",{},globals.HLMethodReference)})},
  110. args: [],
  111. source: "source\x0a\x09^ self method source",
  112. messageSends: ["source", "method"],
  113. referencedClasses: []
  114. }),
  115. globals.HLMethodReference);
  116. smalltalk.addMethod(
  117. smalltalk.method({
  118. selector: "on:",
  119. protocol: 'instance creation',
  120. fn: function (aCompiledMethod){
  121. var self=this;
  122. return smalltalk.withContext(function($ctx1) {
  123. var $2,$3,$1;
  124. $2=self._new();
  125. _st($2)._initializeFromMethod_(aCompiledMethod);
  126. $3=_st($2)._yourself();
  127. $1=$3;
  128. return $1;
  129. }, function($ctx1) {$ctx1.fill(self,"on:",{aCompiledMethod:aCompiledMethod},globals.HLMethodReference.klass)})},
  130. args: ["aCompiledMethod"],
  131. source: "on: aCompiledMethod\x0a\x09^ self new\x0a\x09\x09initializeFromMethod: aCompiledMethod;\x0a\x09\x09yourself",
  132. messageSends: ["initializeFromMethod:", "new", "yourself"],
  133. referencedClasses: []
  134. }),
  135. globals.HLMethodReference.klass);
  136. smalltalk.addClass('HLReferences', globals.HLWidget, ['model', 'sendersListWidget', 'implementorsListWidget', 'classReferencesListWidget', 'regexpListWidget', 'sourceCodeWidget'], 'Helios-References');
  137. smalltalk.addMethod(
  138. smalltalk.method({
  139. selector: "classReferencesListWidget",
  140. protocol: 'accessing',
  141. fn: function (){
  142. var self=this;
  143. function $HLClassReferencesListWidget(){return globals.HLClassReferencesListWidget||(typeof HLClassReferencesListWidget=="undefined"?nil:HLClassReferencesListWidget)}
  144. return smalltalk.withContext(function($ctx1) {
  145. var $2,$1,$receiver;
  146. $2=self["@classReferencesListWidget"];
  147. if(($receiver = $2) == null || $receiver.isNil){
  148. self["@classReferencesListWidget"]=_st($HLClassReferencesListWidget())._on_(self._model());
  149. self["@classReferencesListWidget"];
  150. $1=_st(self["@classReferencesListWidget"])._next_(self._regexpListWidget());
  151. } else {
  152. $1=$2;
  153. };
  154. return $1;
  155. }, function($ctx1) {$ctx1.fill(self,"classReferencesListWidget",{},globals.HLReferences)})},
  156. args: [],
  157. source: "classReferencesListWidget\x0a\x09^ classReferencesListWidget ifNil: [\x0a \x09classReferencesListWidget := HLClassReferencesListWidget on: self model.\x0a\x09\x09classReferencesListWidget next: self regexpListWidget ]",
  158. messageSends: ["ifNil:", "on:", "model", "next:", "regexpListWidget"],
  159. referencedClasses: ["HLClassReferencesListWidget"]
  160. }),
  161. globals.HLReferences);
  162. smalltalk.addMethod(
  163. smalltalk.method({
  164. selector: "implementorsListWidget",
  165. protocol: 'accessing',
  166. fn: function (){
  167. var self=this;
  168. function $HLImplementorsListWidget(){return globals.HLImplementorsListWidget||(typeof HLImplementorsListWidget=="undefined"?nil:HLImplementorsListWidget)}
  169. return smalltalk.withContext(function($ctx1) {
  170. var $2,$1,$receiver;
  171. $2=self["@implementorsListWidget"];
  172. if(($receiver = $2) == null || $receiver.isNil){
  173. self["@implementorsListWidget"]=_st($HLImplementorsListWidget())._on_(self._model());
  174. self["@implementorsListWidget"];
  175. $1=_st(self["@implementorsListWidget"])._next_(self._classReferencesListWidget());
  176. } else {
  177. $1=$2;
  178. };
  179. return $1;
  180. }, function($ctx1) {$ctx1.fill(self,"implementorsListWidget",{},globals.HLReferences)})},
  181. args: [],
  182. source: "implementorsListWidget\x0a\x09^ implementorsListWidget ifNil: [\x0a \x09implementorsListWidget := HLImplementorsListWidget on: self model.\x0a\x09\x09implementorsListWidget next: self classReferencesListWidget ]",
  183. messageSends: ["ifNil:", "on:", "model", "next:", "classReferencesListWidget"],
  184. referencedClasses: ["HLImplementorsListWidget"]
  185. }),
  186. globals.HLReferences);
  187. smalltalk.addMethod(
  188. smalltalk.method({
  189. selector: "model",
  190. protocol: 'accessing',
  191. fn: function (){
  192. var self=this;
  193. function $HLReferencesModel(){return globals.HLReferencesModel||(typeof HLReferencesModel=="undefined"?nil:HLReferencesModel)}
  194. return smalltalk.withContext(function($ctx1) {
  195. var $2,$3,$4,$1,$receiver;
  196. $2=self["@model"];
  197. if(($receiver = $2) == null || $receiver.isNil){
  198. $3=_st($HLReferencesModel())._new();
  199. _st($3)._environment_(_st(self._manager())._environment());
  200. $4=_st($3)._yourself();
  201. self["@model"]=$4;
  202. $1=self["@model"];
  203. } else {
  204. $1=$2;
  205. };
  206. return $1;
  207. }, function($ctx1) {$ctx1.fill(self,"model",{},globals.HLReferences)})},
  208. args: [],
  209. source: "model\x0a\x09^ model ifNil: [\x0a\x09\x09model := (HLReferencesModel new\x0a\x09\x09\x09environment: self manager environment;\x0a\x09\x09\x09yourself) ]",
  210. messageSends: ["ifNil:", "environment:", "new", "environment", "manager", "yourself"],
  211. referencedClasses: ["HLReferencesModel"]
  212. }),
  213. globals.HLReferences);
  214. smalltalk.addMethod(
  215. smalltalk.method({
  216. selector: "model:",
  217. protocol: 'accessing',
  218. fn: function (aModel){
  219. var self=this;
  220. self["@model"]=aModel;
  221. return self},
  222. args: ["aModel"],
  223. source: "model: aModel\x0a\x09model := aModel",
  224. messageSends: [],
  225. referencedClasses: []
  226. }),
  227. globals.HLReferences);
  228. smalltalk.addMethod(
  229. smalltalk.method({
  230. selector: "regexpListWidget",
  231. protocol: 'accessing',
  232. fn: function (){
  233. var self=this;
  234. function $HLRegexpListWidget(){return globals.HLRegexpListWidget||(typeof HLRegexpListWidget=="undefined"?nil:HLRegexpListWidget)}
  235. return smalltalk.withContext(function($ctx1) {
  236. var $2,$1,$receiver;
  237. $2=self["@regexpListWidget"];
  238. if(($receiver = $2) == null || $receiver.isNil){
  239. self["@regexpListWidget"]=_st($HLRegexpListWidget())._on_(self._model());
  240. self["@regexpListWidget"];
  241. $1=_st(self["@regexpListWidget"])._next_(self._sourceCodeWidget());
  242. } else {
  243. $1=$2;
  244. };
  245. return $1;
  246. }, function($ctx1) {$ctx1.fill(self,"regexpListWidget",{},globals.HLReferences)})},
  247. args: [],
  248. source: "regexpListWidget\x0a\x09^ regexpListWidget ifNil: [\x0a \x09regexpListWidget := HLRegexpListWidget on: self model.\x0a\x09\x09regexpListWidget next: self sourceCodeWidget ]",
  249. messageSends: ["ifNil:", "on:", "model", "next:", "sourceCodeWidget"],
  250. referencedClasses: ["HLRegexpListWidget"]
  251. }),
  252. globals.HLReferences);
  253. smalltalk.addMethod(
  254. smalltalk.method({
  255. selector: "registerBindingsOn:",
  256. protocol: 'actions',
  257. fn: function (aBindingGroup){
  258. var self=this;
  259. function $HLToolCommand(){return globals.HLToolCommand||(typeof HLToolCommand=="undefined"?nil:HLToolCommand)}
  260. return smalltalk.withContext(function($ctx1) {
  261. _st($HLToolCommand())._registerConcreteClassesOn_for_(aBindingGroup,self._model());
  262. return self}, function($ctx1) {$ctx1.fill(self,"registerBindingsOn:",{aBindingGroup:aBindingGroup},globals.HLReferences)})},
  263. args: ["aBindingGroup"],
  264. source: "registerBindingsOn: aBindingGroup\x0a\x09HLToolCommand \x0a\x09\x09registerConcreteClassesOn: aBindingGroup \x0a\x09\x09for: self model",
  265. messageSends: ["registerConcreteClassesOn:for:", "model"],
  266. referencedClasses: ["HLToolCommand"]
  267. }),
  268. globals.HLReferences);
  269. smalltalk.addMethod(
  270. smalltalk.method({
  271. selector: "renderContentOn:",
  272. protocol: 'rendering',
  273. fn: function (html){
  274. var self=this;
  275. function $HLContainer(){return globals.HLContainer||(typeof HLContainer=="undefined"?nil:HLContainer)}
  276. function $HLHorizontalSplitter(){return globals.HLHorizontalSplitter||(typeof HLHorizontalSplitter=="undefined"?nil:HLHorizontalSplitter)}
  277. function $HLVerticalSplitter(){return globals.HLVerticalSplitter||(typeof HLVerticalSplitter=="undefined"?nil:HLVerticalSplitter)}
  278. return smalltalk.withContext(function($ctx1) {
  279. var $5,$4,$3,$2,$1;
  280. $5=self._sendersListWidget();
  281. $ctx1.sendIdx["sendersListWidget"]=1;
  282. $4=_st($HLVerticalSplitter())._with_with_($5,self._implementorsListWidget());
  283. $ctx1.sendIdx["with:with:"]=3;
  284. $3=_st($HLVerticalSplitter())._with_with_($4,_st($HLVerticalSplitter())._with_with_(self._classReferencesListWidget(),self._regexpListWidget()));
  285. $ctx1.sendIdx["with:with:"]=2;
  286. $2=_st($HLHorizontalSplitter())._with_with_($3,self._sourceCodeWidget());
  287. $ctx1.sendIdx["with:with:"]=1;
  288. $1=_st($HLContainer())._with_($2);
  289. _st(html)._with_($1);
  290. $ctx1.sendIdx["with:"]=1;
  291. _st(self._sendersListWidget())._focus();
  292. return self}, function($ctx1) {$ctx1.fill(self,"renderContentOn:",{html:html},globals.HLReferences)})},
  293. args: ["html"],
  294. source: "renderContentOn: html\x0a\x09html with: (HLContainer with: (HLHorizontalSplitter \x0a \x09with: (HLVerticalSplitter\x0a \x09with: (HLVerticalSplitter\x0a \x09with: self sendersListWidget\x0a with: self implementorsListWidget)\x0a with: (HLVerticalSplitter\x0a \x09with: self classReferencesListWidget\x0a with: self regexpListWidget)) \x0a with: self sourceCodeWidget)).\x0a\x09\x0a\x09self sendersListWidget focus",
  295. messageSends: ["with:", "with:with:", "sendersListWidget", "implementorsListWidget", "classReferencesListWidget", "regexpListWidget", "sourceCodeWidget", "focus"],
  296. referencedClasses: ["HLContainer", "HLHorizontalSplitter", "HLVerticalSplitter"]
  297. }),
  298. globals.HLReferences);
  299. smalltalk.addMethod(
  300. smalltalk.method({
  301. selector: "search:",
  302. protocol: 'actions',
  303. fn: function (aString){
  304. var self=this;
  305. return smalltalk.withContext(function($ctx1) {
  306. _st(self._model())._search_(aString);
  307. self._setTabLabel_(aString);
  308. return self}, function($ctx1) {$ctx1.fill(self,"search:",{aString:aString},globals.HLReferences)})},
  309. args: ["aString"],
  310. source: "search: aString\x0a\x09self model search: aString.\x0a\x09self setTabLabel: aString",
  311. messageSends: ["search:", "model", "setTabLabel:"],
  312. referencedClasses: []
  313. }),
  314. globals.HLReferences);
  315. smalltalk.addMethod(
  316. smalltalk.method({
  317. selector: "sendersListWidget",
  318. protocol: 'accessing',
  319. fn: function (){
  320. var self=this;
  321. function $HLSendersListWidget(){return globals.HLSendersListWidget||(typeof HLSendersListWidget=="undefined"?nil:HLSendersListWidget)}
  322. return smalltalk.withContext(function($ctx1) {
  323. var $2,$1,$receiver;
  324. $2=self["@sendersListWidget"];
  325. if(($receiver = $2) == null || $receiver.isNil){
  326. self["@sendersListWidget"]=_st($HLSendersListWidget())._on_(self._model());
  327. self["@sendersListWidget"];
  328. $1=_st(self["@sendersListWidget"])._next_(self._implementorsListWidget());
  329. } else {
  330. $1=$2;
  331. };
  332. return $1;
  333. }, function($ctx1) {$ctx1.fill(self,"sendersListWidget",{},globals.HLReferences)})},
  334. args: [],
  335. source: "sendersListWidget\x0a\x09^ sendersListWidget ifNil: [\x0a \x09sendersListWidget := HLSendersListWidget on: self model.\x0a\x09\x09sendersListWidget next: self implementorsListWidget ]",
  336. messageSends: ["ifNil:", "on:", "model", "next:", "implementorsListWidget"],
  337. referencedClasses: ["HLSendersListWidget"]
  338. }),
  339. globals.HLReferences);
  340. smalltalk.addMethod(
  341. smalltalk.method({
  342. selector: "sourceCodeWidget",
  343. protocol: 'accessing',
  344. fn: function (){
  345. var self=this;
  346. function $HLBrowserCodeWidget(){return globals.HLBrowserCodeWidget||(typeof HLBrowserCodeWidget=="undefined"?nil:HLBrowserCodeWidget)}
  347. return smalltalk.withContext(function($ctx1) {
  348. var $2,$3,$4,$1,$receiver;
  349. $2=self["@sourceCodeWidget"];
  350. if(($receiver = $2) == null || $receiver.isNil){
  351. $3=_st($HLBrowserCodeWidget())._new();
  352. _st($3)._browserModel_(self._model());
  353. $4=_st($3)._yourself();
  354. self["@sourceCodeWidget"]=$4;
  355. $1=self["@sourceCodeWidget"];
  356. } else {
  357. $1=$2;
  358. };
  359. return $1;
  360. }, function($ctx1) {$ctx1.fill(self,"sourceCodeWidget",{},globals.HLReferences)})},
  361. args: [],
  362. source: "sourceCodeWidget\x0a\x09^ sourceCodeWidget ifNil: [\x0a \x09sourceCodeWidget := HLBrowserCodeWidget new\x0a\x09\x09\x09browserModel: self model;\x0a\x09\x09\x09yourself ]",
  363. messageSends: ["ifNil:", "browserModel:", "new", "model", "yourself"],
  364. referencedClasses: ["HLBrowserCodeWidget"]
  365. }),
  366. globals.HLReferences);
  367. smalltalk.addMethod(
  368. smalltalk.method({
  369. selector: "canBeOpenAsTab",
  370. protocol: 'testing',
  371. fn: function (){
  372. var self=this;
  373. return false;
  374. },
  375. args: [],
  376. source: "canBeOpenAsTab\x0a\x09^ false",
  377. messageSends: [],
  378. referencedClasses: []
  379. }),
  380. globals.HLReferences.klass);
  381. smalltalk.addMethod(
  382. smalltalk.method({
  383. selector: "tabClass",
  384. protocol: 'accessing',
  385. fn: function (){
  386. var self=this;
  387. return "references";
  388. },
  389. args: [],
  390. source: "tabClass\x0a\x09^ 'references'",
  391. messageSends: [],
  392. referencedClasses: []
  393. }),
  394. globals.HLReferences.klass);
  395. smalltalk.addMethod(
  396. smalltalk.method({
  397. selector: "tabLabel",
  398. protocol: 'accessing',
  399. fn: function (){
  400. var self=this;
  401. return "References";
  402. },
  403. args: [],
  404. source: "tabLabel\x0a\x09^ 'References'",
  405. messageSends: [],
  406. referencedClasses: []
  407. }),
  408. globals.HLReferences.klass);
  409. smalltalk.addMethod(
  410. smalltalk.method({
  411. selector: "tabPriority",
  412. protocol: 'accessing',
  413. fn: function (){
  414. var self=this;
  415. return (100);
  416. },
  417. args: [],
  418. source: "tabPriority\x0a\x09^ 100",
  419. messageSends: [],
  420. referencedClasses: []
  421. }),
  422. globals.HLReferences.klass);
  423. smalltalk.addClass('HLReferencesListWidget', globals.HLToolListWidget, [], 'Helios-References');
  424. smalltalk.addMethod(
  425. smalltalk.method({
  426. selector: "activateListItem:",
  427. protocol: 'actions',
  428. fn: function (anItem){
  429. var self=this;
  430. return smalltalk.withContext(function($ctx1) {
  431. _st(self._model())._withChangesDo_((function(){
  432. return smalltalk.withContext(function($ctx2) {
  433. return ($ctx2.supercall = true, globals.HLReferencesListWidget.superclass.fn.prototype._activateListItem_.apply(_st(self), [anItem]));
  434. $ctx2.supercall = false;
  435. }, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)})}));
  436. return self}, function($ctx1) {$ctx1.fill(self,"activateListItem:",{anItem:anItem},globals.HLReferencesListWidget)})},
  437. args: ["anItem"],
  438. source: "activateListItem: anItem\x0a\x09self model withChangesDo: [ super activateListItem: anItem ]",
  439. messageSends: ["withChangesDo:", "model", "activateListItem:"],
  440. referencedClasses: []
  441. }),
  442. globals.HLReferencesListWidget);
  443. smalltalk.addMethod(
  444. smalltalk.method({
  445. selector: "commandCategory",
  446. protocol: 'accessing',
  447. fn: function (){
  448. var self=this;
  449. return "Methods";
  450. },
  451. args: [],
  452. source: "commandCategory\x0a\x09^ 'Methods'",
  453. messageSends: [],
  454. referencedClasses: []
  455. }),
  456. globals.HLReferencesListWidget);
  457. smalltalk.addMethod(
  458. smalltalk.method({
  459. selector: "label",
  460. protocol: 'accessing',
  461. fn: function (){
  462. var self=this;
  463. return "List";
  464. },
  465. args: [],
  466. source: "label\x0a\x09^ 'List'",
  467. messageSends: [],
  468. referencedClasses: []
  469. }),
  470. globals.HLReferencesListWidget);
  471. smalltalk.addMethod(
  472. smalltalk.method({
  473. selector: "observeModel",
  474. protocol: 'actions',
  475. fn: function (){
  476. var self=this;
  477. function $HLSearchReferences(){return globals.HLSearchReferences||(typeof HLSearchReferences=="undefined"?nil:HLSearchReferences)}
  478. function $HLMethodSelected(){return globals.HLMethodSelected||(typeof HLMethodSelected=="undefined"?nil:HLMethodSelected)}
  479. return smalltalk.withContext(function($ctx1) {
  480. var $1,$2;
  481. $1=_st(self._model())._announcer();
  482. _st($1)._on_do_($HLSearchReferences(),(function(ann){
  483. return smalltalk.withContext(function($ctx2) {
  484. return self._onSearchReferences_(_st(ann)._searchString());
  485. }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1,1)})}));
  486. $ctx1.sendIdx["on:do:"]=1;
  487. $2=_st($1)._on_do_($HLMethodSelected(),(function(ann){
  488. return smalltalk.withContext(function($ctx2) {
  489. return self._onMethodSelected_(_st(ann)._item());
  490. }, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1,2)})}));
  491. return self}, function($ctx1) {$ctx1.fill(self,"observeModel",{},globals.HLReferencesListWidget)})},
  492. args: [],
  493. source: "observeModel\x0a\x09self model announcer\x0a\x09\x09on: HLSearchReferences\x0a\x09\x09do: [ :ann | self onSearchReferences: ann searchString ];\x0a\x09\x09on: HLMethodSelected\x0a\x09\x09do: [ :ann | self onMethodSelected: ann item ]",
  494. messageSends: ["on:do:", "announcer", "model", "onSearchReferences:", "searchString", "onMethodSelected:", "item"],
  495. referencedClasses: ["HLSearchReferences", "HLMethodSelected"]
  496. }),
  497. globals.HLReferencesListWidget);
  498. smalltalk.addMethod(
  499. smalltalk.method({
  500. selector: "onMethodSelected:",
  501. protocol: 'reactions',
  502. fn: function (aMethod){
  503. var self=this;
  504. return smalltalk.withContext(function($ctx1) {
  505. var $1,$2,$3,$receiver;
  506. var $early={};
  507. try {
  508. if(($receiver = aMethod) == null || $receiver.isNil){
  509. return self;
  510. } else {
  511. aMethod;
  512. };
  513. _st(self._items())._detect_ifNone_((function(each){
  514. return smalltalk.withContext(function($ctx2) {
  515. $1=_st(aMethod)._selector();
  516. $ctx2.sendIdx["selector"]=1;
  517. return _st(each).__eq($1);
  518. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,2)})}),(function(){
  519. throw $early=[self];
  520. }));
  521. $2=_st(aMethod)._selector();
  522. $ctx1.sendIdx["selector"]=2;
  523. self._selectedItem_($2);
  524. $3=self._activateItem_(_st(aMethod)._selector());
  525. return self}
  526. catch(e) {if(e===$early)return e[0]; throw e}
  527. }, function($ctx1) {$ctx1.fill(self,"onMethodSelected:",{aMethod:aMethod},globals.HLReferencesListWidget)})},
  528. args: ["aMethod"],
  529. source: "onMethodSelected: aMethod\x0a\x09aMethod ifNil: [ ^ self ].\x0a\x09self items detect: [ :each | each = aMethod selector ] ifNone: [ ^ self ].\x0a\x09\x0a\x09self \x0a\x09\x09selectedItem: aMethod selector;\x0a\x09\x09activateItem: aMethod selector",
  530. messageSends: ["ifNil:", "detect:ifNone:", "items", "=", "selector", "selectedItem:", "activateItem:"],
  531. referencedClasses: []
  532. }),
  533. globals.HLReferencesListWidget);
  534. smalltalk.addMethod(
  535. smalltalk.method({
  536. selector: "onSearchReferences:",
  537. protocol: 'reactions',
  538. fn: function (aString){
  539. var self=this;
  540. return smalltalk.withContext(function($ctx1) {
  541. self._subclassResponsibility();
  542. return self}, function($ctx1) {$ctx1.fill(self,"onSearchReferences:",{aString:aString},globals.HLReferencesListWidget)})},
  543. args: ["aString"],
  544. source: "onSearchReferences: aString\x0a\x09self subclassResponsibility",
  545. messageSends: ["subclassResponsibility"],
  546. referencedClasses: []
  547. }),
  548. globals.HLReferencesListWidget);
  549. smalltalk.addMethod(
  550. smalltalk.method({
  551. selector: "renderItemLabel:on:",
  552. protocol: 'rendering',
  553. fn: function (aMethod,html){
  554. var self=this;
  555. return smalltalk.withContext(function($ctx1) {
  556. var $1;
  557. $1=_st(_st(_st(_st(aMethod)._methodClass())._name()).__comma(" >> #")).__comma(_st(aMethod)._selector());
  558. $ctx1.sendIdx[","]=1;
  559. _st(html)._with_($1);
  560. return self}, function($ctx1) {$ctx1.fill(self,"renderItemLabel:on:",{aMethod:aMethod,html:html},globals.HLReferencesListWidget)})},
  561. args: ["aMethod", "html"],
  562. source: "renderItemLabel: aMethod on: html\x0a\x09html with: aMethod methodClass name, ' >> #', aMethod selector",
  563. messageSends: ["with:", ",", "name", "methodClass", "selector"],
  564. referencedClasses: []
  565. }),
  566. globals.HLReferencesListWidget);
  567. smalltalk.addMethod(
  568. smalltalk.method({
  569. selector: "selectItem:",
  570. protocol: 'actions',
  571. fn: function (aMethod){
  572. var self=this;
  573. return smalltalk.withContext(function($ctx1) {
  574. _st(self._model())._selectedMethod_(aMethod);
  575. return self}, function($ctx1) {$ctx1.fill(self,"selectItem:",{aMethod:aMethod},globals.HLReferencesListWidget)})},
  576. args: ["aMethod"],
  577. source: "selectItem: aMethod\x0a\x09self model selectedMethod: aMethod",
  578. messageSends: ["selectedMethod:", "model"],
  579. referencedClasses: []
  580. }),
  581. globals.HLReferencesListWidget);
  582. smalltalk.addMethod(
  583. smalltalk.method({
  584. selector: "on:",
  585. protocol: 'instance creation',
  586. fn: function (aModel){
  587. var self=this;
  588. return smalltalk.withContext(function($ctx1) {
  589. var $2,$3,$1;
  590. $2=self._new();
  591. _st($2)._model_(aModel);
  592. $3=_st($2)._yourself();
  593. $1=$3;
  594. return $1;
  595. }, function($ctx1) {$ctx1.fill(self,"on:",{aModel:aModel},globals.HLReferencesListWidget.klass)})},
  596. args: ["aModel"],
  597. source: "on: aModel\x0a\x09^ self new \x0a\x09\x09model: aModel; \x0a\x09\x09yourself",
  598. messageSends: ["model:", "new", "yourself"],
  599. referencedClasses: []
  600. }),
  601. globals.HLReferencesListWidget.klass);
  602. smalltalk.addClass('HLClassReferencesListWidget', globals.HLReferencesListWidget, [], 'Helios-References');
  603. smalltalk.addMethod(
  604. smalltalk.method({
  605. selector: "label",
  606. protocol: 'accessing',
  607. fn: function (){
  608. var self=this;
  609. return "Class references";
  610. },
  611. args: [],
  612. source: "label\x0a\x09^ 'Class references'",
  613. messageSends: [],
  614. referencedClasses: []
  615. }),
  616. globals.HLClassReferencesListWidget);
  617. smalltalk.addMethod(
  618. smalltalk.method({
  619. selector: "onSearchReferences:",
  620. protocol: 'reactions',
  621. fn: function (aString){
  622. var self=this;
  623. return smalltalk.withContext(function($ctx1) {
  624. self._selectItem_(nil);
  625. self._items_(_st(self._model())._classReferencesOf_(aString));
  626. self._refresh();
  627. return self}, function($ctx1) {$ctx1.fill(self,"onSearchReferences:",{aString:aString},globals.HLClassReferencesListWidget)})},
  628. args: ["aString"],
  629. source: "onSearchReferences: aString\x0a\x09self selectItem: nil.\x0a\x09self items: (self model classReferencesOf: aString).\x0a\x09self refresh",
  630. messageSends: ["selectItem:", "items:", "classReferencesOf:", "model", "refresh"],
  631. referencedClasses: []
  632. }),
  633. globals.HLClassReferencesListWidget);
  634. smalltalk.addClass('HLImplementorsListWidget', globals.HLReferencesListWidget, [], 'Helios-References');
  635. smalltalk.addMethod(
  636. smalltalk.method({
  637. selector: "label",
  638. protocol: 'accessing',
  639. fn: function (){
  640. var self=this;
  641. return "Implementors";
  642. },
  643. args: [],
  644. source: "label\x0a\x09^ 'Implementors'",
  645. messageSends: [],
  646. referencedClasses: []
  647. }),
  648. globals.HLImplementorsListWidget);
  649. smalltalk.addMethod(
  650. smalltalk.method({
  651. selector: "onSearchReferences:",
  652. protocol: 'reactions',
  653. fn: function (aString){
  654. var self=this;
  655. return smalltalk.withContext(function($ctx1) {
  656. self._selectItem_(nil);
  657. self._items_(_st(self._model())._implementorsOf_(aString));
  658. self._refresh();
  659. return self}, function($ctx1) {$ctx1.fill(self,"onSearchReferences:",{aString:aString},globals.HLImplementorsListWidget)})},
  660. args: ["aString"],
  661. source: "onSearchReferences: aString\x0a\x09self selectItem: nil.\x0a\x09self items: (self model implementorsOf: aString).\x0a\x09self refresh",
  662. messageSends: ["selectItem:", "items:", "implementorsOf:", "model", "refresh"],
  663. referencedClasses: []
  664. }),
  665. globals.HLImplementorsListWidget);
  666. smalltalk.addClass('HLRegexpListWidget', globals.HLReferencesListWidget, [], 'Helios-References');
  667. smalltalk.addMethod(
  668. smalltalk.method({
  669. selector: "label",
  670. protocol: 'accessing',
  671. fn: function (){
  672. var self=this;
  673. return "Source search";
  674. },
  675. args: [],
  676. source: "label\x0a\x09^ 'Source search'",
  677. messageSends: [],
  678. referencedClasses: []
  679. }),
  680. globals.HLRegexpListWidget);
  681. smalltalk.addMethod(
  682. smalltalk.method({
  683. selector: "onSearchReferences:",
  684. protocol: 'reactions',
  685. fn: function (aString){
  686. var self=this;
  687. return smalltalk.withContext(function($ctx1) {
  688. self._selectItem_(nil);
  689. self._items_(_st(self._model())._regexpReferencesOf_(aString));
  690. self._refresh();
  691. return self}, function($ctx1) {$ctx1.fill(self,"onSearchReferences:",{aString:aString},globals.HLRegexpListWidget)})},
  692. args: ["aString"],
  693. source: "onSearchReferences: aString\x0a\x09self selectItem: nil.\x0a\x09self items: (self model regexpReferencesOf: aString).\x0a\x09self refresh",
  694. messageSends: ["selectItem:", "items:", "regexpReferencesOf:", "model", "refresh"],
  695. referencedClasses: []
  696. }),
  697. globals.HLRegexpListWidget);
  698. smalltalk.addClass('HLSendersListWidget', globals.HLReferencesListWidget, [], 'Helios-References');
  699. smalltalk.addMethod(
  700. smalltalk.method({
  701. selector: "label",
  702. protocol: 'accessing',
  703. fn: function (){
  704. var self=this;
  705. return "Senders";
  706. },
  707. args: [],
  708. source: "label\x0a\x09^ 'Senders'",
  709. messageSends: [],
  710. referencedClasses: []
  711. }),
  712. globals.HLSendersListWidget);
  713. smalltalk.addMethod(
  714. smalltalk.method({
  715. selector: "onSearchReferences:",
  716. protocol: 'reactions',
  717. fn: function (aString){
  718. var self=this;
  719. return smalltalk.withContext(function($ctx1) {
  720. self._selectItem_(nil);
  721. self._items_(_st(self._model())._sendersOf_(aString));
  722. self._refresh();
  723. return self}, function($ctx1) {$ctx1.fill(self,"onSearchReferences:",{aString:aString},globals.HLSendersListWidget)})},
  724. args: ["aString"],
  725. source: "onSearchReferences: aString\x0a\x09self selectItem: nil.\x0a\x09self items: (self model sendersOf: aString).\x0a\x09self refresh",
  726. messageSends: ["selectItem:", "items:", "sendersOf:", "model", "refresh"],
  727. referencedClasses: []
  728. }),
  729. globals.HLSendersListWidget);
  730. smalltalk.addClass('HLReferencesModel', globals.HLToolModel, ['methodsCache', 'classesAndMetaclassesCache'], 'Helios-References');
  731. smalltalk.addMethod(
  732. smalltalk.method({
  733. selector: "allMethods",
  734. protocol: 'accessing',
  735. fn: function (){
  736. var self=this;
  737. return smalltalk.withContext(function($ctx1) {
  738. var $1;
  739. $1=self._methodsCache();
  740. return $1;
  741. }, function($ctx1) {$ctx1.fill(self,"allMethods",{},globals.HLReferencesModel)})},
  742. args: [],
  743. source: "allMethods\x0a\x09^ self methodsCache",
  744. messageSends: ["methodsCache"],
  745. referencedClasses: []
  746. }),
  747. globals.HLReferencesModel);
  748. smalltalk.addMethod(
  749. smalltalk.method({
  750. selector: "classReferencesOf:",
  751. protocol: 'accessing',
  752. fn: function (aString){
  753. var self=this;
  754. return smalltalk.withContext(function($ctx1) {
  755. var $1;
  756. $1=_st(self._allMethods())._select_((function(each){
  757. return smalltalk.withContext(function($ctx2) {
  758. return _st(_st(each)._referencedClasses())._includes_(aString);
  759. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)})}));
  760. return $1;
  761. }, function($ctx1) {$ctx1.fill(self,"classReferencesOf:",{aString:aString},globals.HLReferencesModel)})},
  762. args: ["aString"],
  763. source: "classReferencesOf: aString\x0a\x09\x22Answer all methods referencing the class named aString\x22\x0a\x09\x0a\x09^self allMethods select: [ :each |\x0a\x09\x09\x09(each referencedClasses includes: aString) ].",
  764. messageSends: ["select:", "allMethods", "includes:", "referencedClasses"],
  765. referencedClasses: []
  766. }),
  767. globals.HLReferencesModel);
  768. smalltalk.addMethod(
  769. smalltalk.method({
  770. selector: "classesAndMetaclasses",
  771. protocol: 'accessing',
  772. fn: function (){
  773. var self=this;
  774. return smalltalk.withContext(function($ctx1) {
  775. var $1;
  776. $1=self._classesAndMetaclassesCache();
  777. return $1;
  778. }, function($ctx1) {$ctx1.fill(self,"classesAndMetaclasses",{},globals.HLReferencesModel)})},
  779. args: [],
  780. source: "classesAndMetaclasses\x0a\x09^ self classesAndMetaclassesCache",
  781. messageSends: ["classesAndMetaclassesCache"],
  782. referencedClasses: []
  783. }),
  784. globals.HLReferencesModel);
  785. smalltalk.addMethod(
  786. smalltalk.method({
  787. selector: "classesAndMetaclassesCache",
  788. protocol: 'cache',
  789. fn: function (){
  790. var self=this;
  791. return smalltalk.withContext(function($ctx1) {
  792. var $1,$2,$receiver;
  793. $1=self["@classesAndMetaclassesCache"];
  794. if(($receiver = $1) == null || $receiver.isNil){
  795. self._updateClassesAndMetaclassesCache();
  796. } else {
  797. $1;
  798. };
  799. $2=self["@classesAndMetaclassesCache"];
  800. return $2;
  801. }, function($ctx1) {$ctx1.fill(self,"classesAndMetaclassesCache",{},globals.HLReferencesModel)})},
  802. args: [],
  803. source: "classesAndMetaclassesCache\x0a\x09classesAndMetaclassesCache ifNil: [ self updateClassesAndMetaclassesCache ].\x0a\x09^ classesAndMetaclassesCache",
  804. messageSends: ["ifNil:", "updateClassesAndMetaclassesCache"],
  805. referencedClasses: []
  806. }),
  807. globals.HLReferencesModel);
  808. smalltalk.addMethod(
  809. smalltalk.method({
  810. selector: "implementorsOf:",
  811. protocol: 'accessing',
  812. fn: function (aString){
  813. var self=this;
  814. return smalltalk.withContext(function($ctx1) {
  815. var $1;
  816. $1=_st(_st(self._allMethods())._select_((function(each){
  817. return smalltalk.withContext(function($ctx2) {
  818. return _st(_st(each)._selector()).__eq(aString);
  819. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)})})))._collect_((function(each){
  820. return smalltalk.withContext(function($ctx2) {
  821. return self._methodReferenceOn_(each);
  822. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,2)})}));
  823. return $1;
  824. }, function($ctx1) {$ctx1.fill(self,"implementorsOf:",{aString:aString},globals.HLReferencesModel)})},
  825. args: ["aString"],
  826. source: "implementorsOf: aString\x0a\x09^ (self allMethods select: [ :each |\x0a\x09\x09each selector = aString ])\x0a\x09\x09\x09collect: [ :each | self methodReferenceOn: each ]",
  827. messageSends: ["collect:", "select:", "allMethods", "=", "selector", "methodReferenceOn:"],
  828. referencedClasses: []
  829. }),
  830. globals.HLReferencesModel);
  831. smalltalk.addMethod(
  832. smalltalk.method({
  833. selector: "isReferencesModel",
  834. protocol: 'testing',
  835. fn: function (){
  836. var self=this;
  837. return true;
  838. },
  839. args: [],
  840. source: "isReferencesModel\x0a\x09^ true",
  841. messageSends: [],
  842. referencedClasses: []
  843. }),
  844. globals.HLReferencesModel);
  845. smalltalk.addMethod(
  846. smalltalk.method({
  847. selector: "methodReferenceOn:",
  848. protocol: 'accessing',
  849. fn: function (aCompiledMethod){
  850. var self=this;
  851. function $HLMethodReference(){return globals.HLMethodReference||(typeof HLMethodReference=="undefined"?nil:HLMethodReference)}
  852. return smalltalk.withContext(function($ctx1) {
  853. var $1;
  854. $1=_st($HLMethodReference())._on_(aCompiledMethod);
  855. return $1;
  856. }, function($ctx1) {$ctx1.fill(self,"methodReferenceOn:",{aCompiledMethod:aCompiledMethod},globals.HLReferencesModel)})},
  857. args: ["aCompiledMethod"],
  858. source: "methodReferenceOn: aCompiledMethod\x0a\x09^ HLMethodReference on: aCompiledMethod",
  859. messageSends: ["on:"],
  860. referencedClasses: ["HLMethodReference"]
  861. }),
  862. globals.HLReferencesModel);
  863. smalltalk.addMethod(
  864. smalltalk.method({
  865. selector: "methodsCache",
  866. protocol: 'cache',
  867. fn: function (){
  868. var self=this;
  869. return smalltalk.withContext(function($ctx1) {
  870. var $1,$2,$receiver;
  871. $1=self["@methodsCache"];
  872. if(($receiver = $1) == null || $receiver.isNil){
  873. self._updateMethodsCache();
  874. } else {
  875. $1;
  876. };
  877. $2=self["@methodsCache"];
  878. return $2;
  879. }, function($ctx1) {$ctx1.fill(self,"methodsCache",{},globals.HLReferencesModel)})},
  880. args: [],
  881. source: "methodsCache\x0a\x09methodsCache ifNil: [ self updateMethodsCache ].\x0a\x09^ methodsCache",
  882. messageSends: ["ifNil:", "updateMethodsCache"],
  883. referencedClasses: []
  884. }),
  885. globals.HLReferencesModel);
  886. smalltalk.addMethod(
  887. smalltalk.method({
  888. selector: "openClassNamed:",
  889. protocol: 'actions',
  890. fn: function (aString){
  891. var self=this;
  892. var browser;
  893. function $HLBrowser(){return globals.HLBrowser||(typeof HLBrowser=="undefined"?nil:HLBrowser)}
  894. return smalltalk.withContext(function($ctx1) {
  895. self._withChangesDo_((function(){
  896. return smalltalk.withContext(function($ctx2) {
  897. browser=_st($HLBrowser())._openAsTab();
  898. browser;
  899. return _st(browser)._openClassNamed_(aString);
  900. }, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)})}));
  901. return self}, function($ctx1) {$ctx1.fill(self,"openClassNamed:",{aString:aString,browser:browser},globals.HLReferencesModel)})},
  902. args: ["aString"],
  903. source: "openClassNamed: aString\x0a\x09| browser |\x0a\x09\x0a\x09self withChangesDo: [\x0a\x09\x09browser := HLBrowser openAsTab.\x0a\x09\x09browser openClassNamed: aString ]",
  904. messageSends: ["withChangesDo:", "openAsTab", "openClassNamed:"],
  905. referencedClasses: ["HLBrowser"]
  906. }),
  907. globals.HLReferencesModel);
  908. smalltalk.addMethod(
  909. smalltalk.method({
  910. selector: "openMethod",
  911. protocol: 'actions',
  912. fn: function (){
  913. var self=this;
  914. var browser;
  915. function $HLBrowser(){return globals.HLBrowser||(typeof HLBrowser=="undefined"?nil:HLBrowser)}
  916. return smalltalk.withContext(function($ctx1) {
  917. var $1,$receiver;
  918. $1=self._selectedMethod();
  919. $ctx1.sendIdx["selectedMethod"]=1;
  920. if(($receiver = $1) == null || $receiver.isNil){
  921. return self;
  922. } else {
  923. $1;
  924. };
  925. self._withChangesDo_((function(){
  926. return smalltalk.withContext(function($ctx2) {
  927. browser=_st($HLBrowser())._openAsTab();
  928. browser;
  929. return _st(browser)._openMethod_(self._selectedMethod());
  930. }, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)})}));
  931. return self}, function($ctx1) {$ctx1.fill(self,"openMethod",{browser:browser},globals.HLReferencesModel)})},
  932. args: [],
  933. source: "openMethod\x0a\x09| browser |\x0a\x09\x0a\x09self selectedMethod ifNil: [ ^ self ].\x0a\x09\x0a\x09self withChangesDo: [\x0a\x09\x09browser := HLBrowser openAsTab.\x0a\x09\x09browser openMethod: self selectedMethod ]",
  934. messageSends: ["ifNil:", "selectedMethod", "withChangesDo:", "openAsTab", "openMethod:"],
  935. referencedClasses: ["HLBrowser"]
  936. }),
  937. globals.HLReferencesModel);
  938. smalltalk.addMethod(
  939. smalltalk.method({
  940. selector: "regexpReferencesOf:",
  941. protocol: 'accessing',
  942. fn: function (aString){
  943. var self=this;
  944. return smalltalk.withContext(function($ctx1) {
  945. var $1;
  946. $1=_st(_st(self._allMethods())._select_((function(each){
  947. return smalltalk.withContext(function($ctx2) {
  948. return _st(_st(each)._source())._match_(aString);
  949. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)})})))._collect_((function(each){
  950. return smalltalk.withContext(function($ctx2) {
  951. return self._methodReferenceOn_(each);
  952. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,2)})}));
  953. return $1;
  954. }, function($ctx1) {$ctx1.fill(self,"regexpReferencesOf:",{aString:aString},globals.HLReferencesModel)})},
  955. args: ["aString"],
  956. source: "regexpReferencesOf: aString\x0a\x09^ (self allMethods select: [ :each |\x0a\x09\x09each source match: aString ])\x0a\x09\x09\x09collect: [ :each | self methodReferenceOn: each ]",
  957. messageSends: ["collect:", "select:", "allMethods", "match:", "source", "methodReferenceOn:"],
  958. referencedClasses: []
  959. }),
  960. globals.HLReferencesModel);
  961. smalltalk.addMethod(
  962. smalltalk.method({
  963. selector: "search:",
  964. protocol: 'actions',
  965. fn: function (aString){
  966. var self=this;
  967. function $HLSearchReferences(){return globals.HLSearchReferences||(typeof HLSearchReferences=="undefined"?nil:HLSearchReferences)}
  968. return smalltalk.withContext(function($ctx1) {
  969. var $1,$2;
  970. self._updateCaches();
  971. $1=_st($HLSearchReferences())._new();
  972. _st($1)._searchString_(aString);
  973. $2=_st($1)._yourself();
  974. _st(self._announcer())._announce_($2);
  975. return self}, function($ctx1) {$ctx1.fill(self,"search:",{aString:aString},globals.HLReferencesModel)})},
  976. args: ["aString"],
  977. source: "search: aString\x0a\x09self updateCaches.\x0a\x09\x0a\x09self announcer announce: (HLSearchReferences new\x0a\x09\x09searchString: aString;\x0a\x09\x09yourself)",
  978. messageSends: ["updateCaches", "announce:", "announcer", "searchString:", "new", "yourself"],
  979. referencedClasses: ["HLSearchReferences"]
  980. }),
  981. globals.HLReferencesModel);
  982. smalltalk.addMethod(
  983. smalltalk.method({
  984. selector: "sendersOf:",
  985. protocol: 'accessing',
  986. fn: function (aString){
  987. var self=this;
  988. return smalltalk.withContext(function($ctx1) {
  989. var $1;
  990. $1=_st(_st(self._allMethods())._select_((function(each){
  991. return smalltalk.withContext(function($ctx2) {
  992. return _st(_st(each)._messageSends())._includes_(aString);
  993. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)})})))._collect_((function(each){
  994. return smalltalk.withContext(function($ctx2) {
  995. return self._methodReferenceOn_(each);
  996. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,2)})}));
  997. return $1;
  998. }, function($ctx1) {$ctx1.fill(self,"sendersOf:",{aString:aString},globals.HLReferencesModel)})},
  999. args: ["aString"],
  1000. source: "sendersOf: aString\x0a\x09^ (self allMethods select: [ :each |\x0a\x09\x09each messageSends includes: aString ])\x0a\x09\x09\x09collect: [ :each | self methodReferenceOn: each ]",
  1001. messageSends: ["collect:", "select:", "allMethods", "includes:", "messageSends", "methodReferenceOn:"],
  1002. referencedClasses: []
  1003. }),
  1004. globals.HLReferencesModel);
  1005. smalltalk.addMethod(
  1006. smalltalk.method({
  1007. selector: "updateCaches",
  1008. protocol: 'cache',
  1009. fn: function (){
  1010. var self=this;
  1011. return smalltalk.withContext(function($ctx1) {
  1012. var $1;
  1013. self._updateClassesAndMetaclassesCache();
  1014. $1=self._updateMethodsCache();
  1015. return self}, function($ctx1) {$ctx1.fill(self,"updateCaches",{},globals.HLReferencesModel)})},
  1016. args: [],
  1017. source: "updateCaches\x0a\x09self \x0a\x09\x09updateClassesAndMetaclassesCache;\x0a\x09\x09updateMethodsCache",
  1018. messageSends: ["updateClassesAndMetaclassesCache", "updateMethodsCache"],
  1019. referencedClasses: []
  1020. }),
  1021. globals.HLReferencesModel);
  1022. smalltalk.addMethod(
  1023. smalltalk.method({
  1024. selector: "updateClassesAndMetaclassesCache",
  1025. protocol: 'cache',
  1026. fn: function (){
  1027. var self=this;
  1028. function $OrderedCollection(){return globals.OrderedCollection||(typeof OrderedCollection=="undefined"?nil:OrderedCollection)}
  1029. return smalltalk.withContext(function($ctx1) {
  1030. var $1,$2;
  1031. self["@classesAndMetaclassesCache"]=_st($OrderedCollection())._new();
  1032. _st(_st(self._environment())._classes())._do_((function(each){
  1033. return smalltalk.withContext(function($ctx2) {
  1034. $1=self["@classesAndMetaclassesCache"];
  1035. _st($1)._add_(each);
  1036. $ctx2.sendIdx["add:"]=1;
  1037. $2=_st($1)._add_(_st(each)._class());
  1038. return $2;
  1039. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)})}));
  1040. return self}, function($ctx1) {$ctx1.fill(self,"updateClassesAndMetaclassesCache",{},globals.HLReferencesModel)})},
  1041. args: [],
  1042. source: "updateClassesAndMetaclassesCache\x0a\x09classesAndMetaclassesCache := OrderedCollection new.\x0a\x09\x0a\x09self environment classes do: [ :each |\x0a\x09\x09classesAndMetaclassesCache\x0a\x09\x09\x09\x09add: each; \x0a\x09\x09\x09\x09add: each class ]",
  1043. messageSends: ["new", "do:", "classes", "environment", "add:", "class"],
  1044. referencedClasses: ["OrderedCollection"]
  1045. }),
  1046. globals.HLReferencesModel);
  1047. smalltalk.addMethod(
  1048. smalltalk.method({
  1049. selector: "updateMethodsCache",
  1050. protocol: 'cache',
  1051. fn: function (){
  1052. var self=this;
  1053. function $OrderedCollection(){return globals.OrderedCollection||(typeof OrderedCollection=="undefined"?nil:OrderedCollection)}
  1054. return smalltalk.withContext(function($ctx1) {
  1055. self["@methodsCache"]=_st($OrderedCollection())._new();
  1056. _st(self._classesAndMetaclasses())._do_((function(each){
  1057. return smalltalk.withContext(function($ctx2) {
  1058. return _st(self["@methodsCache"])._addAll_(_st(each)._methods());
  1059. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)})}));
  1060. return self}, function($ctx1) {$ctx1.fill(self,"updateMethodsCache",{},globals.HLReferencesModel)})},
  1061. args: [],
  1062. source: "updateMethodsCache\x0a\x09methodsCache := OrderedCollection new.\x0a\x09\x0a\x09self classesAndMetaclasses\x0a\x09\x09do: [ :each | methodsCache addAll: each methods ]",
  1063. messageSends: ["new", "do:", "classesAndMetaclasses", "addAll:", "methods"],
  1064. referencedClasses: ["OrderedCollection"]
  1065. }),
  1066. globals.HLReferencesModel);
  1067. });