Chromium Code Reviews| Index: third_party/WebKit/Source/core/frame/ImageBitmap.h |
| diff --git a/third_party/WebKit/Source/core/frame/ImageBitmap.h b/third_party/WebKit/Source/core/frame/ImageBitmap.h |
| index 8dc3a51e7070dd73fd00cf08973306fd253b6a49..9bedd6bbcaf5b4e6eb39bb20d27354835b1336f4 100644 |
| --- a/third_party/WebKit/Source/core/frame/ImageBitmap.h |
| +++ b/third_party/WebKit/Source/core/frame/ImageBitmap.h |
| @@ -12,6 +12,7 @@ |
| #include "platform/geometry/IntRect.h" |
| #include "platform/graphics/Image.h" |
| #include "platform/heap/Handle.h" |
| +#include "third_party/skia/include/core/SkImage.h" |
| #include "wtf/PassRefPtr.h" |
| #include "wtf/RefCounted.h" |
| @@ -32,8 +33,7 @@ public: |
| static PassRefPtrWillBeRawPtr<ImageBitmap> create(ImageBitmap*, const IntRect&); |
| static PassRefPtrWillBeRawPtr<ImageBitmap> create(Image*, const IntRect&); |
| - PassRefPtr<Image> bitmapImage() const; |
| - PassRefPtrWillBeRawPtr<HTMLImageElement> imageElement() const { return m_imageElement; } |
| + PassRefPtr<SkImage> bitmapData() const; |
|
Justin Novosad
2015/10/30 18:57:45
Clearer name for this: skImage(). Also, It should
|
| IntRect bitmapRect() const { return m_bitmapRect; } |
| @@ -63,10 +63,7 @@ private: |
| void notifyImageSourceChanged() override; |
| bool requestsHighLiveResourceCachePriority() override { return true; } |
| - // ImageBitmaps constructed from HTMLImageElements hold a reference to the HTMLImageElement until |
| - // the image source changes. |
| - RefPtrWillBeMember<HTMLImageElement> m_imageElement; |
| - RefPtr<Image> m_bitmap; |
| + RefPtr<SkImage> m_bitmap; |
|
Justin Novosad
2015/10/30 18:57:45
m_bitmap -> m_image
|
| IntRect m_bitmapRect; // The rect where the underlying Image should be placed in reference to the ImageBitmap. |
| IntRect m_cropRect; |
|
Justin Novosad
2015/10/30 18:57:45
Why do we still need this?
|
| @@ -75,7 +72,6 @@ private: |
| // ImageBitmaps constructed from HTMLImageElements reference the entire ImageResource and may have a non-zero bitmap offset. |
| // ImageBitmaps not constructed from HTMLImageElements always pre-crop and store the image at (0, 0). |
| IntPoint m_bitmapOffset; |
| - |
| }; |
| } // namespace blink |