开发者

How do I share styles in WP7?

There's no "ResourceDictionary" templates in the WP7 SDK. Is there a di开发者_JAVA技巧fferent way of creating styles to share across pages?

Thanks!


App.xaml is the starting point where you can create various styles - specifically in Application.Resources.

And what do you mean by:

There's no "ResourceDictionary" templates in the WP7 SDK

What's wrong with using ResourceDictionary directly in App.xaml?


You can use to share it

    <!--Application Resources-->
<Application.Resources>
    <Style x:Key="bestButtonStyle" TargetType="ButtonBase">
...

Or page resouces to limit the scope

    <phone:PhoneApplicationPage.Resources>
            <Storyboard  x:Name="historyAnimationIn">
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