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

Side by Side Diff: content/browser/renderer_host/compositor_impl_android.cc

Issue 2238693002: Plumb SetVisible from ui::Compositor to the DirectRenderer. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: setvisible-browser: onemore Created 4 years, 4 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
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/browser/renderer_host/compositor_impl_android.h" 5 #include "content/browser/renderer_host/compositor_impl_android.h"
6 6
7 #include <android/bitmap.h> 7 #include <android/bitmap.h>
8 #include <android/native_window_jni.h> 8 #include <android/native_window_jni.h>
9 #include <stdint.h> 9 #include <stdint.h>
10 #include <unordered_set> 10 #include <unordered_set>
(...skipping 684 matching lines...) Expand 10 before | Expand all | Expand 10 after
695 base::MakeUnique<cc::TextureMailboxDeleter>(task_runner))); 695 base::MakeUnique<cc::TextureMailboxDeleter>(task_runner)));
696 696
697 std::unique_ptr<cc::SurfaceDisplayOutputSurface> delegated_output_surface( 697 std::unique_ptr<cc::SurfaceDisplayOutputSurface> delegated_output_surface(
698 vulkan_context_provider ? new cc::SurfaceDisplayOutputSurface( 698 vulkan_context_provider ? new cc::SurfaceDisplayOutputSurface(
699 manager, surface_id_allocator_.get(), 699 manager, surface_id_allocator_.get(),
700 display_.get(), vulkan_context_provider) 700 display_.get(), vulkan_context_provider)
701 : new cc::SurfaceDisplayOutputSurface( 701 : new cc::SurfaceDisplayOutputSurface(
702 manager, surface_id_allocator_.get(), 702 manager, surface_id_allocator_.get(),
703 display_.get(), context_provider, nullptr)); 703 display_.get(), context_provider, nullptr));
704 704
705 display_->SetVisible(true);
705 display_->Resize(size_); 706 display_->Resize(size_);
706 host_->SetOutputSurface(std::move(delegated_output_surface)); 707 host_->SetOutputSurface(std::move(delegated_output_surface));
707 } 708 }
708 709
709 void CompositorImpl::PopulateGpuCapabilities( 710 void CompositorImpl::PopulateGpuCapabilities(
710 gpu::Capabilities gpu_capabilities) { 711 gpu::Capabilities gpu_capabilities) {
711 gpu_capabilities_ = gpu_capabilities; 712 gpu_capabilities_ = gpu_capabilities;
712 } 713 }
713 714
714 void CompositorImpl::AddObserver(VSyncObserver* observer) { 715 void CompositorImpl::AddObserver(VSyncObserver* observer) {
(...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after
793 794
794 TRACE_EVENT0("compositor", "Compositor::SetNeedsAnimate"); 795 TRACE_EVENT0("compositor", "Compositor::SetNeedsAnimate");
795 host_->SetNeedsAnimate(); 796 host_->SetNeedsAnimate();
796 } 797 }
797 798
798 bool CompositorImpl::HavePendingReadbacks() { 799 bool CompositorImpl::HavePendingReadbacks() {
799 return !readback_layer_tree_->children().empty(); 800 return !readback_layer_tree_->children().empty();
800 } 801 }
801 802
802 } // namespace content 803 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698