Tools__ViewTreeApplication.st
changeset 3658 18137fdc0f76
parent 3628 dae68c3b50a6
child 3660 4b4a427f8976
equal deleted inserted replaced
3657:bb1dd1360035 3658:18137fdc0f76
  2037 
  2037 
  2038 setRootItem:aRootItemOrNil
  2038 setRootItem:aRootItemOrNil
  2039     |theProcess|
  2039     |theProcess|
  2040 
  2040 
  2041     aRootItemOrNil isNil ifTrue:[
  2041     aRootItemOrNil isNil ifTrue:[
  2042 	process := nil.
  2042         process := nil.
  2043     ] ifFalse:[
  2043     ] ifFalse:[
  2044 	"/ expand tree to level 3
  2044         "/ expand tree to level 3
  2045 	aRootItemOrNil do:[:aRootChild|
  2045         aRootItemOrNil do:[:aRootChild|
  2046 	    aRootChild do:[:aSubChild| aSubChild expand ].
  2046             aRootChild do:[:aSubChild| aSubChild expand ].
  2047 	    aRootChild expand.
  2047             aRootChild expand.
  2048 	].
  2048         ].
  2049 	aRootItemOrNil expand.
  2049         aRootItemOrNil expand.
  2050 
  2050 
  2051 	process isNil ifTrue:[
  2051         process isNil ifTrue:[
  2052 	    theProcess := process :=
  2052             "/ the focusFollower process terminates itself, when process is not longer theProcess
  2053 		Process
  2053             theProcess := process :=
  2054 		    for:[
  2054                 Process
  2055 			|update testModeChannel|
  2055                     for:[
  2056 
  2056                         |update testModeChannel|
  2057 			update := false.
  2057 
  2058 			testModeChannel := model testModeChannel.
  2058                         update := false.
  2059 
  2059                         testModeChannel := model testModeChannel.
  2060 			[process == theProcess] whileTrue:[
  2060 
  2061 			    Delay waitForSeconds:0.5.
  2061                         [process == theProcess] whileTrue:[
  2062 
  2062                             Delay waitForSeconds:0.5.
  2063 			    (treeView notNil and:[process == theProcess and:[treeView shown]]) ifTrue:[
  2063 
  2064 				(testModeChannel value == true and:[followFocusChannel value == true]) ifTrue:[
  2064                             (treeView notNil and:[process == theProcess and:[treeView shown]]) ifTrue:[
  2065 				    self selectFocusView.
  2065                                 (testModeChannel value == true and:[followFocusChannel value == true]) ifTrue:[
  2066 				].
  2066                                     self selectFocusView.
  2067 				update ifTrue:[
  2067                                 ].
  2068 				    self updateShownStatus.
  2068                                 update ifTrue:[
  2069 				].
  2069                                     self updateShownStatus.
  2070 				update := update not.
  2070                                 ].
  2071 			    ].
  2071                                 update := update not.
  2072 			].
  2072                             ].
  2073 		    ]
  2073                         ].
  2074 		    priority:(Processor userSchedulingPriority).
  2074                     ]
  2075 	    theProcess name:'ViewTreeInspector - Focus Follower'.
  2075                     priority:(Processor userSchedulingPriority).
  2076 	    theProcess resume.
  2076             theProcess name:'ViewTreeInspector - Focus Follower'.
  2077 	].
  2077             theProcess resume.
       
  2078         ].
  2078     ].
  2079     ].
  2079     model rootItem:aRootItemOrNil.
  2080     model rootItem:aRootItemOrNil.
  2080 
  2081 
  2081     "Modified: / 25-07-2013 / 12:03:44 / cg"
  2082     "Modified: / 25-07-2013 / 12:03:44 / cg"
       
  2083     "Modified (format): / 30-04-2019 / 22:32:23 / Claus Gittinger"
  2082 !
  2084 !
  2083 
  2085 
  2084 updateShownStatus
  2086 updateShownStatus
  2085     |rootItem min max visState listIdx visY0 visY1 height damage|
  2087     |rootItem min max visState listIdx visY0 visY1 height damage|
  2086 
  2088