diff options
author | nduca@chromium.org <nduca@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-05-15 04:33:32 +0000 |
---|---|---|
committer | nduca@chromium.org <nduca@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-05-15 04:33:32 +0000 |
commit | 051e8217c8b9e844411c5ad3344f3b833908300c (patch) | |
tree | 511cce0131d3e47bc1e81e0815ef07d83c78f4b7 /cc/base/math_util.cc | |
parent | 2694ceea8b05c7a82ae83ed206cff6a106fc79b4 (diff) | |
download | chromium_src-051e8217c8b9e844411c5ad3344f3b833908300c.zip chromium_src-051e8217c8b9e844411c5ad3344f3b833908300c.tar.gz chromium_src-051e8217c8b9e844411c5ad3344f3b833908300c.tar.bz2 |
Trace picture piles on layers
R=enne
Review URL: https://chromiumcodereview.appspot.com/14772032
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@200154 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'cc/base/math_util.cc')
-rw-r--r-- | cc/base/math_util.cc | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/cc/base/math_util.cc b/cc/base/math_util.cc index 7873d93..4123cf8 100644 --- a/cc/base/math_util.cc +++ b/cc/base/math_util.cc @@ -526,6 +526,15 @@ scoped_ptr<base::Value> MathUtil::AsValue(gfx::Size s) { return res.PassAs<base::Value>(); } +scoped_ptr<base::Value> MathUtil::AsValue(gfx::Rect r) { + scoped_ptr<base::ListValue> res(new base::ListValue()); + res->AppendInteger(r.x()); + res->AppendInteger(r.y()); + res->AppendInteger(r.width()); + res->AppendInteger(r.height()); + return res.PassAs<base::Value>(); +} + scoped_ptr<base::Value> MathUtil::AsValue(gfx::PointF pt) { scoped_ptr<base::ListValue> res(new base::ListValue()); res->AppendDouble(pt.x()); |