richedit: Updated internal style flags on EM_SHOWSCROLLBAR.

The internal style flags are used to determine whether to show or hide
the scrollbar when ME_UpdateScrollBar is called.  EM_SHOWSCROLLBAR seems
to update this state in native richedit controls.
oldstable
Dylan Smith 2009-01-28 01:35:06 -05:00 committed by Alexandre Julliard
parent a051a23119
commit f42e151a6c
1 changed files with 22 additions and 0 deletions

View File

@ -3183,6 +3183,28 @@ LRESULT ME_HandleMessage(ME_TextEditor *editor, UINT msg, WPARAM wParam,
}
case EM_SHOWSCROLLBAR:
{
DWORD flags;
switch (wParam)
{
case SB_HORZ:
flags = WS_HSCROLL;
break;
case SB_VERT:
flags = WS_VSCROLL;
break;
case SB_BOTH:
flags = WS_HSCROLL|WS_VSCROLL;
break;
default:
return 0;
}
if (lParam)
editor->styleFlags |= flags;
else
editor->styleFlags &= flags;
ITextHost_TxShowScrollBar(editor->texthost, wParam, lParam);
return 0;
}