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

Side by Side Diff: content/renderer/android/synchronous_compositor_output_surface.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
« no previous file with comments | « content/browser/renderer_host/compositor_impl_android.cc ('k') | ui/compositor/DEPS » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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/android/synchronous_compositor_output_surface.h" 5 #include "content/renderer/android/synchronous_compositor_output_surface.h"
6 6
7 #include <vector> 7 #include <vector>
8 8
9 #include "base/auto_reset.h" 9 #include "base/auto_reset.h"
10 #include "base/location.h" 10 #include "base/location.h"
(...skipping 158 matching lines...) Expand 10 before | Expand all | Expand 10 after
169 // this Display is only used for resourcesless software draws, where no 169 // this Display is only used for resourcesless software draws, where no
170 // resources are included in the frame swapped from the compositor. So there 170 // resources are included in the frame swapped from the compositor. So there
171 // is no need for these. 171 // is no need for these.
172 display_.reset(new cc::Display( 172 display_.reset(new cc::Display(
173 nullptr /* shared_bitmap_manager */, 173 nullptr /* shared_bitmap_manager */,
174 nullptr /* gpu_memory_buffer_manager */, software_renderer_settings, 174 nullptr /* gpu_memory_buffer_manager */, software_renderer_settings,
175 nullptr /* begin_frame_source */, std::move(output_surface), 175 nullptr /* begin_frame_source */, std::move(output_surface),
176 nullptr /* scheduler */, nullptr /* texture_mailbox_deleter */)); 176 nullptr /* scheduler */, nullptr /* texture_mailbox_deleter */));
177 display_->Initialize(&display_client_, surface_manager_.get(), 177 display_->Initialize(&display_client_, surface_manager_.get(),
178 surface_id_allocator_->client_id()); 178 surface_id_allocator_->client_id());
179 display_->SetVisible(true);
179 return true; 180 return true;
180 } 181 }
181 182
182 void SynchronousCompositorOutputSurface::DetachFromClient() { 183 void SynchronousCompositorOutputSurface::DetachFromClient() {
183 DCHECK(CalledOnValidThread()); 184 DCHECK(CalledOnValidThread());
184 if (registered_) { 185 if (registered_) {
185 registry_->UnregisterOutputSurface(routing_id_, this); 186 registry_->UnregisterOutputSurface(routing_id_, this);
186 } 187 }
187 client_->SetTreeActivationCallback(base::Closure()); 188 client_->SetTreeActivationCallback(base::Closure());
188 if (!delegated_surface_id_.is_null()) 189 if (!delegated_surface_id_.is_null())
(...skipping 229 matching lines...) Expand 10 before | Expand all | Expand 10 after
418 client_->ReclaimResources(resources); 419 client_->ReclaimResources(resources);
419 } 420 }
420 421
421 void SynchronousCompositorOutputSurface::SetBeginFrameSource( 422 void SynchronousCompositorOutputSurface::SetBeginFrameSource(
422 cc::BeginFrameSource* begin_frame_source) { 423 cc::BeginFrameSource* begin_frame_source) {
423 // Software output is synchronous and doesn't use a BeginFrameSource. 424 // Software output is synchronous and doesn't use a BeginFrameSource.
424 NOTREACHED(); 425 NOTREACHED();
425 } 426 }
426 427
427 } // namespace content 428 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/renderer_host/compositor_impl_android.cc ('k') | ui/compositor/DEPS » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698