Index: mash/session/session.cc |
diff --git a/mash/session/session.cc b/mash/session/session.cc |
index a4640efb4fe93f2dae61a6e84139da4cfcfd08f8..f10b3535fce5160c6598813b139f74fbcea26b1a 100644 |
--- a/mash/session/session.cc |
+++ b/mash/session/session.cc |
@@ -29,14 +29,12 @@ namespace session { |
Session::Session() : screen_locked_(false) {} |
Session::~Session() {} |
-void Session::OnStart(service_manager::ServiceContext* context) { |
- context_ = context; |
- |
+void Session::OnStart() { |
StartWindowManager(); |
StartQuickLaunch(); |
// Launch a chrome window for dev convience; don't do this in the long term. |
- context->connector()->Connect("service:content_browser"); |
+ context()->connector()->Connect("service:content_browser"); |
} |
bool Session::OnConnect(const service_manager::ServiceInfo& remote_info, |
@@ -49,7 +47,7 @@ void Session::Logout() { |
// TODO(beng): Notify connected listeners that login is happening, potentially |
// give them the option to stop it. |
mash::login::mojom::LoginPtr login; |
- context_->connector()->ConnectToInterface("service:login", &login); |
+ context()->connector()->ConnectToInterface("service:login", &login); |
login->ShowLoginUI(); |
// This kills the user environment. |
base::MessageLoop::current()->QuitWhenIdle(); |
@@ -57,7 +55,7 @@ void Session::Logout() { |
void Session::SwitchUser() { |
mash::login::mojom::LoginPtr login; |
- context_->connector()->ConnectToInterface("service:login", &login); |
+ context()->connector()->ConnectToInterface("service:login", &login); |
login->SwitchUser(); |
} |
@@ -126,7 +124,7 @@ void Session::StartRestartableService( |
// TODO(beng): This would be the place to insert logic that counted restarts |
// to avoid infinite crash-restart loops. |
std::unique_ptr<service_manager::Connection> connection = |
- context_->connector()->Connect(url); |
+ context()->connector()->Connect(url); |
// Note: |connection| may be null if we've lost our connection to the service |
// manager. |
if (connection) { |