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

Unified Diff: third_party/WebKit/Source/platform/graphics/filters/FEOffset.cpp

Issue 2341923002: Harmonize FilterEffect::mapRect and mapPaintRect (Closed)
Patch Set: Rebase Created 4 years, 3 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: third_party/WebKit/Source/platform/graphics/filters/FEOffset.cpp
diff --git a/third_party/WebKit/Source/platform/graphics/filters/FEOffset.cpp b/third_party/WebKit/Source/platform/graphics/filters/FEOffset.cpp
index 35090177a9de1ba15097ae25ccf8d2528674328c..a6a27d700c89c9dde14b17e7621c9add0ef34e47 100644
--- a/third_party/WebKit/Source/platform/graphics/filters/FEOffset.cpp
+++ b/third_party/WebKit/Source/platform/graphics/filters/FEOffset.cpp
@@ -63,13 +63,10 @@ void FEOffset::setDy(float dy)
m_dy = dy;
}
-FloatRect FEOffset::mapRect(const FloatRect& rect, bool forward) const
+FloatRect FEOffset::mapEffect(const FloatRect& rect) const
{
FloatRect result = rect;
- if (forward)
- result.move(getFilter()->applyHorizontalScale(m_dx), getFilter()->applyVerticalScale(m_dy));
- else
- result.move(-getFilter()->applyHorizontalScale(m_dx), -getFilter()->applyVerticalScale(m_dy));
+ result.move(getFilter()->applyHorizontalScale(m_dx), getFilter()->applyVerticalScale(m_dy));
return result;
}

Powered by Google App Engine
This is Rietveld 408576698