Bug 211139

Summary: [WebKitLegacy] Implement -hidePlaceholder and -showPlaceholderIfNecessary in terms of setCanShowPlaceholder()
Product: WebKit Reporter: Daniel Bates <dbates>
Component: WebCore Misc.Assignee: Daniel Bates <dbates>
Status: RESOLVED FIXED    
Severity: Normal CC: cdumez, eric.carlson, esprehn+autocc, ews-watchlist, gyuyoung.kim, mifenton, simon.fraser, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: WebKit Local Build   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Patch
none
To Land - now with 50% less indentation none

Daniel Bates
Reported 2020-04-28 12:11:09 PDT
Implement -hidePlaceholder and -showPlaceholderIfNecessary in terms of -setCanShowPlaceholder, which was added in the patch for bug #206459. Why do this? Because: 1. Unlike -hidePlaceholder and -showPlaceholderIfNecessary, -setCanShowPlaceholder does NOT of reach into the guts of the field and mutate its CSS. 2. Because of (1), it works correctly should future code be written then modifies the DOM or CSS of the placeholder (which is in the guts of the field). 3. Unlike -hidePlaceholder and -showPlaceholderIfNecessary, there is test coverage of setCanShowPlaceholder() to ensure (2).
Attachments
Patch (6.11 KB, patch)
2020-04-28 12:32 PDT, Daniel Bates
no flags
To Land - now with 50% less indentation (6.01 KB, patch)
2020-04-28 16:34 PDT, Daniel Bates
no flags
Daniel Bates
Comment 1 2020-04-28 12:32:32 PDT
Daniel Bates
Comment 2 2020-04-28 16:05:49 PDT
Window failure unrelated.
Simon Fraser (smfr)
Comment 3 2020-04-28 16:25:48 PDT
Comment on attachment 397871 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=397871&action=review > Source/WebKitLegacy/mac/ChangeLog:11 > + 1. Unlike -hidePlaceholder and -showPlaceholderIfNecessary, setCanShowPlaceholder() does NOT of So much indent.
Daniel Bates
Comment 4 2020-04-28 16:34:44 PDT
Created attachment 397901 [details] To Land - now with 50% less indentation
Daniel Bates
Comment 5 2020-04-28 16:35:12 PDT
Radar WebKit Bug Importer
Comment 6 2020-04-28 16:36:14 PDT
Eric Carlson
Comment 7 2020-04-28 16:39:12 PDT
Comment on attachment 397901 [details] To Land - now with 50% less indentation View in context: https://bugs.webkit.org/attachment.cgi?id=397901&action=review > Source/WebKitLegacy/mac/ChangeLog:11 > + 1. Unlike -hidePlaceholder and -showPlaceholderIfNecessary, setCanShowPlaceholder() does NOT of s/does NOT of/does Not/
Daniel Bates
Comment 8 2020-04-28 16:57:50 PDT
Comment on attachment 397901 [details] To Land - now with 50% less indentation View in context: https://bugs.webkit.org/attachment.cgi?id=397901&action=review >> Source/WebKitLegacy/mac/ChangeLog:11 >> + 1. Unlike -hidePlaceholder and -showPlaceholderIfNecessary, setCanShowPlaceholder() does NOT of > > s/does NOT of/does Not/ yep, I noticed that too AFTER I landed it. I may fix it up in the ChangeLog...
Note You need to log in before you can comment on or make changes to this bug.