提交 042de0b4 编写于 作者: A art

6235443: REG:Overlapping a swing app with an AWT app causes flickering in the...

6235443: REG:Overlapping a swing app with an AWT app causes flickering in the background swing app on Windows
Summary: AWT text area no longer uses LockWindowUpdate
Reviewed-by: uta, dcherepanov
上级 e4f535c7
......@@ -209,15 +209,13 @@ done:
void AwtTextArea::EditSetSel(CHARRANGE &cr) {
// Fix for 5003402: added restoring/hiding selection to enable automatic scrolling
LockWindowUpdate(GetHWnd());
SendMessage(EM_HIDESELECTION, FALSE, TRUE);
SendMessage(EM_EXSETSEL, 0, reinterpret_cast<LPARAM>(&cr));
SendMessage(EM_HIDESELECTION, TRUE, TRUE);
// 6417581: LockWindowUpdate doesn't force expected drawing
// 6417581: force expected drawing
if (IS_WINVISTA && cr.cpMin == cr.cpMax) {
::InvalidateRect(GetHWnd(), NULL, TRUE);
}
LockWindowUpdate(NULL);
}
void AwtTextArea::EditGetSel(CHARRANGE &cr) {
......@@ -993,12 +991,10 @@ void AwtTextArea::_ReplaceText(void *param)
c->CheckLineSeparator(buffer);
c->RemoveCR(buffer);
// Fix for 5003402: added restoring/hiding selection to enable automatic scrolling
LockWindowUpdate(c->GetHWnd());
c->SendMessage(EM_HIDESELECTION, FALSE, TRUE);
c->SendMessageW(EM_SETSEL, start, end);
c->SendMessageW(EM_REPLACESEL, FALSE, (LPARAM)buffer);
c->SendMessage(EM_HIDESELECTION, TRUE, TRUE);
LockWindowUpdate(NULL);
delete[] buffer;
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册