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

Side by Side Diff: services/ui/service.cc

Issue 2503923003: Demonstrate external-window-mode in mus-demo (Closed)
Patch Set: Determine external window mode in mus-ws based on if a WM is connected Created 4 years 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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "services/ui/service.h" 5 #include "services/ui/service.h"
6 6
7 #include <set> 7 #include <set>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/command_line.h" 10 #include "base/command_line.h"
(...skipping 209 matching lines...) Expand 10 before | Expand all | Expand 10 after
220 220
221 platform_screen_->AddInterfaces(registry); 221 platform_screen_->AddInterfaces(registry);
222 222
223 #if defined(USE_OZONE) 223 #if defined(USE_OZONE)
224 ui::OzonePlatform::GetInstance()->AddInterfaces(registry); 224 ui::OzonePlatform::GetInstance()->AddInterfaces(registry);
225 #endif 225 #endif
226 226
227 return true; 227 return true;
228 } 228 }
229 229
230 void Service::StartDisplayInit() { 230 void Service::StartDisplayInit(bool window_manager_connected) {
231 platform_screen_->Init(window_server_->display_manager()); 231 platform_screen_->Init(window_server_->display_manager(),
232 !window_manager_connected);
tonikitoo 2016/11/22 03:07:39 nit: in order to self-document the parameter, mayb
Tom (Use chromium acct) 2016/11/22 19:19:48 Done.
232 } 233 }
233 234
234 void Service::OnFirstDisplayReady() { 235 void Service::OnFirstDisplayReady() {
235 PendingRequests requests; 236 PendingRequests requests;
236 requests.swap(pending_requests_); 237 requests.swap(pending_requests_);
237 for (auto& request : requests) { 238 for (auto& request : requests) {
238 if (request->wtf_request) 239 if (request->wtf_request)
239 Create(request->remote_identity, std::move(*request->wtf_request)); 240 Create(request->remote_identity, std::move(*request->wtf_request));
240 else 241 else
241 Create(request->remote_identity, std::move(*request->dm_request)); 242 Create(request->remote_identity, std::move(*request->dm_request));
(...skipping 119 matching lines...) Expand 10 before | Expand all | Expand 10 after
361 mojom::WindowServerTestRequest request) { 362 mojom::WindowServerTestRequest request) {
362 if (!test_config_) 363 if (!test_config_)
363 return; 364 return;
364 mojo::MakeStrongBinding( 365 mojo::MakeStrongBinding(
365 base::MakeUnique<ws::WindowServerTestImpl>(window_server_.get()), 366 base::MakeUnique<ws::WindowServerTestImpl>(window_server_.get()),
366 std::move(request)); 367 std::move(request));
367 } 368 }
368 369
369 370
370 } // namespace ui 371 } // namespace ui
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698