0
списка следует менятриггера события для всего элемента
<ListView ScrollViewer.VerticalScrollBarVisibility="Auto" Grid.Row="1" Grid.Column="0" Margin="2" Name="CoursesListView" ItemsSource="{Binding CourseTags}">
<ListView.ItemContainerStyle>
<Style TargetType="{x:Type ListViewItem}">
<Setter Property="HorizontalContentAlignment" Value="Stretch"/>
</Style>
</ListView.ItemContainerStyle>
<ListView.ItemTemplate>
<DataTemplate>
<Border Margin="2" BorderThickness="1" BorderBrush="Red" Background="AntiqueWhite" CornerRadius="2" Cursor="Hand">
<WrapPanel ToolTip="{Binding Description}" HorizontalAlignment="Stretch">
<TextBlock Text="{Binding Name}" FontWeight="Bold" />
<TextBlock Text=" (" />
<TextBlock Text="{Binding NumberOfCourses}" TextDecorations="Underline" Foreground="Blue" />
<TextBlock Text=")" />
<i:Interaction.Triggers>
<i:EventTrigger EventName="MouseLeftButtonUp">
<GalaSoft_MvvmLight_Command:EventToCommand Command="{Binding DataContext.ProductTagSelectedCommand, ElementName=LayoutRoot}"
CommandParameter="{Binding Name}" />
</i:EventTrigger>
</i:Interaction.Triggers>
</WrapPanel>
</Border>
</DataTemplate>
</ListView.ItemTemplate>
</ListView>
Элементы растягиваются хорошо и имеет одинаковую ширину, независимо сколько текста у них есть. Ручной курсор также отображается правильно (везде, где я указываю) Проблема заключается в том, что EventTrigger срабатывает только при нажатии текстовых блоков. Как заставить его работать по всему предмету?
Вот так, спасибо! – amplifier