开发者

<ContentControl><ContentPresenter/></ContentControl>?

I am looking at someone's control template and wherever this template needs to include content, it uses:

<ContentControl>
   <ContentPresenter />
</ContentControl> 

Why not use just <ContentPresenter />? Is there any reason why it needs to be wrapp开发者_运维知识库ed in ContentControl?

Thanks

konstantin


Is there any reason why it needs to be wrapped in ContentControl?

It doesn't need to. Doing this is useless, you only need to use <ContentPresenter /> in a ControlTemplate

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