| Index: content/browser/renderer_host/compositor_impl_android.cc
|
| diff --git a/content/browser/renderer_host/compositor_impl_android.cc b/content/browser/renderer_host/compositor_impl_android.cc
|
| index adbbd6f2d4e13d0a9561a7771f434e30f185a3ad..affcac97c7bc4fadd00493613fe463819d281457 100644
|
| --- a/content/browser/renderer_host/compositor_impl_android.cc
|
| +++ b/content/browser/renderer_host/compositor_impl_android.cc
|
| @@ -66,8 +66,7 @@
|
| #include "third_party/khronos/GLES2/gl2ext.h"
|
| #include "third_party/skia/include/core/SkMallocPixelRef.h"
|
| #include "ui/android/window_android.h"
|
| -#include "ui/display/display.h"
|
| -#include "ui/display/screen.h"
|
| +#include "ui/gfx/android/device_display_info.h"
|
| #include "ui/gfx/swap_result.h"
|
|
|
| namespace gpu {
|
| @@ -80,14 +79,11 @@
|
|
|
| const unsigned int kMaxDisplaySwapBuffers = 1U;
|
|
|
| -gpu::SharedMemoryLimits GetCompositorContextSharedMemoryLimits(
|
| - gfx::NativeWindow window) {
|
| +gpu::SharedMemoryLimits GetCompositorContextSharedMemoryLimits() {
|
| constexpr size_t kBytesPerPixel = 4;
|
| - const gfx::Size size = display::Screen::GetScreen()
|
| - ->GetDisplayNearestWindow(window)
|
| - .GetSizeInPixel();
|
| const size_t full_screen_texture_size_in_bytes =
|
| - size.width() * size.height() * kBytesPerPixel;
|
| + gfx::DeviceDisplayInfo().GetDisplayHeight() *
|
| + gfx::DeviceDisplayInfo().GetDisplayWidth() * kBytesPerPixel;
|
|
|
| gpu::SharedMemoryLimits limits;
|
| // This limit is meant to hold the contents of the display compositor
|
| @@ -607,8 +603,7 @@
|
| scoped_refptr<cc::ContextProvider> context_provider =
|
| ContextProviderFactoryImpl::GetInstance()
|
| ->CreateDisplayContextProvider(
|
| - surface_handle_,
|
| - GetCompositorContextSharedMemoryLimits(root_window_),
|
| + surface_handle_, GetCompositorContextSharedMemoryLimits(),
|
| GetCompositorContextAttributes(has_transparent_background_),
|
| false /*support_locking*/, false /*automatic_flushes*/,
|
| std::move(gpu_channel_host));
|
|
|