ElementName vs. RelativeResource?

前端 未结 3 967
别跟我提以往
别跟我提以往 2020-12-31 03:21

What of the following TextBlocks\' Bindings costs more performance:



        
3条回答
  •  余生分开走
    2020-12-31 03:26

    The later of the two needs to walk the visual tree looking for a particular ancestor type, where as the prior looks directly to the window's namescope for a registered object with that name...my guess would be the later is marginally slower...that said, I don't think there will be a significant performance difference.

    Hope it helps,

    Aj

提交回复
热议问题