<div dir="ltr">Hmm. <div>I seems when you click explore/ inspect the current selection you &quot;jump up&quot; a level and then you lose the inspector/ explorer for the object you had in the previous tool.</div><div><br></div><div>Eg:</div><div>Inspect a object. </div><div>Select it&#39;s instance variable</div><div>Click Explore</div><div>A explorer for the instance variable opens</div><div>You can&#39;t go back to original object</div><div class="gmail_extra"><br></div><div class="gmail_extra">Karl</div><div class="gmail_extra"><br></div><div class="gmail_extra"><br><div class="gmail_quote">On Sun, Apr 12, 2015 at 6:27 PM, karl ramberg <span dir="ltr">&lt;<a href="mailto:karlramberg@gmail.com" target="_blank">karlramberg@gmail.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Hi,<div>You are making really nice enhancements :-)</div><div><br></div><div><div>BTW : Could we preserve the selection in the list as well ? </div><div>Or are the list models too different for it to make sense ?</div><div>First level selection should probably work...</div><span class="HOEnZb"><font color="#888888"><div><br></div><div>Karl</div></font></span><div><div class="h5"><div><br></div><div><br><div class="gmail_extra"><br><div class="gmail_quote">On Sun, Apr 12, 2015 at 4:56 PM,  <span dir="ltr">&lt;<a href="mailto:commits@source.squeak.org" target="_blank">commits@source.squeak.org</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Marcel Taeumel uploaded a new version of Tools to project The Trunk:<br>
<a href="http://source.squeak.org/trunk/Tools-mt.582.mcz" target="_blank">http://source.squeak.org/trunk/Tools-mt.582.mcz</a><br>
<br>
==================== Summary ====================<br>
<br>
Name: Tools-mt.582<br>
Author: mt<br>
Time: 12 April 2015, 4:56:27.909 pm<br>
UUID: 3ad55be5-74b1-f84f-98d1-b1cf671476d2<br>
Ancestors: Tools-mt.581<br>
<br>
Preserve expressions that were entered in the code pane in inspector/explorer when switching between those tools.<br>
<br>
=============== Diff against Tools-mt.581 ===============<br>
<br>
Item was changed:<br>
  StringHolder subclass: #Inspector<br>
+       instanceVariableNames: &#39;object selectionIndex timeOfLastListUpdate selectionUpdateTime context expression&#39;<br>
-       instanceVariableNames: &#39;object selectionIndex timeOfLastListUpdate selectionUpdateTime context&#39;<br>
        classVariableNames: &#39;&#39;<br>
        poolDictionaries: &#39;&#39;<br>
        category: &#39;Tools-Inspector&#39;!<br>
<br>
  !Inspector commentStamp: &#39;&lt;historical&gt;&#39; prior: 0!<br>
  I represent a query path into the internal representation of an object. As a StringHolder, the string I represent is the value of the currently selected variable of the observed object.!<br>
