Fixing Issue #235 #253

Merged
merged 3 commits into from Aug 3, 2014

Projects

None yet

2 participants

@DavidKarlas
Member

Here are 2 problems fixed. 1. TreeView problem with overwriting selected values at Loaded event with default Items[0] value. Now this is checked with if (SelectedItems.Count == 0) and 2. Not selecting TreeItem because Item was selected before TreeItem created because WPF is LazyLoading TreeItems for Items after Loaded event... Now we register for ItemContainerGenerator_StatusChanged which is fired when TreeItem is lazyloaded so we check with ContainerFromObject(SelectedItems[0]) != null if our item is loaded and if it is we reselect it to make it visible...

@DavidKarlas DavidKarlas Fixing Issue #235 TreeView problem with overwriting selected values a…
…t Loaded event with default Items[0] value and not selecting TreeItem because Item was selected before TreeItem was because WPF is LazyLoading TreeItems for Items after Loaded event...
0667c39
Owner
slluis commented Oct 31, 2013

Hi! The changes look good, but could you please add some comments in the code explaining why that event subscription is required? Thanks!

DavidKarlas added some commits Oct 31, 2013
@DavidKarlas DavidKarlas Added comments to code 1b137e8
@DavidKarlas DavidKarlas Removed part for delayed selecting of VisualItem because it should be…
… solved more generally for all cases. So this pull now only contains fix for issue #235
3c618da
@slluis slluis merged commit dbf1c51 into mono:master Aug 3, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment