Added user friendly Ghz awareness :-).

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13521 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Philippe Houdoin
2005-07-07 10:26:13 +00:00
parent 441bb1aa7a
commit 67522bbd91
+5 -1
View File
@@ -216,7 +216,11 @@ NormalPulseView::Draw(BRect rect)
// Draw processor type and speed
char buf[500];
sprintf(buf, "%d MHz", CalculateCPUSpeed());
int cpu_speed = CalculateCPUSpeed();
if (cpu_speed > 1000)
sprintf(buf, "%.2f Ghz", cpu_speed / 1000.0f);
else
sprintf(buf, "%d MHz", cpu_speed);
SetDrawingMode(B_OP_OVER);
SetHighColor(240, 240, 240);
SetFontSize(fProcessorFontSize);