From 509fb5e0010ee04331c6b24c2d7ce3ff3cf19d60 Mon Sep 17 00:00:00 2001 From: Erik Faye-Lund Date: Fri, 23 Nov 2007 00:30:25 +0000 Subject: [PATCH] dummy message --- synctracker2.cpp | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/synctracker2.cpp b/synctracker2.cpp index 01d8698..6048fc8 100644 --- a/synctracker2.cpp +++ b/synctracker2.cpp @@ -144,8 +144,6 @@ void paintTracks(HDC hdc, RECT rcTracks) int trackTop = topMarginHeight + (firstLine - scrollPosY) * fontHeight; for (int y = firstLine; y < lastLine; ++y) { - int val = y | (x << 8); - RECT patternDataRect; patternDataRect.left = trackLeft; patternDataRect.right = trackLeft + trackWidth; @@ -153,9 +151,12 @@ void paintTracks(HDC hdc, RECT rcTracks) patternDataRect.bottom = patternDataRect.top + fontHeight; FillRect( hdc, &patternDataRect, (HBRUSH)GetStockObject(WHITE_BRUSH)); + bool key = (y % 8 == 0); + float val = (float(y) / 16); + /* format the text */ - if (y % 16 != 0) _snprintf_s(temp, 256, "- - -", val); - else _snprintf_s(temp, 256, "%2.2f", (float(y) / 16)); + if (!key) _snprintf_s(temp, 256, " - - -"); + else _snprintf_s(temp, 256, "%2.2f", val); TextOut(hdc, trackLeft, trackTop, temp, int(strlen(temp))