Changeset 1258 for trunk/src/user32/listbox.cpp
- Timestamp:
- Oct 12, 1999, 8:14:56 PM (26 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/user32/listbox.cpp
r1203 r1258 1 /* $Id: listbox.cpp,v 1. 2 1999-10-08 21:24:40 cbratschiExp $ */1 /* $Id: listbox.cpp,v 1.3 1999-10-12 18:14:55 sandervl Exp $ */ 2 2 /* 3 3 * Listbox controls … … 186 186 { 187 187 info.nMin = 0; 188 info.nMax 188 info.nMax = (descr->nb_items - 1) / descr->page_size; 189 189 info.nPos = descr->top_item / descr->page_size; 190 190 info.nPage = descr->width / descr->column_width; … … 201 201 { 202 202 info.nMin = 0; 203 info.nMax = descr->nb_items - 1; 204 info.nPos = descr->top_item; 203 info.nMax = descr->nb_items - 1; 204 // info.nPos = descr->top_item; 205 info.nPos = descr->selected_item - 1; 205 206 info.nPage = LISTBOX_GetCurrentPageSize( hwnd, descr ); 206 207 info.fMask = SIF_RANGE | SIF_POS | SIF_PAGE; 207 208 if (descr->style & LBS_DISABLENOSCROLL) 208 209 info.fMask |= SIF_DISABLENOSCROLL; 209 SetScrollInfo( hwnd, SB_VERT, &info, TRUE ); 210 211 if(info.nMax > (INT)info.nPage) { 212 ShowScrollBar(hwnd, SB_VERT, TRUE); 213 EnableScrollBar(hwnd, SB_VERT, ESB_ENABLE_BOTH); 214 SetScrollInfo( hwnd, SB_VERT, &info, TRUE ); 215 } 216 else { 217 ShowScrollBar(hwnd, SB_VERT, FALSE); 218 EnableScrollBar(hwnd, SB_VERT, ESB_DISABLE_BOTH); 219 } 210 220 211 221 if (descr->horz_extent) … … 2550 2560 LISTBOX_HandleMouseMove( hwnd, descr, (INT16)LOWORD(lParam), 2551 2561 (INT16)HIWORD(lParam) ); 2552 return 0; 2562 return 1; //SvL: Bugfix -> PMWINDOW expects non-zero return value if 2563 // we want to restore the default mouse cursor 2564 2553 2565 case WM_LBUTTONUP: 2554 2566 return LISTBOX_HandleLButtonUp( hwnd, descr );
Note:
See TracChangeset
for help on using the changeset viewer.