<br>
Item was changed:<br>
  ----- Method: Inspector&gt;&gt;buildCodePaneWith: (in category &#39;toolbuilder&#39;) -----<br>
  buildCodePaneWith: builder<br>
        | textSpec |<br>
        textSpec := builder pluggableTextSpec new.<br>
        textSpec<br>
                model: self;<br>
+               getText: #expression;<br>
+               editText: #expression:;<br>
-               getText: #trash;<br>
-               setText: #trash:;<br>
                help: #helpText;<br>
                selection: #contentsSelection;<br>
                menu: #codePaneMenu:shifted:;<br>
                askBeforeDiscardingEdits: false.<br>
        ^textSpec!<br>
<br>
Item was changed:<br>
  ----- Method: Inspector&gt;&gt;exploreObject (in category &#39;toolbuilder&#39;) -----<br>
  exploreObject<br>
        &quot;Switch to an explorer tool.&quot;<br>
<br>
+       | window model |<br>
+       window := self object explore.<br>
+       model := window model.<br>
+<br>
+       model setExpression: self expression.<br>
+       window bounds: self containingWindow bounds.<br>
-       self object explore<br>
-               bounds: self containingWindow bounds.<br>
        self changed: #close.!<br>
<br>
Item was added:<br>
+ ----- Method: Inspector&gt;&gt;expression (in category &#39;accessing&#39;) -----<br>
+ expression<br>
+<br>
+       ^ expression ifNil: [&#39;&#39;]!<br>
<br>
Item was added:<br>
+ ----- Method: Inspector&gt;&gt;expression: (in category &#39;accessing&#39;) -----<br>
+ expression: aString<br>
+<br>
+       expression := aString.!<br>
<br>
Item was added:<br>
+ ----- Method: Inspector&gt;&gt;setExpression: (in category &#39;code&#39;) -----<br>
+ setExpression: aString<br>
+<br>
+       self expression: aString.<br>
+       self changed: #expression.!<br>
<br>
Item was changed:<br>
  AbstractHierarchicalList subclass: #ObjectExplorer<br>
+       instanceVariableNames: &#39;root currentParent inspector monitorList expression&#39;<br>
-       instanceVariableNames: &#39;root currentParent inspector monitorList&#39;<br>
        classVariableNames: &#39;&#39;<br>
        poolDictionaries: &#39;&#39;<br>
        category: &#39;Tools-Explorer&#39;!<br>
<br>
  !ObjectExplorer commentStamp: &#39;&lt;historical&gt;&#39; prior: 0!<br>
  ObjectExplorer provides a hierarchical alternative to #inspect. Simply evaluate an expression like:<br>
<br>
  World explore<br>
<br>
  and enjoy.!<br>
<br>
Item was changed:<br>
  ----- Method: ObjectExplorer&gt;&gt;buildWith: (in category &#39;toolbuilder&#39;) -----<br>
  buildWith: builder<br>
<br>
        | windowSpec treeSpec textSpec buttonSpec buttonOffset |<br>
        windowSpec := builder pluggableWindowSpec new.<br>
        windowSpec<br>
                model: self;<br>
                children: OrderedCollection new;<br>
                label: #label;<br>
                extent: self initialExtent.<br>
<br>
        treeSpec := builder pluggableTreeSpec new.<br>
        treeSpec<br>
                model: self;<br>
                nodeClass: self class nodeClass;<br>
                roots: #getList;<br>
                keyPress: #explorerKey:from:event:;<br>
                getSelected: #currentSelection;<br>
                setSelected: #currentSelection:;<br>
                setSelectedParent: #currentParent:;<br>
                menu: #genericMenu:;<br>
                autoDeselect: false;<br>
                columns: (ObjectExplorerWrapper showContentsInColumns<br>
                        ifTrue: [{<br>
                                [:listMorph | (listMorph filteredItems collect: [:item |<br>
                                        item preferredWidthOfColumn: 1]) max].<br>
                                nil &quot;take all the space&quot;}]);<br>
                frame: (0@0 corner: 1@0.75).<br>
        windowSpec children add: treeSpec.<br>
<br>
        buttonOffset := (Preferences standardButtonFont widthOfString: &#39;inspect&#39;) * 3/2.<br>
<br>
        textSpec := builder pluggableTextSpec new.<br>
        textSpec<br>
                model: self;<br>
+               getText: #expression;<br>
+               editText: #expression:;<br>
                menu: #codePaneMenu:shifted:;<br>
                help: &#39;Evaluate expressions for the current tree selection...&#39; translated;<br>
                frame: (LayoutFrame fractions: (0@0.75 corner: 1@1) offsets: (0@0 corner: buttonOffset negated@0)).<br>
        windowSpec children add: textSpec.<br>
<br>
        buttonSpec := builder pluggableButtonSpec new<br>
                model: self;<br>
                label: &#39;inspect&#39;;<br>
                action: #inspectObject;<br>
                help: &#39;Switch to an inspector tool&#39;;<br>
                frame: (LayoutFrame fractions: (1@0.75 corner: 1@1) offsets: (buttonOffset negated@0 corner: 0 @ 0)).<br>
        windowSpec children add: buttonSpec.<br>
<br>
        [^ builder build: windowSpec]<br>
                ensure: [self changed: #expandRootsRequested]!<br>
<br>
Item was added:<br>
+ ----- Method: ObjectExplorer&gt;&gt;expression (in category &#39;accessing&#39;) -----<br>
+ expression<br>
+<br>
+       ^ expression!<br>
<br>
Item was added:<br>
+ ----- Method: ObjectExplorer&gt;&gt;expression: (in category &#39;accessing&#39;) -----<br>
+ expression: aString<br>
+<br>
+       expression := aString.!<br>
<br>
Item was changed:<br>
  ----- Method: ObjectExplorer&gt;&gt;inspectObject (in category &#39;toolbuilder&#39;) -----<br>
  inspectObject<br>
        &quot;Switch to an inspector tool.&quot;<br>
<br>
+       | window model |<br>
+       window := self object inspect.<br>
+       model := window model.<br>
+<br>
+       model setExpression: self expression.<br>
+       window bounds: self containingWindow bounds.<br>
-       self object inspect<br>
-               bounds: self containingWindow bounds.<br>
        self changed: #close.!<br>
<br>
Item was added:<br>
+ ----- Method: ObjectExplorer&gt;&gt;setExpression: (in category &#39;accessing - other&#39;) -----<br>
+ setExpression: aString<br>
+<br>
+       self expression: aString.<br>
+       self changed: #expression.!<br>
<br>
<br>
</blockquote></div><br></div></div></div></div></div></div>
</blockquote></div><br></div></div>