| OLD | NEW |
| 1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef CC_RESOURCES_TILE_H_ | 5 #ifndef CC_RESOURCES_TILE_H_ |
| 6 #define CC_RESOURCES_TILE_H_ | 6 #define CC_RESOURCES_TILE_H_ |
| 7 | 7 |
| 8 #include "base/memory/ref_counted.h" | 8 #include "base/memory/ref_counted.h" |
| 9 #include "base/memory/scoped_ptr.h" | 9 #include "base/memory/scoped_ptr.h" |
| 10 #include "base/memory/scoped_vector.h" | 10 #include "base/memory/scoped_vector.h" |
| (...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 49 scoped_ptr<base::Value> AsValue() const; | 49 scoped_ptr<base::Value> AsValue() const; |
| 50 | 50 |
| 51 const ManagedTileState::DrawingInfo& drawing_info() const { | 51 const ManagedTileState::DrawingInfo& drawing_info() const { |
| 52 return managed_state_.drawing_info; | 52 return managed_state_.drawing_info; |
| 53 } | 53 } |
| 54 ManagedTileState::DrawingInfo& drawing_info() { | 54 ManagedTileState::DrawingInfo& drawing_info() { |
| 55 return managed_state_.drawing_info; | 55 return managed_state_.drawing_info; |
| 56 } | 56 } |
| 57 | 57 |
| 58 const gfx::Rect& opaque_rect() const { return opaque_rect_; } | 58 const gfx::Rect& opaque_rect() const { return opaque_rect_; } |
| 59 const bool has_text() const { |
| 60 return managed_state_.picture_pile_analysis.has_text; |
| 61 } |
| 59 | 62 |
| 60 float contents_scale() const { return contents_scale_; } | 63 float contents_scale() const { return contents_scale_; } |
| 61 gfx::Rect content_rect() const { return content_rect_; } | 64 gfx::Rect content_rect() const { return content_rect_; } |
| 62 | 65 |
| 63 int layer_id() const { return layer_id_; } | 66 int layer_id() const { return layer_id_; } |
| 64 | 67 |
| 65 void set_picture_pile(scoped_refptr<PicturePileImpl> pile) { | 68 void set_picture_pile(scoped_refptr<PicturePileImpl> pile) { |
| 66 DCHECK(pile->CanRaster(contents_scale_, content_rect_)); | 69 DCHECK(pile->CanRaster(contents_scale_, content_rect_)); |
| 67 picture_pile_ = pile; | 70 picture_pile_ = pile; |
| 68 } | 71 } |
| (...skipping 26 matching lines...) Expand all Loading... |
| 95 TilePriority priority_[NUM_BIN_PRIORITIES]; | 98 TilePriority priority_[NUM_BIN_PRIORITIES]; |
| 96 ManagedTileState managed_state_; | 99 ManagedTileState managed_state_; |
| 97 int layer_id_; | 100 int layer_id_; |
| 98 | 101 |
| 99 DISALLOW_COPY_AND_ASSIGN(Tile); | 102 DISALLOW_COPY_AND_ASSIGN(Tile); |
| 100 }; | 103 }; |
| 101 | 104 |
| 102 } // namespace cc | 105 } // namespace cc |
| 103 | 106 |
| 104 #endif // CC_RESOURCES_TILE_H_ | 107 #endif // CC_RESOURCES_TILE_H_ |
| OLD | NEW |