优化Background组件的生效条件,需要有单独的父节点

This commit is contained in:
monitor1394
2020-05-31 07:43:29 +08:00
parent 73919ab32a
commit 2de64580ec
12 changed files with 96 additions and 31 deletions

View File

@@ -11,9 +11,9 @@ namespace XCharts
{
internal static class ThemeHelper
{
public static Color GetBackgroundColor(ThemeInfo themeInfo, Background background, bool m_IsControlledByLayout)
public static Color GetBackgroundColor(ThemeInfo themeInfo, Background background)
{
if (!m_IsControlledByLayout && background.show && background.hideThemeBackgroundColor) return Color.clear;
if (background.show && background.runtimeActive && background.hideThemeBackgroundColor) return Color.clear;
else return themeInfo.backgroundColor;
}
}