Changeset 252 for trunk/src/comctl32/trackbar.c
- Timestamp:
- Jun 30, 1999, 5:52:19 PM (26 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/comctl32/trackbar.c
r236 r252 1 /* $Id: trackbar.c,v 1. 9 1999-06-28 15:46:28 cbratschi Exp $ */1 /* $Id: trackbar.c,v 1.10 1999-06-30 15:52:18 cbratschi Exp $ */ 2 2 /* 3 3 * Trackbar control … … 67 67 #define SCROLL_TIMER_ID 1 68 68 69 /* Tooltips */ 70 71 #define TOOLTIP_XSPACE 5 72 #define TOOLTIP_YSPACE 5 73 69 74 static BOOL TRACKBAR_SendNotify (HWND hwnd, UINT code); 70 75 … … 78 83 COMCTL32_Free(infoPtr->tics); 79 84 infoPtr->tics = NULL; 85 80 86 infoPtr->uNumTics = 0; 81 87 return; … … 1570 1576 1571 1577 return 0; 1578 } 1579 1580 /* pt intialized with cursor position */ 1581 1582 static VOID TRACKBAR_CalcToolTipPos(HWND hwnd,DWORD dwStyle,TRACKBAR_INFO *infoPtr,POINT *pt) 1583 { 1584 if (dwStyle & TBS_VERT) 1585 { 1586 pt->x += 5; 1587 pt->y += 15; 1588 } else 1589 { 1590 pt->x += 15; 1591 pt->y += 5; 1592 } 1572 1593 } 1573 1594 … … 1613 1634 1614 1635 GetCursorPos(&pt); 1636 TRACKBAR_CalcToolTipPos(hwnd,dwStyle,infoPtr,&pt); 1615 1637 SendMessageA(infoPtr->hwndToolTip,TTM_TRACKPOSITION,0,(LPARAM)MAKELPARAM(pt.x,pt.y)); 1616 1638 … … 1906 1928 ti.lpszText = (LPSTR)buf; 1907 1929 GetCursorPos(&pt); 1930 TRACKBAR_CalcToolTipPos(hwnd,dwStyle,infoPtr,&pt); 1908 1931 1909 1932 SendMessageA(infoPtr->hwndToolTip,TTM_UPDATETIPTEXTA,0,(LPARAM)&ti); 1910 if (dwStyle & TBS_VERT) 1911 { 1912 SendMessageA(infoPtr->hwndToolTip,TTM_TRACKPOSITION,0,(LPARAM)MAKELPARAM(pt.x+5,pt.y+15)); //CB: optimize 1913 } else 1914 { 1915 SendMessageA(infoPtr->hwndToolTip,TTM_TRACKPOSITION,0,(LPARAM)MAKELPARAM(pt.x+15,pt.y+5)); //CB: optimize 1916 } 1933 SendMessageA(infoPtr->hwndToolTip,TTM_TRACKPOSITION,0,(LPARAM)MAKELPARAM(pt.x,pt.y)); 1917 1934 } 1918 1935
Note:
See TracChangeset
for help on using the changeset viewer.