Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(41)

Unified Diff: third_party/WebKit/Source/core/html/HTMLMeterElement.cpp

Issue 1958073002: Introduce :-internal-shadow-host-has-appearance pseudo class, and apply it to METER element. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Remove null host check Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/core/html/HTMLMeterElement.cpp
diff --git a/third_party/WebKit/Source/core/html/HTMLMeterElement.cpp b/third_party/WebKit/Source/core/html/HTMLMeterElement.cpp
index a1f927f610184a37b5a543f8d32f22baa4dcba7a..821b92dfe87cedef58566a7c29b5f7ffd0450aec 100644
--- a/third_party/WebKit/Source/core/html/HTMLMeterElement.cpp
+++ b/third_party/WebKit/Source/core/html/HTMLMeterElement.cpp
@@ -30,7 +30,6 @@
#include "core/html/HTMLContentElement.h"
#include "core/html/HTMLDivElement.h"
#include "core/html/parser/HTMLParserIdioms.h"
-#include "core/html/shadow/AppearanceSwitchElement.h"
#include "core/layout/LayoutObject.h"
#include "core/style/ComputedStyle.h"
@@ -195,7 +194,7 @@ void HTMLMeterElement::didAddUserAgentShadowRoot(ShadowRoot& root)
{
ASSERT(!m_value);
- AppearanceSwitchElement* inner = AppearanceSwitchElement::create(document(), AppearanceSwitchElement::ShowIfHostHasAppearance);
+ HTMLDivElement* inner = HTMLDivElement::create(document());
inner->setShadowPseudoId(AtomicString("-webkit-meter-inner-element"));
root.appendChild(inner);
@@ -208,8 +207,9 @@ void HTMLMeterElement::didAddUserAgentShadowRoot(ShadowRoot& root)
inner->appendChild(bar);
- AppearanceSwitchElement* fallback = AppearanceSwitchElement::create(document(), AppearanceSwitchElement::ShowIfHostHasNoAppearance);
+ HTMLDivElement* fallback = HTMLDivElement::create(document());
fallback->appendChild(HTMLContentElement::create(document()));
+ fallback->setShadowPseudoId(AtomicString("-internal-fallback"));
root.appendChild(fallback);
}
« no previous file with comments | « third_party/WebKit/Source/core/dom/Element.cpp ('k') | third_party/WebKit/Source/core/html/shadow/AppearanceSwitchElement.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698