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

Unified Diff: Source/platform/DragImage.h

Issue 886323005: Pass InterpolationQuality into DragImage to respect image-rendering:pixelated. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 5 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 side-by-side diff with in-line comments
Download patch
Index: Source/platform/DragImage.h
diff --git a/Source/platform/DragImage.h b/Source/platform/DragImage.h
index 9abdf5f7696bf5fc499391fa260e3c4adfda7c8b..81bd5ac15f9defbf9c3d88dd21ab26040710d36a 100644
--- a/Source/platform/DragImage.h
+++ b/Source/platform/DragImage.h
@@ -29,6 +29,7 @@
#include "platform/geometry/IntSize.h"
#include "platform/graphics/ImageOrientation.h"
#include "platform/graphics/paint/DisplayItemClient.h"
+#include "skia/ext/image_operations.h"
Justin Novosad 2015/02/05 05:06:24 I realize this dependency is not new to this patch
jackhou1 2015/02/10 01:53:56 Done.
#include "third_party/skia/include/core/SkBitmap.h"
#include "wtf/Forward.h"
@@ -40,7 +41,9 @@ class KURL;
class PLATFORM_EXPORT DragImage {
public:
- static PassOwnPtr<DragImage> create(Image*, RespectImageOrientationEnum = DoNotRespectImageOrientation, float deviceScaleFactor = 1);
+ typedef skia::ImageOperations::ResizeMethod ResizeMethod;
+
+ static PassOwnPtr<DragImage> create(Image*, RespectImageOrientationEnum = DoNotRespectImageOrientation, float deviceScaleFactor = 1, ResizeMethod = ResizeMethod::RESIZE_LANCZOS3);
static PassOwnPtr<DragImage> create(const KURL&, const String& label, const FontDescription& systemFont, float deviceScaleFactor);
~DragImage();
@@ -53,12 +56,13 @@ public:
void dissolveToFraction(float fraction);
private:
- DragImage(const SkBitmap&, float resolutionScale);
+ DragImage(const SkBitmap&, float resolutionScale, ResizeMethod);
DisplayItemClient displayItemClient() const { return toDisplayItemClient(this); }
SkBitmap m_bitmap;
float m_resolutionScale;
+ ResizeMethod m_resizeMethod;
};
}

Powered by Google App Engine
This is Rietveld 408576698