1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030 |
- smalltalk.addPackage('Helios-Inspector', {});
- smalltalk.addClass('HLInspector', smalltalk.HLWidget, ['model', 'variables', 'display', 'code', 'label'], 'Helios-Inspector');
- smalltalk.addMethod(
- "_code",
- smalltalk.method({
- selector: "code",
- fn: function () {
- var self = this;
- var $1;
- if (($receiver = self['@code']) == nil || $receiver == undefined) {
- $1 = smalltalk.send(self, "_initializeCode", []);
- } else {
- $1 = self['@code'];
- }
- return $1;
- }
- }),
- smalltalk.HLInspector);
- smalltalk.addMethod(
- "_display",
- smalltalk.method({
- selector: "display",
- fn: function () {
- var self = this;
- var $1;
- if (($receiver = self['@display']) == nil || $receiver == undefined) {
- $1 = smalltalk.send(self, "_initializeDisplay", []);
- } else {
- $1 = self['@display'];
- }
- return $1;
- }
- }),
- smalltalk.HLInspector);
- smalltalk.addMethod(
- "_ensureModel",
- smalltalk.method({
- selector: "ensureModel",
- fn: function () {
- var self = this;
- smalltalk.send(self, "_observeVariables", []);
- if (($receiver = self['@model']) == nil || $receiver == undefined) {
- smalltalk.send(self, "_model_", [smalltalk.send(self, "_model", [])]);
- } else {
- self['@model'];
- }
- return self;
- }
- }),
- smalltalk.HLInspector);
- smalltalk.addMethod(
- "_initializeCode",
- smalltalk.method({
- selector: "initializeCode",
- fn: function () {
- var self = this;
- var $1;
- self['@code'] = smalltalk.send(self, "_makeCode", []);
- $1 = self['@code'];
- return $1;
- }
- }),
- smalltalk.HLInspector);
- smalltalk.addMethod(
- "_initializeDisplay",
- smalltalk.method({
- selector: "initializeDisplay",
- fn: function () {
- var self = this;
- var $1;
- self['@display'] = smalltalk.send(self, "_makeDisplay", []);
- $1 = self['@display'];
- return $1;
- }
- }),
- smalltalk.HLInspector);
- smalltalk.addMethod(
- "_initializeLabel",
- smalltalk.method({
- selector: "initializeLabel",
- fn: function () {
- var self = this;
- var $1;
- self['@label'] = smalltalk.send(smalltalk.send(self['@model'], "_inspectee", []), "_printString", []);
- $1 = self['@label'];
- return $1;
- }
- }),
- smalltalk.HLInspector);
- smalltalk.addMethod(
- "_initializeModel",
- smalltalk.method({
- selector: "initializeModel",
- fn: function () {
- var self = this;
- var $1;
- self['@model'] = smalltalk.send(smalltalk.HLInspectorModel || HLInspectorModel, "_new", []);
- $1 = self['@model'];
- return $1;
- }
- }),
- smalltalk.HLInspector);
- smalltalk.addMethod(
- "_initializeVariables",
- smalltalk.method({
- selector: "initializeVariables",
- fn: function () {
- var self = this;
- var $1;
- self['@variables'] = smalltalk.send(self, "_makeVariables", []);
- $1 = self['@variables'];
- return $1;
- }
- }),
- smalltalk.HLInspector);
- smalltalk.addMethod(
- "_inspect_",
- smalltalk.method({
- selector: "inspect:",
- fn: function (anObject) {
- var self = this;
- var $1;
- smalltalk.send(smalltalk.send(self, "_model", []), "_inspect_on_", [anObject, self]);
- smalltalk.send(self, "_refreshVariables", []);
- smalltalk.send(self, "_refreshDisplay", []);
- $1 = smalltalk.send(self, "_yourself", []);
- return self;
- }
- }),
- smalltalk.HLInspector);
- smalltalk.addMethod(
- "_inspectee",
- smalltalk.method({
- selector: "inspectee",
- fn: function () {
- var self = this;
- var $1;
- $1 = smalltalk.send(smalltalk.send(self, "_model", []), "_inspectee", []);
- return $1;
- }
- }),
- smalltalk.HLInspector);
- smalltalk.addMethod(
- "_inspectee_",
- smalltalk.method({
- selector: "inspectee:",
- fn: function (anObject) {
- var self = this;
- smalltalk.send(smalltalk.send(self, "_model", []), "_inspectee_", [anObject]);
- return self;
- }
- }),
- smalltalk.HLInspector);
- smalltalk.addMethod(
- "_label",
- smalltalk.method({
- selector: "label",
- fn: function () {
- var self = this;
- var $1;
- if (($receiver = self['@label']) == nil || $receiver == undefined) {
- $1 = smalltalk.send(self, "_initializeLabel", []);
- } else {
- $1 = self['@label'];
- }
- return $1;
- }
- }),
- smalltalk.HLInspector);
- smalltalk.addMethod(
- "_makeCode",
- smalltalk.method({
- selector: "makeCode",
- fn: function () {
- var self = this;
- var $2, $3, $1;
- $2 = smalltalk.send(smalltalk.HLCodeWidget || HLCodeWidget, "_new", []);
- smalltalk.send($2, "_model_", [smalltalk.send(self['@model'], "_code", [])]);
- smalltalk.send($2, "_receiver_", [smalltalk.send(self['@model'], "_inspectee", [])]);
- $3 = smalltalk.send($2, "_yourself", []);
- $1 = $3;
- return $1;
- }
- }),
- smalltalk.HLInspector);
- smalltalk.addMethod(
- "_makeDisplay",
- smalltalk.method({
- selector: "makeDisplay",
- fn: function () {
- var self = this;
- var $2, $3, $1;
- $2 = smalltalk.send(smalltalk.HLInspectorDisplay || HLInspectorDisplay, "_new", []);
- smalltalk.send($2, "_model_", [smalltalk.send(self, "_model", [])]);
- $3 = smalltalk.send($2, "_yourself", []);
- $1 = $3;
- return $1;
- }
- }),
- smalltalk.HLInspector);
- smalltalk.addMethod(
- "_makeVariables",
- smalltalk.method({
- selector: "makeVariables",
- fn: function () {
- var self = this;
- var $2, $3, $1;
- $2 = smalltalk.send(smalltalk.HLInspectorVariables || HLInspectorVariables, "_new", []);
- smalltalk.send($2, "_model_", [smalltalk.send(self, "_model", [])]);
- $3 = smalltalk.send($2, "_yourself", []);
- $1 = $3;
- return $1;
- }
- }),
- smalltalk.HLInspector);
- smalltalk.addMethod(
- "_model",
- smalltalk.method({
- selector: "model",
- fn: function () {
- var self = this;
- var $1;
- if (($receiver = self['@model']) == nil || $receiver == undefined) {
- $1 = smalltalk.send(self, "_initializeModel", []);
- } else {
- $1 = self['@model'];
- }
- return $1;
- }
- }),
- smalltalk.HLInspector);
- smalltalk.addMethod(
- "_model_",
- smalltalk.method({
- selector: "model:",
- fn: function (aModel) {
- var self = this;
- self['@model'] = aModel;
- smalltalk.send(smalltalk.send(self, "_code", []), "_model_", [smalltalk.send(aModel, "_code", [])]);
- smalltalk.send(self, "_observeCode", []);
- return self;
- }
- }),
- smalltalk.HLInspector);
- smalltalk.addMethod(
- "_observeCode",
- smalltalk.method({
- selector: "observeCode",
- fn: function () {
- var self = this;
- smalltalk.send(smalltalk.send(smalltalk.send(self, "_code", []), "_announcer", []), "_on_do_", [smalltalk.HLDoItExecuted || HLDoItExecuted, function () {return smalltalk.send(self, "_onDoneIt", []);}]);
- return self;
- }
- }),
- smalltalk.HLInspector);
- smalltalk.addMethod(
- "_observeVariables",
- smalltalk.method({
- selector: "observeVariables",
- fn: function () {
- var self = this;
- var $1, $2, $3, $4;
- $1 = smalltalk.send(smalltalk.send(self, "_variables", []), "_announcer", []);
- smalltalk.send($1, "_on_do_", [smalltalk.HLRefreshRequested || HLRefreshRequested, function (ann) {return smalltalk.send(self, "_onRefresh", []);}]);
- smalltalk.send($1, "_on_do_", [smalltalk.HLDiveRequested || HLDiveRequested, function () {return smalltalk.send(self, "_onDive", []);}]);
- $2 = smalltalk.send($1, "_yourself", []);
- $3 = smalltalk.send(smalltalk.send(self, "_model", []), "_announcer", []);
- smalltalk.send($3, "_on_do_", [smalltalk.HLInstanceVariableSelected || HLInstanceVariableSelected, function (ann) {return smalltalk.send(self, "_onInstanceVariableSelected", []);}]);
- $4 = smalltalk.send($3, "_yourself", []);
- return self;
- }
- }),
- smalltalk.HLInspector);
- smalltalk.addMethod(
- "_onDive",
- smalltalk.method({
- selector: "onDive",
- fn: function () {
- var self = this;
- smalltalk.send(self, "_inspect_", [smalltalk.send(smalltalk.send(self, "_model", []), "_selectedInstVarObject", [])]);
- return self;
- }
- }),
- smalltalk.HLInspector);
- smalltalk.addMethod(
- "_onDoIt",
- smalltalk.method({
- selector: "onDoIt",
- fn: function () {
- var self = this;
- return self;
- }
- }),
- smalltalk.HLInspector);
- smalltalk.addMethod(
- "_onDoneIt",
- smalltalk.method({
- selector: "onDoneIt",
- fn: function () {
- var self = this;
- smalltalk.send(self, "_refresh", []);
- return self;
- }
- }),
- smalltalk.HLInspector);
- smalltalk.addMethod(
- "_onInspectIt",
- smalltalk.method({
- selector: "onInspectIt",
- fn: function () {
- var self = this;
- return self;
- }
- }),
- smalltalk.HLInspector);
- smalltalk.addMethod(
- "_onInstanceVariableSelected",
- smalltalk.method({
- selector: "onInstanceVariableSelected",
- fn: function () {
- var self = this;
- smalltalk.send(smalltalk.send(self, "_code", []), "_receiver_", [smalltalk.send(smalltalk.send(self, "_model", []), "_selectedInstVarObject", [])]);
- smalltalk.send(self, "_refreshDisplay", []);
- return self;
- }
- }),
- smalltalk.HLInspector);
- smalltalk.addMethod(
- "_onPrintIt",
- smalltalk.method({
- selector: "onPrintIt",
- fn: function () {
- var self = this;
- return self;
- }
- }),
- smalltalk.HLInspector);
- smalltalk.addMethod(
- "_onRefresh",
- smalltalk.method({
- selector: "onRefresh",
- fn: function () {
- var self = this;
- smalltalk.send(self, "_refresh", []);
- return self;
- }
- }),
- smalltalk.HLInspector);
- smalltalk.addMethod(
- "_open",
- smalltalk.method({
- selector: "open",
- fn: function () {
- var self = this;
- smalltalk.send(smalltalk.send(smalltalk.HLManager || HLManager, "_current", []), "_addTab_", [smalltalk.send(smalltalk.HLTab || HLTab, "_on_labelled_", [self, smalltalk.send(self, "_tabLabel", [])])]);
- return self;
- }
- }),
- smalltalk.HLInspector);
- smalltalk.addMethod(
- "_refresh",
- smalltalk.method({
- selector: "refresh",
- fn: function () {
- var self = this;
- smalltalk.send(self, "_inspect_", [smalltalk.send(self, "_inspectee", [])]);
- return self;
- }
- }),
- smalltalk.HLInspector);
- smalltalk.addMethod(
- "_refreshDisplay",
- smalltalk.method({
- selector: "refreshDisplay",
- fn: function () {
- var self = this;
- smalltalk.send(smalltalk.send(self, "_display", []), "_refresh", []);
- return self;
- }
- }),
- smalltalk.HLInspector);
- smalltalk.addMethod(
- "_refreshVariables",
- smalltalk.method({
- selector: "refreshVariables",
- fn: function () {
- var self = this;
- smalltalk.send(smalltalk.send(self, "_variables", []), "_refresh", []);
- return self;
- }
- }),
- smalltalk.HLInspector);
- smalltalk.addMethod(
- "_renderContentOn_",
- smalltalk.method({
- selector: "renderContentOn:",
- fn: function (html) {
- var self = this;
- smalltalk.send(self, "_ensureModel", []);
- smalltalk.send(html, "_with_", [smalltalk.send(smalltalk.HLContainer || HLContainer, "_with_", [smalltalk.send(smalltalk.HLHorizontalSplitter || HLHorizontalSplitter, "_with_with_", [smalltalk.send(smalltalk.HLVerticalSplitter || HLVerticalSplitter, "_with_with_", [smalltalk.send(self, "_variables", []), smalltalk.send(self, "_display", [])]), smalltalk.send(self, "_code", [])])])]);
- return self;
- }
- }),
- smalltalk.HLInspector);
- smalltalk.addMethod(
- "_setLabel_",
- smalltalk.method({
- selector: "setLabel:",
- fn: function (aString) {
- var self = this;
- self['@label'] = aString;
- return self;
- }
- }),
- smalltalk.HLInspector);
- smalltalk.addMethod(
- "_setVariables_",
- smalltalk.method({
- selector: "setVariables:",
- fn: function (aDictionary) {
- var self = this;
- smalltalk.send(smalltalk.send(self, "_model", []), "_variables_", [aDictionary]);
- return self;
- }
- }),
- smalltalk.HLInspector);
- smalltalk.addMethod(
- "_tabLabel",
- smalltalk.method({
- selector: "tabLabel",
- fn: function () {
- var self = this;
- var $1;
- $1 = smalltalk.send(self, "_label", []);
- return $1;
- }
- }),
- smalltalk.HLInspector);
- smalltalk.addMethod(
- "_variables",
- smalltalk.method({
- selector: "variables",
- fn: function () {
- var self = this;
- var $1;
- if (($receiver = self['@variables']) == nil || $receiver == undefined) {
- $1 = smalltalk.send(self, "_initializeVariables", []);
- } else {
- $1 = self['@variables'];
- }
- return $1;
- }
- }),
- smalltalk.HLInspector);
- smalltalk.addMethod(
- "_canBeOpenAsTab",
- smalltalk.method({
- selector: "canBeOpenAsTab",
- fn: function () {
- var self = this;
- return false;
- }
- }),
- smalltalk.HLInspector.klass);
- smalltalk.addMethod(
- "_tabLabel",
- smalltalk.method({
- selector: "tabLabel",
- fn: function () {
- var self = this;
- return "Inspector";
- }
- }),
- smalltalk.HLInspector.klass);
- smalltalk.addMethod(
- "_tabPriority",
- smalltalk.method({
- selector: "tabPriority",
- fn: function () {
- var self = this;
- return 10;
- }
- }),
- smalltalk.HLInspector.klass);
- smalltalk.addClass('HLInspectorDisplay', smalltalk.HLNavigationListWidget, ['model'], 'Helios-Inspector');
- smalltalk.addMethod(
- "_model",
- smalltalk.method({
- selector: "model",
- fn: function () {
- var self = this;
- return self['@model'];
- }
- }),
- smalltalk.HLInspectorDisplay);
- smalltalk.addMethod(
- "_model_",
- smalltalk.method({
- selector: "model:",
- fn: function (aModel) {
- var self = this;
- self['@model'] = aModel;
- return self;
- }
- }),
- smalltalk.HLInspectorDisplay);
- smalltalk.addMethod(
- "_renderContentOn_",
- smalltalk.method({
- selector: "renderContentOn:",
- fn: function (html) {
- var self = this;
- smalltalk.send(smalltalk.send(html, "_div", []), "_with_", [smalltalk.send(self, "_selectionDisplayString", [])]);
- return self;
- }
- }),
- smalltalk.HLInspectorDisplay);
- smalltalk.addMethod(
- "_selectionDisplayString",
- smalltalk.method({
- selector: "selectionDisplayString",
- fn: function () {
- var self = this;
- var $2, $1;
- var selection;
- selection = smalltalk.send(self['@model'], "_selection", []);
- $2 = smalltalk.send(smalltalk.send(smalltalk.send(self['@model'], "_variables", []), "_keys", []), "_includes_", [selection]);
- if (smalltalk.assert($2)) {
- $1 = smalltalk.send(smalltalk.send(self['@model'], "_instVarObjectAt_", [selection]), "_printString", []);
- } else {
- $1 = "";
- }
- return $1;
- }
- }),
- smalltalk.HLInspectorDisplay);
- smalltalk.addClass('HLInspectorModel', smalltalk.Object, ['announcer', 'environment', 'inspectee', 'code', 'variables', 'selection'], 'Helios-Inspector');
- smalltalk.addMethod(
- "_announcer",
- smalltalk.method({
- selector: "announcer",
- fn: function () {
- var self = this;
- var $1;
- if (($receiver = self['@announcer']) == nil || $receiver == undefined) {
- $1 = smalltalk.send(self, "_initializeAnnouncer", []);
- } else {
- $1 = self['@announcer'];
- }
- return $1;
- }
- }),
- smalltalk.HLInspectorModel);
- smalltalk.addMethod(
- "_code",
- smalltalk.method({
- selector: "code",
- fn: function () {
- var self = this;
- var $1;
- if (($receiver = self['@code']) == nil || $receiver == undefined) {
- $1 = smalltalk.send(self, "_initializeCode", []);
- } else {
- $1 = self['@code'];
- }
- return $1;
- }
- }),
- smalltalk.HLInspectorModel);
- smalltalk.addMethod(
- "_environment",
- smalltalk.method({
- selector: "environment",
- fn: function () {
- var self = this;
- var $1;
- if (($receiver = self['@environment']) == nil || $receiver == undefined) {
- $1 = smalltalk.send(smalltalk.send(smalltalk.HLManager || HLManager, "_current", []), "_environment", []);
- } else {
- $1 = self['@environment'];
- }
- return $1;
- }
- }),
- smalltalk.HLInspectorModel);
- smalltalk.addMethod(
- "_environment_",
- smalltalk.method({
- selector: "environment:",
- fn: function (anEnvironment) {
- var self = this;
- self['@environment'] = anEnvironment;
- return self;
- }
- }),
- smalltalk.HLInspectorModel);
- smalltalk.addMethod(
- "_initializeAnnouncer",
- smalltalk.method({
- selector: "initializeAnnouncer",
- fn: function () {
- var self = this;
- var $1;
- self['@announcer'] = smalltalk.send(smalltalk.Announcer || Announcer, "_new", []);
- $1 = self['@announcer'];
- return $1;
- }
- }),
- smalltalk.HLInspectorModel);
- smalltalk.addMethod(
- "_initializeCode",
- smalltalk.method({
- selector: "initializeCode",
- fn: function () {
- var self = this;
- var $1;
- self['@code'] = smalltalk.send(smalltalk.HLCodeModel || HLCodeModel, "_on_", [smalltalk.send(self, "_environment", [])]);
- $1 = self['@code'];
- return $1;
- }
- }),
- smalltalk.HLInspectorModel);
- smalltalk.addMethod(
- "_initializeSelection",
- smalltalk.method({
- selector: "initializeSelection",
- fn: function () {
- var self = this;
- var $1;
- self['@selection'] = "";
- $1 = self['@selection'];
- return $1;
- }
- }),
- smalltalk.HLInspectorModel);
- smalltalk.addMethod(
- "_inspect_on_",
- smalltalk.method({
- selector: "inspect:on:",
- fn: function (anObject, anInspector) {
- var self = this;
- self['@inspectee'] = anObject;
- self['@variables'] = [];
- smalltalk.send(self['@inspectee'], "_inspectOn_", [anInspector]);
- return self;
- }
- }),
- smalltalk.HLInspectorModel);
- smalltalk.addMethod(
- "_inspectee",
- smalltalk.method({
- selector: "inspectee",
- fn: function () {
- var self = this;
- return self['@inspectee'];
- }
- }),
- smalltalk.HLInspectorModel);
- smalltalk.addMethod(
- "_inspectee_",
- smalltalk.method({
- selector: "inspectee:",
- fn: function (anObject) {
- var self = this;
- self['@inspectee'] = anObject;
- return self;
- }
- }),
- smalltalk.HLInspectorModel);
- smalltalk.addMethod(
- "_instVarObjectAt_",
- smalltalk.method({
- selector: "instVarObjectAt:",
- fn: function (anInstVarName) {
- var self = this;
- var $1;
- $1 = smalltalk.send(smalltalk.send(self, "_variables", []), "_at_", [anInstVarName]);
- return $1;
- }
- }),
- smalltalk.HLInspectorModel);
- smalltalk.addMethod(
- "_onKeyDown_",
- smalltalk.method({
- selector: "onKeyDown:",
- fn: function (anEvent) {
- var self = this;
- if (anEvent.ctrlKey) {
- if (anEvent.keyCode === 80) {
- self._printIt();
- anEvent.preventDefault();
- return false;
- }
- if (anEvent.keyCode === 68) {
- self._doIt();
- anEvent.preventDefault();
- return false;
- }
- if (anEvent.keyCode === 73) {
- self._inspectIt();
- anEvent.preventDefault();
- return false;
- }
- }
- return self;
- }
- }),
- smalltalk.HLInspectorModel);
- smalltalk.addMethod(
- "_selectedInstVar_",
- smalltalk.method({
- selector: "selectedInstVar:",
- fn: function (anInstVarName) {
- var self = this;
- smalltalk.send(self, "_selection_", [anInstVarName]);
- return self;
- }
- }),
- smalltalk.HLInspectorModel);
- smalltalk.addMethod(
- "_selectedInstVarObject",
- smalltalk.method({
- selector: "selectedInstVarObject",
- fn: function () {
- var self = this;
- var $1;
- $1 = smalltalk.send(self, "_instVarObjectAt_", [smalltalk.send(self, "_selection", [])]);
- return $1;
- }
- }),
- smalltalk.HLInspectorModel);
- smalltalk.addMethod(
- "_selection",
- smalltalk.method({
- selector: "selection",
- fn: function () {
- var self = this;
- var $1;
- if (($receiver = self['@selection']) == nil || $receiver == undefined) {
- $1 = smalltalk.send(self, "_initializeSelection", []);
- } else {
- $1 = self['@selection'];
- }
- return $1;
- }
- }),
- smalltalk.HLInspectorModel);
- smalltalk.addMethod(
- "_selection_",
- smalltalk.method({
- selector: "selection:",
- fn: function (anObject) {
- var self = this;
- self['@selection'] = anObject;
- smalltalk.send(smalltalk.send(self, "_announcer", []), "_announce_", [smalltalk.send(smalltalk.HLInstanceVariableSelected || HLInstanceVariableSelected, "_on_", [self['@selection']])]);
- return self;
- }
- }),
- smalltalk.HLInspectorModel);
- smalltalk.addMethod(
- "_subscribe_",
- smalltalk.method({
- selector: "subscribe:",
- fn: function (aWidget) {
- var self = this;
- smalltalk.send(aWidget, "_subscribeTo_", [smalltalk.send(self, "_announcer", [])]);
- return self;
- }
- }),
- smalltalk.HLInspectorModel);
- smalltalk.addMethod(
- "_variables",
- smalltalk.method({
- selector: "variables",
- fn: function () {
- var self = this;
- return self['@variables'];
- }
- }),
- smalltalk.HLInspectorModel);
- smalltalk.addMethod(
- "_variables_",
- smalltalk.method({
- selector: "variables:",
- fn: function (aCollection) {
- var self = this;
- self['@variables'] = aCollection;
- return self;
- }
- }),
- smalltalk.HLInspectorModel);
- smalltalk.addMethod(
- "_on_",
- smalltalk.method({
- selector: "on:",
- fn: function (anEnvironment) {
- var self = this;
- var $2, $3, $1;
- $2 = smalltalk.send(self, "_new", []);
- smalltalk.send($2, "_environment_", [anEnvironment]);
- $3 = smalltalk.send($2, "_yourself", []);
- $1 = $3;
- return $1;
- }
- }),
- smalltalk.HLInspectorModel.klass);
- smalltalk.addClass('HLInspectorVariables', smalltalk.HLNavigationListWidget, ['announcer', 'model', 'list', 'diveButton'], 'Helios-Inspector');
- smalltalk.addMethod(
- "_announcer",
- smalltalk.method({
- selector: "announcer",
- fn: function () {
- var self = this;
- var $1;
- if (($receiver = self['@announcer']) == nil || $receiver == undefined) {
- $1 = smalltalk.send(self, "_initializeAnnouncer", []);
- } else {
- $1 = self['@announcer'];
- }
- return $1;
- }
- }),
- smalltalk.HLInspectorVariables);
- smalltalk.addMethod(
- "_initializeAnnouncer",
- smalltalk.method({
- selector: "initializeAnnouncer",
- fn: function () {
- var self = this;
- var $1;
- self['@announcer'] = smalltalk.send(smalltalk.Announcer || Announcer, "_new", []);
- $1 = self['@announcer'];
- return $1;
- }
- }),
- smalltalk.HLInspectorVariables);
- smalltalk.addMethod(
- "_initializeItems",
- smalltalk.method({
- selector: "initializeItems",
- fn: function () {
- var self = this;
- var $1;
- self['@items'] = smalltalk.send(smalltalk.send(smalltalk.send(self, "_model", []), "_variables", []), "_keys", []);
- $1 = self['@items'];
- return $1;
- }
- }),
- smalltalk.HLInspectorVariables);
- smalltalk.addMethod(
- "_model",
- smalltalk.method({
- selector: "model",
- fn: function () {
- var self = this;
- return self['@model'];
- }
- }),
- smalltalk.HLInspectorVariables);
- smalltalk.addMethod(
- "_model_",
- smalltalk.method({
- selector: "model:",
- fn: function (aModel) {
- var self = this;
- self['@model'] = aModel;
- return self;
- }
- }),
- smalltalk.HLInspectorVariables);
- smalltalk.addMethod(
- "_refresh",
- smalltalk.method({
- selector: "refresh",
- fn: function () {
- var self = this;
- smalltalk.send(self, "_resetItems", []);
- smalltalk.send(self, "_refresh", [], smalltalk.HLNavigationListWidget);
- return self;
- }
- }),
- smalltalk.HLInspectorVariables);
- smalltalk.addMethod(
- "_renderButtonsOn_",
- smalltalk.method({
- selector: "renderButtonsOn:",
- fn: function (html) {
- var self = this;
- var $1, $2, $3, $4;
- $1 = smalltalk.send(html, "_button", []);
- smalltalk.send($1, "_class_", ["btn"]);
- smalltalk.send($1, "_with_", ["Refresh"]);
- $2 = smalltalk.send($1, "_onClick_", [function () {return smalltalk.send(smalltalk.send(self, "_announcer", []), "_announce_", [smalltalk.send(smalltalk.HLRefreshRequested || HLRefreshRequested, "_new", [])]);}]);
- $3 = smalltalk.send(html, "_button", []);
- smalltalk.send($3, "_class_", ["btn"]);
- smalltalk.send($3, "_with_", ["Dive"]);
- $4 = smalltalk.send($3, "_onClick_", [function () {return smalltalk.send(smalltalk.send(self, "_announcer", []), "_announce_", [smalltalk.send(smalltalk.HLDiveRequested || HLDiveRequested, "_new", [])]);}]);
- self['@diveButton'] = $4;
- return self;
- }
- }),
- smalltalk.HLInspectorVariables);
- smalltalk.addMethod(
- "_resetItems",
- smalltalk.method({
- selector: "resetItems",
- fn: function () {
- var self = this;
- self['@items'] = nil;
- return self;
- }
- }),
- smalltalk.HLInspectorVariables);
- smalltalk.addMethod(
- "_selectItem_",
- smalltalk.method({
- selector: "selectItem:",
- fn: function (anObject) {
- var self = this;
- smalltalk.send(self, "_selectItem_", [anObject], smalltalk.HLNavigationListWidget);
- smalltalk.send(smalltalk.send(self, "_model", []), "_selectedInstVar_", [anObject]);
- return self;
- }
- }),
- smalltalk.HLInspectorVariables);
- smalltalk.addMethod(
- "_selection",
- smalltalk.method({
- selector: "selection",
- fn: function () {
- var self = this;
- var $1;
- $1 = smalltalk.send(self['@model'], "_selection", []);
- return $1;
- }
- }),
- smalltalk.HLInspectorVariables);
- smalltalk.addMethod(
- "_variables",
- smalltalk.method({
- selector: "variables",
- fn: function () {
- var self = this;
- var $1;
- $1 = smalltalk.send(self['@model'], "_variables", []);
- return $1;
- }
- }),
- smalltalk.HLInspectorVariables);
|