[squeak-dev] The Trunk: Morphic-mt.1588.mcz

commits at source.squeak.org commits at source.squeak.org
Fri Nov 15 15:10:12 UTC 2019


Marcel Taeumel uploaded a new version of Morphic to project The Trunk:
http://source.squeak.org/trunk/Morphic-mt.1588.mcz

==================== Summary ====================

Name: Morphic-mt.1588
Author: mt
Time: 15 November 2019, 4:10:03.49233 pm
UUID: 2564e3d0-73ee-7849-920d-e60f2ba06e76
Ancestors: Morphic-mt.1587

Flag a serious bug in a tree-widget's roots-update-algorithm.

=============== Diff against Morphic-mt.1587 ===============

Item was changed:
  ----- Method: SimpleHierarchicalListMorph>>addMorphsTo:from:allowSorting:withExpandedItems:atLevel: (in category 'private') -----
  addMorphsTo: morphList from: aCollection allowSorting: sortBoolean withExpandedItems: expandedItems atLevel: newIndent
  
  	| priorMorph newCollection firstAddition |
  	priorMorph := nil.
  	newCollection := (sortBoolean and: [sortingSelector notNil]) ifTrue: [
  		aCollection sorted: [ :a :b | 
  			(a perform: sortingSelector) <= (b perform: sortingSelector)]
  	] ifFalse: [
  		aCollection
  	].
  	firstAddition := nil.
  	newCollection do: [:item | 
  		priorMorph := self indentingItemClass basicNew 
  			initWithContents: item 
  			prior: priorMorph 
  			forList: self
  			indentLevel: newIndent.
  		priorMorph
  			color: self textColor;
  			font: self font;
  			selectionColor: self selectionColor;
  			selectionTextColor: self selectionTextColor;
  			hoverColor: self hoverColor;
  			highlightTextColor: self highlightTextColor;
  			filterColor: self filterColor;
  			filterTextColor: self filterTextColor.
  		firstAddition ifNil: [firstAddition := priorMorph].
  		morphList add: priorMorph.
  		((item hasEquivalentIn: expandedItems) or: [priorMorph isExpanded]) ifTrue: [
+ 			self flag: #bug. "mt: Endless recursion can happen for similar items in the tree."
  			priorMorph isExpanded: true.
  			priorMorph 
  				addChildrenForList: self 
  				addingTo: morphList
  				withExpandedItems: expandedItems.
  		].
  	].
  	^firstAddition
  	
  !



More information about the Squeak-dev mailing list