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

Unified Diff: skia/ext/platform_device.h

Issue 22796028: Updating Chromium to Skia SkBaseDevice/SkBitmapDevice split (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Minor cleanup Created 7 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 side-by-side diff with in-line comments
Download patch
Index: skia/ext/platform_device.h
diff --git a/skia/ext/platform_device.h b/skia/ext/platform_device.h
index 4ac3aee56570e122c93fa0d17192ee023fb024b8..c39db2bc6a6f5a7980356627d8d20b58be58b2a0 100644
--- a/skia/ext/platform_device.h
+++ b/skia/ext/platform_device.h
@@ -13,7 +13,7 @@
#endif
#include "third_party/skia/include/core/SkColor.h"
-#include "third_party/skia/include/core/SkDevice.h"
+#include "third_party/skia/include/core/SkBitmapDevice.h"
#include "third_party/skia/include/core/SkPreConfig.h"
class SkMatrix;
@@ -51,7 +51,7 @@ typedef CGRect PlatformRect;
// The following routines provide accessor points for the functionality
vandebo (ex-Chrome) 2013/08/22 20:41:58 The comments in this file needs some closer attent
robertphillips 2013/08/23 14:01:03 I have removed the bits that are obviously wrong (
// exported by the various PlatformDevice ports. The PlatformDevice, and
-// BitmapPlatformDevice classes inherit directly from SkDevice, which is no
+// BitmapPlatformDevice classes inherit directly from SkBitmapDevice, which is no
// longer a supported usage-pattern for skia. In preparation of the removal of
// these classes, all calls to PlatformDevice::* should be routed through these
// helper functions.
@@ -59,20 +59,20 @@ typedef CGRect PlatformRect;
// Bind a PlatformDevice instance, |platform_device| to |device|. Subsequent
// calls to the functions exported below will forward the request to the
// corresponding method on the bound PlatformDevice instance. If no
-// PlatformDevice has been bound to the SkDevice passed, then the routines are
+// PlatformDevice has been bound to the SkBaseDevice passed, then the routines are
// NOPS.
-SK_API void SetPlatformDevice(SkDevice* device,
+SK_API void SetPlatformDevice(SkBaseDevice* device,
PlatformDevice* platform_device);
-SK_API PlatformDevice* GetPlatformDevice(SkDevice* device);
+SK_API PlatformDevice* GetPlatformDevice(SkBaseDevice* device);
#if defined(OS_WIN)
// Initializes the default settings and colors in a device context.
SK_API void InitializeDC(HDC context);
#elif defined(OS_MACOSX)
-// Returns the CGContext that backing the SkDevice. Forwards to the bound
+// Returns the CGContext that backing the SkBaseDevice. Forwards to the bound
// PlatformDevice. Returns NULL if no PlatformDevice is bound.
-SK_API CGContextRef GetBitmapContext(SkDevice* device);
+SK_API CGContextRef GetBitmapContext(SkBaseDevice* device);
#endif
// Following routines are used in print preview workflow to mark the draft mode
@@ -86,13 +86,13 @@ SK_API void SetIsPreviewMetafile(const SkCanvas& canvas, bool is_preview);
SK_API bool IsPreviewMetafile(const SkCanvas& canvas);
#endif
-// A SkDevice is basically a wrapper around SkBitmap that provides a surface for
+// A SkBitmapDevice is basically a wrapper around SkBitmap that provides a surface for
// SkCanvas to draw into. PlatformDevice provides a surface Windows can also
// write to. It also provides functionality to play well with GDI drawing
// functions. This class is abstract and must be subclassed. It provides the
// basic interface to implement it either with or without a bitmap backend.
//
-// PlatformDevice provides an interface which sub-classes of SkDevice can also
+// PlatformDevice provides an interface which sub-classes of SkBaseDevice can also
// provide to allow for drawing by the native platform into the device.
class SK_API PlatformDevice {
vandebo (ex-Chrome) 2013/08/22 20:41:58 Not part of this CL, but with SkBitmapDevice separ
robertphillips 2013/08/23 14:01:03 I think that would make sense but I'm not too fami
vandebo (ex-Chrome) 2013/08/23 17:10:04 Can you add a TODO here to figure it out... Platf
robertphillips 2013/08/26 13:11:48 Done.
public:

Powered by Google App Engine
This is Rietveld 408576698