Index: ui/compositor/layer.h |
diff --git a/ui/compositor/layer.h b/ui/compositor/layer.h |
index bcdbd4cf3a184cdee2d987ce509e440dde735555..b446e16cead1760b27cf804aa831c6cf56fe9901 100644 |
--- a/ui/compositor/layer.h |
+++ b/ui/compositor/layer.h |
@@ -28,6 +28,7 @@ |
#include "ui/compositor/layer_delegate.h" |
#include "ui/compositor/layer_type.h" |
#include "ui/gfx/geometry/rect.h" |
+#include "ui/gfx/image/image_skia.h" |
#include "ui/gfx/transform.h" |
class SkCanvas; |
@@ -300,9 +301,9 @@ class COMPOSITOR_EXPORT Layer |
// Sets the layer's fill color. May only be called for LAYER_SOLID_COLOR. |
void SetColor(SkColor color); |
- // Updates the nine patch layer's bitmap, aperture and border. May only be |
+ // Updates the nine patch layer's image, aperture and border. May only be |
// called for LAYER_NINE_PATCH. |
- void UpdateNinePatchLayerBitmap(const SkBitmap& bitmap); |
+ void UpdateNinePatchLayerImage(const gfx::ImageSkia& image); |
void UpdateNinePatchLayerAperture(const gfx::Rect& aperture); |
void UpdateNinePatchLayerBorder(const gfx::Rect& border); |
@@ -512,6 +513,11 @@ class COMPOSITOR_EXPORT Layer |
// A cached copy of |Compositor::device_scale_factor()|. |
float device_scale_factor_; |
+ // A cached copy of the nine patch layer's image and aperture. |
+ // These are required for device scale factor change. |
+ gfx::ImageSkia nine_patch_layer_image_; |
+ gfx::Rect nine_patch_layer_aperture_; |
+ |
// The mailbox used by texture_layer_. |
cc::TextureMailbox mailbox_; |