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

Unified Diff: Source/core/css/MediaValuesDynamic.cpp

Issue 252743004: A thread safe CSS calc parser for sizes (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Removed CSSCalc tests that assert Created 6 years, 8 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 | « Source/core/css/MediaValuesDynamic.h ('k') | Source/core/css/parser/MediaConditionTest.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/css/MediaValuesDynamic.cpp
diff --git a/Source/core/css/MediaValuesDynamic.cpp b/Source/core/css/MediaValuesDynamic.cpp
index cc0e3fe2964224f2b751788fc344ae628791a85e..844c2cdc543cc1f9292ff4ad67c2330963978f07 100644
--- a/Source/core/css/MediaValuesDynamic.cpp
+++ b/Source/core/css/MediaValuesDynamic.cpp
@@ -39,6 +39,16 @@ bool MediaValuesDynamic::computeLength(double value, CSSPrimitiveValue::UnitType
result);
}
+bool MediaValuesDynamic::computeLength(double value, CSSPrimitiveValue::UnitTypes type, double& result) const
+{
+ return MediaValues::computeLength(value,
+ type,
+ calculateDefaultFontSize(m_frame),
+ calculateViewportWidth(m_frame),
+ calculateViewportHeight(m_frame),
+ result);
+}
+
bool MediaValuesDynamic::isSafeToSendToAnotherThread() const
{
return false;
« no previous file with comments | « Source/core/css/MediaValuesDynamic.h ('k') | Source/core/css/parser/MediaConditionTest.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698