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

Unified Diff: cc/base/math_util.cc

Issue 390233003: Decrement CreateDoubleValue count (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 6 years, 5 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: cc/base/math_util.cc
diff --git a/cc/base/math_util.cc b/cc/base/math_util.cc
index a619b50698b4c536ec3cd9542b60b67e5349b4c3..07ad77bd7703d8fc2ed7768858044a7a9b348688 100644
--- a/cc/base/math_util.cc
+++ b/cc/base/math_util.cc
@@ -650,12 +650,12 @@ scoped_ptr<base::Value> MathUtil::AsValue(const gfx::BoxF& box) {
}
scoped_ptr<base::Value> MathUtil::AsValueSafely(double value) {
- return scoped_ptr<base::Value>(base::Value::CreateDoubleValue(
+ return scoped_ptr<base::Value>(new base::FundamentalValue(
std::min(value, std::numeric_limits<double>::max())));
}
scoped_ptr<base::Value> MathUtil::AsValueSafely(float value) {
- return scoped_ptr<base::Value>(base::Value::CreateDoubleValue(
+ return scoped_ptr<base::Value>(new base::FundamentalValue(
std::min(value, std::numeric_limits<float>::max())));
}
« no previous file with comments | « base/prefs/pref_value_map_unittest.cc ('k') | components/policy/core/browser/configuration_policy_handler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698