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

Unified Diff: third_party/WebKit/Source/core/svg/SVGLengthTearOff.cpp

Issue 2113943003: SVGLength.value setter should set the value to <number> (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Align with review comments Created 4 years, 6 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/svg/SVGLength.cpp ('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/svg/SVGLengthTearOff.cpp
diff --git a/third_party/WebKit/Source/core/svg/SVGLengthTearOff.cpp b/third_party/WebKit/Source/core/svg/SVGLengthTearOff.cpp
index ebff1f65177f326445c48f10344a3d3bf6ab2c7d..178046be9ddfa528971fe49db29a9ca3e5fdbba7 100644
--- a/third_party/WebKit/Source/core/svg/SVGLengthTearOff.cpp
+++ b/third_party/WebKit/Source/core/svg/SVGLengthTearOff.cpp
@@ -138,13 +138,7 @@ void SVGLengthTearOff::setValue(float value, ExceptionState& exceptionState)
return;
}
- if (target()->isRelative() && !canResolveRelativeUnits(contextElement())) {
- exceptionState.throwDOMException(NotSupportedError, "Could not resolve relative length.");
- return;
- }
-
- SVGLengthContext lengthContext(contextElement());
- target()->setValue(value, lengthContext);
+ target()->setValueAsNumber(value);
commitChange();
}
« no previous file with comments | « third_party/WebKit/Source/core/svg/SVGLength.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698