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

Side by Side Diff: third_party/WebKit/Source/platform/transforms/Matrix3DTransformOperation.cpp

Issue 2482753002: Fix matrix3d transform under page zoom (Closed)
Patch Set: Add a comment for zoom Created 4 years, 1 month 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2009 Apple Inc. All rights reserved. 2 * Copyright (C) 2009 Apple Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
47 47
48 if (blendToIdentity) 48 if (blendToIdentity)
49 std::swap(fromT, toT); 49 std::swap(fromT, toT);
50 50
51 toT.blend(fromT, progress); 51 toT.blend(fromT, progress);
52 return Matrix3DTransformOperation::create(toT); 52 return Matrix3DTransformOperation::create(toT);
53 } 53 }
54 54
55 PassRefPtr<TransformOperation> Matrix3DTransformOperation::zoom(double factor) { 55 PassRefPtr<TransformOperation> Matrix3DTransformOperation::zoom(double factor) {
56 TransformationMatrix result = m_matrix; 56 TransformationMatrix result = m_matrix;
57 result.setM41(result.m41() * factor); 57 result.zoom(factor);
58 result.setM42(result.m42() * factor);
59 return create(result); 58 return create(result);
60 } 59 }
61 60
62 } // namespace blink 61 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698