私はこのような方法を行うことができますか?
あなたはA〜Zの
からアルファベットで自分のグループのタイトルをソートしたい場合は、ちょうどあなたのListViewののItemsSourceにバインドあなたの前にそれを自分のグループをソートする必要があります。
var gpData = Contacts.GroupBy(a => a.Name[0], (key, con) => new GroupData() { HeaderTitle = key, Items = con.ToList() }).OrderBy(o=>o.HeaderTitle);
がどのように私はDをクリックするからユーザーを防ぐことができ、J、K、L項目のGridViewの(私はZoomInViewでD、J、K、Lのいずれかのアイテムを持っていないとして)。
基本的な原則は、ListViewItemのIsEnabled
プロパティをfalseに設定する必要があるということです。
<SemanticZoom.ZoomedOutView>
<ListView ItemsSource="{x:Bind CVS.View.CollectionGroups}" SelectionMode="None" GotFocus="ListView_GotFocus">
<ListView.ItemContainerStyle>
<Style TargetType="ListViewItem">
<Setter Property="IsEnabled" Value="False"></Setter>
</Style>
</ListView.ItemContainerStyle>
<ListView.ItemTemplate>
<DataTemplate x:DataType="wuxdata:ICollectionViewGroup">
<TextBlock Text="{x:Bind Group.(data:GroupData.HeaderTitle)}"/>
</DataTemplate>
</ListView.ItemTemplate>
</ListView>
</SemanticZoom.ZoomedOutView>
あなたの場合、IsEnable
プロパティを動的に設定する必要があります。
ありがとうございました –