lixiaojun
2025-04-03 2e52f10a2cccb1471859b05e0d0e9dd9649859c8
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
namespace Yw.WpfUI.Hydro
{
    /// <summary>
    ///  为 Visual3D 添加属性
    /// </summary>
    public static class Visual3DProperties
    {
        //Tag属性
        public static readonly DependencyProperty TagProperty =
            DependencyProperty.RegisterAttached(
                "Tag",
                typeof(VisualL3d),
                typeof(Visual3DProperties),
                new PropertyMetadata(null));
 
        /// <summary>
        /// 获取Tag
        /// </summary>
        public static VisualL3d GetTag(Visual3D visual)
        {
            return (VisualL3d)visual.GetValue(TagProperty);
        }
 
        /// <summary>
        /// 设置Tag
        /// </summary>
        public static void SetTag(Visual3D visual, VisualL3d value)
        {
            visual.SetValue(TagProperty, value);
        }
 
 
    }
}