WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
207328
Search cancel button becomes visible when there's a hover effect in CSS
https://bugs.webkit.org/show_bug.cgi?id=207328
Summary
Search cancel button becomes visible when there's a hover effect in CSS
Carlos Garcia Campos
Reported
2020-02-06 05:27:45 PST
Created
attachment 389942
[details]
Test case See the attached test case. To reproduce: 1. Click on the search cancel button to clear the text. The button is now hidden 2. Move the mouse and the button is visible again Clicking again in the search field, or any other part of the document makes the button hide permanently. So, when the search field value is emptied the button visibility is correctly set to hidden in RenderSearchField::updateCancelButtonVisibility(), but as soon as the mouse is moved, the style visibility is changed to visible again (I couldn't find where). If we remove the hover effect from the style then the button is correctly hidden, so it has to do with that somehow.
Attachments
Test case
(410 bytes, text/html)
2020-02-06 05:27 PST
,
Carlos Garcia Campos
no flags
Details
WIP: update the style when a new renderer is created
(1.60 KB, patch)
2020-02-06 06:41 PST
,
Carlos Garcia Campos
no flags
Details
Formatted Diff
Diff
Patch
(5.58 KB, patch)
2020-02-07 02:08 PST
,
Carlos Garcia Campos
no flags
Details
Formatted Diff
Diff
Patch
(6.25 KB, patch)
2020-02-10 07:05 PST
,
Carlos Garcia Campos
aperez
: review+
Details
Formatted Diff
Diff
Show Obsolete
(2)
View All
Add attachment
proposed patch, testcase, etc.
Carlos Garcia Campos
Comment 1
2020-02-06 06:41:36 PST
Created
attachment 389949
[details]
WIP: update the style when a new renderer is created It's the render tree updater that creates a new renderer for the search cancel button element in RenderTreeUpdater::updateRenderTree(). In that case, the input element doesn't know about it and RenderSearchField::updateCancelButtonVisibility() is not called. This patch fixes the problem by updating the style when the new renderer is created. I'll try to convert the attached test case into a proper layout test.
Carlos Garcia Campos
Comment 2
2020-02-07 02:08:02 PST
Created
attachment 390068
[details]
Patch
Carlos Garcia Campos
Comment 3
2020-02-10 00:26:50 PST
hmm, the test doesn't pass in iOS for some reason. I will need some help there, I don't have a way to test in iOS.
Carlos Garcia Campos
Comment 4
2020-02-10 01:50:34 PST
Ah, I always forget iOS doesn't support eventSender.mouseDown/Up/MoveTo, I'll just skip this test in iOS.
Carlos Garcia Campos
Comment 5
2020-02-10 07:05:45 PST
Created
attachment 390249
[details]
Patch
Carlos Garcia Campos
Comment 6
2020-02-17 01:37:22 PST
Committed
r256725
: <
https://trac.webkit.org/changeset/256725
>
Radar WebKit Bug Importer
Comment 7
2020-02-17 01:38:14 PST
<
rdar://problem/59504132
>
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