Commit 4dc7f4ca authored by Susan Farley's avatar Susan Farley Committed by Alexandre Julliard

Under some conditions its necessary to explicitly show the

scrollbars.
parent 75b25be6
...@@ -2495,26 +2495,25 @@ TREEVIEW_UpdateScrollBars(TREEVIEW_INFO *infoPtr) ...@@ -2495,26 +2495,25 @@ TREEVIEW_UpdateScrollBars(TREEVIEW_INFO *infoPtr)
if (vert) if (vert)
{ {
infoPtr->uInternalStatus |= TV_VSCROLL;
si.nPage = TREEVIEW_GetVisibleCount(infoPtr); si.nPage = TREEVIEW_GetVisibleCount(infoPtr);
si.nPos = infoPtr->firstVisible->visibleOrder; si.nPos = infoPtr->firstVisible->visibleOrder;
si.nMax = infoPtr->maxVisibleOrder - 1; si.nMax = infoPtr->maxVisibleOrder - 1;
SetScrollInfo(hwnd, SB_VERT, &si, TRUE); SetScrollInfo(hwnd, SB_VERT, &si, TRUE);
if (!(infoPtr->uInternalStatus & TV_VSCROLL))
ShowScrollBar(hwnd, SB_VERT, TRUE);
infoPtr->uInternalStatus |= TV_VSCROLL;
} }
else else
{ {
if (infoPtr->uInternalStatus & TV_VSCROLL) if (infoPtr->uInternalStatus & TV_VSCROLL)
ShowScrollBar(hwnd, SB_VERT, FALSE); ShowScrollBar(hwnd, SB_VERT, FALSE);
infoPtr->uInternalStatus &= ~TV_VSCROLL; infoPtr->uInternalStatus &= ~TV_VSCROLL;
} }
if (horz) if (horz)
{ {
infoPtr->uInternalStatus |= TV_HSCROLL;
si.nPage = infoPtr->clientWidth; si.nPage = infoPtr->clientWidth;
si.nPos = infoPtr->scrollX; si.nPos = infoPtr->scrollX;
si.nMax = infoPtr->treeWidth - 1; si.nMax = infoPtr->treeWidth - 1;
...@@ -2525,12 +2524,17 @@ TREEVIEW_UpdateScrollBars(TREEVIEW_INFO *infoPtr) ...@@ -2525,12 +2524,17 @@ TREEVIEW_UpdateScrollBars(TREEVIEW_INFO *infoPtr)
scrollX = si.nPos; scrollX = si.nPos;
} }
if (!(infoPtr->uInternalStatus & TV_HSCROLL))
ShowScrollBar(hwnd, SB_HORZ, TRUE);
infoPtr->uInternalStatus |= TV_HSCROLL;
SetScrollInfo(hwnd, SB_HORZ, &si, TRUE); SetScrollInfo(hwnd, SB_HORZ, &si, TRUE);
} }
else else
{ {
if (infoPtr->uInternalStatus & TV_HSCROLL) if (infoPtr->uInternalStatus & TV_HSCROLL)
ShowScrollBar(hwnd, SB_HORZ, FALSE); ShowScrollBar(hwnd, SB_HORZ, FALSE);
infoPtr->uInternalStatus &= ~TV_HSCROLL;
scrollX = 0; scrollX = 0;
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment