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

Side by Side Diff: skia/ext/vector_platform_device_cairo_linux.h

Issue 7633040: CL removing inheritance of SkDevice from PlatformDevice. Flavours of PlatformDevice classes now ... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Fix use of drawSprite. Created 9 years, 4 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 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 SKIA_EXT_VECTOR_PLATFORM_DEVICE_CAIRO_LINUX_H_ 5 #ifndef SKIA_EXT_VECTOR_PLATFORM_DEVICE_CAIRO_LINUX_H_
6 #define SKIA_EXT_VECTOR_PLATFORM_DEVICE_CAIRO_LINUX_H_ 6 #define SKIA_EXT_VECTOR_PLATFORM_DEVICE_CAIRO_LINUX_H_
7 #pragma once 7 #pragma once
8 8
9 #include "base/basictypes.h" 9 #include "base/basictypes.h"
10 #include "base/compiler_specific.h" 10 #include "base/compiler_specific.h"
11 #include "skia/ext/platform_device.h" 11 #include "skia/ext/platform_device.h"
12 #include "third_party/skia/include/core/SkMatrix.h" 12 #include "third_party/skia/include/core/SkMatrix.h"
13 #include "third_party/skia/include/core/SkRegion.h" 13 #include "third_party/skia/include/core/SkRegion.h"
14 14
15 namespace skia { 15 namespace skia {
16 16
17 // This device is basically a wrapper that provides a surface for SkCanvas 17 // This device is basically a wrapper that provides a surface for SkCanvas
18 // to draw into. It is basically an adaptor which converts skia APIs into 18 // to draw into. It is basically an adaptor which converts skia APIs into
19 // cooresponding Cairo APIs and outputs to a Cairo surface. Please NOTE that 19 // cooresponding Cairo APIs and outputs to a Cairo surface. Please NOTE that
20 // since it is completely vectorial, the bitmap content in it is thus 20 // since it is completely vectorial, the bitmap content in it is thus
21 // meaningless. 21 // meaningless.
22 class SK_API VectorPlatformDeviceCairo : public PlatformDevice { 22 class SK_API VectorPlatformDeviceCairo : public PlatformDevice,
23 public SkDevice {
23 public: 24 public:
24 virtual ~VectorPlatformDeviceCairo(); 25 virtual ~VectorPlatformDeviceCairo();
25 26
26 static PlatformDevice* CreateDevice(cairo_t* context, int width, int height, 27 static PlatformDevice* CreateDevice(cairo_t* context, int width, int height,
27 bool isOpaque); 28 bool isOpaque);
28 29
29 // Clean up cached fonts. It is an error to call this while some 30 // Clean up cached fonts. It is an error to call this while some
30 // VectorPlatformDeviceCairo callee is still using fonts created for it by 31 // VectorPlatformDeviceCairo callee is still using fonts created for it by
31 // this class. 32 // this class.
32 static void ClearFontCache(); 33 static void ClearFontCache();
(...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after
119 120
120 // Device context. 121 // Device context.
121 PlatformSurface context_; 122 PlatformSurface context_;
122 123
123 DISALLOW_COPY_AND_ASSIGN(VectorPlatformDeviceCairo); 124 DISALLOW_COPY_AND_ASSIGN(VectorPlatformDeviceCairo);
124 }; 125 };
125 126
126 } // namespace skia 127 } // namespace skia
127 128
128 #endif // SKIA_EXT_VECTOR_PLATFORM_DEVICE_CAIRO_LINUX_H_ 129 #endif // SKIA_EXT_VECTOR_PLATFORM_DEVICE_CAIRO_LINUX_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698