4
votes

Why is the default button visual behavior on click different in Windows Phone 8.1 "universal" apps? Is there some way to restore it to the behavior consistent with all other versions of Windows Phone/Windows 8 or do I need to create a new custom control?

  • Windows Phone 7/8/8.1 Silverlight/Windows 8.1: Button background flashes a complementary color based on theme, button stays fixed.

  • Windows Phone 8.1 "universal": Button background doesn't change color, tilt effect is applied to the button displacing it based on where the user has touched it.

I'm a beginner developer with some experience in developing WP7/WP8 apps, trying to make my first universal app for WP8.1/Windows 8.1. I verified this behavior in VS2013 Update 2 RC with a new Windows Store App, new WP8.1 Silverlight app, new WP8.1 universal app and one of my existing WP8 apps by just creating a new button object in xaml. Appreciate any help!

1

1 Answers

0
votes

In my own test, the button does change color to the PhoneAccentBrush resource.

But if you want to remove the tilt effect, you should just edit the style of the button. Since you claim to be a beginner, I'll explain how to easily change the style using VS2013. Maybe you don't know this yet.

Right-click your Button in the designer, goto Edit Template... on the menu, then select Edit a Copy...

This will generate the standard button style in your xaml which you can edit. FYI, this will change your document outline to the button style outline. (See Document Outline window in VS2013.) To go back to the page outline, click the up arrow icon at the top of the outline.

Anyways, find the < VisualState x:Name="Pressed"/ > line and then comment out the PointerDownThemeAnimation line.

Done!