- // Grab snapshot of all list control items before changing the window
- // style (which deletes the items)
- for ( i = 0; i < GetPageCount(); i++ )
- {
- labels.Add(GetPageText(i));
- imageIds.Add(GetPageImage(i));
- }
-
- // Update the style to use icon view for images, report view otherwise
- long style = wxLC_SINGLE_SEL;
+ // Update the style to use icon view for images, list view otherwise
+ long style = list->GetWindowStyle() & ~wxLC_MASK_TYPE;