From 23ad24751a1b45a99b424b0262c3eba9e4ccc784 Mon Sep 17 00:00:00 2001 From: Wojtek Figat Date: Sat, 12 Oct 2024 00:00:02 +0200 Subject: [PATCH] Fix editor tables rows coloring to start with darker one --- Source/Editor/Windows/Profiler/Assets.cs | 2 +- Source/Editor/Windows/Profiler/CPU.cs | 2 +- Source/Editor/Windows/Profiler/GPU.cs | 2 +- Source/Editor/Windows/Profiler/MemoryGPU.cs | 2 +- Source/Editor/Windows/Profiler/Network.cs | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/Source/Editor/Windows/Profiler/Assets.cs b/Source/Editor/Windows/Profiler/Assets.cs index 159392138..3b408587a 100644 --- a/Source/Editor/Windows/Profiler/Assets.cs +++ b/Source/Editor/Windows/Profiler/Assets.cs @@ -266,7 +266,7 @@ namespace FlaxEditor.Windows.Profiler // Add row to the table row.Width = _table.Width; - row.BackgroundColor = rowIndex % 2 == 0 ? rowColor2 : Color.Transparent; + row.BackgroundColor = rowIndex % 2 == 1 ? rowColor2 : Color.Transparent; row.Parent = _table; rowIndex++; } diff --git a/Source/Editor/Windows/Profiler/CPU.cs b/Source/Editor/Windows/Profiler/CPU.cs index 8c6ff5e78..ab25532d4 100644 --- a/Source/Editor/Windows/Profiler/CPU.cs +++ b/Source/Editor/Windows/Profiler/CPU.cs @@ -538,7 +538,7 @@ namespace FlaxEditor.Windows.Profiler row.Depth = e.Depth; row.Width = _table.Width; row.Visible = e.Depth < 2; - row.BackgroundColor = i % 2 == 0 ? rowColor2 : Color.Transparent; + row.BackgroundColor = i % 2 == 1 ? rowColor2 : Color.Transparent; row.Parent = _table; } } diff --git a/Source/Editor/Windows/Profiler/GPU.cs b/Source/Editor/Windows/Profiler/GPU.cs index 7b837768f..b1203787e 100644 --- a/Source/Editor/Windows/Profiler/GPU.cs +++ b/Source/Editor/Windows/Profiler/GPU.cs @@ -384,7 +384,7 @@ namespace FlaxEditor.Windows.Profiler row.Depth = e.Depth; row.Width = _table.Width; row.Visible = e.Depth < 3; - row.BackgroundColor = i % 2 == 0 ? rowColor2 : Color.Transparent; + row.BackgroundColor = i % 2 == 1 ? rowColor2 : Color.Transparent; row.Parent = _table; } } diff --git a/Source/Editor/Windows/Profiler/MemoryGPU.cs b/Source/Editor/Windows/Profiler/MemoryGPU.cs index dd3c6d6ea..84853b275 100644 --- a/Source/Editor/Windows/Profiler/MemoryGPU.cs +++ b/Source/Editor/Windows/Profiler/MemoryGPU.cs @@ -326,7 +326,7 @@ namespace FlaxEditor.Windows.Profiler // Add row to the table row.Width = _table.Width; - row.BackgroundColor = rowIndex % 2 == 0 ? rowColor2 : Color.Transparent; + row.BackgroundColor = rowIndex % 2 == 1 ? rowColor2 : Color.Transparent; row.Parent = _table; rowIndex++; } diff --git a/Source/Editor/Windows/Profiler/Network.cs b/Source/Editor/Windows/Profiler/Network.cs index 2c064351a..c2418f590 100644 --- a/Source/Editor/Windows/Profiler/Network.cs +++ b/Source/Editor/Windows/Profiler/Network.cs @@ -220,7 +220,7 @@ namespace FlaxEditor.Windows.Profiler var table = isRpc ? _tableRpc : _tableRep; row.Width = table.Width; - row.BackgroundColor = rowCount[isRpc ? 0 : 1] % 2 == 0 ? rowColor2 : Color.Transparent; + row.BackgroundColor = rowCount[isRpc ? 0 : 1] % 2 == 1 ? rowColor2 : Color.Transparent; row.Parent = table; if (isRpc) rowCount.X++;