我在下面有以下列表框,它绑定到图像 URL 的数据库表。当应用程序运行时,可以单击每个单独的图像,并见证一个浅蓝色的选择框出现在图像上(您可以知道每个单独的图像何时被选中作为单击)。我想做的是在单击每个图像时执行缩放。有谁知道我可以通过修改我目前在下面使用的代码来做到这一点!?(这样做的原因是我需要在水平列表框中显示图像,这就是这段代码的作用。)
<ListBox x:Name="list1" HorizontalAlignment="Left" RenderTransformOrigin="0.5,0.5" Width="400" d:LayoutOverrides="HorizontalAlignment">
<ListBox.ItemsPanel>
<ItemsPanelTemplate>
<StackPanel Orientation="Horizontal"/>
</ItemsPanelTemplate>
</ListBox.ItemsPanel>
<ListBox.ItemTemplate>
<DataTemplate >
<Image Width="100" Height="100" Stretch="Fill" Source="{Binding LowResUrl}"/>
</DataTemplate>
</ListBox.ItemTemplate>
</ListBox>