在 WPF 中,您可以使用 DependencyPropertyKey
将依赖项属性注册为只读。但是,这似乎不适用于 UWP。是否有替代方案,或者他们是否删除了只读依赖属性?
最佳答案
如 DependencyProperty docs 中所述
The Windows Runtime does not provide a way to register a custom dependency property as read-only.
关于c# - 具有私有(private) setter 的 UWP DependencyProperty,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/43440197/