I have created a custom button style with triggers for "Keyboard Focus" and "IsMouseOver".
If I give keyboard control to one button while the mouse is over the other, the style works fine. However, as soon as I do "press" the button that has keyboard focus using the space key, the style for the button that is being moused over is reverted
as if the control did not have the mouse over. Once the pressed button is released, the mouse over button reverts to the expected style.
This behavior does not occur in other windows programs, e.g. visual studio where the moused over control retains its style.
Here is some sample code to reproduce the issue and the steps:
1. Place mouse over button labeled "Another Button".
2. Press the tab key until the button labeled "One Button" has the style for keyboard focus.
3. Press the space key to trigger the style change for the "One Button" to the "Pressed Button" style. Hold the space bar.
At this point the "Another Button" loses the style for "Mouse Over".
View Complete Post