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

Side by Side Diff: mash/wm/window_manager_application.cc

Issue 1459653002: Gets mustash frames looking like that of ash (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: update test Created 5 years, 1 month 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 | « mash/wm/non_client_frame_view_impl.cc ('k') | mash/wm/window_manager_impl.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 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 "mash/wm/window_manager_application.h" 5 #include "mash/wm/window_manager_application.h"
6 6
7 #include "components/mus/common/util.h" 7 #include "components/mus/common/util.h"
8 #include "components/mus/public/cpp/window.h" 8 #include "components/mus/public/cpp/window.h"
9 #include "components/mus/public/cpp/window_tree_connection.h" 9 #include "components/mus/public/cpp/window_tree_connection.h"
10 #include "components/mus/public/cpp/window_tree_host_factory.h" 10 #include "components/mus/public/cpp/window_tree_host_factory.h"
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after
56 background_layout_.reset(new BackgroundLayout( 56 background_layout_.reset(new BackgroundLayout(
57 GetWindowForContainer(mash::wm::mojom::CONTAINER_USER_BACKGROUND))); 57 GetWindowForContainer(mash::wm::mojom::CONTAINER_USER_BACKGROUND)));
58 shelf_layout_.reset(new ShelfLayout( 58 shelf_layout_.reset(new ShelfLayout(
59 GetWindowForContainer(mash::wm::mojom::CONTAINER_USER_SHELF))); 59 GetWindowForContainer(mash::wm::mojom::CONTAINER_USER_SHELF)));
60 window_layout_.reset(new WindowLayout( 60 window_layout_.reset(new WindowLayout(
61 GetWindowForContainer(mash::wm::mojom::CONTAINER_USER_WINDOWS))); 61 GetWindowForContainer(mash::wm::mojom::CONTAINER_USER_WINDOWS)));
62 62
63 window_manager_.reset(new WindowManagerImpl(this)); 63 window_manager_.reset(new WindowManagerImpl(this));
64 64
65 ui_init_.reset(new ui::mojo::UIInit(views::GetDisplaysFromWindow(root))); 65 ui_init_.reset(new ui::mojo::UIInit(views::GetDisplaysFromWindow(root)));
66 aura_init_.reset(new views::AuraInit(app_, "views_mus_resources.pak")); 66 aura_init_.reset(new views::AuraInit(app_, "mash_wm_resources.pak"));
67 67
68 for (auto request : requests_) 68 for (auto request : requests_)
69 window_manager_binding_.AddBinding(window_manager_.get(), request->Pass()); 69 window_manager_binding_.AddBinding(window_manager_.get(), request->Pass());
70 requests_.clear(); 70 requests_.clear();
71 } 71 }
72 72
73 void WindowManagerApplication::OnConnectionLost( 73 void WindowManagerApplication::OnConnectionLost(
74 mus::WindowTreeConnection* connection) { 74 mus::WindowTreeConnection* connection) {
75 // TODO(sky): shutdown. 75 // TODO(sky): shutdown.
76 NOTIMPLEMENTED(); 76 NOTIMPLEMENTED();
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
117 container < static_cast<uint16_t>(mash::wm::mojom::CONTAINER_COUNT); 117 container < static_cast<uint16_t>(mash::wm::mojom::CONTAINER_COUNT);
118 ++container) { 118 ++container) {
119 mus::Window* window = root_->connection()->NewWindow(); 119 mus::Window* window = root_->connection()->NewWindow();
120 DCHECK_EQ(mus::LoWord(window->id()), container) 120 DCHECK_EQ(mus::LoWord(window->id()), container)
121 << "Containers must be created before other windows!"; 121 << "Containers must be created before other windows!";
122 window->SetBounds(root_->bounds()); 122 window->SetBounds(root_->bounds());
123 window->SetVisible(true); 123 window->SetVisible(true);
124 root_->AddChild(window); 124 root_->AddChild(window);
125 } 125 }
126 } 126 }
OLDNEW
« no previous file with comments | « mash/wm/non_client_frame_view_impl.cc ('k') | mash/wm/window_manager_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698