riched20: Only call ME_SendRequestResize when control is in-place active.

Prevent GetClientRect from being called when not in-place active.
This commit is contained in:
Charlotte Pabst 2024-10-02 21:03:44 +02:00 committed by Alexandre Julliard
parent dafaadcb4a
commit e61db557ab
Notes: Alexandre Julliard 2024-10-09 23:15:20 +02:00
Approved-by: Huw Davies (@huw)
Approved-by: Alexandre Julliard (@julliard)
Merge-Request: https://gitlab.winehq.org/wine/wine/merge_requests/6608
2 changed files with 6 additions and 5 deletions

View file

@ -110,10 +110,12 @@ void editor_draw( ME_TextEditor *editor, HDC hDC, const RECT *update )
if (oldRgn) DeleteObject( oldRgn );
ME_DestroyContext( &c );
if (editor->nTotalLength != editor->nLastTotalLength || editor->nTotalWidth != editor->nLastTotalWidth)
ME_SendRequestResize(editor, FALSE);
editor->nLastTotalLength = editor->nTotalLength;
editor->nLastTotalWidth = editor->nTotalWidth;
if (editor->in_place_active) {
if (editor->nTotalLength != editor->nLastTotalLength || editor->nTotalWidth != editor->nLastTotalWidth)
ME_SendRequestResize(editor, FALSE);
editor->nLastTotalLength = editor->nTotalLength;
editor->nLastTotalWidth = editor->nTotalWidth;
}
}
void ME_Repaint(ME_TextEditor *editor)

View file

@ -1446,7 +1446,6 @@ static void test_inplace_active( BOOL active )
CHECK_CALLED(ITextHostImpl_TxGetClientRect);
} else {
CHECK_NOT_CALLED(ITextHostImpl_TxScrollWindowEx);
todo_wine
CHECK_NOT_CALLED(ITextHostImpl_TxGetClientRect);
}