summaryrefslogtreecommitdiffstats
path: root/webkit/glue/webframe_impl.cc
diff options
context:
space:
mode:
Diffstat (limited to 'webkit/glue/webframe_impl.cc')
-rw-r--r--webkit/glue/webframe_impl.cc8
1 files changed, 6 insertions, 2 deletions
diff --git a/webkit/glue/webframe_impl.cc b/webkit/glue/webframe_impl.cc
index f65bf9e..c68b9b5 100644
--- a/webkit/glue/webframe_impl.cc
+++ b/webkit/glue/webframe_impl.cc
@@ -1466,12 +1466,16 @@ void WebFrameImpl::Paint(gfx::PlatformCanvas* canvas, const gfx::Rect& rect) {
StatsScope<StatsRate> rendering_scope(rendering);
if (!rect.IsEmpty()) {
+ IntRect dirty_rect(rect.x(), rect.y(), rect.width(), rect.height());
+#if defined(OS_MACOSX)
+ CGContextRef context = canvas->getTopPlatformDevice().GetBitmapContext();
+ GraphicsContext gc(context);
+#else
PlatformContextSkia context(canvas);
// PlatformGraphicsContext is actually a pointer to PlatformContextSkia
GraphicsContext gc(reinterpret_cast<PlatformGraphicsContext*>(&context));
- IntRect dirty_rect(rect.x(), rect.y(), rect.width(), rect.height());
-
+#endif
if (frame_->document() && frameview()) {
frameview()->paint(&gc, dirty_rect);
} else {