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

Side by Side Diff: cc/image_layer.h

Issue 11365025: Make cc a component (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 8 years, 1 month 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 | Annotate | Revision Log
« no previous file with comments | « cc/heads_up_display_layer_impl.h ('k') | cc/input_handler.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 2010 The Chromium Authors. All rights reserved. 1 // Copyright 2010 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 ImageLayerChromium_h 5 #ifndef ImageLayerChromium_h
6 #define ImageLayerChromium_h 6 #define ImageLayerChromium_h
7 7
8 #include "cc/cc_export.h"
8 #include "cc/content_layer.h" 9 #include "cc/content_layer.h"
9 #include "third_party/skia/include/core/SkBitmap.h" 10 #include "third_party/skia/include/core/SkBitmap.h"
10 11
11 namespace cc { 12 namespace cc {
12 13
13 class ImageLayerUpdater; 14 class ImageLayerUpdater;
14 15
15 // A Layer that contains only an Image element. 16 // A Layer that contains only an Image element.
16 class ImageLayer : public TiledLayer { 17 class CC_EXPORT ImageLayer : public TiledLayer {
17 public: 18 public:
18 static scoped_refptr<ImageLayer> create(); 19 static scoped_refptr<ImageLayer> create();
19 20
20 virtual bool drawsContent() const OVERRIDE; 21 virtual bool drawsContent() const OVERRIDE;
21 virtual void setTexturePriorities(const PriorityCalculator&) OVERRIDE; 22 virtual void setTexturePriorities(const PriorityCalculator&) OVERRIDE;
22 virtual void update(ResourceUpdateQueue&, const OcclusionTracker*, Rendering Stats&) OVERRIDE; 23 virtual void update(ResourceUpdateQueue&, const OcclusionTracker*, Rendering Stats&) OVERRIDE;
23 virtual float contentsScaleX() const OVERRIDE; 24 virtual float contentsScaleX() const OVERRIDE;
24 virtual float contentsScaleY() const OVERRIDE; 25 virtual float contentsScaleY() const OVERRIDE;
25 26
26 void setBitmap(const SkBitmap& image); 27 void setBitmap(const SkBitmap& image);
27 28
28 private: 29 private:
29 ImageLayer(); 30 ImageLayer();
30 virtual ~ImageLayer(); 31 virtual ~ImageLayer();
31 32
32 void setTilingOption(TilingOption); 33 void setTilingOption(TilingOption);
33 34
34 virtual LayerUpdater* updater() const OVERRIDE; 35 virtual LayerUpdater* updater() const OVERRIDE;
35 virtual void createUpdaterIfNeeded() OVERRIDE; 36 virtual void createUpdaterIfNeeded() OVERRIDE;
36 virtual gfx::Size contentBounds() const OVERRIDE; 37 virtual gfx::Size contentBounds() const OVERRIDE;
37 38
38 SkBitmap m_bitmap; 39 SkBitmap m_bitmap;
39 40
40 scoped_refptr<ImageLayerUpdater> m_updater; 41 scoped_refptr<ImageLayerUpdater> m_updater;
41 }; 42 };
42 43
43 } // namespace cc 44 } // namespace cc
44 45
45 #endif 46 #endif
OLDNEW
« no previous file with comments | « cc/heads_up_display_layer_impl.h ('k') | cc/input_handler.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698