0
J'ai un StackPanel
avec plusieurs Expander
s:StackPanel avec plusieurs extenseurs
<StackPanel Margin="0,10,0,0">
<Expander Header="Test 1">
<ListBox>
<ListBoxItem Content="Unit 1"/>
<ListBoxItem Content="Unit 2"/>
</ListBox>
</Expander>
<Expander Header="Test 2">
<ListBox>
<ListBoxItem Content="Unit 3"/>
<ListBoxItem Content="Unit 4"/>
</ListBox>
</Expander>
</StackPanel>
Et je veux mettre en œuvre ces comportements:
- un ou les deux
Expander
(s) pourrait être élargi - un seul
Expander
peut être actif (modifier le fond d'en-tête) - l'actif
Expander
changera si je sélectionne une autreExpander
à l'intérieur du panneau si je sélectionne d'autresExpander
ou d'autres contrôles en dehors du panneau desExpander
actifs séjours
Comment puis-je y parvenir?