#FEATURE by cg
authorClaus Gittinger <cg@exept.de>
Tue, 17 Dec 2019 15:56:20 +0100
changeset 3827 d4de0de1a991
parent 3826 bd1cae72d73d
child 3828 d06d8ab3e5b8
#FEATURE by cg class: ViewTreeInspectorApplication changed: #postBuildBrowserCanvas: #updateBrowser class: ViewTreeInspectorApplication class changed: #windowSpec
Tools__ViewTreeApplication.st
--- a/Tools__ViewTreeApplication.st	Fri Dec 13 21:50:18 2019 +0100
+++ b/Tools__ViewTreeApplication.st	Tue Dec 17 15:56:20 2019 +0100
@@ -369,7 +369,7 @@
                          hasHorizontalScrollBar: true
                          hasVerticalScrollBar: true
                          majorKey: #'Tools::NewSystemBrowser'
-                         minorKey: singleClassWithoutVariableListBrowserSpec
+                         minorKey: multipleClassBrowserSpec "/ singleClassWithoutVariableListBrowserSpec
                          createNewApplication: true
                          createNewBuilder: true
                          postBuildCallback: postBuildBrowserCanvas:
@@ -1245,17 +1245,31 @@
 !
 
 updateBrowser
-    |cls widget|
+    |cls widget navigationState|
 
     widget := self selectedView.
 
     "/ update the browser
     self inspectorMode == #widgetClass ifTrue:[
-	cls := widget class.
+        cls := widget class.
     ] ifFalse:[
-	cls := widget application class
+        cls := widget application class
     ].
-    browser switchToClass:cls selector:nil.
+    "/ browser switchToClass:cls selector:nil.
+
+    navigationState := browser navigationState.
+
+    navigationState classList value:(cls theNonMetaclass withAllSuperclasses).
+    navigationState meta value:(cls isMetaclass).
+    browser classListGenerator value:(cls theNonMetaclass withAllSuperclasses).
+    browser sortByNameAndInheritance value:true.
+    browser
+        selectClass:cls;
+        selectProtocol: (Tools::BrowserList nameListEntryForALL).
+    browser switchToClass:cls selector:nil updateHistory: false.
+
+    "/ sigh must be done after postbuild
+    "/ navigationState classListApplication addOwnerClasses value:false.
 !
 
 updateInspector
@@ -1540,8 +1554,25 @@
 !
 
 postBuildBrowserCanvas:aSubCanvas
+    |navigationState|
+
     browser := aSubCanvas application.
 
+    browser isEmbeddedBrowser:true.
+"/    navigationState := browser navigationState.
+"/
+"/    navigationState classList value:(aClass theNonMetaclass withAllSuperclasses).
+"/    navigationState meta value:(aClass isMetaclass).
+"/    browser classListGenerator value:(aClass theNonMetaclass withAllSuperclasses).
+"/    browser sortByNameAndInheritance value:true.
+"/    browser
+"/        selectClass:aClass;
+"/        selectProtocol: (Tools::BrowserList nameListEntryForALL).
+"/    browser switchToClass:aClass selector:initialSelectorOrNil updateHistory: false.
+"/
+"/    "/ sigh must be done after postbuild
+"/    navigationState classListApplication addOwnerClasses value:false.
+
     "/ browser navigationState meta onChangeEvaluate:(self updateBrowser).
     "/ self updateBrowser.
 !