public Level_AreaItemControl(Level_AreaItemWrapper wrapper, BitmapImage icon) : base(wrapper, icon) { PropertyInfo prop = null; // Текст подсказки StringBuilder sb = new StringBuilder(); sb.AppendLine(String.Format(Localization.Tooltip_Level, wrapper.Caption)); prop = wrapper.GetCustomProperty(InfoBase.HIERARCHY_CAPTION); if (prop != null) { sb.AppendLine(String.Format(Localization.Tooltip_Hierarchy, prop.Value)); } prop = wrapper.GetCustomProperty(InfoBase.DIMENSION_CAPTION); if (prop != null) { sb.AppendLine(String.Format(Localization.Tooltip_Dimension, prop.Value)); } prop = wrapper.GetCustomProperty(InfoBase.CUBE_CAPTION); if (prop != null) { sb.AppendLine(String.Format(Localization.Tooltip_Cube, prop.Value)); } String str = sb.ToString(); str = str.TrimEnd('\n'); str.TrimEnd('\r'); // Подсказка ToolTip.Caption = wrapper.Caption; ToolTip.Text = str; }
public Level_AreaItemControl(Level_AreaItemWrapper wrapper) : this(wrapper, null) { }