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

Unified Diff: third_party/WebKit/Source/platform/graphics/Image.cpp

Issue 2536883002: Rename Image::drawTiled methods (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « third_party/WebKit/Source/platform/graphics/Image.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/platform/graphics/Image.cpp
diff --git a/third_party/WebKit/Source/platform/graphics/Image.cpp b/third_party/WebKit/Source/platform/graphics/Image.cpp
index c64e17d7b42e3c4b98862a0ba97568c9be568ad1..2e7cbef90cb8f41f73ceefd6de24d0fabda1b667 100644
--- a/third_party/WebKit/Source/platform/graphics/Image.cpp
+++ b/third_party/WebKit/Source/platform/graphics/Image.cpp
@@ -88,20 +88,20 @@ Image::SizeAvailability Image::setData(PassRefPtr<SharedBuffer> data,
return dataChanged(allDataReceived);
}
-void Image::drawTiled(GraphicsContext& ctxt,
- const FloatRect& destRect,
- const FloatPoint& srcPoint,
- const FloatSize& scaledTileSize,
- SkBlendMode op,
- const FloatSize& repeatSpacing) {
- FloatSize intrinsicTileSize = FloatSize(size());
+void Image::drawTiledBackground(GraphicsContext& ctxt,
+ const FloatRect& destRect,
+ const FloatPoint& srcPoint,
+ const FloatSize& scaledTileSize,
+ SkBlendMode op,
+ const FloatSize& repeatSpacing) {
+ FloatSize intrinsicTileSize(size());
if (hasRelativeSize()) {
intrinsicTileSize.setWidth(scaledTileSize.width());
intrinsicTileSize.setHeight(scaledTileSize.height());
}
- FloatSize scale(scaledTileSize.width() / intrinsicTileSize.width(),
- scaledTileSize.height() / intrinsicTileSize.height());
+ const FloatSize scale(scaledTileSize.width() / intrinsicTileSize.width(),
+ scaledTileSize.height() / intrinsicTileSize.height());
const FloatRect oneTileRect = computeTileContaining(
destRect.location(), scaledTileSize, srcPoint, repeatSpacing);
@@ -123,14 +123,13 @@ void Image::drawTiled(GraphicsContext& ctxt,
startAnimation();
}
-// TODO(cavalcantii): see crbug.com/662504.
-void Image::drawTiled(GraphicsContext& ctxt,
- const FloatRect& dstRect,
- const FloatRect& srcRect,
- const FloatSize& providedTileScaleFactor,
- TileRule hRule,
- TileRule vRule,
- SkBlendMode op) {
+void Image::drawTiledBorder(GraphicsContext& ctxt,
+ const FloatRect& dstRect,
+ const FloatRect& srcRect,
+ const FloatSize& providedTileScaleFactor,
+ TileRule hRule,
+ TileRule vRule,
+ SkBlendMode op) {
// TODO(cavalcantii): see crbug.com/662513.
FloatSize tileScaleFactor = providedTileScaleFactor;
if (vRule == RoundTile) {
« no previous file with comments | « third_party/WebKit/Source/platform/graphics/Image.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698