更新基类

pull/56/head
Sunny 3 years ago
parent cee61dd7cb
commit 1ded23bba0

Binary file not shown.

@ -401,6 +401,8 @@ namespace Sunny.UI
color = rectSelectedColor; color = rectSelectedColor;
if (ShowFocusColor && Focused) if (ShowFocusColor && Focused)
color = rectPressColor; color = rectPressColor;
if (isReadOnly)
color = rectReadOnlyColor;
return Enabled ? color : rectDisableColor; return Enabled ? color : rectDisableColor;
} }
@ -412,6 +414,8 @@ namespace Sunny.UI
set; set;
} }
protected bool isReadOnly;
/// <summary> /// <summary>
/// 获取字体颜色 /// 获取字体颜色
/// </summary> /// </summary>
@ -428,6 +432,8 @@ namespace Sunny.UI
color = foreSelectedColor; color = foreSelectedColor;
if (ShowFocusColor && Focused) if (ShowFocusColor && Focused)
color = forePressColor; color = forePressColor;
if (isReadOnly)
color = foreReadOnlyColor;
return Enabled ? color : foreDisableColor; return Enabled ? color : foreDisableColor;
} }
@ -447,6 +453,8 @@ namespace Sunny.UI
color = fillSelectedColor; color = fillSelectedColor;
if (ShowFocusColor && Focused) if (ShowFocusColor && Focused)
color = fillPressColor; color = fillPressColor;
if (isReadOnly)
color = fillReadOnlyColor;
return Enabled ? color : fillDisableColor; return Enabled ? color : fillDisableColor;
} }

Loading…
Cancel
Save