Index: trunk/src/comctl32/progress.c
===================================================================
--- trunk/src/comctl32/progress.c	(revision 218)
+++ trunk/src/comctl32/progress.c	(revision 219)
@@ -1,3 +1,3 @@
-/* $Id: progress.c,v 1.5 1999-06-16 20:25:43 cbratschi Exp $ */
+/* $Id: progress.c,v 1.6 1999-06-26 14:20:31 cbratschi Exp $ */
 /*
  * Progress control
@@ -56,11 +56,9 @@
 
   /* get the required background brush */
-  if (infoPtr->ColorBk == CLR_DEFAULT) hbrBk = GetSysColorBrush (COLOR_3DFACE);
-  else hbrBk = CreateSolidBrush (infoPtr->ColorBk);
+  if (infoPtr->ColorBk == CLR_DEFAULT) hbrBk = GetSysColorBrush(COLOR_3DFACE);
+  else hbrBk = CreateSolidBrush(infoPtr->ColorBk);
 
   /* get client rectangle */
   GetClientRect (hwnd, &rect);
-  rect.right--;
-  rect.bottom--;
 
   /* draw the background */
@@ -69,13 +67,13 @@
     FillRect(hdc, &rect, hbrBk);
     //Border
-    hbrLight = GetSysColorBrush(COLOR_3DLIGHT);
-    hbrShadow = GetSysColorBrush(COLOR_3DSHADOW);
-    MoveToEx(hdc,rect.left,rect.bottom,NULL);
+    hbrLight = GetSysColorPen(COLOR_BTNHILIGHT);
+    hbrShadow = GetSysColorPen(COLOR_BTNSHADOW);
+    MoveToEx(hdc,rect.left,rect.bottom-1,NULL);
     hbrOld = SelectObject(hdc,hbrShadow);
     LineTo(hdc,rect.left,rect.top);
-    LineTo(hdc,rect.right,rect.top);
+    LineTo(hdc,rect.right-1,rect.top);
     SelectObject(hdc,hbrLight);
-    LineTo(hdc,rect.right,rect.bottom);
-    LineTo(hdc,rect.left,rect.bottom);
+    LineTo(hdc,rect.right-1,rect.bottom-1);
+    LineTo(hdc,rect.left,rect.bottom-1);
     SelectObject(hdc,hbrOld);
   }
Index: trunk/src/comctl32/tooltips.c
===================================================================
--- trunk/src/comctl32/tooltips.c	(revision 218)
+++ trunk/src/comctl32/tooltips.c	(revision 219)
@@ -1,3 +1,3 @@
-/* $Id: tooltips.c,v 1.6 1999-06-24 16:37:45 cbratschi Exp $ */
+/* $Id: tooltips.c,v 1.7 1999-06-26 14:20:31 cbratschi Exp $ */
 /*
  * Tool tip control
@@ -19,5 +19,4 @@
 
 /* CB: Odin32 problems
- - not defined colors: COLOR_INFOBK, COLOR_INFOTEXT
  - WM_NCCREATE not handled first -> title bar visible if WS_POPUP wasn't set before
 */
@@ -1858,6 +1857,6 @@
     infoPtr->bActive = TRUE;
     infoPtr->bTrackActive = FALSE;
-    infoPtr->clrBk   = RGB(0,0,0);//GetSysColor(COLOR_INFOBK);//CB: to change
-    infoPtr->clrText = RGB(255,255,255);//GetSysColor(COLOR_INFOTEXT);//CB: to change
+    infoPtr->clrBk   = GetSysColor(COLOR_INFOBK);
+    infoPtr->clrText = GetSysColor(COLOR_INFOTEXT);
 
     nclm.cbSize = sizeof(NONCLIENTMETRICSA);
Index: trunk/src/comctl32/trackbar.c
===================================================================
--- trunk/src/comctl32/trackbar.c	(revision 218)
+++ trunk/src/comctl32/trackbar.c	(revision 219)
@@ -1,3 +1,3 @@
-/* $Id: trackbar.c,v 1.7 1999-06-24 16:37:45 cbratschi Exp $ */
+/* $Id: trackbar.c,v 1.8 1999-06-26 14:20:32 cbratschi Exp $ */
 /*
  * Trackbar control
@@ -11,6 +11,7 @@
  * TODO:
  *
- *   - more notifications.
- *   - Fix Odin32/WINE DrawEdge() bugs
+ *   - more notifications. (CB: should be complete)
+ *   - TRACKBAR_UpdateThumb, TRACKBAR_UpdateThumbPosition:
+ *     use a memory dc to avoid flickering by short movements
  */
 
