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

Unified Diff: content/browser/renderer_host/render_widget_host_impl.cc

Issue 10835014: Support copying a partial rectangle region from the compositing surface on Mac. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: address comments Created 8 years, 5 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: content/browser/renderer_host/render_widget_host_impl.cc
diff --git a/content/browser/renderer_host/render_widget_host_impl.cc b/content/browser/renderer_host/render_widget_host_impl.cc
index 8d311f77bc8cfaeae0c82017abb6d8203da514f4..ccf2e2016765d4265610f92cbf40a40161d43a16 100644
--- a/content/browser/renderer_host/render_widget_host_impl.cc
+++ b/content/browser/renderer_host/render_widget_host_impl.cc
@@ -503,12 +503,12 @@ void RenderWidgetHostImpl::CopyFromBackingStore(
if (view_ && is_accelerated_compositing_active_) {
TRACE_EVENT0("browser",
"RenderWidgetHostImpl::CopyFromBackingStore::FromCompositingSurface");
-#if defined(USE_AURA) || defined(OS_LINUX)
+#if defined(USE_AURA) || defined(OS_LINUX) || defined(OS_MACOSX)
gfx::Rect copy_rect = src_subrect.IsEmpty() ?
gfx::Rect(view_->GetViewBounds().size()) : src_subrect;
#else
// Just passes an empty rect to CopyFromCompositingSurface on non-Aura Win
- // and Mac because copying a partial rectangle is not supported.
+ // because copying a partial rectangle is not supported.
gfx::Rect copy_rect;
#endif
view_->CopyFromCompositingSurface(copy_rect,

Powered by Google App Engine
This is Rietveld 408576698