Helios-References.js 39 KB

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