| Index: chrome/browser/plugins/plugin_power_saver_browsertest.cc
|
| diff --git a/chrome/browser/plugins/plugin_power_saver_browsertest.cc b/chrome/browser/plugins/plugin_power_saver_browsertest.cc
|
| index c60a6ee130b6dde35df22ae9f5f8787ee975cff1..e688838a30544df4208105ede29aa157199e66ce 100644
|
| --- a/chrome/browser/plugins/plugin_power_saver_browsertest.cc
|
| +++ b/chrome/browser/plugins/plugin_power_saver_browsertest.cc
|
| @@ -28,6 +28,7 @@
|
| #include "content/public/browser/render_frame_host.h"
|
| #include "content/public/browser/render_view_host.h"
|
| #include "content/public/browser/render_widget_host.h"
|
| +#include "content/public/browser/render_widget_host_view.h"
|
| #include "content/public/common/content_features.h"
|
| #include "content/public/common/content_switches.h"
|
| #include "content/public/test/browser_test_utils.h"
|
| @@ -366,13 +367,13 @@ class PluginPowerSaverBrowserTest : public InProcessBrowserTest {
|
| content::RenderWidgetHost* rwh =
|
| GetActiveWebContents()->GetRenderViewHost()->GetWidget();
|
|
|
| - if (!rwh->CanCopyFromBackingStore()) {
|
| - ADD_FAILURE() << "Could not copy from backing store.";
|
| + if (!rwh->GetView() || !rwh->GetView()->IsSurfaceAvailableForCopy()) {
|
| + ADD_FAILURE() << "RWHV surface not available for copy.";
|
| return false;
|
| }
|
|
|
| bool snapshot_matches = false;
|
| - rwh->CopyFromBackingStore(
|
| + rwh->GetView()->CopyFromSurface(
|
| gfx::Rect(), gfx::Size(),
|
| base::Bind(&CompareSnapshotToReference, reference, &snapshot_matches,
|
| base::MessageLoop::QuitWhenIdleClosure()),
|
|
|