@@ -449,6 +450,6 @@
       if (dwStyle & TBS_BOTH)
       {
-        DrawEdge (hdc,&thumb,EDGE_RAISED,BF_RECT | BF_ADJUST);
-        FillRect (hdc,&thumb,hbr);
+        DrawEdge(hdc,&thumb,EDGE_RAISED,BF_RECT | BF_ADJUST);
+        FillRect(hdc,&thumb,hbr);
       } else
       {
@@ -462,4 +463,6 @@
           if (dwStyle & TBS_LEFT)
           {
+            HPEN oldPen,pen;
+
             //Outline
 
@@ -477,5 +480,5 @@
             points[5].x = points[0].x;
             points[5].y = points[0].y;
-            Polygon (hdc,points,6);
+            Polygon(hdc,points,6);
 
             //Edge
@@ -487,18 +490,25 @@
             //Draw notch
 
-            triangle.right = points[0].x-1;
-            triangle.top = points[0].y+1+1;
+            triangle.right = points[0].x;
+            triangle.top = points[0].y;
             triangle.left = points[1].x;
-            triangle.bottom = points[1].y+1; //Odin32 fix
-            DrawEdge(hdc,&triangle,EDGE_SUNKEN,BF_DIAGONAL | BF_DIAGONAL_ENDBOTTOMLEFT);
-            triangle.right = points[2].x;
-            triangle.bottom = points[2].y;
-            triangle.left = points[1].x;
-            triangle.top = points[1].y; //Odin32 bug: wrong lines
-            DrawEdge(hdc,&triangle,EDGE_SUNKEN,BF_DIAGONAL | BF_DIAGONAL_ENDTOPLEFT);
-
+            triangle.bottom = points[1].y;
+            DrawEdge(hdc,&triangle,EDGE_RAISED,BF_DIAGONAL | BF_DIAGONAL_ENDTOPRIGHT);
+
+            //draw this line direct, DrawEdge not useful
+            pen = GetSysColorPen(COLOR_3DDKSHADOW);
+            oldPen = SelectObject(hdc,pen);
+            MoveToEx(hdc,points[1].x,points[1].y,NULL);
+            LineTo(hdc,points[2].x-1,points[2].y-1);
+            pen = GetSysColorPen(COLOR_BTNSHADOW);
+            SelectObject(hdc,pen);
+            MoveToEx(hdc,points[1].x+1,points[1].y,NULL);
+            LineTo(hdc,points[2].x,points[2].y-1);
+            SelectObject(hdc,oldPen);
 
           } else //Right
           {
+            HPEN oldPen,pen;
+
             //Outline
 
@@ -516,5 +526,5 @@
             points[5].x = points[0].x;
             points[5].y = points[0].y;
-            Polygon (hdc,points,6);
+            Polygon(hdc,points,6);
 
             //Edge
@@ -525,14 +535,20 @@
             //Draw notch
 
-            triangle.left = points[4].x;
-            triangle.top = points[4].y;
+            //draw this line direct, DrawEdge not useful
+            pen = GetSysColorPen(COLOR_3DLIGHT);
+            oldPen = SelectObject(hdc,pen);
+            MoveToEx(hdc,points[4].x,points[4].y,NULL);
+            LineTo(hdc,points[3].x-1,points[3].y-1);
+            pen = GetSysColorPen(COLOR_BTNHIGHLIGHT);
+            SelectObject(hdc,pen);
+            MoveToEx(hdc,points[4].x,points[4].y+1,NULL);
+            LineTo(hdc,points[3].x-2,points[3].y-1);
+            SelectObject(hdc,oldPen);
+
             triangle.right = points[3].x;
-            triangle.bottom = points[3].y;
-            DrawEdge(hdc,&triangle,EDGE_SUNKEN,BF_DIAGONAL | BF_DIAGONAL_ENDBOTTOMRIGHT);
+            triangle.top = points[3].y;
             triangle.left = points[2].x;
             triangle.bottom = points[2].y;
-            triangle.right = points[3].x;
-            triangle.top = points[3].y; //Odin32: pixel bug
-            DrawEdge(hdc,&triangle,EDGE_SUNKEN,BF_DIAGONAL | BF_DIAGONAL_ENDTOPRIGHT);
+            DrawEdge(hdc,&triangle,EDGE_RAISED,BF_DIAGONAL | BF_DIAGONAL_ENDBOTTOMLEFT);
           }
         } else
@@ -556,5 +572,5 @@
             points[5].x = points[0].x;
             points[5].y = points[0].y;
-            Polygon (hdc,points,6);
+            Polygon(hdc,points,6);
 
             //Edge
@@ -571,9 +587,11 @@
             triangle.top = points[1].y;
             DrawEdge(hdc,&triangle,EDGE_RAISED,BF_DIAGONAL | BF_DIAGONAL_ENDTOPRIGHT);
