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

Side by Side Diff: third_party/WebKit/WebCore/platform/graphics/FloatPoint.cpp

Issue 21184: WebKit merge 40722:40785 (part 1) (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 11 years, 10 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2004, 2006, 2007 Apple Inc. All rights reserved. 2 * Copyright (C) 2004, 2006, 2007 Apple Inc. All rights reserved.
3 * Copyright (C) 2005 Nokia. All rights reserved. 3 * Copyright (C) 2005 Nokia. All rights reserved.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions 6 * modification, are permitted provided that the following conditions
7 * are met: 7 * are met:
8 * 1. Redistributions of source code must retain the above copyright 8 * 1. Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright 10 * 2. Redistributions in binary form must reproduce the above copyright
(...skipping 22 matching lines...) Expand all
33 33
34 namespace WebCore { 34 namespace WebCore {
35 35
36 FloatPoint::FloatPoint(const IntPoint& p) : m_x(p.x()), m_y(p.y()) 36 FloatPoint::FloatPoint(const IntPoint& p) : m_x(p.x()), m_y(p.y())
37 { 37 {
38 } 38 }
39 39
40 FloatPoint FloatPoint::matrixTransform(const TransformationMatrix& transform) co nst 40 FloatPoint FloatPoint::matrixTransform(const TransformationMatrix& transform) co nst
41 { 41 {
42 double newX, newY; 42 double newX, newY;
43 transform.map(static_cast<double>(m_x), static_cast<double>(m_y), &newX, &ne wY); 43 transform.map(static_cast<double>(m_x), static_cast<double>(m_y), newX, newY );
44 return narrowPrecision(newX, newY); 44 return narrowPrecision(newX, newY);
45 } 45 }
46 46
47 FloatPoint FloatPoint::narrowPrecision(double x, double y) 47 FloatPoint FloatPoint::narrowPrecision(double x, double y)
48 { 48 {
49 return FloatPoint(narrowPrecisionToFloat(x), narrowPrecisionToFloat(y)); 49 return FloatPoint(narrowPrecisionToFloat(x), narrowPrecisionToFloat(y));
50 } 50 }
51 51
52 } 52 }
OLDNEW
« no previous file with comments | « third_party/WebKit/WebCore/platform/graphics/BitmapImage.h ('k') | third_party/WebKit/WebCore/platform/graphics/Image.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698