diff options
author | brettw@google.com <brettw@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2008-11-07 16:37:31 +0000 |
---|---|---|
committer | brettw@google.com <brettw@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2008-11-07 16:37:31 +0000 |
commit | 6610d56ab0db07cc3487d0cc6e0b8015fe676c93 (patch) | |
tree | 878864874cd1edf923d39a88efa440752c7e8936 | |
parent | e79f10f3a37828e770dc3cfdbc0aa84eb0a07c9d (diff) | |
download | chromium_src-6610d56ab0db07cc3487d0cc6e0b8015fe676c93.zip chromium_src-6610d56ab0db07cc3487d0cc6e0b8015fe676c93.tar.gz chromium_src-6610d56ab0db07cc3487d0cc6e0b8015fe676c93.tar.bz2 |
Fix Linux build bustage by making the ImageBufferSkia code compilable on all Skia platforms. I do this by making the calling of PlatformCanvas.initialize() able to be the same by using an evil default parameter.
Review URL: http://codereview.chromium.org/9695
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@4990 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r-- | base/gfx/platform_canvas_win.h | 7 | ||||
-rw-r--r-- | webkit/port/platform/graphics/ImageBufferSkia.cpp | 2 |
2 files changed, 6 insertions, 3 deletions
diff --git a/base/gfx/platform_canvas_win.h b/base/gfx/platform_canvas_win.h index b5f1e73..95ae856 100644 --- a/base/gfx/platform_canvas_win.h +++ b/base/gfx/platform_canvas_win.h @@ -28,8 +28,11 @@ class PlatformCanvasWin : public SkCanvas { HANDLE shared_section); virtual ~PlatformCanvasWin(); - // For two-part init, call if you use the no-argument constructor above - bool initialize(int width, int height, bool is_opaque, HANDLE shared_section); + // For two-part init, call if you use the no-argument constructor above. Note + // that we want this to optionally match the Linux initialize if you only + // pass 3 arguments, hence the evil default argument. + bool initialize(int width, int height, bool is_opaque, + HANDLE shared_section = NULL); // These calls should surround calls to platform drawing routines, the DC // returned by beginPlatformPaint is the DC that can be used to draw into. diff --git a/webkit/port/platform/graphics/ImageBufferSkia.cpp b/webkit/port/platform/graphics/ImageBufferSkia.cpp index 80056f4..9b14c05 100644 --- a/webkit/port/platform/graphics/ImageBufferSkia.cpp +++ b/webkit/port/platform/graphics/ImageBufferSkia.cpp @@ -56,7 +56,7 @@ ImageBuffer::ImageBuffer(const IntSize& size, bool grayScale, bool& success) : m_data(size) , m_size(size) { - if (!m_data.m_canvas.initialize(size.width(), size.height(), false, NULL)) { + if (!m_data.m_canvas.initialize(size.width(), size.height(), false)) { success = false; return; } |