-            triangle.right = points[1].x;
-            triangle.bottom = points[1].y;
-            triangle.left = points[2].x-1;
-            triangle.top = points[2].y-1;
-            DrawEdge(hdc,&triangle,EDGE_SUNKEN,BF_DIAGONAL | BF_DIAGONAL_ENDTOPLEFT);
+
+
+            triangle.left = points[1].x;
+            triangle.top = points[1].y;
+            triangle.right = points[2].x;
+            triangle.bottom = points[2].y;
+            DrawEdge(hdc,&triangle,EDGE_RAISED,BF_DIAGONAL | BF_DIAGONAL_ENDBOTTOMRIGHT);
 
           } else //Bottom
@@ -595,5 +613,5 @@
             points[5].x = points[0].x;
             points[5].y = points[0].y;
-            Polygon (hdc,points,6);
+            Polygon(hdc,points,6);
 
             //Edge
@@ -605,14 +623,14 @@
             //Draw notch
 
-            triangle.left = points[4].x;
-            triangle.top = points[4].y; //Odin32: wrong pixel at .y-1!
+            triangle.right = points[2].x;
+            triangle.top = points[2].y;
+            triangle.left = points[3].x;
+            triangle.bottom = points[3].y;
+            DrawEdge(hdc,&triangle,EDGE_RAISED,BF_DIAGONAL | BF_DIAGONAL_ENDBOTTOMLEFT);
             triangle.right = points[3].x;
             triangle.bottom = points[3].y;
-            DrawEdge(hdc,&triangle,EDGE_SUNKEN,BF_DIAGONAL | BF_DIAGONAL_ENDBOTTOMRIGHT);
-            triangle.left = points[3].x-1; //Odin32: wrong pixel at .x-2!
-            triangle.bottom = points[3].y+1;
-            triangle.right = points[2].x-1;
-            triangle.top = points[2].y+1;
-            DrawEdge(hdc,&triangle,EDGE_SUNKEN,BF_DIAGONAL | BF_DIAGONAL_ENDTOPRIGHT);
+            triangle.left = points[4].x;
+            triangle.top = points[4].y;
+            DrawEdge(hdc,&triangle,EDGE_RAISED,BF_DIAGONAL | BF_DIAGONAL_ENDTOPLEFT);
 
           }
@@ -629,10 +647,10 @@
 {
     TRACKBAR_INFO *infoPtr = TRACKBAR_GetInfoPtr (hwnd);
-    DWORD dwStyle = GetWindowLongA (hwnd, GWL_STYLE);
-    RECT rcClient, rcChannel, rcSelection;
-    HBRUSH hBrush = CreateSolidBrush (infoPtr->clrBk);
+    DWORD dwStyle = GetWindowLongA(hwnd, GWL_STYLE);
+    RECT rcClient,rcChannel,rcSelection;
+    HBRUSH hBrush = CreateSolidBrush(infoPtr->clrBk);
     int i;
 
-    GetClientRect (hwnd, &rcClient);
+    GetClientRect(hwnd,&rcClient);
 
     //Background
@@ -659,5 +677,5 @@
     rcChannel = infoPtr->rcChannel;
     rcSelection = infoPtr->rcSelection;
-    DrawEdge (hdc,&rcChannel,EDGE_SUNKEN,BF_RECT | BF_ADJUST);
+    DrawEdge(hdc,&rcChannel,EDGE_SUNKEN,BF_RECT | BF_ADJUST);
 
     if (dwStyle & TBS_ENABLESELRANGE)           /* fill the channel */
@@ -680,5 +698,5 @@
     {
       int ticFlags = dwStyle & 0x0f;
-      COLORREF clrTic = RGB(0,0,0);//CB: black instead of GetSysColor(COLOR_3DDKSHADOW);
+      COLORREF clrTic = GetSysColor(COLOR_3DDKSHADOW);
 
       for (i = 0;i < infoPtr->uNumTics;i++)
@@ -737,9 +755,4 @@
    newRect.right++;
    newRect.bottom++;
-   //Odin32 pixel bugs
-   lastRect.top--;
-   lastRect.left--;
-   newRect.top--;
-   newRect.left--;
 
    hdc = GetDC(hwnd);
@@ -1775,7 +1788,7 @@
     PAINTSTRUCT ps;
 
-    hdc = wParam==0 ? BeginPaint (hwnd, &ps) : (HDC)wParam;
+    hdc = wParam == 0 ? BeginPaint(hwnd,&ps) : (HDC)wParam;
     TRACKBAR_Draw(hwnd,hdc);
-    if (!wParam) EndPaint (hwnd, &ps);
+    if (!wParam) EndPaint(hwnd,&ps);
     return 0;
 }
