From 00a4277c4adcab300154892e071be3fb91d57683 Mon Sep 17 00:00:00 2001 From: Philippe Houdoin Date: Sun, 5 Sep 2010 08:09:00 +0000 Subject: [PATCH] Support up to B_MAX_CPU_COUNT distinct colors. This fix #6541. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@38531 a95241bf-73f2-0310-859d-f6bbb57e9c96 --- src/apps/activitymonitor/DataSource.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/apps/activitymonitor/DataSource.cpp b/src/apps/activitymonitor/DataSource.cpp index 4cf8c6b473..5268167198 100644 --- a/src/apps/activitymonitor/DataSource.cpp +++ b/src/apps/activitymonitor/DataSource.cpp @@ -875,12 +875,16 @@ CPUUsageDataSource::_SetCPU(int32 cpu) fShortLabel = fLabel; fLabel << " usage"; - const rgb_color kColors[] = { + const rgb_color kColors[B_MAX_CPU_COUNT] = { // TODO: find some better defaults... {200, 0, 200}, {0, 200, 200}, {80, 80, 80}, {230, 150, 50}, + {255, 0, 0}, + {0, 255, 0}, + {0, 0, 255}, + {0, 150, 230} }; const uint32 kNumColors = sizeof(kColors) / sizeof(kColors[0]);