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

Side by Side Diff: cc/resources/layer_updater.h

Issue 590313004: Revert of Fix bad scaling in TiledLayer (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 2 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 unified diff | Download patch
« no previous file with comments | « cc/resources/content_layer_updater.cc ('k') | cc/resources/skpicture_content_layer_updater.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2011 The Chromium Authors. All rights reserved. 1 // Copyright 2011 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_LAYER_UPDATER_H_ 5 #ifndef CC_RESOURCES_LAYER_UPDATER_H_
6 #define CC_RESOURCES_LAYER_UPDATER_H_ 6 #define CC_RESOURCES_LAYER_UPDATER_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 "cc/base/cc_export.h" 10 #include "cc/base/cc_export.h"
11 #include "third_party/skia/include/core/SkColor.h"
12 #include "ui/gfx/rect.h" 11 #include "ui/gfx/rect.h"
13 #include "ui/gfx/vector2d.h" 12 #include "ui/gfx/vector2d.h"
14 13
15 namespace cc { 14 namespace cc {
16 15
17 class PrioritizedResource; 16 class PrioritizedResource;
18 class PrioritizedResourceManager; 17 class PrioritizedResourceManager;
19 class ResourceUpdateQueue; 18 class ResourceUpdateQueue;
20 class TextureManager; 19 class TextureManager;
21 20
(...skipping 18 matching lines...) Expand all
40 private: 39 private:
41 scoped_ptr<PrioritizedResource> texture_; 40 scoped_ptr<PrioritizedResource> texture_;
42 41
43 DISALLOW_COPY_AND_ASSIGN(Resource); 42 DISALLOW_COPY_AND_ASSIGN(Resource);
44 }; 43 };
45 44
46 LayerUpdater() {} 45 LayerUpdater() {}
47 46
48 virtual scoped_ptr<Resource> CreateResource( 47 virtual scoped_ptr<Resource> CreateResource(
49 PrioritizedResourceManager* manager) = 0; 48 PrioritizedResourceManager* manager) = 0;
50 virtual void PrepareToUpdate(const gfx::Size& content_size, 49 virtual void PrepareToUpdate(const gfx::Rect& content_rect,
51 const gfx::Rect& paint_rect,
52 const gfx::Size& tile_size, 50 const gfx::Size& tile_size,
53 float contents_width_scale, 51 float contents_width_scale,
54 float contents_height_scale) {} 52 float contents_height_scale) {}
55 virtual void ReduceMemoryUsage() {} 53 virtual void ReduceMemoryUsage() {}
56 54
57 // Set true by the layer when it is known that the entire output is going to 55 // Set true by the layer when it is known that the entire output is going to
58 // be opaque. 56 // be opaque.
59 virtual void SetOpaque(bool opaque) {} 57 virtual void SetOpaque(bool opaque) {}
60 // Set true by the layer when it is known that the entire output bounds will 58 // Set true by the layer when it is known that the entire output bounds will
61 // be rasterized. 59 // be rasterized.
62 virtual void SetFillsBoundsCompletely(bool fills_bounds) {} 60 virtual void SetFillsBoundsCompletely(bool fills_bounds) {}
63 virtual void SetBackgroundColor(SkColor background_color) {}
64 61
65 protected: 62 protected:
66 virtual ~LayerUpdater() {} 63 virtual ~LayerUpdater() {}
67 64
68 private: 65 private:
69 friend class base::RefCounted<LayerUpdater>; 66 friend class base::RefCounted<LayerUpdater>;
70 67
71 DISALLOW_COPY_AND_ASSIGN(LayerUpdater); 68 DISALLOW_COPY_AND_ASSIGN(LayerUpdater);
72 }; 69 };
73 70
74 } // namespace cc 71 } // namespace cc
75 72
76 #endif // CC_RESOURCES_LAYER_UPDATER_H_ 73 #endif // CC_RESOURCES_LAYER_UPDATER_H_
OLDNEW
« no previous file with comments | « cc/resources/content_layer_updater.cc ('k') | cc/resources/skpicture_content_layer_updater.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698