Changeset 292523 in webkit
- Timestamp:
- Apr 6, 2022 9:29:06 PM (3 months ago)
- Location:
- trunk
- Files:
-
- 4 edited
-
LayoutTests/imported/w3c/ChangeLog (modified) (1 diff)
-
LayoutTests/imported/w3c/web-platform-tests/css/selectors/invalidation/input-pseudo-classes-in-has-expected.txt (modified) (1 diff)
-
Source/WebCore/ChangeLog (modified) (1 diff)
-
Source/WebCore/html/HTMLTextFormControlElement.cpp (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/imported/w3c/ChangeLog
r292467 r292523 1 2022-04-06 Tim Nguyen <ntim@apple.com> 2 3 [:has() pseudo-class] Support invalidation for :placeholder-shown 4 https://bugs.webkit.org/show_bug.cgi?id=238894 5 6 Reviewed by Simon Fraser. 7 8 * web-platform-tests/css/selectors/invalidation/input-pseudo-classes-in-has-expected.txt: 9 1 10 2022-04-06 Oriol Brufau <obrufau@igalia.com> 2 11 -
trunk/LayoutTests/imported/w3c/web-platform-tests/css/selectors/invalidation/input-pseudo-classes-in-has-expected.txt
r292466 r292523 8 8 PASS :required invalidation 9 9 FAIL :out-of-range invalidation assert_equals: ancestor should be darkgreen expected "rgb(0, 100, 0)" but got "rgb(0, 0, 0)" 10 FAIL :placeholder-shown invalidation assert_equals: ancestor should be navy expected "rgb(0, 0, 128)" but got "rgb(0, 0, 0)" 10 PASS :placeholder-shown invalidation 11 11 -
trunk/Source/WebCore/ChangeLog
r292522 r292523 1 2022-04-06 Tim Nguyen <ntim@apple.com> 2 3 [:has() pseudo-class] Support invalidation for :placeholder-shown 4 https://bugs.webkit.org/show_bug.cgi?id=238894 5 6 Reviewed by Simon Fraser. 7 8 Test: imported/w3c/web-platform-tests/css/selectors/invalidation/input-pseudo-classes-in-has.html 9 10 Use same pattern as other input pseudo classes. 11 12 * html/HTMLTextFormControlElement.cpp: 13 (WebCore::HTMLTextFormControlElement::updatePlaceholderVisibility): 14 1 15 2022-04-06 Myles C. Maxfield <mmaxfield@apple.com> 2 16 -
trunk/Source/WebCore/html/HTMLTextFormControlElement.cpp
r292370 r292523 50 50 #include "NodeTraversal.h" 51 51 #include "Page.h" 52 #include "PseudoClassChangeInvalidation.h" 52 53 #include "RenderLineBreak.h" 53 54 #include "RenderTextControlSingleLine.h" … … 184 185 void HTMLTextFormControlElement::updatePlaceholderVisibility() 185 186 { 186 bool placeHolderWasVisible = m_isPlaceholderVisible; 187 m_isPlaceholderVisible = placeholderShouldBeVisible(); 188 189 if (placeHolderWasVisible == m_isPlaceholderVisible) 187 bool newIsPlaceholderVisible = placeholderShouldBeVisible(); 188 if (m_isPlaceholderVisible == newIsPlaceholderVisible) 190 189 return; 191 190 192 invalidateStyleForSubtree(); 191 Style::PseudoClassChangeInvalidation styleInvalidation(*this, CSSSelector::PseudoClassPlaceholderShown, newIsPlaceholderVisible); 192 m_isPlaceholderVisible = newIsPlaceholderVisible; 193 194 if (RefPtr placeholder = placeholderElement()) 195 placeholder->invalidateStyle(); 193 196 } 194 197
Note: See TracChangeset
for help on using the changeset viewer.