Helios-Inspector.js 48 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444
  1. smalltalk.addPackage('Helios-Inspector');
  2. smalltalk.addClass('HLInspectorDisplayWidget', smalltalk.HLNavigationListWidget, ['model'], 'Helios-Inspector');
  3. smalltalk.addMethod(
  4. smalltalk.method({
  5. selector: "model",
  6. category: 'accessing',
  7. fn: function (){
  8. var self=this;
  9. return smalltalk.withContext(function($ctx1) {
  10. var $1;
  11. $1=self["@model"];
  12. return $1;
  13. }, function($ctx1) {$ctx1.fill(self,"model",{},smalltalk.HLInspectorDisplayWidget)})},
  14. args: [],
  15. source: "model\x0a\x0a\x09^ model",
  16. messageSends: [],
  17. referencedClasses: []
  18. }),
  19. smalltalk.HLInspectorDisplayWidget);
  20. smalltalk.addMethod(
  21. smalltalk.method({
  22. selector: "model:",
  23. category: 'accessing',
  24. fn: function (aModel){
  25. var self=this;
  26. return smalltalk.withContext(function($ctx1) {
  27. self["@model"]=aModel;
  28. return self}, function($ctx1) {$ctx1.fill(self,"model:",{aModel:aModel},smalltalk.HLInspectorDisplayWidget)})},
  29. args: ["aModel"],
  30. source: "model: aModel\x0a\x0a\x09model := aModel",
  31. messageSends: [],
  32. referencedClasses: []
  33. }),
  34. smalltalk.HLInspectorDisplayWidget);
  35. smalltalk.addMethod(
  36. smalltalk.method({
  37. selector: "renderContentOn:",
  38. category: 'rendering',
  39. fn: function (html){
  40. var self=this;
  41. return smalltalk.withContext(function($ctx1) {
  42. _st(_st(html)._div())._with_(_st(self)._selectionDisplayString());
  43. return self}, function($ctx1) {$ctx1.fill(self,"renderContentOn:",{html:html},smalltalk.HLInspectorDisplayWidget)})},
  44. args: ["html"],
  45. source: "renderContentOn: html\x0a\x09\x0a html div with: self selectionDisplayString\x0a ",
  46. messageSends: ["with:", "selectionDisplayString", "div"],
  47. referencedClasses: []
  48. }),
  49. smalltalk.HLInspectorDisplayWidget);
  50. smalltalk.addMethod(
  51. smalltalk.method({
  52. selector: "selectionDisplayString",
  53. category: 'rendering',
  54. fn: function (){
  55. var self=this;
  56. var selection;
  57. return smalltalk.withContext(function($ctx1) {
  58. var $2,$1;
  59. selection=_st(self["@model"])._selection();
  60. $2=_st(_st(_st(self["@model"])._variables())._keys())._includes_(selection);
  61. if(smalltalk.assert($2)){
  62. $1=_st(_st(self["@model"])._instVarObjectAt_(selection))._printString();
  63. } else {
  64. $1="";
  65. };
  66. return $1;
  67. }, function($ctx1) {$ctx1.fill(self,"selectionDisplayString",{selection:selection},smalltalk.HLInspectorDisplayWidget)})},
  68. args: [],
  69. source: "selectionDisplayString\x0a\x09|selection|\x0a\x09selection := model selection.\x0a ^ (model variables keys includes: selection)\x0a \x09ifTrue:[(model instVarObjectAt: selection) printString]\x0a \x09ifFalse:['']",
  70. messageSends: ["selection", "ifTrue:ifFalse:", "printString", "instVarObjectAt:", "includes:", "keys", "variables"],
  71. referencedClasses: []
  72. }),
  73. smalltalk.HLInspectorDisplayWidget);
  74. smalltalk.addClass('HLInspectorModel', smalltalk.Object, ['announcer', 'environment', 'inspectee', 'code', 'variables', 'label', 'selection'], 'Helios-Inspector');
  75. smalltalk.addMethod(
  76. smalltalk.method({
  77. selector: "announcer",
  78. category: 'accessing',
  79. fn: function (){
  80. var self=this;
  81. function $Announcer(){return smalltalk.Announcer||(typeof Announcer=="undefined"?nil:Announcer)}
  82. return smalltalk.withContext(function($ctx1) {
  83. var $2,$1;
  84. $2=self["@announcer"];
  85. if(($receiver = $2) == nil || $receiver == undefined){
  86. self["@announcer"]=_st($Announcer())._new();
  87. $1=self["@announcer"];
  88. } else {
  89. $1=$2;
  90. };
  91. return $1;
  92. }, function($ctx1) {$ctx1.fill(self,"announcer",{},smalltalk.HLInspectorModel)})},
  93. args: [],
  94. source: "announcer\x0a\x09^ announcer ifNil: [announcer := Announcer new ]",
  95. messageSends: ["ifNil:", "new"],
  96. referencedClasses: ["Announcer"]
  97. }),
  98. smalltalk.HLInspectorModel);
  99. smalltalk.addMethod(
  100. smalltalk.method({
  101. selector: "code",
  102. category: 'accessing',
  103. fn: function (){
  104. var self=this;
  105. function $HLCodeModel(){return smalltalk.HLCodeModel||(typeof HLCodeModel=="undefined"?nil:HLCodeModel)}
  106. return smalltalk.withContext(function($ctx1) {
  107. var $2,$1;
  108. $2=self["@code"];
  109. if(($receiver = $2) == nil || $receiver == undefined){
  110. self["@code"]=_st($HLCodeModel())._on_(_st(self)._environment());
  111. $1=self["@code"];
  112. } else {
  113. $1=$2;
  114. };
  115. return $1;
  116. }, function($ctx1) {$ctx1.fill(self,"code",{},smalltalk.HLInspectorModel)})},
  117. args: [],
  118. source: "code\x0a\x09\x22Answers the code model working for this workspace model\x22\x0a\x09^ code ifNil:[ code := HLCodeModel on: self environment ]",
  119. messageSends: ["ifNil:", "on:", "environment"],
  120. referencedClasses: ["HLCodeModel"]
  121. }),
  122. smalltalk.HLInspectorModel);
  123. smalltalk.addMethod(
  124. smalltalk.method({
  125. selector: "environment",
  126. category: 'accessing',
  127. fn: function (){
  128. var self=this;
  129. function $HLManager(){return smalltalk.HLManager||(typeof HLManager=="undefined"?nil:HLManager)}
  130. return smalltalk.withContext(function($ctx1) {
  131. var $2,$1;
  132. $2=self["@environment"];
  133. if(($receiver = $2) == nil || $receiver == undefined){
  134. $1=_st(_st($HLManager())._current())._environment();
  135. } else {
  136. $1=$2;
  137. };
  138. return $1;
  139. }, function($ctx1) {$ctx1.fill(self,"environment",{},smalltalk.HLInspectorModel)})},
  140. args: [],
  141. source: "environment\x0a\x09^ environment ifNil: [ HLManager current environment ]",
  142. messageSends: ["ifNil:", "environment", "current"],
  143. referencedClasses: ["HLManager"]
  144. }),
  145. smalltalk.HLInspectorModel);
  146. smalltalk.addMethod(
  147. smalltalk.method({
  148. selector: "environment:",
  149. category: 'accessing',
  150. fn: function (anEnvironment){
  151. var self=this;
  152. return smalltalk.withContext(function($ctx1) {
  153. self["@environment"]=anEnvironment;
  154. return self}, function($ctx1) {$ctx1.fill(self,"environment:",{anEnvironment:anEnvironment},smalltalk.HLInspectorModel)})},
  155. args: ["anEnvironment"],
  156. source: "environment: anEnvironment\x0a\x09environment := anEnvironment",
  157. messageSends: [],
  158. referencedClasses: []
  159. }),
  160. smalltalk.HLInspectorModel);
  161. smalltalk.addMethod(
  162. smalltalk.method({
  163. selector: "inspect:on:",
  164. category: 'actions',
  165. fn: function (anObject,anInspector){
  166. var self=this;
  167. return smalltalk.withContext(function($ctx1) {
  168. self["@inspectee"]=anObject;
  169. self["@variables"]=[];
  170. _st(self["@inspectee"])._inspectOn_(anInspector);
  171. return self}, function($ctx1) {$ctx1.fill(self,"inspect:on:",{anObject:anObject,anInspector:anInspector},smalltalk.HLInspectorModel)})},
  172. args: ["anObject", "anInspector"],
  173. source: "inspect: anObject on: anInspector\x0a\x09inspectee := anObject.\x0a\x09variables := #().\x0a\x09inspectee inspectOn: anInspector ",
  174. messageSends: ["inspectOn:"],
  175. referencedClasses: []
  176. }),
  177. smalltalk.HLInspectorModel);
  178. smalltalk.addMethod(
  179. smalltalk.method({
  180. selector: "inspectee",
  181. category: 'accessing',
  182. fn: function (){
  183. var self=this;
  184. return smalltalk.withContext(function($ctx1) {
  185. var $1;
  186. $1=self["@inspectee"];
  187. return $1;
  188. }, function($ctx1) {$ctx1.fill(self,"inspectee",{},smalltalk.HLInspectorModel)})},
  189. args: [],
  190. source: "inspectee \x0a\x09^ inspectee ",
  191. messageSends: [],
  192. referencedClasses: []
  193. }),
  194. smalltalk.HLInspectorModel);
  195. smalltalk.addMethod(
  196. smalltalk.method({
  197. selector: "inspectee:",
  198. category: 'accessing',
  199. fn: function (anObject){
  200. var self=this;
  201. return smalltalk.withContext(function($ctx1) {
  202. self["@inspectee"]=anObject;
  203. return self}, function($ctx1) {$ctx1.fill(self,"inspectee:",{anObject:anObject},smalltalk.HLInspectorModel)})},
  204. args: ["anObject"],
  205. source: "inspectee: anObject \x0a\x09inspectee := anObject\x0a ",
  206. messageSends: [],
  207. referencedClasses: []
  208. }),
  209. smalltalk.HLInspectorModel);
  210. smalltalk.addMethod(
  211. smalltalk.method({
  212. selector: "instVarObjectAt:",
  213. category: 'actions',
  214. fn: function (anInstVarName){
  215. var self=this;
  216. return smalltalk.withContext(function($ctx1) {
  217. var $1;
  218. $1=_st(_st(self)._variables())._at_(anInstVarName);
  219. return $1;
  220. }, function($ctx1) {$ctx1.fill(self,"instVarObjectAt:",{anInstVarName:anInstVarName},smalltalk.HLInspectorModel)})},
  221. args: ["anInstVarName"],
  222. source: "instVarObjectAt: anInstVarName\x0a\x09^ self variables at: anInstVarName",
  223. messageSends: ["at:", "variables"],
  224. referencedClasses: []
  225. }),
  226. smalltalk.HLInspectorModel);
  227. smalltalk.addMethod(
  228. smalltalk.method({
  229. selector: "label",
  230. category: 'accessing',
  231. fn: function (){
  232. var self=this;
  233. return smalltalk.withContext(function($ctx1) {
  234. var $2,$1;
  235. $2=self["@label"];
  236. if(($receiver = $2) == nil || $receiver == undefined){
  237. $1=_st(_st(self)._inspectee())._printString();
  238. } else {
  239. $1=$2;
  240. };
  241. return $1;
  242. }, function($ctx1) {$ctx1.fill(self,"label",{},smalltalk.HLInspectorModel)})},
  243. args: [],
  244. source: "label\x0a ^ label ifNil: [ self inspectee printString ]",
  245. messageSends: ["ifNil:", "printString", "inspectee"],
  246. referencedClasses: []
  247. }),
  248. smalltalk.HLInspectorModel);
  249. smalltalk.addMethod(
  250. smalltalk.method({
  251. selector: "label:",
  252. category: 'accessing',
  253. fn: function (aString){
  254. var self=this;
  255. return smalltalk.withContext(function($ctx1) {
  256. self["@label"]=aString;
  257. return self}, function($ctx1) {$ctx1.fill(self,"label:",{aString:aString},smalltalk.HLInspectorModel)})},
  258. args: ["aString"],
  259. source: "label: aString\x0a label := aString",
  260. messageSends: [],
  261. referencedClasses: []
  262. }),
  263. smalltalk.HLInspectorModel);
  264. smalltalk.addMethod(
  265. smalltalk.method({
  266. selector: "onKeyDown:",
  267. category: 'reactions',
  268. fn: function (anEvent){
  269. var self=this;
  270. return smalltalk.withContext(function($ctx1) {
  271. if(anEvent.ctrlKey) {
  272. if(anEvent.keyCode === 80) { //ctrl+p
  273. self._printIt();
  274. anEvent.preventDefault();
  275. return false;
  276. }
  277. if(anEvent.keyCode === 68) { //ctrl+d
  278. self._doIt();
  279. anEvent.preventDefault();
  280. return false;
  281. }
  282. if(anEvent.keyCode === 73) { //ctrl+i
  283. self._inspectIt();
  284. anEvent.preventDefault();
  285. return false;
  286. }
  287. };
  288. return self}, function($ctx1) {$ctx1.fill(self,"onKeyDown:",{anEvent:anEvent},smalltalk.HLInspectorModel)})},
  289. args: ["anEvent"],
  290. source: "onKeyDown: anEvent\x0a\x0a\x09<if(anEvent.ctrlKey) {\x0a\x09\x09if(anEvent.keyCode === 80) { //ctrl+p\x0a\x09\x09\x09self._printIt();\x0a\x09\x09\x09anEvent.preventDefault();\x0a\x09\x09\x09return false;\x0a\x09\x09}\x0a\x09\x09if(anEvent.keyCode === 68) { //ctrl+d\x0a\x09\x09\x09self._doIt();\x0a\x09\x09\x09anEvent.preventDefault();\x0a\x09\x09\x09return false;\x0a\x09\x09}\x0a\x09\x09if(anEvent.keyCode === 73) { //ctrl+i\x0a\x09\x09\x09self._inspectIt();\x0a\x09\x09\x09anEvent.preventDefault();\x0a\x09\x09\x09return false;\x0a\x09\x09}\x0a\x09}>",
  291. messageSends: [],
  292. referencedClasses: []
  293. }),
  294. smalltalk.HLInspectorModel);
  295. smalltalk.addMethod(
  296. smalltalk.method({
  297. selector: "selectedInstVar:",
  298. category: 'actions',
  299. fn: function (anInstVarName){
  300. var self=this;
  301. return smalltalk.withContext(function($ctx1) {
  302. _st(self)._selection_(anInstVarName);
  303. return self}, function($ctx1) {$ctx1.fill(self,"selectedInstVar:",{anInstVarName:anInstVarName},smalltalk.HLInspectorModel)})},
  304. args: ["anInstVarName"],
  305. source: "selectedInstVar: anInstVarName\x0a self selection: anInstVarName",
  306. messageSends: ["selection:"],
  307. referencedClasses: []
  308. }),
  309. smalltalk.HLInspectorModel);
  310. smalltalk.addMethod(
  311. smalltalk.method({
  312. selector: "selectedInstVarObject",
  313. category: 'accessing',
  314. fn: function (){
  315. var self=this;
  316. return smalltalk.withContext(function($ctx1) {
  317. var $1;
  318. $1=_st(self)._instVarObjectAt_(_st(self)._selection());
  319. return $1;
  320. }, function($ctx1) {$ctx1.fill(self,"selectedInstVarObject",{},smalltalk.HLInspectorModel)})},
  321. args: [],
  322. source: "selectedInstVarObject\x0a\x09^ self instVarObjectAt: self selection\x0a ",
  323. messageSends: ["instVarObjectAt:", "selection"],
  324. referencedClasses: []
  325. }),
  326. smalltalk.HLInspectorModel);
  327. smalltalk.addMethod(
  328. smalltalk.method({
  329. selector: "selection",
  330. category: 'accessing',
  331. fn: function (){
  332. var self=this;
  333. return smalltalk.withContext(function($ctx1) {
  334. var $2,$1;
  335. $2=self["@selection"];
  336. if(($receiver = $2) == nil || $receiver == undefined){
  337. $1="";
  338. } else {
  339. $1=$2;
  340. };
  341. return $1;
  342. }, function($ctx1) {$ctx1.fill(self,"selection",{},smalltalk.HLInspectorModel)})},
  343. args: [],
  344. source: "selection\x0a\x09^ selection ifNil:[ '' ] ",
  345. messageSends: ["ifNil:"],
  346. referencedClasses: []
  347. }),
  348. smalltalk.HLInspectorModel);
  349. smalltalk.addMethod(
  350. smalltalk.method({
  351. selector: "selection:",
  352. category: 'accessing',
  353. fn: function (anObject){
  354. var self=this;
  355. function $HLInstanceVariableSelected(){return smalltalk.HLInstanceVariableSelected||(typeof HLInstanceVariableSelected=="undefined"?nil:HLInstanceVariableSelected)}
  356. return smalltalk.withContext(function($ctx1) {
  357. self["@selection"]=anObject;
  358. _st(_st(self)._announcer())._announce_(_st($HLInstanceVariableSelected())._on_(self["@selection"]));
  359. return self}, function($ctx1) {$ctx1.fill(self,"selection:",{anObject:anObject},smalltalk.HLInspectorModel)})},
  360. args: ["anObject"],
  361. source: "selection: anObject\x0a\x09selection := anObject.\x0a\x0a\x09self announcer announce: (HLInstanceVariableSelected on: selection)\x0a ",
  362. messageSends: ["announce:", "on:", "announcer"],
  363. referencedClasses: ["HLInstanceVariableSelected"]
  364. }),
  365. smalltalk.HLInspectorModel);
  366. smalltalk.addMethod(
  367. smalltalk.method({
  368. selector: "subscribe:",
  369. category: 'actions',
  370. fn: function (aWidget){
  371. var self=this;
  372. return smalltalk.withContext(function($ctx1) {
  373. _st(aWidget)._subscribeTo_(_st(self)._announcer());
  374. return self}, function($ctx1) {$ctx1.fill(self,"subscribe:",{aWidget:aWidget},smalltalk.HLInspectorModel)})},
  375. args: ["aWidget"],
  376. source: "subscribe: aWidget\x0a\x09aWidget subscribeTo: self announcer",
  377. messageSends: ["subscribeTo:", "announcer"],
  378. referencedClasses: []
  379. }),
  380. smalltalk.HLInspectorModel);
  381. smalltalk.addMethod(
  382. smalltalk.method({
  383. selector: "variables",
  384. category: 'accessing',
  385. fn: function (){
  386. var self=this;
  387. function $Dictionary(){return smalltalk.Dictionary||(typeof Dictionary=="undefined"?nil:Dictionary)}
  388. return smalltalk.withContext(function($ctx1) {
  389. var $2,$1;
  390. $2=self["@variables"];
  391. if(($receiver = $2) == nil || $receiver == undefined){
  392. $1=_st($Dictionary())._new();
  393. } else {
  394. $1=$2;
  395. };
  396. return $1;
  397. }, function($ctx1) {$ctx1.fill(self,"variables",{},smalltalk.HLInspectorModel)})},
  398. args: [],
  399. source: "variables\x0a\x09^ variables ifNil: [ Dictionary new ]",
  400. messageSends: ["ifNil:", "new"],
  401. referencedClasses: ["Dictionary"]
  402. }),
  403. smalltalk.HLInspectorModel);
  404. smalltalk.addMethod(
  405. smalltalk.method({
  406. selector: "variables:",
  407. category: 'accessing',
  408. fn: function (aCollection){
  409. var self=this;
  410. return smalltalk.withContext(function($ctx1) {
  411. self["@variables"]=aCollection;
  412. return self}, function($ctx1) {$ctx1.fill(self,"variables:",{aCollection:aCollection},smalltalk.HLInspectorModel)})},
  413. args: ["aCollection"],
  414. source: "variables: aCollection\x0a\x09variables := aCollection\x0a ",
  415. messageSends: [],
  416. referencedClasses: []
  417. }),
  418. smalltalk.HLInspectorModel);
  419. smalltalk.addMethod(
  420. smalltalk.method({
  421. selector: "on:",
  422. category: 'actions',
  423. fn: function (anEnvironment){
  424. var self=this;
  425. return smalltalk.withContext(function($ctx1) {
  426. var $2,$3,$1;
  427. $2=_st(self)._new();
  428. _st($2)._environment_(anEnvironment);
  429. $3=_st($2)._yourself();
  430. $1=$3;
  431. return $1;
  432. }, function($ctx1) {$ctx1.fill(self,"on:",{anEnvironment:anEnvironment},smalltalk.HLInspectorModel.klass)})},
  433. args: ["anEnvironment"],
  434. source: "on: anEnvironment\x0a\x0a\x09^ self new\x0a \x09environment: anEnvironment;\x0a yourself",
  435. messageSends: ["environment:", "new", "yourself"],
  436. referencedClasses: []
  437. }),
  438. smalltalk.HLInspectorModel.klass);
  439. smalltalk.addClass('HLInspectorVariablesWidget', smalltalk.HLNavigationListWidget, ['announcer', 'model', 'list', 'diveButton'], 'Helios-Inspector');
  440. smalltalk.addMethod(
  441. smalltalk.method({
  442. selector: "announcer",
  443. category: 'accessing',
  444. fn: function (){
  445. var self=this;
  446. function $Announcer(){return smalltalk.Announcer||(typeof Announcer=="undefined"?nil:Announcer)}
  447. return smalltalk.withContext(function($ctx1) {
  448. var $2,$1;
  449. $2=self["@announcer"];
  450. if(($receiver = $2) == nil || $receiver == undefined){
  451. self["@announcer"]=_st($Announcer())._new();
  452. $1=self["@announcer"];
  453. } else {
  454. $1=$2;
  455. };
  456. return $1;
  457. }, function($ctx1) {$ctx1.fill(self,"announcer",{},smalltalk.HLInspectorVariablesWidget)})},
  458. args: [],
  459. source: "announcer\x0a\x09^ announcer ifNil:[ announcer := Announcer new ]",
  460. messageSends: ["ifNil:", "new"],
  461. referencedClasses: ["Announcer"]
  462. }),
  463. smalltalk.HLInspectorVariablesWidget);
  464. smalltalk.addMethod(
  465. smalltalk.method({
  466. selector: "defaultItems",
  467. category: 'defaults',
  468. fn: function (){
  469. var self=this;
  470. return smalltalk.withContext(function($ctx1) {
  471. var $1;
  472. $1=_st(_st(_st(self)._model())._variables())._keys();
  473. return $1;
  474. }, function($ctx1) {$ctx1.fill(self,"defaultItems",{},smalltalk.HLInspectorVariablesWidget)})},
  475. args: [],
  476. source: "defaultItems\x0a\x09^ self model variables keys",
  477. messageSends: ["keys", "variables", "model"],
  478. referencedClasses: []
  479. }),
  480. smalltalk.HLInspectorVariablesWidget);
  481. smalltalk.addMethod(
  482. smalltalk.method({
  483. selector: "label",
  484. category: 'accessing',
  485. fn: function (){
  486. var self=this;
  487. return smalltalk.withContext(function($ctx1) {
  488. var $1;
  489. $1=_st(_st(self)._model())._label();
  490. return $1;
  491. }, function($ctx1) {$ctx1.fill(self,"label",{},smalltalk.HLInspectorVariablesWidget)})},
  492. args: [],
  493. source: "label\x0a\x09^ self model label",
  494. messageSends: ["label", "model"],
  495. referencedClasses: []
  496. }),
  497. smalltalk.HLInspectorVariablesWidget);
  498. smalltalk.addMethod(
  499. smalltalk.method({
  500. selector: "model",
  501. category: 'accessing',
  502. fn: function (){
  503. var self=this;
  504. return smalltalk.withContext(function($ctx1) {
  505. var $1;
  506. $1=self["@model"];
  507. return $1;
  508. }, function($ctx1) {$ctx1.fill(self,"model",{},smalltalk.HLInspectorVariablesWidget)})},
  509. args: [],
  510. source: "model\x0a ^ model\x0a ",
  511. messageSends: [],
  512. referencedClasses: []
  513. }),
  514. smalltalk.HLInspectorVariablesWidget);
  515. smalltalk.addMethod(
  516. smalltalk.method({
  517. selector: "model:",
  518. category: 'accessing',
  519. fn: function (aModel){
  520. var self=this;
  521. return smalltalk.withContext(function($ctx1) {
  522. self["@model"]=aModel;
  523. return self}, function($ctx1) {$ctx1.fill(self,"model:",{aModel:aModel},smalltalk.HLInspectorVariablesWidget)})},
  524. args: ["aModel"],
  525. source: "model: aModel\x0a model := aModel\x0a ",
  526. messageSends: [],
  527. referencedClasses: []
  528. }),
  529. smalltalk.HLInspectorVariablesWidget);
  530. smalltalk.addMethod(
  531. smalltalk.method({
  532. selector: "refresh",
  533. category: 'actions',
  534. fn: function (){
  535. var self=this;
  536. return smalltalk.withContext(function($ctx1) {
  537. _st(self)._resetItems();
  538. smalltalk.HLNavigationListWidget.fn.prototype._refresh.apply(_st(self), []);
  539. return self}, function($ctx1) {$ctx1.fill(self,"refresh",{},smalltalk.HLInspectorVariablesWidget)})},
  540. args: [],
  541. source: "refresh\x0a\x09self resetItems.\x0a super refresh\x0a ",
  542. messageSends: ["resetItems", "refresh"],
  543. referencedClasses: []
  544. }),
  545. smalltalk.HLInspectorVariablesWidget);
  546. smalltalk.addMethod(
  547. smalltalk.method({
  548. selector: "renderButtonsOn:",
  549. category: 'rendering',
  550. fn: function (html){
  551. var self=this;
  552. function $HLDiveRequested(){return smalltalk.HLDiveRequested||(typeof HLDiveRequested=="undefined"?nil:HLDiveRequested)}
  553. return smalltalk.withContext(function($ctx1) {
  554. var $1,$2;
  555. $1=_st(html)._button();
  556. _st($1)._class_("btn");
  557. _st($1)._with_("Dive");
  558. $2=_st($1)._onClick_((function(){
  559. return smalltalk.withContext(function($ctx2) {
  560. return _st(_st(self)._announcer())._announce_(_st($HLDiveRequested())._new());
  561. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  562. self["@diveButton"]=$2;
  563. return self}, function($ctx1) {$ctx1.fill(self,"renderButtonsOn:",{html:html},smalltalk.HLInspectorVariablesWidget)})},
  564. args: ["html"],
  565. source: "renderButtonsOn: html\x0a\x09diveButton := html button \x0a\x09\x09class: 'btn';\x0a\x09\x09with: 'Dive'; \x0a\x09\x09onClick: [ self announcer announce: HLDiveRequested new ]",
  566. messageSends: ["class:", "button", "with:", "onClick:", "announce:", "new", "announcer"],
  567. referencedClasses: ["HLDiveRequested"]
  568. }),
  569. smalltalk.HLInspectorVariablesWidget);
  570. smalltalk.addMethod(
  571. smalltalk.method({
  572. selector: "renderContentOn:",
  573. category: 'rendering',
  574. fn: function (html){
  575. var self=this;
  576. return smalltalk.withContext(function($ctx1) {
  577. _st(self)._renderHeadOn_(html);
  578. smalltalk.HLNavigationListWidget.fn.prototype._renderContentOn_.apply(_st(self), [html]);
  579. return self}, function($ctx1) {$ctx1.fill(self,"renderContentOn:",{html:html},smalltalk.HLInspectorVariablesWidget)})},
  580. args: ["html"],
  581. source: "renderContentOn: html\x0a\x09self renderHeadOn: html.\x0a\x09super renderContentOn: html",
  582. messageSends: ["renderHeadOn:", "renderContentOn:"],
  583. referencedClasses: []
  584. }),
  585. smalltalk.HLInspectorVariablesWidget);
  586. smalltalk.addMethod(
  587. smalltalk.method({
  588. selector: "renderHeadOn:",
  589. category: 'rendering',
  590. fn: function (html){
  591. var self=this;
  592. return smalltalk.withContext(function($ctx1) {
  593. var $1,$2;
  594. $1=_st(html)._div();
  595. _st($1)._class_("list-label");
  596. $2=_st($1)._with_(_st(self)._label());
  597. return self}, function($ctx1) {$ctx1.fill(self,"renderHeadOn:",{html:html},smalltalk.HLInspectorVariablesWidget)})},
  598. args: ["html"],
  599. source: "renderHeadOn: html\x0a\x09html div \x0a\x09\x09class: 'list-label';\x0a\x09\x09with: self label",
  600. messageSends: ["class:", "div", "with:", "label"],
  601. referencedClasses: []
  602. }),
  603. smalltalk.HLInspectorVariablesWidget);
  604. smalltalk.addMethod(
  605. smalltalk.method({
  606. selector: "resetItems",
  607. category: 'actions',
  608. fn: function (){
  609. var self=this;
  610. return smalltalk.withContext(function($ctx1) {
  611. self["@items"]=nil;
  612. return self}, function($ctx1) {$ctx1.fill(self,"resetItems",{},smalltalk.HLInspectorVariablesWidget)})},
  613. args: [],
  614. source: "resetItems\x0a\x09items := nil",
  615. messageSends: [],
  616. referencedClasses: []
  617. }),
  618. smalltalk.HLInspectorVariablesWidget);
  619. smalltalk.addMethod(
  620. smalltalk.method({
  621. selector: "selectItem:",
  622. category: 'reactions',
  623. fn: function (anObject){
  624. var self=this;
  625. return smalltalk.withContext(function($ctx1) {
  626. smalltalk.HLNavigationListWidget.fn.prototype._selectItem_.apply(_st(self), [anObject]);
  627. _st(_st(self)._model())._selectedInstVar_(anObject);
  628. return self}, function($ctx1) {$ctx1.fill(self,"selectItem:",{anObject:anObject},smalltalk.HLInspectorVariablesWidget)})},
  629. args: ["anObject"],
  630. source: "selectItem: anObject\x0a\x09super selectItem: anObject.\x0a self model selectedInstVar: anObject",
  631. messageSends: ["selectItem:", "selectedInstVar:", "model"],
  632. referencedClasses: []
  633. }),
  634. smalltalk.HLInspectorVariablesWidget);
  635. smalltalk.addMethod(
  636. smalltalk.method({
  637. selector: "selection",
  638. category: 'accessing',
  639. fn: function (){
  640. var self=this;
  641. return smalltalk.withContext(function($ctx1) {
  642. var $1;
  643. $1=_st(self["@model"])._selection();
  644. return $1;
  645. }, function($ctx1) {$ctx1.fill(self,"selection",{},smalltalk.HLInspectorVariablesWidget)})},
  646. args: [],
  647. source: "selection\x0a\x09^ model selection",
  648. messageSends: ["selection"],
  649. referencedClasses: []
  650. }),
  651. smalltalk.HLInspectorVariablesWidget);
  652. smalltalk.addMethod(
  653. smalltalk.method({
  654. selector: "variables",
  655. category: 'accessing',
  656. fn: function (){
  657. var self=this;
  658. return smalltalk.withContext(function($ctx1) {
  659. var $1;
  660. $1=_st(self["@model"])._variables();
  661. return $1;
  662. }, function($ctx1) {$ctx1.fill(self,"variables",{},smalltalk.HLInspectorVariablesWidget)})},
  663. args: [],
  664. source: "variables\x0a\x09^ model variables",
  665. messageSends: ["variables"],
  666. referencedClasses: []
  667. }),
  668. smalltalk.HLInspectorVariablesWidget);
  669. smalltalk.addClass('HLInspectorWidget', smalltalk.HLWidget, ['model', 'variablesWidget', 'displayWidget', 'codeWidget'], 'Helios-Inspector');
  670. smalltalk.addMethod(
  671. smalltalk.method({
  672. selector: "codeWidget",
  673. category: 'accessing',
  674. fn: function (){
  675. var self=this;
  676. function $HLCodeWidget(){return smalltalk.HLCodeWidget||(typeof HLCodeWidget=="undefined"?nil:HLCodeWidget)}
  677. return smalltalk.withContext(function($ctx1) {
  678. var $2,$3,$4,$1;
  679. $2=self["@codeWidget"];
  680. if(($receiver = $2) == nil || $receiver == undefined){
  681. $3=_st($HLCodeWidget())._new();
  682. _st($3)._model_(_st(self["@model"])._code());
  683. _st($3)._receiver_(_st(self["@model"])._inspectee());
  684. $4=_st($3)._yourself();
  685. self["@codeWidget"]=$4;
  686. $1=self["@codeWidget"];
  687. } else {
  688. $1=$2;
  689. };
  690. return $1;
  691. }, function($ctx1) {$ctx1.fill(self,"codeWidget",{},smalltalk.HLInspectorWidget)})},
  692. args: [],
  693. source: "codeWidget\x0a\x09^ codeWidget ifNil: [\x0a\x09\x09codeWidget := HLCodeWidget new\x0a \x09\x09model: model code;\x0a \x09receiver: model inspectee;\x0a \x09yourself ]",
  694. messageSends: ["ifNil:", "model:", "code", "new", "receiver:", "inspectee", "yourself"],
  695. referencedClasses: ["HLCodeWidget"]
  696. }),
  697. smalltalk.HLInspectorWidget);
  698. smalltalk.addMethod(
  699. smalltalk.method({
  700. selector: "displayWidget",
  701. category: 'accessing',
  702. fn: function (){
  703. var self=this;
  704. function $HLInspectorDisplayWidget(){return smalltalk.HLInspectorDisplayWidget||(typeof HLInspectorDisplayWidget=="undefined"?nil:HLInspectorDisplayWidget)}
  705. return smalltalk.withContext(function($ctx1) {
  706. var $2,$3,$4,$1;
  707. $2=self["@displayWidget"];
  708. if(($receiver = $2) == nil || $receiver == undefined){
  709. $3=_st($HLInspectorDisplayWidget())._new();
  710. _st($3)._model_(_st(self)._model());
  711. $4=_st($3)._yourself();
  712. self["@displayWidget"]=$4;
  713. $1=self["@displayWidget"];
  714. } else {
  715. $1=$2;
  716. };
  717. return $1;
  718. }, function($ctx1) {$ctx1.fill(self,"displayWidget",{},smalltalk.HLInspectorWidget)})},
  719. args: [],
  720. source: "displayWidget\x0a\x09^ displayWidget ifNil: [\x0a\x09\x09displayWidget := HLInspectorDisplayWidget new\x0a \x09\x09model: self model;\x0a \x09yourself ]",
  721. messageSends: ["ifNil:", "model:", "model", "new", "yourself"],
  722. referencedClasses: ["HLInspectorDisplayWidget"]
  723. }),
  724. smalltalk.HLInspectorWidget);
  725. smalltalk.addMethod(
  726. smalltalk.method({
  727. selector: "initialize",
  728. category: 'accessing',
  729. fn: function (){
  730. var self=this;
  731. return smalltalk.withContext(function($ctx1) {
  732. smalltalk.HLWidget.fn.prototype._initialize.apply(_st(self), []);
  733. _st(self)._register();
  734. return self}, function($ctx1) {$ctx1.fill(self,"initialize",{},smalltalk.HLInspectorWidget)})},
  735. args: [],
  736. source: "initialize\x0a\x09super initialize.\x0a\x09self register",
  737. messageSends: ["initialize", "register"],
  738. referencedClasses: []
  739. }),
  740. smalltalk.HLInspectorWidget);
  741. smalltalk.addMethod(
  742. smalltalk.method({
  743. selector: "inspect:",
  744. category: 'actions',
  745. fn: function (anObject){
  746. var self=this;
  747. return smalltalk.withContext(function($ctx1) {
  748. var $1,$2;
  749. _st(_st(self)._model())._inspect_on_(anObject,self);
  750. $1=self;
  751. _st($1)._refreshVariablesWidget();
  752. $2=_st($1)._refreshDisplayWidget();
  753. return self}, function($ctx1) {$ctx1.fill(self,"inspect:",{anObject:anObject},smalltalk.HLInspectorWidget)})},
  754. args: ["anObject"],
  755. source: "inspect: anObject\x0a\x09self model inspect: anObject on: self.\x0a \x0a\x09self \x0a \x09refreshVariablesWidget;\x0a\x09\x09refreshDisplayWidget",
  756. messageSends: ["inspect:on:", "model", "refreshVariablesWidget", "refreshDisplayWidget"],
  757. referencedClasses: []
  758. }),
  759. smalltalk.HLInspectorWidget);
  760. smalltalk.addMethod(
  761. smalltalk.method({
  762. selector: "inspectee",
  763. category: 'accessing',
  764. fn: function (){
  765. var self=this;
  766. return smalltalk.withContext(function($ctx1) {
  767. var $1;
  768. $1=_st(_st(self)._model())._inspectee();
  769. return $1;
  770. }, function($ctx1) {$ctx1.fill(self,"inspectee",{},smalltalk.HLInspectorWidget)})},
  771. args: [],
  772. source: "inspectee\x0a\x09^ self model inspectee",
  773. messageSends: ["inspectee", "model"],
  774. referencedClasses: []
  775. }),
  776. smalltalk.HLInspectorWidget);
  777. smalltalk.addMethod(
  778. smalltalk.method({
  779. selector: "inspectee:",
  780. category: 'accessing',
  781. fn: function (anObject){
  782. var self=this;
  783. return smalltalk.withContext(function($ctx1) {
  784. _st(_st(self)._model())._inspectee_(anObject);
  785. return self}, function($ctx1) {$ctx1.fill(self,"inspectee:",{anObject:anObject},smalltalk.HLInspectorWidget)})},
  786. args: ["anObject"],
  787. source: "inspectee: anObject\x0a\x09self model inspectee: anObject",
  788. messageSends: ["inspectee:", "model"],
  789. referencedClasses: []
  790. }),
  791. smalltalk.HLInspectorWidget);
  792. smalltalk.addMethod(
  793. smalltalk.method({
  794. selector: "label",
  795. category: 'accessing',
  796. fn: function (){
  797. var self=this;
  798. return smalltalk.withContext(function($ctx1) {
  799. var $1;
  800. $1=_st(_st(self)._model())._label();
  801. return $1;
  802. }, function($ctx1) {$ctx1.fill(self,"label",{},smalltalk.HLInspectorWidget)})},
  803. args: [],
  804. source: "label\x0a ^ self model label",
  805. messageSends: ["label", "model"],
  806. referencedClasses: []
  807. }),
  808. smalltalk.HLInspectorWidget);
  809. smalltalk.addMethod(
  810. smalltalk.method({
  811. selector: "model",
  812. category: 'accessing',
  813. fn: function (){
  814. var self=this;
  815. function $HLInspectorModel(){return smalltalk.HLInspectorModel||(typeof HLInspectorModel=="undefined"?nil:HLInspectorModel)}
  816. return smalltalk.withContext(function($ctx1) {
  817. var $2,$1;
  818. $2=self["@model"];
  819. if(($receiver = $2) == nil || $receiver == undefined){
  820. _st(self)._model_(_st($HLInspectorModel())._new());
  821. $1=self["@model"];
  822. } else {
  823. $1=$2;
  824. };
  825. return $1;
  826. }, function($ctx1) {$ctx1.fill(self,"model",{},smalltalk.HLInspectorWidget)})},
  827. args: [],
  828. source: "model\x0a\x09^ model ifNil: [ \x0a \x09self model: HLInspectorModel new.\x0a\x09\x09model ]",
  829. messageSends: ["ifNil:", "model:", "new"],
  830. referencedClasses: ["HLInspectorModel"]
  831. }),
  832. smalltalk.HLInspectorWidget);
  833. smalltalk.addMethod(
  834. smalltalk.method({
  835. selector: "model:",
  836. category: 'accessing',
  837. fn: function (aModel){
  838. var self=this;
  839. return smalltalk.withContext(function($ctx1) {
  840. var $1,$2;
  841. self["@model"]=aModel;
  842. _st(_st(self)._codeWidget())._model_(_st(aModel)._code());
  843. $1=self;
  844. _st($1)._observeCodeWidget();
  845. _st($1)._observeVariablesWidget();
  846. $2=_st($1)._observeModel();
  847. return self}, function($ctx1) {$ctx1.fill(self,"model:",{aModel:aModel},smalltalk.HLInspectorWidget)})},
  848. args: ["aModel"],
  849. source: "model: aModel\x0a\x09model := aModel. \x0a self codeWidget model: aModel code.\x0a \x0a self \x0a observeCodeWidget;\x0a \x09observeVariablesWidget;\x0a observeModel",
  850. messageSends: ["model:", "code", "codeWidget", "observeCodeWidget", "observeVariablesWidget", "observeModel"],
  851. referencedClasses: []
  852. }),
  853. smalltalk.HLInspectorWidget);
  854. smalltalk.addMethod(
  855. smalltalk.method({
  856. selector: "observeCodeWidget",
  857. category: 'actions',
  858. fn: function (){
  859. var self=this;
  860. function $HLDoItExecuted(){return smalltalk.HLDoItExecuted||(typeof HLDoItExecuted=="undefined"?nil:HLDoItExecuted)}
  861. return smalltalk.withContext(function($ctx1) {
  862. _st(_st(_st(self)._codeWidget())._announcer())._on_do_($HLDoItExecuted(),(function(){
  863. return smalltalk.withContext(function($ctx2) {
  864. return _st(self)._onDoneIt();
  865. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  866. return self}, function($ctx1) {$ctx1.fill(self,"observeCodeWidget",{},smalltalk.HLInspectorWidget)})},
  867. args: [],
  868. source: "observeCodeWidget\x0a\x09self codeWidget announcer \x0a \x09on: HLDoItExecuted \x0a do: [ self onDoneIt ]",
  869. messageSends: ["on:do:", "onDoneIt", "announcer", "codeWidget"],
  870. referencedClasses: ["HLDoItExecuted"]
  871. }),
  872. smalltalk.HLInspectorWidget);
  873. smalltalk.addMethod(
  874. smalltalk.method({
  875. selector: "observeModel",
  876. category: 'actions',
  877. fn: function (){
  878. var self=this;
  879. function $HLInstanceVariableSelected(){return smalltalk.HLInstanceVariableSelected||(typeof HLInstanceVariableSelected=="undefined"?nil:HLInstanceVariableSelected)}
  880. return smalltalk.withContext(function($ctx1) {
  881. _st(_st(_st(self)._model())._announcer())._on_send_to_($HLInstanceVariableSelected(),"onInstanceVariableSelected",self);
  882. return self}, function($ctx1) {$ctx1.fill(self,"observeModel",{},smalltalk.HLInspectorWidget)})},
  883. args: [],
  884. source: "observeModel\x0a\x09self model announcer\x0a on: HLInstanceVariableSelected\x0a\x09\x09send: #onInstanceVariableSelected\x0a\x09\x09to: self",
  885. messageSends: ["on:send:to:", "announcer", "model"],
  886. referencedClasses: ["HLInstanceVariableSelected"]
  887. }),
  888. smalltalk.HLInspectorWidget);
  889. smalltalk.addMethod(
  890. smalltalk.method({
  891. selector: "observeVariablesWidget",
  892. category: 'actions',
  893. fn: function (){
  894. var self=this;
  895. function $HLDiveRequested(){return smalltalk.HLDiveRequested||(typeof HLDiveRequested=="undefined"?nil:HLDiveRequested)}
  896. return smalltalk.withContext(function($ctx1) {
  897. _st(_st(_st(self)._variablesWidget())._announcer())._on_do_($HLDiveRequested(),(function(){
  898. return smalltalk.withContext(function($ctx2) {
  899. return _st(self)._onDive();
  900. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}));
  901. return self}, function($ctx1) {$ctx1.fill(self,"observeVariablesWidget",{},smalltalk.HLInspectorWidget)})},
  902. args: [],
  903. source: "observeVariablesWidget\x0a\x09self variablesWidget announcer \x0a on: HLDiveRequested do:[ self onDive ]\x0a ",
  904. messageSends: ["on:do:", "onDive", "announcer", "variablesWidget"],
  905. referencedClasses: ["HLDiveRequested"]
  906. }),
  907. smalltalk.HLInspectorWidget);
  908. smalltalk.addMethod(
  909. smalltalk.method({
  910. selector: "onDive",
  911. category: 'reactions',
  912. fn: function (){
  913. var self=this;
  914. function $HLInspector(){return smalltalk.HLInspector||(typeof HLInspector=="undefined"?nil:HLInspector)}
  915. return smalltalk.withContext(function($ctx1) {
  916. var $1,$2;
  917. $1=_st($HLInspector())._new();
  918. _st($1)._inspect_(_st(_st(self)._model())._selectedInstVarObject());
  919. $2=_st($1)._open();
  920. return self}, function($ctx1) {$ctx1.fill(self,"onDive",{},smalltalk.HLInspectorWidget)})},
  921. args: [],
  922. source: "onDive\x0a\x0a\x09HLInspector new \x0a\x09\x09inspect: self model selectedInstVarObject;\x0a\x09\x09open",
  923. messageSends: ["inspect:", "selectedInstVarObject", "model", "new", "open"],
  924. referencedClasses: ["HLInspector"]
  925. }),
  926. smalltalk.HLInspectorWidget);
  927. smalltalk.addMethod(
  928. smalltalk.method({
  929. selector: "onDoneIt",
  930. category: 'reactions',
  931. fn: function (){
  932. var self=this;
  933. return smalltalk.withContext(function($ctx1) {
  934. _st(self)._refresh();
  935. return self}, function($ctx1) {$ctx1.fill(self,"onDoneIt",{},smalltalk.HLInspectorWidget)})},
  936. args: [],
  937. source: "onDoneIt\x0a\x0a\x09self refresh",
  938. messageSends: ["refresh"],
  939. referencedClasses: []
  940. }),
  941. smalltalk.HLInspectorWidget);
  942. smalltalk.addMethod(
  943. smalltalk.method({
  944. selector: "onInspectIt",
  945. category: 'reactions',
  946. fn: function (){
  947. var self=this;
  948. return smalltalk.withContext(function($ctx1) {
  949. return self}, function($ctx1) {$ctx1.fill(self,"onInspectIt",{},smalltalk.HLInspectorWidget)})},
  950. args: [],
  951. source: "onInspectIt",
  952. messageSends: [],
  953. referencedClasses: []
  954. }),
  955. smalltalk.HLInspectorWidget);
  956. smalltalk.addMethod(
  957. smalltalk.method({
  958. selector: "onInstanceVariableSelected",
  959. category: 'reactions',
  960. fn: function (){
  961. var self=this;
  962. return smalltalk.withContext(function($ctx1) {
  963. _st(_st(self)._codeWidget())._receiver_(_st(_st(self)._model())._selectedInstVarObject());
  964. _st(self)._refreshDisplayWidget();
  965. return self}, function($ctx1) {$ctx1.fill(self,"onInstanceVariableSelected",{},smalltalk.HLInspectorWidget)})},
  966. args: [],
  967. source: "onInstanceVariableSelected\x0a\x09self codeWidget receiver: self model selectedInstVarObject.\x0a\x09self refreshDisplayWidget",
  968. messageSends: ["receiver:", "selectedInstVarObject", "model", "codeWidget", "refreshDisplayWidget"],
  969. referencedClasses: []
  970. }),
  971. smalltalk.HLInspectorWidget);
  972. smalltalk.addMethod(
  973. smalltalk.method({
  974. selector: "onPrintIt",
  975. category: 'reactions',
  976. fn: function (){
  977. var self=this;
  978. return smalltalk.withContext(function($ctx1) {
  979. return self}, function($ctx1) {$ctx1.fill(self,"onPrintIt",{},smalltalk.HLInspectorWidget)})},
  980. args: [],
  981. source: "onPrintIt",
  982. messageSends: [],
  983. referencedClasses: []
  984. }),
  985. smalltalk.HLInspectorWidget);
  986. smalltalk.addMethod(
  987. smalltalk.method({
  988. selector: "open",
  989. category: 'actions',
  990. fn: function (){
  991. var self=this;
  992. function $HLTab(){return smalltalk.HLTab||(typeof HLTab=="undefined"?nil:HLTab)}
  993. function $HLManager(){return smalltalk.HLManager||(typeof HLManager=="undefined"?nil:HLManager)}
  994. return smalltalk.withContext(function($ctx1) {
  995. _st(_st($HLManager())._current())._addTab_(_st($HLTab())._on_labelled_(self,_st(self)._tabLabel()));
  996. return self}, function($ctx1) {$ctx1.fill(self,"open",{},smalltalk.HLInspectorWidget)})},
  997. args: [],
  998. source: "open\x0a\x09HLManager current addTab: (HLTab on: self labelled: self tabLabel)",
  999. messageSends: ["addTab:", "on:labelled:", "tabLabel", "current"],
  1000. referencedClasses: ["HLTab", "HLManager"]
  1001. }),
  1002. smalltalk.HLInspectorWidget);
  1003. smalltalk.addMethod(
  1004. smalltalk.method({
  1005. selector: "refresh",
  1006. category: 'actions',
  1007. fn: function (){
  1008. var self=this;
  1009. return smalltalk.withContext(function($ctx1) {
  1010. _st(self)._inspect_(_st(self)._inspectee());
  1011. return self}, function($ctx1) {$ctx1.fill(self,"refresh",{},smalltalk.HLInspectorWidget)})},
  1012. args: [],
  1013. source: "refresh\x0a\x09self inspect: self inspectee",
  1014. messageSends: ["inspect:", "inspectee"],
  1015. referencedClasses: []
  1016. }),
  1017. smalltalk.HLInspectorWidget);
  1018. smalltalk.addMethod(
  1019. smalltalk.method({
  1020. selector: "refreshDisplayWidget",
  1021. category: 'actions',
  1022. fn: function (){
  1023. var self=this;
  1024. return smalltalk.withContext(function($ctx1) {
  1025. _st(_st(self)._displayWidget())._refresh();
  1026. return self}, function($ctx1) {$ctx1.fill(self,"refreshDisplayWidget",{},smalltalk.HLInspectorWidget)})},
  1027. args: [],
  1028. source: "refreshDisplayWidget\x0a\x09self displayWidget refresh",
  1029. messageSends: ["refresh", "displayWidget"],
  1030. referencedClasses: []
  1031. }),
  1032. smalltalk.HLInspectorWidget);
  1033. smalltalk.addMethod(
  1034. smalltalk.method({
  1035. selector: "refreshVariablesWidget",
  1036. category: 'actions',
  1037. fn: function (){
  1038. var self=this;
  1039. return smalltalk.withContext(function($ctx1) {
  1040. _st(_st(self)._variablesWidget())._refresh();
  1041. return self}, function($ctx1) {$ctx1.fill(self,"refreshVariablesWidget",{},smalltalk.HLInspectorWidget)})},
  1042. args: [],
  1043. source: "refreshVariablesWidget\x0a\x09self variablesWidget refresh",
  1044. messageSends: ["refresh", "variablesWidget"],
  1045. referencedClasses: []
  1046. }),
  1047. smalltalk.HLInspectorWidget);
  1048. smalltalk.addMethod(
  1049. smalltalk.method({
  1050. selector: "register",
  1051. category: 'registration',
  1052. fn: function (){
  1053. var self=this;
  1054. function $HLInspector(){return smalltalk.HLInspector||(typeof HLInspector=="undefined"?nil:HLInspector)}
  1055. return smalltalk.withContext(function($ctx1) {
  1056. _st($HLInspector())._register_(self);
  1057. return self}, function($ctx1) {$ctx1.fill(self,"register",{},smalltalk.HLInspectorWidget)})},
  1058. args: [],
  1059. source: "register\x0a\x09HLInspector register: self",
  1060. messageSends: ["register:"],
  1061. referencedClasses: ["HLInspector"]
  1062. }),
  1063. smalltalk.HLInspectorWidget);
  1064. smalltalk.addMethod(
  1065. smalltalk.method({
  1066. selector: "renderContentOn:",
  1067. category: 'rendering',
  1068. fn: function (html){
  1069. var self=this;
  1070. function $HLVerticalSplitter(){return smalltalk.HLVerticalSplitter||(typeof HLVerticalSplitter=="undefined"?nil:HLVerticalSplitter)}
  1071. function $HLHorizontalSplitter(){return smalltalk.HLHorizontalSplitter||(typeof HLHorizontalSplitter=="undefined"?nil:HLHorizontalSplitter)}
  1072. return smalltalk.withContext(function($ctx1) {
  1073. _st(html)._with_(_st($HLHorizontalSplitter())._with_with_(_st($HLVerticalSplitter())._with_with_(_st(self)._variablesWidget(),_st(self)._displayWidget()),_st(self)._codeWidget()));
  1074. return self}, function($ctx1) {$ctx1.fill(self,"renderContentOn:",{html:html},smalltalk.HLInspectorWidget)})},
  1075. args: ["html"],
  1076. source: "renderContentOn: html\x0a \x09html with: (HLHorizontalSplitter\x0a \x09with: (HLVerticalSplitter \x0a with: self variablesWidget\x0a with: self displayWidget)\x0a with: self codeWidget)\x0a ",
  1077. messageSends: ["with:", "with:with:", "variablesWidget", "displayWidget", "codeWidget"],
  1078. referencedClasses: ["HLVerticalSplitter", "HLHorizontalSplitter"]
  1079. }),
  1080. smalltalk.HLInspectorWidget);
  1081. smalltalk.addMethod(
  1082. smalltalk.method({
  1083. selector: "setLabel:",
  1084. category: 'actions',
  1085. fn: function (aString){
  1086. var self=this;
  1087. return smalltalk.withContext(function($ctx1) {
  1088. _st(_st(self)._model())._label_(aString);
  1089. return self}, function($ctx1) {$ctx1.fill(self,"setLabel:",{aString:aString},smalltalk.HLInspectorWidget)})},
  1090. args: ["aString"],
  1091. source: "setLabel: aString\x0a\x09self model label: aString",
  1092. messageSends: ["label:", "model"],
  1093. referencedClasses: []
  1094. }),
  1095. smalltalk.HLInspectorWidget);
  1096. smalltalk.addMethod(
  1097. smalltalk.method({
  1098. selector: "setVariables:",
  1099. category: 'actions',
  1100. fn: function (aDictionary){
  1101. var self=this;
  1102. return smalltalk.withContext(function($ctx1) {
  1103. _st(_st(self)._model())._variables_(aDictionary);
  1104. return self}, function($ctx1) {$ctx1.fill(self,"setVariables:",{aDictionary:aDictionary},smalltalk.HLInspectorWidget)})},
  1105. args: ["aDictionary"],
  1106. source: "setVariables: aDictionary\x0a\x09self model variables: aDictionary",
  1107. messageSends: ["variables:", "model"],
  1108. referencedClasses: []
  1109. }),
  1110. smalltalk.HLInspectorWidget);
  1111. smalltalk.addMethod(
  1112. smalltalk.method({
  1113. selector: "tabLabel",
  1114. category: 'accessing',
  1115. fn: function (){
  1116. var self=this;
  1117. return smalltalk.withContext(function($ctx1) {
  1118. return "Inspector";
  1119. }, function($ctx1) {$ctx1.fill(self,"tabLabel",{},smalltalk.HLInspectorWidget)})},
  1120. args: [],
  1121. source: "tabLabel\x0a ^ 'Inspector'",
  1122. messageSends: [],
  1123. referencedClasses: []
  1124. }),
  1125. smalltalk.HLInspectorWidget);
  1126. smalltalk.addMethod(
  1127. smalltalk.method({
  1128. selector: "unregister",
  1129. category: 'registration',
  1130. fn: function (){
  1131. var self=this;
  1132. function $HLInspector(){return smalltalk.HLInspector||(typeof HLInspector=="undefined"?nil:HLInspector)}
  1133. return smalltalk.withContext(function($ctx1) {
  1134. smalltalk.HLWidget.fn.prototype._unregister.apply(_st(self), []);
  1135. _st($HLInspector())._unregister_(self);
  1136. return self}, function($ctx1) {$ctx1.fill(self,"unregister",{},smalltalk.HLInspectorWidget)})},
  1137. args: [],
  1138. source: "unregister\x0a\x09super unregister.\x0a\x09HLInspector unregister: self",
  1139. messageSends: ["unregister", "unregister:"],
  1140. referencedClasses: ["HLInspector"]
  1141. }),
  1142. smalltalk.HLInspectorWidget);
  1143. smalltalk.addMethod(
  1144. smalltalk.method({
  1145. selector: "variablesWidget",
  1146. category: 'accessing',
  1147. fn: function (){
  1148. var self=this;
  1149. function $HLInspectorVariablesWidget(){return smalltalk.HLInspectorVariablesWidget||(typeof HLInspectorVariablesWidget=="undefined"?nil:HLInspectorVariablesWidget)}
  1150. return smalltalk.withContext(function($ctx1) {
  1151. var $2,$3,$4,$1;
  1152. $2=self["@variablesWidget"];
  1153. if(($receiver = $2) == nil || $receiver == undefined){
  1154. $3=_st($HLInspectorVariablesWidget())._new();
  1155. _st($3)._model_(_st(self)._model());
  1156. $4=_st($3)._yourself();
  1157. self["@variablesWidget"]=$4;
  1158. $1=self["@variablesWidget"];
  1159. } else {
  1160. $1=$2;
  1161. };
  1162. return $1;
  1163. }, function($ctx1) {$ctx1.fill(self,"variablesWidget",{},smalltalk.HLInspectorWidget)})},
  1164. args: [],
  1165. source: "variablesWidget\x0a\x09^ variablesWidget ifNil: [\x0a\x09\x09variablesWidget := HLInspectorVariablesWidget new\x0a \x09\x09model: self model;\x0a \x09yourself ]",
  1166. messageSends: ["ifNil:", "model:", "model", "new", "yourself"],
  1167. referencedClasses: ["HLInspectorVariablesWidget"]
  1168. }),
  1169. smalltalk.HLInspectorWidget);
  1170. smalltalk.addClass('HLInspector', smalltalk.HLInspectorWidget, [], 'Helios-Inspector');
  1171. smalltalk.addMethod(
  1172. smalltalk.method({
  1173. selector: "renderContentOn:",
  1174. category: 'rendering',
  1175. fn: function (html){
  1176. var self=this;
  1177. function $HLVerticalSplitter(){return smalltalk.HLVerticalSplitter||(typeof HLVerticalSplitter=="undefined"?nil:HLVerticalSplitter)}
  1178. function $HLHorizontalSplitter(){return smalltalk.HLHorizontalSplitter||(typeof HLHorizontalSplitter=="undefined"?nil:HLHorizontalSplitter)}
  1179. function $HLContainer(){return smalltalk.HLContainer||(typeof HLContainer=="undefined"?nil:HLContainer)}
  1180. return smalltalk.withContext(function($ctx1) {
  1181. _st(html)._with_(_st($HLContainer())._with_(_st($HLHorizontalSplitter())._with_with_(_st($HLVerticalSplitter())._with_with_(_st(self)._variablesWidget(),_st(self)._displayWidget()),_st(self)._codeWidget())));
  1182. _st(_st(self)._variablesWidget())._focus();
  1183. return self}, function($ctx1) {$ctx1.fill(self,"renderContentOn:",{html:html},smalltalk.HLInspector)})},
  1184. args: ["html"],
  1185. source: "renderContentOn: html\x0a \x09html with: (HLContainer with: (HLHorizontalSplitter\x0a \x09with: (HLVerticalSplitter \x0a with: self variablesWidget\x0a with: self displayWidget)\x0a with: self codeWidget)).\x0a\x09\x0a\x09self variablesWidget focus",
  1186. messageSends: ["with:", "with:with:", "variablesWidget", "displayWidget", "codeWidget", "focus"],
  1187. referencedClasses: ["HLVerticalSplitter", "HLHorizontalSplitter", "HLContainer"]
  1188. }),
  1189. smalltalk.HLInspector);
  1190. smalltalk.HLInspector.klass.iVarNames = ['inspectors'];
  1191. smalltalk.addMethod(
  1192. smalltalk.method({
  1193. selector: "canBeOpenAsTab",
  1194. category: 'testing',
  1195. fn: function (){
  1196. var self=this;
  1197. return smalltalk.withContext(function($ctx1) {
  1198. return false;
  1199. }, function($ctx1) {$ctx1.fill(self,"canBeOpenAsTab",{},smalltalk.HLInspector.klass)})},
  1200. args: [],
  1201. source: "canBeOpenAsTab\x0a\x09^ false",
  1202. messageSends: [],
  1203. referencedClasses: []
  1204. }),
  1205. smalltalk.HLInspector.klass);
  1206. smalltalk.addMethod(
  1207. smalltalk.method({
  1208. selector: "initialize",
  1209. category: 'initialization',
  1210. fn: function (){
  1211. var self=this;
  1212. return smalltalk.withContext(function($ctx1) {
  1213. smalltalk.HLInspectorWidget.klass.fn.prototype._initialize.apply(_st(self), []);
  1214. _st(self)._watchChanges();
  1215. return self}, function($ctx1) {$ctx1.fill(self,"initialize",{},smalltalk.HLInspector.klass)})},
  1216. args: [],
  1217. source: "initialize\x0a\x09super initialize.\x0a\x09self watchChanges",
  1218. messageSends: ["initialize", "watchChanges"],
  1219. referencedClasses: []
  1220. }),
  1221. smalltalk.HLInspector.klass);
  1222. smalltalk.addMethod(
  1223. smalltalk.method({
  1224. selector: "inspect:",
  1225. category: 'actions',
  1226. fn: function (anObject){
  1227. var self=this;
  1228. return smalltalk.withContext(function($ctx1) {
  1229. var $1,$2;
  1230. $1=_st(self)._new();
  1231. _st($1)._inspect_(anObject);
  1232. $2=_st($1)._open();
  1233. return self}, function($ctx1) {$ctx1.fill(self,"inspect:",{anObject:anObject},smalltalk.HLInspector.klass)})},
  1234. args: ["anObject"],
  1235. source: "inspect: anObject\x0a\x09self new\x0a\x09\x09inspect: anObject;\x0a\x09\x09open",
  1236. messageSends: ["inspect:", "new", "open"],
  1237. referencedClasses: []
  1238. }),
  1239. smalltalk.HLInspector.klass);
  1240. smalltalk.addMethod(
  1241. smalltalk.method({
  1242. selector: "inspectors",
  1243. category: 'accessing',
  1244. fn: function (){
  1245. var self=this;
  1246. function $OrderedCollection(){return smalltalk.OrderedCollection||(typeof OrderedCollection=="undefined"?nil:OrderedCollection)}
  1247. return smalltalk.withContext(function($ctx1) {
  1248. var $2,$1;
  1249. $2=self["@inspectors"];
  1250. if(($receiver = $2) == nil || $receiver == undefined){
  1251. self["@inspectors"]=_st($OrderedCollection())._new();
  1252. $1=self["@inspectors"];
  1253. } else {
  1254. $1=$2;
  1255. };
  1256. return $1;
  1257. }, function($ctx1) {$ctx1.fill(self,"inspectors",{},smalltalk.HLInspector.klass)})},
  1258. args: [],
  1259. source: "inspectors\x0a\x09^ inspectors ifNil: [ inspectors := OrderedCollection new ]",
  1260. messageSends: ["ifNil:", "new"],
  1261. referencedClasses: ["OrderedCollection"]
  1262. }),
  1263. smalltalk.HLInspector.klass);
  1264. smalltalk.addMethod(
  1265. smalltalk.method({
  1266. selector: "register:",
  1267. category: 'registration',
  1268. fn: function (anInspector){
  1269. var self=this;
  1270. return smalltalk.withContext(function($ctx1) {
  1271. _st(_st(self)._inspectors())._add_(anInspector);
  1272. return self}, function($ctx1) {$ctx1.fill(self,"register:",{anInspector:anInspector},smalltalk.HLInspector.klass)})},
  1273. args: ["anInspector"],
  1274. source: "register: anInspector\x0a\x09self inspectors add: anInspector",
  1275. messageSends: ["add:", "inspectors"],
  1276. referencedClasses: []
  1277. }),
  1278. smalltalk.HLInspector.klass);
  1279. smalltalk.addMethod(
  1280. smalltalk.method({
  1281. selector: "tabClass",
  1282. category: 'accessing',
  1283. fn: function (){
  1284. var self=this;
  1285. return smalltalk.withContext(function($ctx1) {
  1286. return "inspector";
  1287. }, function($ctx1) {$ctx1.fill(self,"tabClass",{},smalltalk.HLInspector.klass)})},
  1288. args: [],
  1289. source: "tabClass\x0a\x09^ 'inspector'",
  1290. messageSends: [],
  1291. referencedClasses: []
  1292. }),
  1293. smalltalk.HLInspector.klass);
  1294. smalltalk.addMethod(
  1295. smalltalk.method({
  1296. selector: "tabLabel",
  1297. category: 'accessing',
  1298. fn: function (){
  1299. var self=this;
  1300. return smalltalk.withContext(function($ctx1) {
  1301. return "Inspector";
  1302. }, function($ctx1) {$ctx1.fill(self,"tabLabel",{},smalltalk.HLInspector.klass)})},
  1303. args: [],
  1304. source: "tabLabel\x0a\x09^ 'Inspector'",
  1305. messageSends: [],
  1306. referencedClasses: []
  1307. }),
  1308. smalltalk.HLInspector.klass);
  1309. smalltalk.addMethod(
  1310. smalltalk.method({
  1311. selector: "tabPriority",
  1312. category: 'accessing',
  1313. fn: function (){
  1314. var self=this;
  1315. return smalltalk.withContext(function($ctx1) {
  1316. return (10);
  1317. }, function($ctx1) {$ctx1.fill(self,"tabPriority",{},smalltalk.HLInspector.klass)})},
  1318. args: [],
  1319. source: "tabPriority\x0a\x09^ 10",
  1320. messageSends: [],
  1321. referencedClasses: []
  1322. }),
  1323. smalltalk.HLInspector.klass);
  1324. smalltalk.addMethod(
  1325. smalltalk.method({
  1326. selector: "unregister:",
  1327. category: 'registration',
  1328. fn: function (anInspector){
  1329. var self=this;
  1330. return smalltalk.withContext(function($ctx1) {
  1331. _st(_st(self)._inspectors())._remove_(anInspector);
  1332. return self}, function($ctx1) {$ctx1.fill(self,"unregister:",{anInspector:anInspector},smalltalk.HLInspector.klass)})},
  1333. args: ["anInspector"],
  1334. source: "unregister: anInspector\x0a\x09self inspectors remove: anInspector",
  1335. messageSends: ["remove:", "inspectors"],
  1336. referencedClasses: []
  1337. }),
  1338. smalltalk.HLInspector.klass);
  1339. smalltalk.addMethod(
  1340. smalltalk.method({
  1341. selector: "watchChanges",
  1342. category: 'initialization',
  1343. fn: function (){
  1344. var self=this;
  1345. return smalltalk.withContext(function($ctx1) {
  1346. _st((function(){
  1347. return smalltalk.withContext(function($ctx2) {
  1348. return _st(_st(self)._inspectors())._do_((function(each){
  1349. return smalltalk.withContext(function($ctx3) {
  1350. return _st(each)._refresh();
  1351. }, function($ctx3) {$ctx3.fillBlock({each:each},$ctx1)})}));
  1352. }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}))._valueWithInterval_((500));
  1353. return self}, function($ctx1) {$ctx1.fill(self,"watchChanges",{},smalltalk.HLInspector.klass)})},
  1354. args: [],
  1355. source: "watchChanges\x0a\x09[ self inspectors do: [ :each | each refresh ] ]\x0a\x09\x09valueWithInterval: 500",
  1356. messageSends: ["valueWithInterval:", "do:", "refresh", "inspectors"],
  1357. referencedClasses: []
  1358. }),
  1359. smalltalk.HLInspector.klass);