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

Side by Side Diff: mash/login/login.cc

Issue 2182643003: Remove shell::Connection* parameter to InterfaceFactory<T>::Create() (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: . 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 | « mash/init/init.cc ('k') | mash/quick_launch/quick_launch_application.h » ('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 "mash/login/login.h" 5 #include "mash/login/login.h"
6 6
7 #include <map> 7 #include <map>
8 #include <memory> 8 #include <memory>
9 9
10 #include "ash/public/interfaces/container.mojom.h" 10 #include "ash/public/interfaces/container.mojom.h"
(...skipping 148 matching lines...) Expand 10 before | Expand all | Expand 10 after
159 159
160 connector_->ConnectToInterface("mojo:ui", &user_access_manager_); 160 connector_->ConnectToInterface("mojo:ui", &user_access_manager_);
161 user_access_manager_->SetActiveUser(identity.user_id()); 161 user_access_manager_->SetActiveUser(identity.user_id());
162 } 162 }
163 bool OnConnect(shell::Connection* connection) override { 163 bool OnConnect(shell::Connection* connection) override {
164 connection->AddInterface<mojom::Login>(this); 164 connection->AddInterface<mojom::Login>(this);
165 return true; 165 return true;
166 } 166 }
167 167
168 // shell::InterfaceFactory<mojom::Login>: 168 // shell::InterfaceFactory<mojom::Login>:
169 void Create(shell::Connection* connection, 169 void Create(const shell::Identity& remote_identity,
170 mojom::LoginRequest request) override { 170 mojom::LoginRequest request) override {
171 bindings_.AddBinding(this, std::move(request)); 171 bindings_.AddBinding(this, std::move(request));
172 } 172 }
173 173
174 // mojom::Login: 174 // mojom::Login:
175 void ShowLoginUI() override { UI::Show(connector_, identity_, this); } 175 void ShowLoginUI() override { UI::Show(connector_, identity_, this); }
176 void SwitchUser() override { UI::Show(connector_, identity_, this); } 176 void SwitchUser() override { UI::Show(connector_, identity_, this); }
177 177
178 void StartWindowManager(); 178 void StartWindowManager();
179 179
(...skipping 20 matching lines...) Expand all
200 } 200 }
201 201
202 } // namespace 202 } // namespace
203 203
204 shell::Service* CreateLogin() { 204 shell::Service* CreateLogin() {
205 return new Login; 205 return new Login;
206 } 206 }
207 207
208 } // namespace login 208 } // namespace login
209 } // namespace main 209 } // namespace main
OLDNEW
« no previous file with comments | « mash/init/init.cc ('k') | mash/quick_launch/quick_launch_application.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698