Helios-Inspector.js 63 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951195219531954195519561957195819591960196119621963196419651966196719681969197019711972197319741975197619771978197919801981198219831984198519861987198819891990199119921993199419951996199719981999200020012002200320042005200620072008200920102011201220132014
  1. define(["amber/boot", "require", "helios/Helios-Core"], function($boot,requirejs){"use strict";
  2. var $core=$boot.api,nil=$boot.nilAsValue,$nil=$boot.nilAsReceiver,$recv=$boot.asReceiver,$globals=$boot.globals;
  3. var $pkg = $core.addPackage("Helios-Inspector");
  4. $pkg.transport = {"type":"amd","amdNamespace":"helios"};
  5. $core.addClass("HLInspectorDisplayWidget", $globals.HLNavigationListWidget, "Helios-Inspector");
  6. $core.setSlots($globals.HLInspectorDisplayWidget, ["inspector"]);
  7. $core.addMethod(
  8. $core.method({
  9. selector: "inspector",
  10. protocol: "accessing",
  11. //>>excludeStart("ide", pragmas.excludeIdeData);
  12. args: [],
  13. source: "inspector\x0a\x09^ inspector",
  14. referencedClasses: [],
  15. //>>excludeEnd("ide");
  16. pragmas: [],
  17. messageSends: []
  18. }, function ($methodClass){ return function (){
  19. var self=this,$self=this;
  20. return $self.inspector;
  21. }; }),
  22. $globals.HLInspectorDisplayWidget);
  23. $core.addMethod(
  24. $core.method({
  25. selector: "inspector:",
  26. protocol: "accessing",
  27. //>>excludeStart("ide", pragmas.excludeIdeData);
  28. args: ["anInspector"],
  29. source: "inspector: anInspector\x0a\x09inspector := anInspector",
  30. referencedClasses: [],
  31. //>>excludeEnd("ide");
  32. pragmas: [],
  33. messageSends: []
  34. }, function ($methodClass){ return function (anInspector){
  35. var self=this,$self=this;
  36. $self.inspector=anInspector;
  37. return self;
  38. }; }),
  39. $globals.HLInspectorDisplayWidget);
  40. $core.addMethod(
  41. $core.method({
  42. selector: "model",
  43. protocol: "accessing",
  44. //>>excludeStart("ide", pragmas.excludeIdeData);
  45. args: [],
  46. source: "model\x0a\x0a\x09^ self inspector model",
  47. referencedClasses: [],
  48. //>>excludeEnd("ide");
  49. pragmas: [],
  50. messageSends: ["model", "inspector"]
  51. }, function ($methodClass){ return function (){
  52. var self=this,$self=this;
  53. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  54. return $core.withContext(function($ctx1) {
  55. //>>excludeEnd("ctx");
  56. return $recv($self._inspector())._model();
  57. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  58. }, function($ctx1) {$ctx1.fill(self,"model",{})});
  59. //>>excludeEnd("ctx");
  60. }; }),
  61. $globals.HLInspectorDisplayWidget);
  62. $core.addMethod(
  63. $core.method({
  64. selector: "renderContentOn:",
  65. protocol: "rendering",
  66. //>>excludeStart("ide", pragmas.excludeIdeData);
  67. args: ["html"],
  68. source: "renderContentOn: html\x0a\x09\x0a html div with: self selectionDisplayString",
  69. referencedClasses: [],
  70. //>>excludeEnd("ide");
  71. pragmas: [],
  72. messageSends: ["with:", "div", "selectionDisplayString"]
  73. }, function ($methodClass){ return function (html){
  74. var self=this,$self=this;
  75. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  76. return $core.withContext(function($ctx1) {
  77. //>>excludeEnd("ctx");
  78. $recv($recv(html)._div())._with_($self._selectionDisplayString());
  79. return self;
  80. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  81. }, function($ctx1) {$ctx1.fill(self,"renderContentOn:",{html:html})});
  82. //>>excludeEnd("ctx");
  83. }; }),
  84. $globals.HLInspectorDisplayWidget);
  85. $core.addMethod(
  86. $core.method({
  87. selector: "selectionDisplayString",
  88. protocol: "rendering",
  89. //>>excludeStart("ide", pragmas.excludeIdeData);
  90. args: [],
  91. source: "selectionDisplayString\x0a\x09|selection|\x0a\x09selection := self model selection.\x0a ^ (self model instVarObjectAt: selection ifAbsent: [ ^ '' ]) printString",
  92. referencedClasses: [],
  93. //>>excludeEnd("ide");
  94. pragmas: [],
  95. messageSends: ["selection", "model", "printString", "instVarObjectAt:ifAbsent:"]
  96. }, function ($methodClass){ return function (){
  97. var self=this,$self=this;
  98. var selection;
  99. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  100. return $core.withContext(function($ctx1) {
  101. //>>excludeEnd("ctx");
  102. var $early={};
  103. try {
  104. selection=$recv([$self._model()
  105. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  106. ,$ctx1.sendIdx["model"]=1
  107. //>>excludeEnd("ctx");
  108. ][0])._selection();
  109. return $recv($recv($self._model())._instVarObjectAt_ifAbsent_(selection,(function(){
  110. throw $early=[""];
  111. })))._printString();
  112. }
  113. catch(e) {if(e===$early)return e[0]; throw e}
  114. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  115. }, function($ctx1) {$ctx1.fill(self,"selectionDisplayString",{selection:selection})});
  116. //>>excludeEnd("ctx");
  117. }; }),
  118. $globals.HLInspectorDisplayWidget);
  119. $core.addClass("HLInspectorModel", $globals.HLModel, "Helios-Inspector");
  120. $core.setSlots($globals.HLInspectorModel, ["inspectee", "code", "variables", "label", "selection"]);
  121. //>>excludeStart("ide", pragmas.excludeIdeData);
  122. $globals.HLInspectorModel.comment="I am the model of the Helios inspector `HLInspectorWidget`.\x0a\x0a## API\x0a\x0aUse the method `inspect:on:` to inspect an object on an inspector.";
  123. //>>excludeEnd("ide");
  124. $core.addMethod(
  125. $core.method({
  126. selector: "code",
  127. protocol: "accessing",
  128. //>>excludeStart("ide", pragmas.excludeIdeData);
  129. args: [],
  130. source: "code\x0a\x09\x22Answers the code model working for this workspace model\x22\x0a\x09^ code ifNil:[ code := HLCodeModel on: self environment ]",
  131. referencedClasses: ["HLCodeModel"],
  132. //>>excludeEnd("ide");
  133. pragmas: [],
  134. messageSends: ["ifNil:", "on:", "environment"]
  135. }, function ($methodClass){ return function (){
  136. var self=this,$self=this;
  137. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  138. return $core.withContext(function($ctx1) {
  139. //>>excludeEnd("ctx");
  140. var $1;
  141. $1=$self.code;
  142. if($1 == null || $1.a$nil){
  143. $self.code=$recv($globals.HLCodeModel)._on_($self._environment());
  144. return $self.code;
  145. } else {
  146. return $1;
  147. }
  148. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  149. }, function($ctx1) {$ctx1.fill(self,"code",{})});
  150. //>>excludeEnd("ctx");
  151. }; }),
  152. $globals.HLInspectorModel);
  153. $core.addMethod(
  154. $core.method({
  155. selector: "inspect:on:",
  156. protocol: "actions",
  157. //>>excludeStart("ide", pragmas.excludeIdeData);
  158. args: ["anObject", "anInspector"],
  159. source: "inspect: anObject on: anInspector\x0a\x09inspectee := anObject.\x0a\x09variables := #().\x0a\x09inspectee inspectOn: anInspector",
  160. referencedClasses: [],
  161. //>>excludeEnd("ide");
  162. pragmas: [],
  163. messageSends: ["inspectOn:"]
  164. }, function ($methodClass){ return function (anObject,anInspector){
  165. var self=this,$self=this;
  166. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  167. return $core.withContext(function($ctx1) {
  168. //>>excludeEnd("ctx");
  169. $self.inspectee=anObject;
  170. $self.variables=[];
  171. $recv($self.inspectee)._inspectOn_(anInspector);
  172. return self;
  173. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  174. }, function($ctx1) {$ctx1.fill(self,"inspect:on:",{anObject:anObject,anInspector:anInspector})});
  175. //>>excludeEnd("ctx");
  176. }; }),
  177. $globals.HLInspectorModel);
  178. $core.addMethod(
  179. $core.method({
  180. selector: "inspectee",
  181. protocol: "accessing",
  182. //>>excludeStart("ide", pragmas.excludeIdeData);
  183. args: [],
  184. source: "inspectee \x0a\x09^ inspectee",
  185. referencedClasses: [],
  186. //>>excludeEnd("ide");
  187. pragmas: [],
  188. messageSends: []
  189. }, function ($methodClass){ return function (){
  190. var self=this,$self=this;
  191. return $self.inspectee;
  192. }; }),
  193. $globals.HLInspectorModel);
  194. $core.addMethod(
  195. $core.method({
  196. selector: "inspectee:",
  197. protocol: "accessing",
  198. //>>excludeStart("ide", pragmas.excludeIdeData);
  199. args: ["anObject"],
  200. source: "inspectee: anObject \x0a\x09inspectee := anObject",
  201. referencedClasses: [],
  202. //>>excludeEnd("ide");
  203. pragmas: [],
  204. messageSends: []
  205. }, function ($methodClass){ return function (anObject){
  206. var self=this,$self=this;
  207. $self.inspectee=anObject;
  208. return self;
  209. }; }),
  210. $globals.HLInspectorModel);
  211. $core.addMethod(
  212. $core.method({
  213. selector: "instVarObjectAt:ifAbsent:",
  214. protocol: "actions",
  215. //>>excludeStart("ide", pragmas.excludeIdeData);
  216. args: ["anInstVarName", "aBlock"],
  217. source: "instVarObjectAt: anInstVarName ifAbsent: aBlock\x0a\x09^ (self variables detect: [ :assoc | assoc key = anInstVarName ] ifNone: aBlock) value",
  218. referencedClasses: [],
  219. //>>excludeEnd("ide");
  220. pragmas: [],
  221. messageSends: ["value", "detect:ifNone:", "variables", "=", "key"]
  222. }, function ($methodClass){ return function (anInstVarName,aBlock){
  223. var self=this,$self=this;
  224. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  225. return $core.withContext(function($ctx1) {
  226. //>>excludeEnd("ctx");
  227. return $recv($recv($self._variables())._detect_ifNone_((function(assoc){
  228. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  229. return $core.withContext(function($ctx2) {
  230. //>>excludeEnd("ctx");
  231. return $recv($recv(assoc)._key()).__eq(anInstVarName);
  232. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  233. }, function($ctx2) {$ctx2.fillBlock({assoc:assoc},$ctx1,1)});
  234. //>>excludeEnd("ctx");
  235. }),aBlock))._value();
  236. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  237. }, function($ctx1) {$ctx1.fill(self,"instVarObjectAt:ifAbsent:",{anInstVarName:anInstVarName,aBlock:aBlock})});
  238. //>>excludeEnd("ctx");
  239. }; }),
  240. $globals.HLInspectorModel);
  241. $core.addMethod(
  242. $core.method({
  243. selector: "label",
  244. protocol: "accessing",
  245. //>>excludeStart("ide", pragmas.excludeIdeData);
  246. args: [],
  247. source: "label\x0a ^ label ifNil: [ self inspectee printString ]",
  248. referencedClasses: [],
  249. //>>excludeEnd("ide");
  250. pragmas: [],
  251. messageSends: ["ifNil:", "printString", "inspectee"]
  252. }, function ($methodClass){ return function (){
  253. var self=this,$self=this;
  254. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  255. return $core.withContext(function($ctx1) {
  256. //>>excludeEnd("ctx");
  257. var $1;
  258. $1=$self.label;
  259. if($1 == null || $1.a$nil){
  260. return $recv($self._inspectee())._printString();
  261. } else {
  262. return $1;
  263. }
  264. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  265. }, function($ctx1) {$ctx1.fill(self,"label",{})});
  266. //>>excludeEnd("ctx");
  267. }; }),
  268. $globals.HLInspectorModel);
  269. $core.addMethod(
  270. $core.method({
  271. selector: "label:",
  272. protocol: "accessing",
  273. //>>excludeStart("ide", pragmas.excludeIdeData);
  274. args: ["aString"],
  275. source: "label: aString\x0a label := aString",
  276. referencedClasses: [],
  277. //>>excludeEnd("ide");
  278. pragmas: [],
  279. messageSends: []
  280. }, function ($methodClass){ return function (aString){
  281. var self=this,$self=this;
  282. $self.label=aString;
  283. return self;
  284. }; }),
  285. $globals.HLInspectorModel);
  286. $core.addMethod(
  287. $core.method({
  288. selector: "selectedInstVar:",
  289. protocol: "actions",
  290. //>>excludeStart("ide", pragmas.excludeIdeData);
  291. args: ["anInstVarName"],
  292. source: "selectedInstVar: anInstVarName\x0a self selection: anInstVarName",
  293. referencedClasses: [],
  294. //>>excludeEnd("ide");
  295. pragmas: [],
  296. messageSends: ["selection:"]
  297. }, function ($methodClass){ return function (anInstVarName){
  298. var self=this,$self=this;
  299. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  300. return $core.withContext(function($ctx1) {
  301. //>>excludeEnd("ctx");
  302. $self._selection_(anInstVarName);
  303. return self;
  304. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  305. }, function($ctx1) {$ctx1.fill(self,"selectedInstVar:",{anInstVarName:anInstVarName})});
  306. //>>excludeEnd("ctx");
  307. }; }),
  308. $globals.HLInspectorModel);
  309. $core.addMethod(
  310. $core.method({
  311. selector: "selectedInstVarObject",
  312. protocol: "accessing",
  313. //>>excludeStart("ide", pragmas.excludeIdeData);
  314. args: [],
  315. source: "selectedInstVarObject\x0a\x09^ self instVarObjectAt: self selection ifAbsent: [ self error: 'Unable to get variable value.' ]",
  316. referencedClasses: [],
  317. //>>excludeEnd("ide");
  318. pragmas: [],
  319. messageSends: ["instVarObjectAt:ifAbsent:", "selection", "error:"]
  320. }, function ($methodClass){ return function (){
  321. var self=this,$self=this;
  322. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  323. return $core.withContext(function($ctx1) {
  324. //>>excludeEnd("ctx");
  325. return $self._instVarObjectAt_ifAbsent_($self._selection(),(function(){
  326. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  327. return $core.withContext(function($ctx2) {
  328. //>>excludeEnd("ctx");
  329. return $self._error_("Unable to get variable value.");
  330. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  331. }, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
  332. //>>excludeEnd("ctx");
  333. }));
  334. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  335. }, function($ctx1) {$ctx1.fill(self,"selectedInstVarObject",{})});
  336. //>>excludeEnd("ctx");
  337. }; }),
  338. $globals.HLInspectorModel);
  339. $core.addMethod(
  340. $core.method({
  341. selector: "selection",
  342. protocol: "accessing",
  343. //>>excludeStart("ide", pragmas.excludeIdeData);
  344. args: [],
  345. source: "selection\x0a\x09^ selection ifNil:[ '' ]",
  346. referencedClasses: [],
  347. //>>excludeEnd("ide");
  348. pragmas: [],
  349. messageSends: ["ifNil:"]
  350. }, function ($methodClass){ return function (){
  351. var self=this,$self=this;
  352. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  353. return $core.withContext(function($ctx1) {
  354. //>>excludeEnd("ctx");
  355. var $1;
  356. $1=$self.selection;
  357. if($1 == null || $1.a$nil){
  358. return "";
  359. } else {
  360. return $1;
  361. }
  362. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  363. }, function($ctx1) {$ctx1.fill(self,"selection",{})});
  364. //>>excludeEnd("ctx");
  365. }; }),
  366. $globals.HLInspectorModel);
  367. $core.addMethod(
  368. $core.method({
  369. selector: "selection:",
  370. protocol: "accessing",
  371. //>>excludeStart("ide", pragmas.excludeIdeData);
  372. args: ["anObject"],
  373. source: "selection: anObject\x0a\x09selection := anObject.\x0a\x0a\x09self announcer announce: (HLInstanceVariableSelected on: selection)",
  374. referencedClasses: ["HLInstanceVariableSelected"],
  375. //>>excludeEnd("ide");
  376. pragmas: [],
  377. messageSends: ["announce:", "announcer", "on:"]
  378. }, function ($methodClass){ return function (anObject){
  379. var self=this,$self=this;
  380. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  381. return $core.withContext(function($ctx1) {
  382. //>>excludeEnd("ctx");
  383. $self.selection=anObject;
  384. $recv($self._announcer())._announce_($recv($globals.HLInstanceVariableSelected)._on_($self.selection));
  385. return self;
  386. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  387. }, function($ctx1) {$ctx1.fill(self,"selection:",{anObject:anObject})});
  388. //>>excludeEnd("ctx");
  389. }; }),
  390. $globals.HLInspectorModel);
  391. $core.addMethod(
  392. $core.method({
  393. selector: "subscribe:",
  394. protocol: "actions",
  395. //>>excludeStart("ide", pragmas.excludeIdeData);
  396. args: ["aWidget"],
  397. source: "subscribe: aWidget\x0a\x09aWidget subscribeTo: self announcer",
  398. referencedClasses: [],
  399. //>>excludeEnd("ide");
  400. pragmas: [],
  401. messageSends: ["subscribeTo:", "announcer"]
  402. }, function ($methodClass){ return function (aWidget){
  403. var self=this,$self=this;
  404. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  405. return $core.withContext(function($ctx1) {
  406. //>>excludeEnd("ctx");
  407. $recv(aWidget)._subscribeTo_($self._announcer());
  408. return self;
  409. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  410. }, function($ctx1) {$ctx1.fill(self,"subscribe:",{aWidget:aWidget})});
  411. //>>excludeEnd("ctx");
  412. }; }),
  413. $globals.HLInspectorModel);
  414. $core.addMethod(
  415. $core.method({
  416. selector: "variables",
  417. protocol: "accessing",
  418. //>>excludeStart("ide", pragmas.excludeIdeData);
  419. args: [],
  420. source: "variables\x0a\x09^ variables ifNil: [ #() ]",
  421. referencedClasses: [],
  422. //>>excludeEnd("ide");
  423. pragmas: [],
  424. messageSends: ["ifNil:"]
  425. }, function ($methodClass){ return function (){
  426. var self=this,$self=this;
  427. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  428. return $core.withContext(function($ctx1) {
  429. //>>excludeEnd("ctx");
  430. var $1;
  431. $1=$self.variables;
  432. if($1 == null || $1.a$nil){
  433. return [];
  434. } else {
  435. return $1;
  436. }
  437. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  438. }, function($ctx1) {$ctx1.fill(self,"variables",{})});
  439. //>>excludeEnd("ctx");
  440. }; }),
  441. $globals.HLInspectorModel);
  442. $core.addMethod(
  443. $core.method({
  444. selector: "variables:",
  445. protocol: "accessing",
  446. //>>excludeStart("ide", pragmas.excludeIdeData);
  447. args: ["aCollection"],
  448. source: "variables: aCollection\x0a\x09variables := aCollection",
  449. referencedClasses: [],
  450. //>>excludeEnd("ide");
  451. pragmas: [],
  452. messageSends: []
  453. }, function ($methodClass){ return function (aCollection){
  454. var self=this,$self=this;
  455. $self.variables=aCollection;
  456. return self;
  457. }; }),
  458. $globals.HLInspectorModel);
  459. $core.addMethod(
  460. $core.method({
  461. selector: "on:",
  462. protocol: "actions",
  463. //>>excludeStart("ide", pragmas.excludeIdeData);
  464. args: ["anEnvironment"],
  465. source: "on: anEnvironment\x0a\x0a\x09^ self new\x0a \x09environment: anEnvironment;\x0a yourself",
  466. referencedClasses: [],
  467. //>>excludeEnd("ide");
  468. pragmas: [],
  469. messageSends: ["environment:", "new", "yourself"]
  470. }, function ($methodClass){ return function (anEnvironment){
  471. var self=this,$self=this;
  472. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  473. return $core.withContext(function($ctx1) {
  474. //>>excludeEnd("ctx");
  475. var $1;
  476. $1=$self._new();
  477. $recv($1)._environment_(anEnvironment);
  478. return $recv($1)._yourself();
  479. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  480. }, function($ctx1) {$ctx1.fill(self,"on:",{anEnvironment:anEnvironment})});
  481. //>>excludeEnd("ctx");
  482. }; }),
  483. $globals.HLInspectorModel.a$cls);
  484. $core.addClass("HLInspectorVariablesWidget", $globals.HLNavigationListWidget, "Helios-Inspector");
  485. $core.setSlots($globals.HLInspectorVariablesWidget, ["announcer", "inspector", "list", "diveButton"]);
  486. $core.addMethod(
  487. $core.method({
  488. selector: "announcer",
  489. protocol: "accessing",
  490. //>>excludeStart("ide", pragmas.excludeIdeData);
  491. args: [],
  492. source: "announcer\x0a\x09^ announcer ifNil:[ announcer := Announcer new ]",
  493. referencedClasses: ["Announcer"],
  494. //>>excludeEnd("ide");
  495. pragmas: [],
  496. messageSends: ["ifNil:", "new"]
  497. }, function ($methodClass){ return function (){
  498. var self=this,$self=this;
  499. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  500. return $core.withContext(function($ctx1) {
  501. //>>excludeEnd("ctx");
  502. var $1;
  503. $1=$self.announcer;
  504. if($1 == null || $1.a$nil){
  505. $self.announcer=$recv($globals.Announcer)._new();
  506. return $self.announcer;
  507. } else {
  508. return $1;
  509. }
  510. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  511. }, function($ctx1) {$ctx1.fill(self,"announcer",{})});
  512. //>>excludeEnd("ctx");
  513. }; }),
  514. $globals.HLInspectorVariablesWidget);
  515. $core.addMethod(
  516. $core.method({
  517. selector: "defaultItems",
  518. protocol: "defaults",
  519. //>>excludeStart("ide", pragmas.excludeIdeData);
  520. args: [],
  521. source: "defaultItems\x0a\x09^ self variables",
  522. referencedClasses: [],
  523. //>>excludeEnd("ide");
  524. pragmas: [],
  525. messageSends: ["variables"]
  526. }, function ($methodClass){ return function (){
  527. var self=this,$self=this;
  528. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  529. return $core.withContext(function($ctx1) {
  530. //>>excludeEnd("ctx");
  531. return $self._variables();
  532. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  533. }, function($ctx1) {$ctx1.fill(self,"defaultItems",{})});
  534. //>>excludeEnd("ctx");
  535. }; }),
  536. $globals.HLInspectorVariablesWidget);
  537. $core.addMethod(
  538. $core.method({
  539. selector: "dive",
  540. protocol: "actions",
  541. //>>excludeStart("ide", pragmas.excludeIdeData);
  542. args: [],
  543. source: "dive\x0a\x09self announcer announce: HLDiveRequested new",
  544. referencedClasses: ["HLDiveRequested"],
  545. //>>excludeEnd("ide");
  546. pragmas: [],
  547. messageSends: ["announce:", "announcer", "new"]
  548. }, function ($methodClass){ return function (){
  549. var self=this,$self=this;
  550. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  551. return $core.withContext(function($ctx1) {
  552. //>>excludeEnd("ctx");
  553. $recv($self._announcer())._announce_($recv($globals.HLDiveRequested)._new());
  554. return self;
  555. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  556. }, function($ctx1) {$ctx1.fill(self,"dive",{})});
  557. //>>excludeEnd("ctx");
  558. }; }),
  559. $globals.HLInspectorVariablesWidget);
  560. $core.addMethod(
  561. $core.method({
  562. selector: "inspector",
  563. protocol: "accessing",
  564. //>>excludeStart("ide", pragmas.excludeIdeData);
  565. args: [],
  566. source: "inspector\x0a\x09^ inspector",
  567. referencedClasses: [],
  568. //>>excludeEnd("ide");
  569. pragmas: [],
  570. messageSends: []
  571. }, function ($methodClass){ return function (){
  572. var self=this,$self=this;
  573. return $self.inspector;
  574. }; }),
  575. $globals.HLInspectorVariablesWidget);
  576. $core.addMethod(
  577. $core.method({
  578. selector: "inspector:",
  579. protocol: "accessing",
  580. //>>excludeStart("ide", pragmas.excludeIdeData);
  581. args: ["anInspector"],
  582. source: "inspector: anInspector\x0a\x09inspector := anInspector",
  583. referencedClasses: [],
  584. //>>excludeEnd("ide");
  585. pragmas: [],
  586. messageSends: []
  587. }, function ($methodClass){ return function (anInspector){
  588. var self=this,$self=this;
  589. $self.inspector=anInspector;
  590. return self;
  591. }; }),
  592. $globals.HLInspectorVariablesWidget);
  593. $core.addMethod(
  594. $core.method({
  595. selector: "label",
  596. protocol: "accessing",
  597. //>>excludeStart("ide", pragmas.excludeIdeData);
  598. args: [],
  599. source: "label\x0a\x09^ self model label",
  600. referencedClasses: [],
  601. //>>excludeEnd("ide");
  602. pragmas: [],
  603. messageSends: ["label", "model"]
  604. }, function ($methodClass){ return function (){
  605. var self=this,$self=this;
  606. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  607. return $core.withContext(function($ctx1) {
  608. //>>excludeEnd("ctx");
  609. return $recv($self._model())._label();
  610. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  611. }, function($ctx1) {$ctx1.fill(self,"label",{})});
  612. //>>excludeEnd("ctx");
  613. }; }),
  614. $globals.HLInspectorVariablesWidget);
  615. $core.addMethod(
  616. $core.method({
  617. selector: "model",
  618. protocol: "accessing",
  619. //>>excludeStart("ide", pragmas.excludeIdeData);
  620. args: [],
  621. source: "model\x0a ^ self inspector model",
  622. referencedClasses: [],
  623. //>>excludeEnd("ide");
  624. pragmas: [],
  625. messageSends: ["model", "inspector"]
  626. }, function ($methodClass){ return function (){
  627. var self=this,$self=this;
  628. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  629. return $core.withContext(function($ctx1) {
  630. //>>excludeEnd("ctx");
  631. return $recv($self._inspector())._model();
  632. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  633. }, function($ctx1) {$ctx1.fill(self,"model",{})});
  634. //>>excludeEnd("ctx");
  635. }; }),
  636. $globals.HLInspectorVariablesWidget);
  637. $core.addMethod(
  638. $core.method({
  639. selector: "refresh",
  640. protocol: "actions",
  641. //>>excludeStart("ide", pragmas.excludeIdeData);
  642. args: [],
  643. source: "refresh\x0a\x09self variables = self items ifFalse: [\x0a\x09\x09self resetItems.\x0a \x09super refresh ]",
  644. referencedClasses: [],
  645. //>>excludeEnd("ide");
  646. pragmas: [],
  647. messageSends: ["ifFalse:", "=", "variables", "items", "resetItems", "refresh"]
  648. }, function ($methodClass){ return function (){
  649. var self=this,$self=this;
  650. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  651. return $core.withContext(function($ctx1) {
  652. //>>excludeEnd("ctx");
  653. if(!$core.assert($recv($self._variables()).__eq($self._items()))){
  654. $self._resetItems();
  655. [(
  656. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  657. $ctx1.supercall = true,
  658. //>>excludeEnd("ctx");
  659. ($methodClass.superclass||$boot.nilAsClass).fn.prototype._refresh.call($self))
  660. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  661. ,$ctx1.supercall = false
  662. //>>excludeEnd("ctx");
  663. ][0];
  664. }
  665. return self;
  666. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  667. }, function($ctx1) {$ctx1.fill(self,"refresh",{})});
  668. //>>excludeEnd("ctx");
  669. }; }),
  670. $globals.HLInspectorVariablesWidget);
  671. $core.addMethod(
  672. $core.method({
  673. selector: "renderButtonsOn:",
  674. protocol: "rendering",
  675. //>>excludeStart("ide", pragmas.excludeIdeData);
  676. args: ["html"],
  677. source: "renderButtonsOn: html\x0a\x09diveButton := html button \x0a\x09\x09class: 'btn btn-default';\x0a\x09\x09with: 'Dive'; \x0a\x09\x09onClick: [ self dive ]",
  678. referencedClasses: [],
  679. //>>excludeEnd("ide");
  680. pragmas: [],
  681. messageSends: ["class:", "button", "with:", "onClick:", "dive"]
  682. }, function ($methodClass){ return function (html){
  683. var self=this,$self=this;
  684. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  685. return $core.withContext(function($ctx1) {
  686. //>>excludeEnd("ctx");
  687. var $1;
  688. $1=$recv(html)._button();
  689. $recv($1)._class_("btn btn-default");
  690. $recv($1)._with_("Dive");
  691. $self.diveButton=$recv($1)._onClick_((function(){
  692. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  693. return $core.withContext(function($ctx2) {
  694. //>>excludeEnd("ctx");
  695. return $self._dive();
  696. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  697. }, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
  698. //>>excludeEnd("ctx");
  699. }));
  700. return self;
  701. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  702. }, function($ctx1) {$ctx1.fill(self,"renderButtonsOn:",{html:html})});
  703. //>>excludeEnd("ctx");
  704. }; }),
  705. $globals.HLInspectorVariablesWidget);
  706. $core.addMethod(
  707. $core.method({
  708. selector: "renderContentOn:",
  709. protocol: "rendering",
  710. //>>excludeStart("ide", pragmas.excludeIdeData);
  711. args: ["html"],
  712. source: "renderContentOn: html\x0a\x09self renderHeadOn: html.\x0a\x09super renderContentOn: html.\x0a\x09self wrapper onDblClick: [ self dive ]",
  713. referencedClasses: [],
  714. //>>excludeEnd("ide");
  715. pragmas: [],
  716. messageSends: ["renderHeadOn:", "renderContentOn:", "onDblClick:", "wrapper", "dive"]
  717. }, function ($methodClass){ return function (html){
  718. var self=this,$self=this;
  719. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  720. return $core.withContext(function($ctx1) {
  721. //>>excludeEnd("ctx");
  722. $self._renderHeadOn_(html);
  723. [(
  724. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  725. $ctx1.supercall = true,
  726. //>>excludeEnd("ctx");
  727. ($methodClass.superclass||$boot.nilAsClass).fn.prototype._renderContentOn_.call($self,html))
  728. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  729. ,$ctx1.supercall = false
  730. //>>excludeEnd("ctx");
  731. ][0];
  732. $recv($self._wrapper())._onDblClick_((function(){
  733. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  734. return $core.withContext(function($ctx2) {
  735. //>>excludeEnd("ctx");
  736. return $self._dive();
  737. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  738. }, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
  739. //>>excludeEnd("ctx");
  740. }));
  741. return self;
  742. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  743. }, function($ctx1) {$ctx1.fill(self,"renderContentOn:",{html:html})});
  744. //>>excludeEnd("ctx");
  745. }; }),
  746. $globals.HLInspectorVariablesWidget);
  747. $core.addMethod(
  748. $core.method({
  749. selector: "renderHeadOn:",
  750. protocol: "rendering",
  751. //>>excludeStart("ide", pragmas.excludeIdeData);
  752. args: ["html"],
  753. source: "renderHeadOn: html\x0a\x09html div \x0a\x09\x09class: 'list-label';\x0a\x09\x09with: self label",
  754. referencedClasses: [],
  755. //>>excludeEnd("ide");
  756. pragmas: [],
  757. messageSends: ["class:", "div", "with:", "label"]
  758. }, function ($methodClass){ return function (html){
  759. var self=this,$self=this;
  760. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  761. return $core.withContext(function($ctx1) {
  762. //>>excludeEnd("ctx");
  763. var $1;
  764. $1=$recv(html)._div();
  765. $recv($1)._class_("list-label");
  766. $recv($1)._with_($self._label());
  767. return self;
  768. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  769. }, function($ctx1) {$ctx1.fill(self,"renderHeadOn:",{html:html})});
  770. //>>excludeEnd("ctx");
  771. }; }),
  772. $globals.HLInspectorVariablesWidget);
  773. $core.addMethod(
  774. $core.method({
  775. selector: "resetItems",
  776. protocol: "actions",
  777. //>>excludeStart("ide", pragmas.excludeIdeData);
  778. args: [],
  779. source: "resetItems\x0a\x09items := nil",
  780. referencedClasses: [],
  781. //>>excludeEnd("ide");
  782. pragmas: [],
  783. messageSends: []
  784. }, function ($methodClass){ return function (){
  785. var self=this,$self=this;
  786. $self.items=nil;
  787. return self;
  788. }; }),
  789. $globals.HLInspectorVariablesWidget);
  790. $core.addMethod(
  791. $core.method({
  792. selector: "selectItem:",
  793. protocol: "reactions",
  794. //>>excludeStart("ide", pragmas.excludeIdeData);
  795. args: ["anObject"],
  796. source: "selectItem: anObject\x0a\x09super selectItem: anObject.\x0a self model selectedInstVar: anObject",
  797. referencedClasses: [],
  798. //>>excludeEnd("ide");
  799. pragmas: [],
  800. messageSends: ["selectItem:", "selectedInstVar:", "model"]
  801. }, function ($methodClass){ return function (anObject){
  802. var self=this,$self=this;
  803. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  804. return $core.withContext(function($ctx1) {
  805. //>>excludeEnd("ctx");
  806. [(
  807. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  808. $ctx1.supercall = true,
  809. //>>excludeEnd("ctx");
  810. ($methodClass.superclass||$boot.nilAsClass).fn.prototype._selectItem_.call($self,anObject))
  811. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  812. ,$ctx1.supercall = false
  813. //>>excludeEnd("ctx");
  814. ][0];
  815. $recv($self._model())._selectedInstVar_(anObject);
  816. return self;
  817. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  818. }, function($ctx1) {$ctx1.fill(self,"selectItem:",{anObject:anObject})});
  819. //>>excludeEnd("ctx");
  820. }; }),
  821. $globals.HLInspectorVariablesWidget);
  822. $core.addMethod(
  823. $core.method({
  824. selector: "selection",
  825. protocol: "accessing",
  826. //>>excludeStart("ide", pragmas.excludeIdeData);
  827. args: [],
  828. source: "selection\x0a\x09^ self model selection",
  829. referencedClasses: [],
  830. //>>excludeEnd("ide");
  831. pragmas: [],
  832. messageSends: ["selection", "model"]
  833. }, function ($methodClass){ return function (){
  834. var self=this,$self=this;
  835. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  836. return $core.withContext(function($ctx1) {
  837. //>>excludeEnd("ctx");
  838. return $recv($self._model())._selection();
  839. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  840. }, function($ctx1) {$ctx1.fill(self,"selection",{})});
  841. //>>excludeEnd("ctx");
  842. }; }),
  843. $globals.HLInspectorVariablesWidget);
  844. $core.addMethod(
  845. $core.method({
  846. selector: "variables",
  847. protocol: "accessing",
  848. //>>excludeStart("ide", pragmas.excludeIdeData);
  849. args: [],
  850. source: "variables\x0a\x09^ self model variables collect: #key",
  851. referencedClasses: [],
  852. //>>excludeEnd("ide");
  853. pragmas: [],
  854. messageSends: ["collect:", "variables", "model"]
  855. }, function ($methodClass){ return function (){
  856. var self=this,$self=this;
  857. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  858. return $core.withContext(function($ctx1) {
  859. //>>excludeEnd("ctx");
  860. return $recv($recv($self._model())._variables())._collect_("key");
  861. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  862. }, function($ctx1) {$ctx1.fill(self,"variables",{})});
  863. //>>excludeEnd("ctx");
  864. }; }),
  865. $globals.HLInspectorVariablesWidget);
  866. $core.addClass("HLInspectorWidget", $globals.HLWidget, "Helios-Inspector");
  867. $core.setSlots($globals.HLInspectorWidget, ["model", "variablesWidget", "displayWidget", "codeWidget"]);
  868. $core.addMethod(
  869. $core.method({
  870. selector: "codeWidget",
  871. protocol: "accessing",
  872. //>>excludeStart("ide", pragmas.excludeIdeData);
  873. args: [],
  874. source: "codeWidget\x0a\x09^ codeWidget ifNil: [\x0a\x09\x09codeWidget := self defaultCodeWidget ]",
  875. referencedClasses: [],
  876. //>>excludeEnd("ide");
  877. pragmas: [],
  878. messageSends: ["ifNil:", "defaultCodeWidget"]
  879. }, function ($methodClass){ return function (){
  880. var self=this,$self=this;
  881. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  882. return $core.withContext(function($ctx1) {
  883. //>>excludeEnd("ctx");
  884. var $1;
  885. $1=$self.codeWidget;
  886. if($1 == null || $1.a$nil){
  887. $self.codeWidget=$self._defaultCodeWidget();
  888. return $self.codeWidget;
  889. } else {
  890. return $1;
  891. }
  892. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  893. }, function($ctx1) {$ctx1.fill(self,"codeWidget",{})});
  894. //>>excludeEnd("ctx");
  895. }; }),
  896. $globals.HLInspectorWidget);
  897. $core.addMethod(
  898. $core.method({
  899. selector: "codeWidget:",
  900. protocol: "accessing",
  901. //>>excludeStart("ide", pragmas.excludeIdeData);
  902. args: ["aWidget"],
  903. source: "codeWidget: aWidget\x0a\x09codeWidget := aWidget",
  904. referencedClasses: [],
  905. //>>excludeEnd("ide");
  906. pragmas: [],
  907. messageSends: []
  908. }, function ($methodClass){ return function (aWidget){
  909. var self=this,$self=this;
  910. $self.codeWidget=aWidget;
  911. return self;
  912. }; }),
  913. $globals.HLInspectorWidget);
  914. $core.addMethod(
  915. $core.method({
  916. selector: "defaultCodeWidget",
  917. protocol: "defaults",
  918. //>>excludeStart("ide", pragmas.excludeIdeData);
  919. args: [],
  920. source: "defaultCodeWidget\x0a\x09^ HLCodeWidget new\x0a \x09model: self model code;\x0a \x09receiver: self model inspectee;\x0a \x09yourself",
  921. referencedClasses: ["HLCodeWidget"],
  922. //>>excludeEnd("ide");
  923. pragmas: [],
  924. messageSends: ["model:", "new", "code", "model", "receiver:", "inspectee", "yourself"]
  925. }, function ($methodClass){ return function (){
  926. var self=this,$self=this;
  927. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  928. return $core.withContext(function($ctx1) {
  929. //>>excludeEnd("ctx");
  930. var $1;
  931. $1=$recv($globals.HLCodeWidget)._new();
  932. $recv($1)._model_($recv([$self._model()
  933. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  934. ,$ctx1.sendIdx["model"]=1
  935. //>>excludeEnd("ctx");
  936. ][0])._code());
  937. $recv($1)._receiver_($recv($self._model())._inspectee());
  938. return $recv($1)._yourself();
  939. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  940. }, function($ctx1) {$ctx1.fill(self,"defaultCodeWidget",{})});
  941. //>>excludeEnd("ctx");
  942. }; }),
  943. $globals.HLInspectorWidget);
  944. $core.addMethod(
  945. $core.method({
  946. selector: "displayWidget",
  947. protocol: "accessing",
  948. //>>excludeStart("ide", pragmas.excludeIdeData);
  949. args: [],
  950. source: "displayWidget\x0a\x09^ displayWidget ifNil: [\x0a\x09\x09displayWidget := HLInspectorDisplayWidget new\x0a \x09\x09inspector: self;\x0a \x09yourself ]",
  951. referencedClasses: ["HLInspectorDisplayWidget"],
  952. //>>excludeEnd("ide");
  953. pragmas: [],
  954. messageSends: ["ifNil:", "inspector:", "new", "yourself"]
  955. }, function ($methodClass){ return function (){
  956. var self=this,$self=this;
  957. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  958. return $core.withContext(function($ctx1) {
  959. //>>excludeEnd("ctx");
  960. var $1,$2;
  961. $1=$self.displayWidget;
  962. if($1 == null || $1.a$nil){
  963. $2=$recv($globals.HLInspectorDisplayWidget)._new();
  964. $recv($2)._inspector_(self);
  965. $self.displayWidget=$recv($2)._yourself();
  966. return $self.displayWidget;
  967. } else {
  968. return $1;
  969. }
  970. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  971. }, function($ctx1) {$ctx1.fill(self,"displayWidget",{})});
  972. //>>excludeEnd("ctx");
  973. }; }),
  974. $globals.HLInspectorWidget);
  975. $core.addMethod(
  976. $core.method({
  977. selector: "initialize",
  978. protocol: "accessing",
  979. //>>excludeStart("ide", pragmas.excludeIdeData);
  980. args: [],
  981. source: "initialize\x0a\x09super initialize.\x0a\x09self register",
  982. referencedClasses: [],
  983. //>>excludeEnd("ide");
  984. pragmas: [],
  985. messageSends: ["initialize", "register"]
  986. }, function ($methodClass){ return function (){
  987. var self=this,$self=this;
  988. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  989. return $core.withContext(function($ctx1) {
  990. //>>excludeEnd("ctx");
  991. [(
  992. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  993. $ctx1.supercall = true,
  994. //>>excludeEnd("ctx");
  995. ($methodClass.superclass||$boot.nilAsClass).fn.prototype._initialize.call($self))
  996. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  997. ,$ctx1.supercall = false
  998. //>>excludeEnd("ctx");
  999. ][0];
  1000. $self._register();
  1001. return self;
  1002. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1003. }, function($ctx1) {$ctx1.fill(self,"initialize",{})});
  1004. //>>excludeEnd("ctx");
  1005. }; }),
  1006. $globals.HLInspectorWidget);
  1007. $core.addMethod(
  1008. $core.method({
  1009. selector: "inspect:",
  1010. protocol: "actions",
  1011. //>>excludeStart("ide", pragmas.excludeIdeData);
  1012. args: ["anObject"],
  1013. source: "inspect: anObject\x0a\x09self model inspect: anObject on: self.\x0a\x09self codeWidget receiver: anObject.\x0a \x0a\x09self \x0a \x09refreshVariablesWidget;\x0a\x09\x09refreshDisplayWidget",
  1014. referencedClasses: [],
  1015. //>>excludeEnd("ide");
  1016. pragmas: [],
  1017. messageSends: ["inspect:on:", "model", "receiver:", "codeWidget", "refreshVariablesWidget", "refreshDisplayWidget"]
  1018. }, function ($methodClass){ return function (anObject){
  1019. var self=this,$self=this;
  1020. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1021. return $core.withContext(function($ctx1) {
  1022. //>>excludeEnd("ctx");
  1023. $recv($self._model())._inspect_on_(anObject,self);
  1024. $recv($self._codeWidget())._receiver_(anObject);
  1025. $self._refreshVariablesWidget();
  1026. $self._refreshDisplayWidget();
  1027. return self;
  1028. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1029. }, function($ctx1) {$ctx1.fill(self,"inspect:",{anObject:anObject})});
  1030. //>>excludeEnd("ctx");
  1031. }; }),
  1032. $globals.HLInspectorWidget);
  1033. $core.addMethod(
  1034. $core.method({
  1035. selector: "inspectee",
  1036. protocol: "accessing",
  1037. //>>excludeStart("ide", pragmas.excludeIdeData);
  1038. args: [],
  1039. source: "inspectee\x0a\x09^ self model inspectee",
  1040. referencedClasses: [],
  1041. //>>excludeEnd("ide");
  1042. pragmas: [],
  1043. messageSends: ["inspectee", "model"]
  1044. }, function ($methodClass){ return function (){
  1045. var self=this,$self=this;
  1046. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1047. return $core.withContext(function($ctx1) {
  1048. //>>excludeEnd("ctx");
  1049. return $recv($self._model())._inspectee();
  1050. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1051. }, function($ctx1) {$ctx1.fill(self,"inspectee",{})});
  1052. //>>excludeEnd("ctx");
  1053. }; }),
  1054. $globals.HLInspectorWidget);
  1055. $core.addMethod(
  1056. $core.method({
  1057. selector: "inspectee:",
  1058. protocol: "accessing",
  1059. //>>excludeStart("ide", pragmas.excludeIdeData);
  1060. args: ["anObject"],
  1061. source: "inspectee: anObject\x0a\x09self model inspectee: anObject",
  1062. referencedClasses: [],
  1063. //>>excludeEnd("ide");
  1064. pragmas: [],
  1065. messageSends: ["inspectee:", "model"]
  1066. }, function ($methodClass){ return function (anObject){
  1067. var self=this,$self=this;
  1068. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1069. return $core.withContext(function($ctx1) {
  1070. //>>excludeEnd("ctx");
  1071. $recv($self._model())._inspectee_(anObject);
  1072. return self;
  1073. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1074. }, function($ctx1) {$ctx1.fill(self,"inspectee:",{anObject:anObject})});
  1075. //>>excludeEnd("ctx");
  1076. }; }),
  1077. $globals.HLInspectorWidget);
  1078. $core.addMethod(
  1079. $core.method({
  1080. selector: "label",
  1081. protocol: "accessing",
  1082. //>>excludeStart("ide", pragmas.excludeIdeData);
  1083. args: [],
  1084. source: "label\x0a ^ self model label",
  1085. referencedClasses: [],
  1086. //>>excludeEnd("ide");
  1087. pragmas: [],
  1088. messageSends: ["label", "model"]
  1089. }, function ($methodClass){ return function (){
  1090. var self=this,$self=this;
  1091. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1092. return $core.withContext(function($ctx1) {
  1093. //>>excludeEnd("ctx");
  1094. return $recv($self._model())._label();
  1095. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1096. }, function($ctx1) {$ctx1.fill(self,"label",{})});
  1097. //>>excludeEnd("ctx");
  1098. }; }),
  1099. $globals.HLInspectorWidget);
  1100. $core.addMethod(
  1101. $core.method({
  1102. selector: "model",
  1103. protocol: "accessing",
  1104. //>>excludeStart("ide", pragmas.excludeIdeData);
  1105. args: [],
  1106. source: "model\x0a\x09^ model ifNil: [ \x0a \x09self model: HLInspectorModel new.\x0a\x09\x09model ]",
  1107. referencedClasses: ["HLInspectorModel"],
  1108. //>>excludeEnd("ide");
  1109. pragmas: [],
  1110. messageSends: ["ifNil:", "model:", "new"]
  1111. }, function ($methodClass){ return function (){
  1112. var self=this,$self=this;
  1113. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1114. return $core.withContext(function($ctx1) {
  1115. //>>excludeEnd("ctx");
  1116. var $1;
  1117. $1=$self.model;
  1118. if($1 == null || $1.a$nil){
  1119. $self._model_($recv($globals.HLInspectorModel)._new());
  1120. return $self.model;
  1121. } else {
  1122. return $1;
  1123. }
  1124. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1125. }, function($ctx1) {$ctx1.fill(self,"model",{})});
  1126. //>>excludeEnd("ctx");
  1127. }; }),
  1128. $globals.HLInspectorWidget);
  1129. $core.addMethod(
  1130. $core.method({
  1131. selector: "model:",
  1132. protocol: "accessing",
  1133. //>>excludeStart("ide", pragmas.excludeIdeData);
  1134. args: ["aModel"],
  1135. source: "model: aModel\x0a\x09model := aModel. \x0a self codeWidget model: aModel code.\x0a \x0a self \x0a observeCodeWidget;\x0a \x09observeVariablesWidget;\x0a observeModel",
  1136. referencedClasses: [],
  1137. //>>excludeEnd("ide");
  1138. pragmas: [],
  1139. messageSends: ["model:", "codeWidget", "code", "observeCodeWidget", "observeVariablesWidget", "observeModel"]
  1140. }, function ($methodClass){ return function (aModel){
  1141. var self=this,$self=this;
  1142. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1143. return $core.withContext(function($ctx1) {
  1144. //>>excludeEnd("ctx");
  1145. $self.model=aModel;
  1146. $recv($self._codeWidget())._model_($recv(aModel)._code());
  1147. $self._observeCodeWidget();
  1148. $self._observeVariablesWidget();
  1149. $self._observeModel();
  1150. return self;
  1151. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1152. }, function($ctx1) {$ctx1.fill(self,"model:",{aModel:aModel})});
  1153. //>>excludeEnd("ctx");
  1154. }; }),
  1155. $globals.HLInspectorWidget);
  1156. $core.addMethod(
  1157. $core.method({
  1158. selector: "observeCodeWidget",
  1159. protocol: "actions",
  1160. //>>excludeStart("ide", pragmas.excludeIdeData);
  1161. args: [],
  1162. source: "observeCodeWidget\x0a\x09self codeWidget announcer \x0a \x09on: HLDoItExecuted \x0a do: [ self onDoneIt ]",
  1163. referencedClasses: ["HLDoItExecuted"],
  1164. //>>excludeEnd("ide");
  1165. pragmas: [],
  1166. messageSends: ["on:do:", "announcer", "codeWidget", "onDoneIt"]
  1167. }, function ($methodClass){ return function (){
  1168. var self=this,$self=this;
  1169. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1170. return $core.withContext(function($ctx1) {
  1171. //>>excludeEnd("ctx");
  1172. $recv($recv($self._codeWidget())._announcer())._on_do_($globals.HLDoItExecuted,(function(){
  1173. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1174. return $core.withContext(function($ctx2) {
  1175. //>>excludeEnd("ctx");
  1176. return $self._onDoneIt();
  1177. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1178. }, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
  1179. //>>excludeEnd("ctx");
  1180. }));
  1181. return self;
  1182. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1183. }, function($ctx1) {$ctx1.fill(self,"observeCodeWidget",{})});
  1184. //>>excludeEnd("ctx");
  1185. }; }),
  1186. $globals.HLInspectorWidget);
  1187. $core.addMethod(
  1188. $core.method({
  1189. selector: "observeModel",
  1190. protocol: "actions",
  1191. //>>excludeStart("ide", pragmas.excludeIdeData);
  1192. args: [],
  1193. source: "observeModel\x0a\x09self model announcer\x0a on: HLInstanceVariableSelected\x0a\x09\x09send: #onInstanceVariableSelected\x0a\x09\x09to: self",
  1194. referencedClasses: ["HLInstanceVariableSelected"],
  1195. //>>excludeEnd("ide");
  1196. pragmas: [],
  1197. messageSends: ["on:send:to:", "announcer", "model"]
  1198. }, function ($methodClass){ return function (){
  1199. var self=this,$self=this;
  1200. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1201. return $core.withContext(function($ctx1) {
  1202. //>>excludeEnd("ctx");
  1203. $recv($recv($self._model())._announcer())._on_send_to_($globals.HLInstanceVariableSelected,"onInstanceVariableSelected",self);
  1204. return self;
  1205. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1206. }, function($ctx1) {$ctx1.fill(self,"observeModel",{})});
  1207. //>>excludeEnd("ctx");
  1208. }; }),
  1209. $globals.HLInspectorWidget);
  1210. $core.addMethod(
  1211. $core.method({
  1212. selector: "observeVariablesWidget",
  1213. protocol: "actions",
  1214. //>>excludeStart("ide", pragmas.excludeIdeData);
  1215. args: [],
  1216. source: "observeVariablesWidget\x0a\x09self variablesWidget announcer \x0a on: HLDiveRequested \x0a\x09\x09send: #onDive\x0a\x09\x09to: self",
  1217. referencedClasses: ["HLDiveRequested"],
  1218. //>>excludeEnd("ide");
  1219. pragmas: [],
  1220. messageSends: ["on:send:to:", "announcer", "variablesWidget"]
  1221. }, function ($methodClass){ return function (){
  1222. var self=this,$self=this;
  1223. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1224. return $core.withContext(function($ctx1) {
  1225. //>>excludeEnd("ctx");
  1226. $recv($recv($self._variablesWidget())._announcer())._on_send_to_($globals.HLDiveRequested,"onDive",self);
  1227. return self;
  1228. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1229. }, function($ctx1) {$ctx1.fill(self,"observeVariablesWidget",{})});
  1230. //>>excludeEnd("ctx");
  1231. }; }),
  1232. $globals.HLInspectorWidget);
  1233. $core.addMethod(
  1234. $core.method({
  1235. selector: "onDive",
  1236. protocol: "reactions",
  1237. //>>excludeStart("ide", pragmas.excludeIdeData);
  1238. args: [],
  1239. source: "onDive\x0a\x09HLInspector new \x0a\x09\x09inspect: self model selectedInstVarObject;\x0a\x09\x09openAsTab",
  1240. referencedClasses: ["HLInspector"],
  1241. //>>excludeEnd("ide");
  1242. pragmas: [],
  1243. messageSends: ["inspect:", "new", "selectedInstVarObject", "model", "openAsTab"]
  1244. }, function ($methodClass){ return function (){
  1245. var self=this,$self=this;
  1246. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1247. return $core.withContext(function($ctx1) {
  1248. //>>excludeEnd("ctx");
  1249. var $1;
  1250. $1=$recv($globals.HLInspector)._new();
  1251. $recv($1)._inspect_($recv($self._model())._selectedInstVarObject());
  1252. $recv($1)._openAsTab();
  1253. return self;
  1254. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1255. }, function($ctx1) {$ctx1.fill(self,"onDive",{})});
  1256. //>>excludeEnd("ctx");
  1257. }; }),
  1258. $globals.HLInspectorWidget);
  1259. $core.addMethod(
  1260. $core.method({
  1261. selector: "onDoneIt",
  1262. protocol: "reactions",
  1263. //>>excludeStart("ide", pragmas.excludeIdeData);
  1264. args: [],
  1265. source: "onDoneIt\x0a\x09| refreshInterval |\x0a\x09refreshInterval := 'helios.inspector.refreshMillis' settingValueIfAbsent: 500.\x0a\x09refreshInterval < 0 ifFalse: [ self refresh ]",
  1266. referencedClasses: [],
  1267. //>>excludeEnd("ide");
  1268. pragmas: [],
  1269. messageSends: ["settingValueIfAbsent:", "ifFalse:", "<", "refresh"]
  1270. }, function ($methodClass){ return function (){
  1271. var self=this,$self=this;
  1272. var refreshInterval;
  1273. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1274. return $core.withContext(function($ctx1) {
  1275. //>>excludeEnd("ctx");
  1276. refreshInterval="helios.inspector.refreshMillis"._settingValueIfAbsent_((500));
  1277. if(!$core.assert($recv(refreshInterval).__lt((0)))){
  1278. $self._refresh();
  1279. }
  1280. return self;
  1281. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1282. }, function($ctx1) {$ctx1.fill(self,"onDoneIt",{refreshInterval:refreshInterval})});
  1283. //>>excludeEnd("ctx");
  1284. }; }),
  1285. $globals.HLInspectorWidget);
  1286. $core.addMethod(
  1287. $core.method({
  1288. selector: "onInspectIt",
  1289. protocol: "reactions",
  1290. //>>excludeStart("ide", pragmas.excludeIdeData);
  1291. args: [],
  1292. source: "onInspectIt",
  1293. referencedClasses: [],
  1294. //>>excludeEnd("ide");
  1295. pragmas: [],
  1296. messageSends: []
  1297. }, function ($methodClass){ return function (){
  1298. var self=this,$self=this;
  1299. return self;
  1300. }; }),
  1301. $globals.HLInspectorWidget);
  1302. $core.addMethod(
  1303. $core.method({
  1304. selector: "onInstanceVariableSelected",
  1305. protocol: "reactions",
  1306. //>>excludeStart("ide", pragmas.excludeIdeData);
  1307. args: [],
  1308. source: "onInstanceVariableSelected\x0a\x09self refreshDisplayWidget",
  1309. referencedClasses: [],
  1310. //>>excludeEnd("ide");
  1311. pragmas: [],
  1312. messageSends: ["refreshDisplayWidget"]
  1313. }, function ($methodClass){ return function (){
  1314. var self=this,$self=this;
  1315. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1316. return $core.withContext(function($ctx1) {
  1317. //>>excludeEnd("ctx");
  1318. $self._refreshDisplayWidget();
  1319. return self;
  1320. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1321. }, function($ctx1) {$ctx1.fill(self,"onInstanceVariableSelected",{})});
  1322. //>>excludeEnd("ctx");
  1323. }; }),
  1324. $globals.HLInspectorWidget);
  1325. $core.addMethod(
  1326. $core.method({
  1327. selector: "onPrintIt",
  1328. protocol: "reactions",
  1329. //>>excludeStart("ide", pragmas.excludeIdeData);
  1330. args: [],
  1331. source: "onPrintIt",
  1332. referencedClasses: [],
  1333. //>>excludeEnd("ide");
  1334. pragmas: [],
  1335. messageSends: []
  1336. }, function ($methodClass){ return function (){
  1337. var self=this,$self=this;
  1338. return self;
  1339. }; }),
  1340. $globals.HLInspectorWidget);
  1341. $core.addMethod(
  1342. $core.method({
  1343. selector: "refresh",
  1344. protocol: "actions",
  1345. //>>excludeStart("ide", pragmas.excludeIdeData);
  1346. args: [],
  1347. source: "refresh\x0a\x09self inspect: self inspectee",
  1348. referencedClasses: [],
  1349. //>>excludeEnd("ide");
  1350. pragmas: [],
  1351. messageSends: ["inspect:", "inspectee"]
  1352. }, function ($methodClass){ return function (){
  1353. var self=this,$self=this;
  1354. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1355. return $core.withContext(function($ctx1) {
  1356. //>>excludeEnd("ctx");
  1357. $self._inspect_($self._inspectee());
  1358. return self;
  1359. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1360. }, function($ctx1) {$ctx1.fill(self,"refresh",{})});
  1361. //>>excludeEnd("ctx");
  1362. }; }),
  1363. $globals.HLInspectorWidget);
  1364. $core.addMethod(
  1365. $core.method({
  1366. selector: "refreshDisplayWidget",
  1367. protocol: "actions",
  1368. //>>excludeStart("ide", pragmas.excludeIdeData);
  1369. args: [],
  1370. source: "refreshDisplayWidget\x0a\x09self displayWidget refresh",
  1371. referencedClasses: [],
  1372. //>>excludeEnd("ide");
  1373. pragmas: [],
  1374. messageSends: ["refresh", "displayWidget"]
  1375. }, function ($methodClass){ return function (){
  1376. var self=this,$self=this;
  1377. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1378. return $core.withContext(function($ctx1) {
  1379. //>>excludeEnd("ctx");
  1380. $recv($self._displayWidget())._refresh();
  1381. return self;
  1382. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1383. }, function($ctx1) {$ctx1.fill(self,"refreshDisplayWidget",{})});
  1384. //>>excludeEnd("ctx");
  1385. }; }),
  1386. $globals.HLInspectorWidget);
  1387. $core.addMethod(
  1388. $core.method({
  1389. selector: "refreshVariablesWidget",
  1390. protocol: "actions",
  1391. //>>excludeStart("ide", pragmas.excludeIdeData);
  1392. args: [],
  1393. source: "refreshVariablesWidget\x0a\x09self variablesWidget refresh",
  1394. referencedClasses: [],
  1395. //>>excludeEnd("ide");
  1396. pragmas: [],
  1397. messageSends: ["refresh", "variablesWidget"]
  1398. }, function ($methodClass){ return function (){
  1399. var self=this,$self=this;
  1400. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1401. return $core.withContext(function($ctx1) {
  1402. //>>excludeEnd("ctx");
  1403. $recv($self._variablesWidget())._refresh();
  1404. return self;
  1405. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1406. }, function($ctx1) {$ctx1.fill(self,"refreshVariablesWidget",{})});
  1407. //>>excludeEnd("ctx");
  1408. }; }),
  1409. $globals.HLInspectorWidget);
  1410. $core.addMethod(
  1411. $core.method({
  1412. selector: "register",
  1413. protocol: "registration",
  1414. //>>excludeStart("ide", pragmas.excludeIdeData);
  1415. args: [],
  1416. source: "register\x0a\x09HLInspector register: self",
  1417. referencedClasses: ["HLInspector"],
  1418. //>>excludeEnd("ide");
  1419. pragmas: [],
  1420. messageSends: ["register:"]
  1421. }, function ($methodClass){ return function (){
  1422. var self=this,$self=this;
  1423. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1424. return $core.withContext(function($ctx1) {
  1425. //>>excludeEnd("ctx");
  1426. $recv($globals.HLInspector)._register_(self);
  1427. return self;
  1428. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1429. }, function($ctx1) {$ctx1.fill(self,"register",{})});
  1430. //>>excludeEnd("ctx");
  1431. }; }),
  1432. $globals.HLInspectorWidget);
  1433. $core.addMethod(
  1434. $core.method({
  1435. selector: "renderContentOn:",
  1436. protocol: "rendering",
  1437. //>>excludeStart("ide", pragmas.excludeIdeData);
  1438. args: ["html"],
  1439. source: "renderContentOn: html\x0a \x09html with: (HLHorizontalSplitter\x0a \x09with: (HLVerticalSplitter \x0a with: self variablesWidget\x0a with: self displayWidget)\x0a with: self codeWidget)",
  1440. referencedClasses: ["HLHorizontalSplitter", "HLVerticalSplitter"],
  1441. //>>excludeEnd("ide");
  1442. pragmas: [],
  1443. messageSends: ["with:", "with:with:", "variablesWidget", "displayWidget", "codeWidget"]
  1444. }, function ($methodClass){ return function (html){
  1445. var self=this,$self=this;
  1446. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1447. return $core.withContext(function($ctx1) {
  1448. //>>excludeEnd("ctx");
  1449. $recv(html)._with_([$recv($globals.HLHorizontalSplitter)._with_with_($recv($globals.HLVerticalSplitter)._with_with_($self._variablesWidget(),$self._displayWidget()),$self._codeWidget())
  1450. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1451. ,$ctx1.sendIdx["with:with:"]=1
  1452. //>>excludeEnd("ctx");
  1453. ][0]);
  1454. return self;
  1455. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1456. }, function($ctx1) {$ctx1.fill(self,"renderContentOn:",{html:html})});
  1457. //>>excludeEnd("ctx");
  1458. }; }),
  1459. $globals.HLInspectorWidget);
  1460. $core.addMethod(
  1461. $core.method({
  1462. selector: "setLabel:",
  1463. protocol: "actions",
  1464. //>>excludeStart("ide", pragmas.excludeIdeData);
  1465. args: ["aString"],
  1466. source: "setLabel: aString\x0a\x09self model label: aString",
  1467. referencedClasses: [],
  1468. //>>excludeEnd("ide");
  1469. pragmas: [],
  1470. messageSends: ["label:", "model"]
  1471. }, function ($methodClass){ return function (aString){
  1472. var self=this,$self=this;
  1473. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1474. return $core.withContext(function($ctx1) {
  1475. //>>excludeEnd("ctx");
  1476. $recv($self._model())._label_(aString);
  1477. return self;
  1478. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1479. }, function($ctx1) {$ctx1.fill(self,"setLabel:",{aString:aString})});
  1480. //>>excludeEnd("ctx");
  1481. }; }),
  1482. $globals.HLInspectorWidget);
  1483. $core.addMethod(
  1484. $core.method({
  1485. selector: "setVariables:",
  1486. protocol: "actions",
  1487. //>>excludeStart("ide", pragmas.excludeIdeData);
  1488. args: ["aCollection"],
  1489. source: "setVariables: aCollection\x0a\x09self model variables: (\x0a\x09\x09(aCollection respondsTo: #associations)\x0a\x09\x09\x09ifTrue: [ aCollection associations ]\x0a\x09\x09\x09ifFalse: [ aCollection ])",
  1490. referencedClasses: [],
  1491. //>>excludeEnd("ide");
  1492. pragmas: [],
  1493. messageSends: ["variables:", "model", "ifTrue:ifFalse:", "respondsTo:", "associations"]
  1494. }, function ($methodClass){ return function (aCollection){
  1495. var self=this,$self=this;
  1496. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1497. return $core.withContext(function($ctx1) {
  1498. //>>excludeEnd("ctx");
  1499. var $1,$2;
  1500. $1=$self._model();
  1501. if($core.assert($recv(aCollection)._respondsTo_("associations"))){
  1502. $2=$recv(aCollection)._associations();
  1503. } else {
  1504. $2=aCollection;
  1505. }
  1506. $recv($1)._variables_($2);
  1507. return self;
  1508. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1509. }, function($ctx1) {$ctx1.fill(self,"setVariables:",{aCollection:aCollection})});
  1510. //>>excludeEnd("ctx");
  1511. }; }),
  1512. $globals.HLInspectorWidget);
  1513. $core.addMethod(
  1514. $core.method({
  1515. selector: "tabLabel",
  1516. protocol: "accessing",
  1517. //>>excludeStart("ide", pragmas.excludeIdeData);
  1518. args: [],
  1519. source: "tabLabel\x0a ^ 'Inspector'",
  1520. referencedClasses: [],
  1521. //>>excludeEnd("ide");
  1522. pragmas: [],
  1523. messageSends: []
  1524. }, function ($methodClass){ return function (){
  1525. var self=this,$self=this;
  1526. return "Inspector";
  1527. }; }),
  1528. $globals.HLInspectorWidget);
  1529. $core.addMethod(
  1530. $core.method({
  1531. selector: "unregister",
  1532. protocol: "registration",
  1533. //>>excludeStart("ide", pragmas.excludeIdeData);
  1534. args: [],
  1535. source: "unregister\x0a\x09super unregister.\x0a\x09HLInspector unregister: self",
  1536. referencedClasses: ["HLInspector"],
  1537. //>>excludeEnd("ide");
  1538. pragmas: [],
  1539. messageSends: ["unregister", "unregister:"]
  1540. }, function ($methodClass){ return function (){
  1541. var self=this,$self=this;
  1542. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1543. return $core.withContext(function($ctx1) {
  1544. //>>excludeEnd("ctx");
  1545. [(
  1546. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1547. $ctx1.supercall = true,
  1548. //>>excludeEnd("ctx");
  1549. ($methodClass.superclass||$boot.nilAsClass).fn.prototype._unregister.call($self))
  1550. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1551. ,$ctx1.supercall = false
  1552. //>>excludeEnd("ctx");
  1553. ][0];
  1554. $recv($globals.HLInspector)._unregister_(self);
  1555. return self;
  1556. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1557. }, function($ctx1) {$ctx1.fill(self,"unregister",{})});
  1558. //>>excludeEnd("ctx");
  1559. }; }),
  1560. $globals.HLInspectorWidget);
  1561. $core.addMethod(
  1562. $core.method({
  1563. selector: "variablesWidget",
  1564. protocol: "accessing",
  1565. //>>excludeStart("ide", pragmas.excludeIdeData);
  1566. args: [],
  1567. source: "variablesWidget\x0a\x09^ variablesWidget ifNil: [\x0a\x09\x09variablesWidget := HLInspectorVariablesWidget new\x0a \x09\x09inspector: self;\x0a \x09yourself ]",
  1568. referencedClasses: ["HLInspectorVariablesWidget"],
  1569. //>>excludeEnd("ide");
  1570. pragmas: [],
  1571. messageSends: ["ifNil:", "inspector:", "new", "yourself"]
  1572. }, function ($methodClass){ return function (){
  1573. var self=this,$self=this;
  1574. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1575. return $core.withContext(function($ctx1) {
  1576. //>>excludeEnd("ctx");
  1577. var $1,$2;
  1578. $1=$self.variablesWidget;
  1579. if($1 == null || $1.a$nil){
  1580. $2=$recv($globals.HLInspectorVariablesWidget)._new();
  1581. $recv($2)._inspector_(self);
  1582. $self.variablesWidget=$recv($2)._yourself();
  1583. return $self.variablesWidget;
  1584. } else {
  1585. return $1;
  1586. }
  1587. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1588. }, function($ctx1) {$ctx1.fill(self,"variablesWidget",{})});
  1589. //>>excludeEnd("ctx");
  1590. }; }),
  1591. $globals.HLInspectorWidget);
  1592. $core.addClass("HLInspector", $globals.HLInspectorWidget, "Helios-Inspector");
  1593. $core.addMethod(
  1594. $core.method({
  1595. selector: "inspect:",
  1596. protocol: "actions",
  1597. //>>excludeStart("ide", pragmas.excludeIdeData);
  1598. args: ["anObject"],
  1599. source: "inspect: anObject\x0a\x09super inspect: anObject.\x0a\x09[ self setTabLabel: self label ] fork",
  1600. referencedClasses: [],
  1601. //>>excludeEnd("ide");
  1602. pragmas: [],
  1603. messageSends: ["inspect:", "fork", "setTabLabel:", "label"]
  1604. }, function ($methodClass){ return function (anObject){
  1605. var self=this,$self=this;
  1606. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1607. return $core.withContext(function($ctx1) {
  1608. //>>excludeEnd("ctx");
  1609. [(
  1610. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1611. $ctx1.supercall = true,
  1612. //>>excludeEnd("ctx");
  1613. ($methodClass.superclass||$boot.nilAsClass).fn.prototype._inspect_.call($self,anObject))
  1614. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1615. ,$ctx1.supercall = false
  1616. //>>excludeEnd("ctx");
  1617. ][0];
  1618. $recv((function(){
  1619. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1620. return $core.withContext(function($ctx2) {
  1621. //>>excludeEnd("ctx");
  1622. return $self._setTabLabel_($self._label());
  1623. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1624. }, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
  1625. //>>excludeEnd("ctx");
  1626. }))._fork();
  1627. return self;
  1628. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1629. }, function($ctx1) {$ctx1.fill(self,"inspect:",{anObject:anObject})});
  1630. //>>excludeEnd("ctx");
  1631. }; }),
  1632. $globals.HLInspector);
  1633. $core.addMethod(
  1634. $core.method({
  1635. selector: "renderContentOn:",
  1636. protocol: "rendering",
  1637. //>>excludeStart("ide", pragmas.excludeIdeData);
  1638. args: ["html"],
  1639. 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",
  1640. referencedClasses: ["HLContainer", "HLHorizontalSplitter", "HLVerticalSplitter"],
  1641. //>>excludeEnd("ide");
  1642. pragmas: [],
  1643. messageSends: ["with:", "with:with:", "variablesWidget", "displayWidget", "codeWidget", "focus"]
  1644. }, function ($methodClass){ return function (html){
  1645. var self=this,$self=this;
  1646. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1647. return $core.withContext(function($ctx1) {
  1648. //>>excludeEnd("ctx");
  1649. [$recv(html)._with_($recv($globals.HLContainer)._with_([$recv($globals.HLHorizontalSplitter)._with_with_($recv($globals.HLVerticalSplitter)._with_with_([$self._variablesWidget()
  1650. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1651. ,$ctx1.sendIdx["variablesWidget"]=1
  1652. //>>excludeEnd("ctx");
  1653. ][0],$self._displayWidget()),$self._codeWidget())
  1654. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1655. ,$ctx1.sendIdx["with:with:"]=1
  1656. //>>excludeEnd("ctx");
  1657. ][0]))
  1658. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1659. ,$ctx1.sendIdx["with:"]=1
  1660. //>>excludeEnd("ctx");
  1661. ][0];
  1662. $recv($self._variablesWidget())._focus();
  1663. return self;
  1664. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1665. }, function($ctx1) {$ctx1.fill(self,"renderContentOn:",{html:html})});
  1666. //>>excludeEnd("ctx");
  1667. }; }),
  1668. $globals.HLInspector);
  1669. $core.setSlots($globals.HLInspector.a$cls, ["inspectors"]);
  1670. $core.addMethod(
  1671. $core.method({
  1672. selector: "canBeOpenAsTab",
  1673. protocol: "testing",
  1674. //>>excludeStart("ide", pragmas.excludeIdeData);
  1675. args: [],
  1676. source: "canBeOpenAsTab\x0a\x09^ false",
  1677. referencedClasses: [],
  1678. //>>excludeEnd("ide");
  1679. pragmas: [],
  1680. messageSends: []
  1681. }, function ($methodClass){ return function (){
  1682. var self=this,$self=this;
  1683. return false;
  1684. }; }),
  1685. $globals.HLInspector.a$cls);
  1686. $core.addMethod(
  1687. $core.method({
  1688. selector: "initialize",
  1689. protocol: "initialization",
  1690. //>>excludeStart("ide", pragmas.excludeIdeData);
  1691. args: [],
  1692. source: "initialize\x0a\x09super initialize.\x0a\x09self watchChanges",
  1693. referencedClasses: [],
  1694. //>>excludeEnd("ide");
  1695. pragmas: [],
  1696. messageSends: ["initialize", "watchChanges"]
  1697. }, function ($methodClass){ return function (){
  1698. var self=this,$self=this;
  1699. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1700. return $core.withContext(function($ctx1) {
  1701. //>>excludeEnd("ctx");
  1702. [(
  1703. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1704. $ctx1.supercall = true,
  1705. //>>excludeEnd("ctx");
  1706. ($methodClass.superclass||$boot.nilAsClass).fn.prototype._initialize.call($self))
  1707. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1708. ,$ctx1.supercall = false
  1709. //>>excludeEnd("ctx");
  1710. ][0];
  1711. $self._watchChanges();
  1712. return self;
  1713. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1714. }, function($ctx1) {$ctx1.fill(self,"initialize",{})});
  1715. //>>excludeEnd("ctx");
  1716. }; }),
  1717. $globals.HLInspector.a$cls);
  1718. $core.addMethod(
  1719. $core.method({
  1720. selector: "inspect:",
  1721. protocol: "actions",
  1722. //>>excludeStart("ide", pragmas.excludeIdeData);
  1723. args: ["anObject"],
  1724. source: "inspect: anObject\x0a\x09self new\x0a\x09\x09openAsTab;\x0a\x09\x09inspect: anObject",
  1725. referencedClasses: [],
  1726. //>>excludeEnd("ide");
  1727. pragmas: [],
  1728. messageSends: ["openAsTab", "new", "inspect:"]
  1729. }, function ($methodClass){ return function (anObject){
  1730. var self=this,$self=this;
  1731. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1732. return $core.withContext(function($ctx1) {
  1733. //>>excludeEnd("ctx");
  1734. var $1;
  1735. $1=$self._new();
  1736. $recv($1)._openAsTab();
  1737. $recv($1)._inspect_(anObject);
  1738. return self;
  1739. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1740. }, function($ctx1) {$ctx1.fill(self,"inspect:",{anObject:anObject})});
  1741. //>>excludeEnd("ctx");
  1742. }; }),
  1743. $globals.HLInspector.a$cls);
  1744. $core.addMethod(
  1745. $core.method({
  1746. selector: "inspectors",
  1747. protocol: "accessing",
  1748. //>>excludeStart("ide", pragmas.excludeIdeData);
  1749. args: [],
  1750. source: "inspectors\x0a\x09^ inspectors ifNil: [ inspectors := OrderedCollection new ]",
  1751. referencedClasses: ["OrderedCollection"],
  1752. //>>excludeEnd("ide");
  1753. pragmas: [],
  1754. messageSends: ["ifNil:", "new"]
  1755. }, function ($methodClass){ return function (){
  1756. var self=this,$self=this;
  1757. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1758. return $core.withContext(function($ctx1) {
  1759. //>>excludeEnd("ctx");
  1760. var $1;
  1761. $1=$self.inspectors;
  1762. if($1 == null || $1.a$nil){
  1763. $self.inspectors=$recv($globals.OrderedCollection)._new();
  1764. return $self.inspectors;
  1765. } else {
  1766. return $1;
  1767. }
  1768. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1769. }, function($ctx1) {$ctx1.fill(self,"inspectors",{})});
  1770. //>>excludeEnd("ctx");
  1771. }; }),
  1772. $globals.HLInspector.a$cls);
  1773. $core.addMethod(
  1774. $core.method({
  1775. selector: "register:",
  1776. protocol: "registration",
  1777. //>>excludeStart("ide", pragmas.excludeIdeData);
  1778. args: ["anInspector"],
  1779. source: "register: anInspector\x0a\x09self inspectors add: anInspector",
  1780. referencedClasses: [],
  1781. //>>excludeEnd("ide");
  1782. pragmas: [],
  1783. messageSends: ["add:", "inspectors"]
  1784. }, function ($methodClass){ return function (anInspector){
  1785. var self=this,$self=this;
  1786. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1787. return $core.withContext(function($ctx1) {
  1788. //>>excludeEnd("ctx");
  1789. $recv($self._inspectors())._add_(anInspector);
  1790. return self;
  1791. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1792. }, function($ctx1) {$ctx1.fill(self,"register:",{anInspector:anInspector})});
  1793. //>>excludeEnd("ctx");
  1794. }; }),
  1795. $globals.HLInspector.a$cls);
  1796. $core.addMethod(
  1797. $core.method({
  1798. selector: "tabClass",
  1799. protocol: "accessing",
  1800. //>>excludeStart("ide", pragmas.excludeIdeData);
  1801. args: [],
  1802. source: "tabClass\x0a\x09^ 'inspector'",
  1803. referencedClasses: [],
  1804. //>>excludeEnd("ide");
  1805. pragmas: [],
  1806. messageSends: []
  1807. }, function ($methodClass){ return function (){
  1808. var self=this,$self=this;
  1809. return "inspector";
  1810. }; }),
  1811. $globals.HLInspector.a$cls);
  1812. $core.addMethod(
  1813. $core.method({
  1814. selector: "tabLabel",
  1815. protocol: "accessing",
  1816. //>>excludeStart("ide", pragmas.excludeIdeData);
  1817. args: [],
  1818. source: "tabLabel\x0a\x09^ 'Inspector'",
  1819. referencedClasses: [],
  1820. //>>excludeEnd("ide");
  1821. pragmas: [],
  1822. messageSends: []
  1823. }, function ($methodClass){ return function (){
  1824. var self=this,$self=this;
  1825. return "Inspector";
  1826. }; }),
  1827. $globals.HLInspector.a$cls);
  1828. $core.addMethod(
  1829. $core.method({
  1830. selector: "tabPriority",
  1831. protocol: "accessing",
  1832. //>>excludeStart("ide", pragmas.excludeIdeData);
  1833. args: [],
  1834. source: "tabPriority\x0a\x09^ 10",
  1835. referencedClasses: [],
  1836. //>>excludeEnd("ide");
  1837. pragmas: [],
  1838. messageSends: []
  1839. }, function ($methodClass){ return function (){
  1840. var self=this,$self=this;
  1841. return (10);
  1842. }; }),
  1843. $globals.HLInspector.a$cls);
  1844. $core.addMethod(
  1845. $core.method({
  1846. selector: "unregister:",
  1847. protocol: "registration",
  1848. //>>excludeStart("ide", pragmas.excludeIdeData);
  1849. args: ["anInspector"],
  1850. source: "unregister: anInspector\x0a\x09self inspectors remove: anInspector",
  1851. referencedClasses: [],
  1852. //>>excludeEnd("ide");
  1853. pragmas: [],
  1854. messageSends: ["remove:", "inspectors"]
  1855. }, function ($methodClass){ return function (anInspector){
  1856. var self=this,$self=this;
  1857. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1858. return $core.withContext(function($ctx1) {
  1859. //>>excludeEnd("ctx");
  1860. $recv($self._inspectors())._remove_(anInspector);
  1861. return self;
  1862. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1863. }, function($ctx1) {$ctx1.fill(self,"unregister:",{anInspector:anInspector})});
  1864. //>>excludeEnd("ctx");
  1865. }; }),
  1866. $globals.HLInspector.a$cls);
  1867. $core.addMethod(
  1868. $core.method({
  1869. selector: "watchChanges",
  1870. protocol: "initialization",
  1871. //>>excludeStart("ide", pragmas.excludeIdeData);
  1872. args: [],
  1873. source: "watchChanges\x0a\x09| refreshInterval |\x0a\x09refreshInterval := 'helios.inspector.refreshMillis' settingValueIfAbsent: 500.\x0a\x09refreshInterval > 0 ifTrue: [\x0a\x09\x09[ self inspectors do: [ :each | each refresh ] ]\x0a\x09\x09\x09valueWithInterval: refreshInterval ]",
  1874. referencedClasses: [],
  1875. //>>excludeEnd("ide");
  1876. pragmas: [],
  1877. messageSends: ["settingValueIfAbsent:", "ifTrue:", ">", "valueWithInterval:", "do:", "inspectors", "refresh"]
  1878. }, function ($methodClass){ return function (){
  1879. var self=this,$self=this;
  1880. var refreshInterval;
  1881. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1882. return $core.withContext(function($ctx1) {
  1883. //>>excludeEnd("ctx");
  1884. refreshInterval="helios.inspector.refreshMillis"._settingValueIfAbsent_((500));
  1885. if($core.assert($recv(refreshInterval).__gt((0)))){
  1886. $recv((function(){
  1887. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1888. return $core.withContext(function($ctx2) {
  1889. //>>excludeEnd("ctx");
  1890. return $recv($self._inspectors())._do_((function(each){
  1891. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1892. return $core.withContext(function($ctx3) {
  1893. //>>excludeEnd("ctx");
  1894. return $recv(each)._refresh();
  1895. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1896. }, function($ctx3) {$ctx3.fillBlock({each:each},$ctx2,3)});
  1897. //>>excludeEnd("ctx");
  1898. }));
  1899. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1900. }, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
  1901. //>>excludeEnd("ctx");
  1902. }))._valueWithInterval_(refreshInterval);
  1903. }
  1904. return self;
  1905. //>>excludeStart("ctx", pragmas.excludeDebugContexts);
  1906. }, function($ctx1) {$ctx1.fill(self,"watchChanges",{refreshInterval:refreshInterval})});
  1907. //>>excludeEnd("ctx");
  1908. }; }),
  1909. $globals.HLInspector.a$cls);
  1910. });