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

Side by Side Diff: content/renderer/render_widget.cc

Issue 361073002: Add switch to disable recording whole document (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « content/renderer/render_widget.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 #include "content/renderer/render_widget.h" 5 #include "content/renderer/render_widget.h"
6 6
7 #include "base/auto_reset.h" 7 #include "base/auto_reset.h"
8 #include "base/bind.h" 8 #include "base/bind.h"
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/debug/trace_event.h" 10 #include "base/debug/trace_event.h"
(...skipping 495 matching lines...) Expand 10 before | Expand all | Expand 10 after
506 } 506 }
507 507
508 bool RenderWidget::UsingSynchronousRendererCompositor() const { 508 bool RenderWidget::UsingSynchronousRendererCompositor() const {
509 #if defined(OS_ANDROID) 509 #if defined(OS_ANDROID)
510 return SynchronousCompositorFactory::GetInstance() != NULL; 510 return SynchronousCompositorFactory::GetInstance() != NULL;
511 #else 511 #else
512 return false; 512 return false;
513 #endif 513 #endif
514 } 514 }
515 515
516 bool RenderWidget::CompositorRecordsDocument() const {
517 #if defined(OS_ANDROID)
518 SynchronousCompositorFactory* factory =
519 SynchronousCompositorFactory::GetInstance();
jamesr 2014/07/01 22:17:10 if this is just accessing statics, why is it on Re
boliu 2014/07/01 22:22:05 Following the pattern of UsingSynchronousRendererC
520 return factory && factory->RecordDocument();
521 #else
522 return false;
523 #endif
524 }
525
516 void RenderWidget::EnableScreenMetricsEmulation( 526 void RenderWidget::EnableScreenMetricsEmulation(
517 const WebDeviceEmulationParams& params) { 527 const WebDeviceEmulationParams& params) {
518 if (!screen_metrics_emulator_) 528 if (!screen_metrics_emulator_)
519 screen_metrics_emulator_.reset(new ScreenMetricsEmulator(this, params)); 529 screen_metrics_emulator_.reset(new ScreenMetricsEmulator(this, params));
520 else 530 else
521 screen_metrics_emulator_->ChangeEmulationParams(params); 531 screen_metrics_emulator_->ChangeEmulationParams(params);
522 } 532 }
523 533
524 void RenderWidget::DisableScreenMetricsEmulation() { 534 void RenderWidget::DisableScreenMetricsEmulation() {
525 screen_metrics_emulator_.reset(); 535 screen_metrics_emulator_.reset();
(...skipping 1539 matching lines...) Expand 10 before | Expand all | Expand 10 after
2065 void RenderWidget::RegisterVideoHoleFrame(RenderFrameImpl* frame) { 2075 void RenderWidget::RegisterVideoHoleFrame(RenderFrameImpl* frame) {
2066 video_hole_frames_.AddObserver(frame); 2076 video_hole_frames_.AddObserver(frame);
2067 } 2077 }
2068 2078
2069 void RenderWidget::UnregisterVideoHoleFrame(RenderFrameImpl* frame) { 2079 void RenderWidget::UnregisterVideoHoleFrame(RenderFrameImpl* frame) {
2070 video_hole_frames_.RemoveObserver(frame); 2080 video_hole_frames_.RemoveObserver(frame);
2071 } 2081 }
2072 #endif // defined(VIDEO_HOLE) 2082 #endif // defined(VIDEO_HOLE)
2073 2083
2074 } // namespace content 2084 } // namespace content
OLDNEW
« no previous file with comments | « content/renderer/render_widget.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698