alain.plantec at free.fr
Mon Nov 29 11:51:30 CET 2010
Le 29/11/2010 11:24, Benjamin a écrit :
> Hi guys,
> I had a little problem about MorphTreeMorph>>#setSelectedNodeItemList:
> setSelectedNodeItemList: aNodeItemCollection
> | keptSelectedMorphList |
> self selectedMorphList removeAll.
> "Don't work directly with selectedMorphList because for very long
> list, #drawOn: is time consuming"
> keptSelectedMorphList := selectedMorphList.
> selectedMorphList := #().
> keptSelectedMorphList addAll: (self nodeMorphsWithAllNodeItems:
> I break here
> selectedMorphList := keptSelectedMorphList.
> lastClickedMorph ifNil: [lastClickedMorph := selectedMorphList
> ifEmpty: [nil] ifNotEmpty: [selectedMorphList last]].
> self selectionChanged.
> Due to the break, selectedMorphList is an empty array, and when I try
> to resend the message, removeAll from the start is not understood ...
> Is there a reason why selectedMorphList is set as an empty array ?
I don't think so.
This assignment should be removed.
More information about the Pharo-project