WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
185216
Hiding then showing an <object> of type image makes the underlaying image disappear
https://bugs.webkit.org/show_bug.cgi?id=185216
Summary
Hiding then showing an <object> of type image makes the underlaying image dis...
Said Abou-Hallawa
Reported
2018-05-02 14:17:40 PDT
Created
attachment 339339
[details]
test case Open the attached test case. The test case contains an <object> element of type image. The script hides the <object> then it shows the <object> again. Result: An outline rectangle is drawn. Expected: The underlaying image of the <object> element is shown. The reason for this bug is the following: -- The ImageLoader and the <object> element stay alive but the RenderImage is destroyed when the element is made hidden. -- When the <object> element is shown again, a new RenderImage is created. -- ImageLoader::updateFromElement() does not call updateRenderer() or dispatchPendingBeforeLoadEvent() because the image is already loaded i.e. (newImage == oldImage). -- Therefore we do not set the CachedImage of the RenderImageResource of the RenderImage. -- When RenderImage::paintReplaced() is called after the image is made visible again, it does not find a CachedImage for its RenderImageResource. -- So RenderImage::paintReplaced() draws an outline rectangle instead.
Attachments
test case
(861 bytes, text/html)
2018-05-02 14:17 PDT
,
Said Abou-Hallawa
no flags
Details
Patch
(4.76 KB, patch)
2018-05-02 14:41 PDT
,
Said Abou-Hallawa
no flags
Details
Formatted Diff
Diff
Patch
(4.35 KB, patch)
2018-05-02 15:54 PDT
,
Said Abou-Hallawa
no flags
Details
Formatted Diff
Diff
Patch
(4.30 KB, patch)
2018-05-02 16:58 PDT
,
Said Abou-Hallawa
no flags
Details
Formatted Diff
Diff
Show Obsolete
(2)
View All
Add attachment
proposed patch, testcase, etc.
Said Abou-Hallawa
Comment 1
2018-05-02 14:18:41 PDT
<
rdar://problem/39055630
>
Said Abou-Hallawa
Comment 2
2018-05-02 14:41:36 PDT
Created
attachment 339343
[details]
Patch
Said Abou-Hallawa
Comment 3
2018-05-02 15:54:54 PDT
Created
attachment 339361
[details]
Patch
youenn fablet
Comment 4
2018-05-02 16:11:38 PDT
Comment on
attachment 339361
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=339361&action=review
> Source/WebCore/html/HTMLPlugInImageElement.cpp:235 > + RenderImageResource& renderImageResource = renderImage.imageResource();
auto&, maybe no need for renderImage variable also.
Said Abou-Hallawa
Comment 5
2018-05-02 16:58:38 PDT
Created
attachment 339364
[details]
Patch
WebKit Commit Bot
Comment 6
2018-05-02 18:18:01 PDT
Comment on
attachment 339364
[details]
Patch Clearing flags on attachment: 339364 Committed
r231292
: <
https://trac.webkit.org/changeset/231292
>
WebKit Commit Bot
Comment 7
2018-05-02 18:18:02 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