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

Side by Side Diff: services/ui/ws/window_tree_host_factory.cc

Issue 2386763002: services/ui: Match naming in cc (and jellyfish branch) (Closed)
Patch Set: Removed bad change Created 4 years, 2 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 | « services/ui/ws/window_server.cc ('k') | services/ui/ws/window_tree_unittest.cc » ('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 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 "services/ui/ws/window_tree_host_factory.h" 5 #include "services/ui/ws/window_tree_host_factory.h"
6 6
7 #include "services/ui/surfaces/surfaces_state.h" 7 #include "services/ui/surfaces/display_compositor.h"
8 #include "services/ui/ws/display.h" 8 #include "services/ui/ws/display.h"
9 #include "services/ui/ws/display_binding.h" 9 #include "services/ui/ws/display_binding.h"
10 #include "services/ui/ws/window_server.h" 10 #include "services/ui/ws/window_server.h"
11 11
12 namespace ui { 12 namespace ui {
13 namespace ws { 13 namespace ws {
14 14
15 WindowTreeHostFactory::WindowTreeHostFactory(WindowServer* window_server, 15 WindowTreeHostFactory::WindowTreeHostFactory(WindowServer* window_server,
16 const UserId& user_id) 16 const UserId& user_id)
17 : window_server_(window_server), user_id_(user_id) { 17 : window_server_(window_server), user_id_(user_id) {
18 platform_display_init_params_.metrics.bounds.set_width(1024); 18 platform_display_init_params_.metrics.bounds.set_width(1024);
19 platform_display_init_params_.metrics.bounds.set_height(768); 19 platform_display_init_params_.metrics.bounds.set_height(768);
20 platform_display_init_params_.metrics.pixel_size.SetSize(1024, 768); 20 platform_display_init_params_.metrics.pixel_size.SetSize(1024, 768);
21 platform_display_init_params_.metrics.device_scale_factor = 1.0f; 21 platform_display_init_params_.metrics.device_scale_factor = 1.0f;
22 platform_display_init_params_.surfaces_state = 22 platform_display_init_params_.display_compositor =
23 window_server_->GetSurfacesState(); 23 window_server_->GetDisplayCompositor();
24 } 24 }
25 25
26 WindowTreeHostFactory::~WindowTreeHostFactory() {} 26 WindowTreeHostFactory::~WindowTreeHostFactory() {}
27 27
28 void WindowTreeHostFactory::AddBinding( 28 void WindowTreeHostFactory::AddBinding(
29 mojom::WindowTreeHostFactoryRequest request) { 29 mojom::WindowTreeHostFactoryRequest request) {
30 bindings_.AddBinding(this, std::move(request)); 30 bindings_.AddBinding(this, std::move(request));
31 } 31 }
32 32
33 void WindowTreeHostFactory::CreateWindowTreeHost( 33 void WindowTreeHostFactory::CreateWindowTreeHost(
34 mojom::WindowTreeHostRequest host, 34 mojom::WindowTreeHostRequest host,
35 mojom::WindowTreeClientPtr tree_client) { 35 mojom::WindowTreeClientPtr tree_client) {
36 Display* display = new Display(window_server_, platform_display_init_params_); 36 Display* display = new Display(window_server_, platform_display_init_params_);
37 std::unique_ptr<DisplayBindingImpl> display_binding( 37 std::unique_ptr<DisplayBindingImpl> display_binding(
38 new DisplayBindingImpl(std::move(host), display, user_id_, 38 new DisplayBindingImpl(std::move(host), display, user_id_,
39 std::move(tree_client), window_server_)); 39 std::move(tree_client), window_server_));
40 display->Init(std::move(display_binding)); 40 display->Init(std::move(display_binding));
41 } 41 }
42 42
43 } // namespace ws 43 } // namespace ws
44 } // namespace ui 44 } // namespace ui
OLDNEW
« no previous file with comments | « services/ui/ws/window_server.cc ('k') | services/ui/ws/window_tree_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698