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

Side by Side Diff: blimp/client/feature/compositor/blimp_compositor_manager.cc

Issue 2008283004: Revert of Added a debug info UI for Blimp (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 7 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 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 "blimp/client/feature/compositor/blimp_compositor_manager.h" 5 #include "blimp/client/feature/compositor/blimp_compositor_manager.h"
6 6
7 #include "base/lazy_instance.h" 7 #include "base/lazy_instance.h"
8 #include "base/memory/ptr_util.h" 8 #include "base/memory/ptr_util.h"
9 #include "blimp/client/feature/compositor/blimp_layer_tree_settings.h" 9 #include "blimp/client/feature/compositor/blimp_layer_tree_settings.h"
10 #include "blimp/client/feature/compositor/client_image_serialization_processor.h " 10 #include "blimp/client/feature/compositor/client_image_serialization_processor.h "
(...skipping 126 matching lines...) Expand 10 before | Expand all | Expand 10 after
137 } 137 }
138 138
139 return settings_.get(); 139 return settings_.get();
140 } 140 }
141 141
142 void BlimpCompositorManager::DidCompleteSwapBuffers() { 142 void BlimpCompositorManager::DidCompleteSwapBuffers() {
143 DCHECK(client_); 143 DCHECK(client_);
144 client_->OnSwapBuffersCompleted(); 144 client_->OnSwapBuffersCompleted();
145 } 145 }
146 146
147 void BlimpCompositorManager::DidCommitAndDrawFrame() {
148 DCHECK(client_);
149 client_->DidCommitAndDrawFrame();
150 }
151
152 scoped_refptr<base::SingleThreadTaskRunner> 147 scoped_refptr<base::SingleThreadTaskRunner>
153 BlimpCompositorManager::GetCompositorTaskRunner() { 148 BlimpCompositorManager::GetCompositorTaskRunner() {
154 if (compositor_thread_) 149 if (compositor_thread_)
155 return compositor_thread_->task_runner(); 150 return compositor_thread_->task_runner();
156 151
157 base::Thread::Options thread_options; 152 base::Thread::Options thread_options;
158 #if defined(OS_ANDROID) 153 #if defined(OS_ANDROID)
159 thread_options.priority = base::ThreadPriority::DISPLAY; 154 thread_options.priority = base::ThreadPriority::DISPLAY;
160 #endif 155 #endif
161 compositor_thread_.reset(new base::Thread("Compositor")); 156 compositor_thread_.reset(new base::Thread("Compositor"));
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after
204 199
205 BlimpCompositor* BlimpCompositorManager::GetCompositor(int render_widget_id) { 200 BlimpCompositor* BlimpCompositorManager::GetCompositor(int render_widget_id) {
206 CompositorMap::const_iterator it = compositors_.find(render_widget_id); 201 CompositorMap::const_iterator it = compositors_.find(render_widget_id);
207 if (it == compositors_.end()) 202 if (it == compositors_.end())
208 return nullptr; 203 return nullptr;
209 return it->second.get(); 204 return it->second.get();
210 } 205 }
211 206
212 } // namespace client 207 } // namespace client
213 } // namespace blimp 208 } // namespace blimp
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698