WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
122549
[Win] BeginPaint should only be called in response to WM_PAINT.
https://bugs.webkit.org/show_bug.cgi?id=122549
Summary
[Win] BeginPaint should only be called in response to WM_PAINT.
peavo
Reported
2013-10-09 06:17:03 PDT
According to the documentation (
http://msdn.microsoft.com/en-us/library/windows/desktop/dd183362(v=vs.85).aspx
), the Win32 api functions BeginPaint and EndPaint should only be called in response to a WM_PAINT message. Currently, the WebView window procedure might call these functions (via WebView::paint(0, 0)) for all types of messages. Also, there is potential double drawing. If some message is dispatched before WM_PAINT, WebView::paint(0, 0) will be called. This call does not validate the area drawn, so later the WM_PAINT will arrive, drawing the same area.
Attachments
Patch
(1.89 KB, patch)
2013-10-09 06:28 PDT
,
peavo
no flags
Details
Formatted Diff
Diff
View All
Add attachment
proposed patch, testcase, etc.
peavo
Comment 1
2013-10-09 06:28:52 PDT
Created
attachment 213770
[details]
Patch
Brent Fulgham
Comment 2
2013-10-09 09:10:10 PDT
Comment on
attachment 213770
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=213770&action=review
> Source/WebKit/win/WebView.cpp:2467 > + ::UpdateWindow(hWnd);
Will this trigger the logic in webView->performLayeredWIndowUpdate()?
peavo
Comment 3
2013-10-09 09:36:54 PDT
(In reply to
comment #2
)
> (From update of
attachment 213770
[details]
) > View in context:
https://bugs.webkit.org/attachment.cgi?id=213770&action=review
> > > Source/WebKit/win/WebView.cpp:2467 > > + ::UpdateWindow(hWnd); > > Will this trigger the logic in webView->performLayeredWIndowUpdate()?
Yes, UpdateWindow will send the WM_PAINT message (synchronously) if there is an invalid area.
Brent Fulgham
Comment 4
2013-10-09 09:40:24 PDT
Comment on
attachment 213770
[details]
Patch r=me
Radar WebKit Bug Importer
Comment 5
2013-10-09 09:41:06 PDT
<
rdar://problem/15187300
>
peavo
Comment 6
2013-10-09 09:44:18 PDT
(In reply to
comment #4
)
> (From update of
attachment 213770
[details]
) > r=me
Thanks for reviewing!
WebKit Commit Bot
Comment 7
2013-10-09 10:04:10 PDT
Comment on
attachment 213770
[details]
Patch Clearing flags on attachment: 213770 Committed
r157174
: <
http://trac.webkit.org/changeset/157174
>
WebKit Commit Bot
Comment 8
2013-10-09 10:04:12 PDT
All reviewed patches have been landed. Closing bug.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug