<Panel ux:Class="GenderSwitch">
<Rectangle
Fill="#fff"
Opacity="0.03"
CornerRadius="{Resource controlRadius}" />
/* If I put the WhilePressed at this level, it does respond */
<Grid ColumnCount="2" Columns="1*, 1*" CellSpacing="10">
<Panel HitTestMode="LocalBoundsAndChildren">
<StackPanel Alignment="Center" Orientation="Horizontal">
<Icon IconColor="#ccc" Size="20" Text="{Resource male}" />
<Text Margin="10,0,0,0" TextColor="#ccc" Value="Hombre" />
</StackPanel>
/* This doesn't respond */
<WhilePressed>
<Scaling Factor="0.5" />
</WhilePressed>
</Panel>
<Panel HitTestMode="LocalBoundsAndChildren">
<StackPanel Alignment="Center" Orientation="Horizontal">
<Icon IconColor="#ccc" Size="20" Text="{Resource female}" />
<Text Margin="10,0,0,0" TextColor="#ccc" Value="Mujer" />
</StackPanel>
/* This doesn't respond */
<WhilePressed>
<Scaling Factor="0.5" />
</WhilePressed>
</Panel>
</Grid>
The WhilePressed
or any other event, doesn’t respond in the inner elements, only if I put it in the first level (at the same level of Grid
).
If there is something I am missing I would appreciate that someone points me to the right direction.
Thanks in advance.