diff options
-rw-r--r-- | ui/snapshot/snapshot_aura.cc | 2 | ||||
-rw-r--r-- | ui/snapshot/snapshot_aura_unittest.cc | 4 |
2 files changed, 4 insertions, 2 deletions
diff --git a/ui/snapshot/snapshot_aura.cc b/ui/snapshot/snapshot_aura.cc index fc7e6e7..911ad35 100644 --- a/ui/snapshot/snapshot_aura.cc +++ b/ui/snapshot/snapshot_aura.cc @@ -36,7 +36,7 @@ static void MakeAsyncCopyRequest( const cc::CopyOutputRequest::CopyOutputRequestCallback& callback) { scoped_ptr<cc::CopyOutputRequest> request = cc::CopyOutputRequest::CreateBitmapRequest(callback); - request->set_area(ui::ConvertRectToPixel(window->layer(), source_rect)); + request->set_area(source_rect); window->layer()->RequestCopyOfOutput(request.Pass()); } diff --git a/ui/snapshot/snapshot_aura_unittest.cc b/ui/snapshot/snapshot_aura_unittest.cc index f8a2a94..5fe05a8 100644 --- a/ui/snapshot/snapshot_aura_unittest.cc +++ b/ui/snapshot/snapshot_aura_unittest.cc @@ -126,12 +126,14 @@ class SnapshotAuraTest : public testing::Test { gfx::Image GrabSnapshotForTestWindow() { gfx::Rect source_rect(test_window_->bounds().size()); + aura::Window::ConvertRectToTarget( + test_window(), root_window(), &source_rect); scoped_refptr<base::TestSimpleTaskRunner> task_runner( new base::TestSimpleTaskRunner()); scoped_refptr<SnapshotHolder> holder(new SnapshotHolder); ui::GrabWindowSnapshotAsync( - test_window(), + root_window(), source_rect, task_runner, base::Bind(&SnapshotHolder::SnapshotCallback, holder)); |