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

Unified Diff: third_party/WebKit/Source/core/html/shadow/ProgressShadowElement.cpp

Issue 1957593003: Simplify PROGRESS shadow elements. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: 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
« no previous file with comments | « third_party/WebKit/Source/core/html/shadow/ProgressShadowElement.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/html/shadow/ProgressShadowElement.cpp
diff --git a/third_party/WebKit/Source/core/html/shadow/ProgressShadowElement.cpp b/third_party/WebKit/Source/core/html/shadow/ProgressShadowElement.cpp
index 4ee7485ae7563ae50a60e0b7ecfea3de86c0d808..d85b2fb6830edf0cd1c22d11795a4b03bd753c63 100644
--- a/third_party/WebKit/Source/core/html/shadow/ProgressShadowElement.cpp
+++ b/third_party/WebKit/Source/core/html/shadow/ProgressShadowElement.cpp
@@ -43,6 +43,8 @@ ProgressShadowElement::ProgressShadowElement(Document& document)
{
}
+DEFINE_NODE_FACTORY(ProgressShadowElement)
+
HTMLProgressElement* ProgressShadowElement::progressElement() const
{
return toHTMLProgressElement(shadowHost());
@@ -54,39 +56,4 @@ bool ProgressShadowElement::layoutObjectIsNeeded(const ComputedStyle& style)
return progressLayoutObject && !progressLayoutObject->style()->hasAppearance() && HTMLDivElement::layoutObjectIsNeeded(style);
}
-inline ProgressInnerElement::ProgressInnerElement(Document& document)
- : ProgressShadowElement(document)
-{
-}
-
-DEFINE_NODE_FACTORY(ProgressInnerElement)
-
-bool ProgressInnerElement::layoutObjectIsNeeded(const ComputedStyle& style)
-{
- if (progressElement()->openShadowRoot())
- return HTMLDivElement::layoutObjectIsNeeded(style);
-
- LayoutObject* progressLayoutObject = progressElement()->layoutObject();
- return progressLayoutObject && !progressLayoutObject->style()->hasAppearance() && HTMLDivElement::layoutObjectIsNeeded(style);
-}
-
-inline ProgressBarElement::ProgressBarElement(Document& document)
- : ProgressShadowElement(document)
-{
-}
-
-DEFINE_NODE_FACTORY(ProgressBarElement)
-
-ProgressValueElement::ProgressValueElement(Document& document)
- : ProgressShadowElement(document)
-{
-}
-
-void ProgressValueElement::setWidthPercentage(double width)
-{
- setInlineStyleProperty(CSSPropertyWidth, width, CSSPrimitiveValue::UnitType::Percentage);
-}
-
-DEFINE_NODE_FACTORY(ProgressValueElement)
-
} // namespace blink
« no previous file with comments | « third_party/WebKit/Source/core/html/shadow/ProgressShadowElement.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698