(LegendTree.__init__): New instance variable
changing_selection to indicate whether the LegendTree code itself
is currently changing the selection
(LegendTree.normalize_selection): New method to normalize the
selection by selecting the layer item even if the user clicked on
the classification.
(LegendTree._OnSelChanged): normalize the selection. This works
around a bug in wx which doesn't keep track of the selection
properly when subtrees are deleted.
|