summaryrefslogtreecommitdiffstats
path: root/mash
diff options
context:
space:
mode:
authorben <ben@chromium.org>2016-03-17 21:54:27 -0700
committerCommit bot <commit-bot@chromium.org>2016-03-18 04:56:07 +0000
commitc740d5b9a7455a94ddce3835561aa2eb22942b7b (patch)
tree69f6e7283c5dcb3ffa2ba9b214289bbc84c475c1 /mash
parentcbe6dc8d336bcf5e8a9b0e7da7d5b0939bda32e6 (diff)
downloadchromium_src-c740d5b9a7455a94ddce3835561aa2eb22942b7b.zip
chromium_src-c740d5b9a7455a94ddce3835561aa2eb22942b7b.tar.gz
chromium_src-c740d5b9a7455a94ddce3835561aa2eb22942b7b.tar.bz2
Rename mash_shell to mash_session.
TBR=sky@chromium.org BUG= Review URL: https://codereview.chromium.org/1817443002 Cr-Commit-Position: refs/heads/master@{#381889}
Diffstat (limited to 'mash')
-rw-r--r--mash/BUILD.gn2
-rw-r--r--mash/example/window_type_launcher/BUILD.gn2
-rw-r--r--mash/example/window_type_launcher/window_type_launcher.cc20
-rw-r--r--mash/login/login.cc2
-rw-r--r--mash/screenlock/BUILD.gn2
-rw-r--r--mash/screenlock/screenlock.cc14
-rw-r--r--mash/screenlock/screenlock.h6
-rw-r--r--mash/session/BUILD.gn (renamed from mash/shell/BUILD.gn)14
-rw-r--r--mash/session/main.cc (renamed from mash/shell/main.cc)4
-rw-r--r--mash/session/manifest.json8
-rw-r--r--mash/session/public/interfaces/BUILD.gn (renamed from mash/shell/public/interfaces/BUILD.gn)2
-rw-r--r--mash/session/public/interfaces/session.mojom (renamed from mash/shell/public/interfaces/shell.mojom)4
-rw-r--r--mash/session/session.cc (renamed from mash/shell/shell_application_delegate.cc)63
-rw-r--r--mash/session/session.h (renamed from mash/shell/shell_application_delegate.h)33
-rw-r--r--mash/shell/manifest.json5
-rw-r--r--mash/wm/BUILD.gn4
-rw-r--r--mash/wm/root_window_controller.cc4
-rw-r--r--mash/wm/window_manager.cc6
-rw-r--r--mash/wm/window_manager.h8
-rw-r--r--mash/wm/window_manager_application.cc4
-rw-r--r--mash/wm/window_manager_application.h8
21 files changed, 107 insertions, 108 deletions
diff --git a/mash/BUILD.gn b/mash/BUILD.gn
index 7ac88a7..f2abd8f 100644
--- a/mash/BUILD.gn
+++ b/mash/BUILD.gn
@@ -15,7 +15,7 @@ group("all") {
"//mash/init",
"//mash/login",
"//mash/screenlock",
- "//mash/shell",
+ "//mash/session",
"//mash/task_viewer",
]
}
diff --git a/mash/example/window_type_launcher/BUILD.gn b/mash/example/window_type_launcher/BUILD.gn
index 7018487..4c183a9 100644
--- a/mash/example/window_type_launcher/BUILD.gn
+++ b/mash/example/window_type_launcher/BUILD.gn
@@ -24,7 +24,7 @@ executable("window_type_launcher") {
"//base:base_static",
"//build/config/sanitizers:deps",
"//components/mus/public/interfaces",
- "//mash/shell/public/interfaces",
+ "//mash/session/public/interfaces",
"//mojo/common:common_base",
"//mojo/converters/geometry",
"//mojo/edk/system",
diff --git a/mash/example/window_type_launcher/window_type_launcher.cc b/mash/example/window_type_launcher/window_type_launcher.cc
index 1d56a87..2628f03 100644
--- a/mash/example/window_type_launcher/window_type_launcher.cc
+++ b/mash/example/window_type_launcher/window_type_launcher.cc
@@ -7,7 +7,7 @@
#include "base/macros.h"
#include "base/message_loop/message_loop.h"
#include "base/strings/utf_string_conversions.h"
-#include "mash/shell/public/interfaces/shell.mojom.h"
+#include "mash/session/public/interfaces/session.mojom.h"
#include "mojo/converters/geometry/geometry_type_converters.h"
#include "mojo/shell/public/cpp/connection.h"
#include "mojo/shell/public/cpp/connector.h"
@@ -279,17 +279,17 @@ class WindowTypeLauncherView : public views::WidgetDelegateView,
} else if (sender == bubble_button_) {
NOTIMPLEMENTED();
} else if (sender == lock_button_) {
- mash::shell::mojom::ShellPtr shell;
- connector_->ConnectToInterface("mojo:mash_shell", &shell);
- shell->LockScreen();
+ mash::session::mojom::SessionPtr session;
+ connector_->ConnectToInterface("mojo:mash_session", &session);
+ session->LockScreen();
} else if (sender == logout_button_) {
- mash::shell::mojom::ShellPtr shell;
- connector_->ConnectToInterface("mojo:mash_shell", &shell);
- shell->Logout();
+ mash::session::mojom::SessionPtr session;
+ connector_->ConnectToInterface("mojo:mash_session", &session);
+ session->Logout();
} else if (sender == switch_user_button_) {
- mash::shell::mojom::ShellPtr shell;
- connector_->ConnectToInterface("mojo:mash_shell", &shell);
- shell->SwitchUser();
+ mash::session::mojom::SessionPtr session;
+ connector_->ConnectToInterface("mojo:mash_session", &session);
+ session->SwitchUser();
} else if (sender == widgets_button_) {
NOTIMPLEMENTED();
}
diff --git a/mash/login/login.cc b/mash/login/login.cc
index e5c566b..92dec1d 100644
--- a/mash/login/login.cc
+++ b/mash/login/login.cc
@@ -139,7 +139,7 @@ class Login : public mojo::ShellClient,
user_access_manager_->SetActiveUser(user_id);
mash::init::mojom::InitPtr init;
connector_->ConnectToInterface("mojo:mash_init", &init);
- init->StartService("mojo:mash_shell", user_id);
+ init->StartService("mojo:mash_session", user_id);
}
private:
diff --git a/mash/screenlock/BUILD.gn b/mash/screenlock/BUILD.gn
index 5463942..90490a5 100644
--- a/mash/screenlock/BUILD.gn
+++ b/mash/screenlock/BUILD.gn
@@ -18,7 +18,7 @@ mojo_native_application("screenlock") {
deps = [
"//base",
"//components/mus/public/cpp",
- "//mash/shell/public/interfaces",
+ "//mash/session/public/interfaces",
"//mash/wm/public/interfaces",
"//mojo/common",
"//mojo/public/cpp/bindings",
diff --git a/mash/screenlock/screenlock.cc b/mash/screenlock/screenlock.cc
index 60f6f1e..310164d 100644
--- a/mash/screenlock/screenlock.cc
+++ b/mash/screenlock/screenlock.cc
@@ -7,7 +7,7 @@
#include "base/macros.h"
#include "base/strings/utf_string_conversions.h"
#include "components/mus/public/cpp/property_type_converters.h"
-#include "mash/shell/public/interfaces/shell.mojom.h"
+#include "mash/session/public/interfaces/session.mojom.h"
#include "mash/wm/public/interfaces/container.mojom.h"
#include "mojo/public/cpp/bindings/binding.h"
#include "mojo/shell/public/cpp/connector.h"
@@ -59,9 +59,9 @@ class ScreenlockView : public views::WidgetDelegateView,
// Overridden from views::ButtonListener:
void ButtonPressed(views::Button* sender, const ui::Event& event) override {
DCHECK_EQ(sender, unlock_button_);
- mash::shell::mojom::ShellPtr shell;
- connector_->ConnectToInterface("mojo:mash_shell", &shell);
- shell->UnlockScreen();
+ mash::session::mojom::SessionPtr session;
+ connector_->ConnectToInterface("mojo:mash_session", &session);
+ session->UnlockScreen();
}
mojo::Connector* connector_;
@@ -80,9 +80,9 @@ void Screenlock::Initialize(mojo::Connector* connector,
uint32_t id) {
tracing_.Initialize(connector, identity.name());
- mash::shell::mojom::ShellPtr mash_shell;
- connector->ConnectToInterface("mojo:mash_shell", &mash_shell);
- mash_shell->AddScreenlockStateListener(
+ mash::session::mojom::SessionPtr session;
+ connector->ConnectToInterface("mojo:mash_session", &session);
+ session->AddScreenlockStateListener(
bindings_.CreateInterfacePtrAndBind(this));
aura_init_.reset(new views::AuraInit(connector, "views_mus_resources.pak"));
diff --git a/mash/screenlock/screenlock.h b/mash/screenlock/screenlock.h
index f1d2755..f7d1723 100644
--- a/mash/screenlock/screenlock.h
+++ b/mash/screenlock/screenlock.h
@@ -9,7 +9,7 @@
#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
-#include "mash/shell/public/interfaces/shell.mojom.h"
+#include "mash/session/public/interfaces/session.mojom.h"
#include "mojo/public/cpp/bindings/binding_set.h"
#include "mojo/services/tracing/public/cpp/tracing_impl.h"
#include "mojo/shell/public/cpp/shell_client.h"
@@ -22,7 +22,7 @@ namespace mash {
namespace screenlock {
class Screenlock : public mojo::ShellClient,
- public shell::mojom::ScreenlockStateListener {
+ public session::mojom::ScreenlockStateListener {
public:
Screenlock();
~Screenlock() override;
@@ -38,7 +38,7 @@ class Screenlock : public mojo::ShellClient,
mojo::TracingImpl tracing_;
scoped_ptr<views::AuraInit> aura_init_;
- mojo::BindingSet<mash::shell::mojom::ScreenlockStateListener> bindings_;
+ mojo::BindingSet<session::mojom::ScreenlockStateListener> bindings_;
DISALLOW_COPY_AND_ASSIGN(Screenlock);
};
diff --git a/mash/shell/BUILD.gn b/mash/session/BUILD.gn
index ffe637b..3155ec1 100644
--- a/mash/shell/BUILD.gn
+++ b/mash/session/BUILD.gn
@@ -10,14 +10,14 @@ import("//tools/grit/repack.gni")
source_set("lib") {
sources = [
- "shell_application_delegate.cc",
- "shell_application_delegate.h",
+ "session.cc",
+ "session.h",
]
deps = [
"//base",
"//mash/login/public/interfaces",
- "//mash/shell/public/interfaces",
+ "//mash/session/public/interfaces",
"//mojo/common",
"//mojo/public/cpp/bindings",
"//mojo/shell/public/cpp",
@@ -32,8 +32,8 @@ source_set("lib") {
]
}
-mojo_native_application("shell") {
- output_name = "mash_shell"
+mojo_native_application("session") {
+ output_name = "mash_session"
sources = [
"main.cc",
@@ -42,7 +42,7 @@ mojo_native_application("shell") {
deps = [
":lib",
"//base",
- "//mash/shell/public/interfaces",
+ "//mash/session/public/interfaces",
"//mojo/common",
"//mojo/public/cpp/bindings",
"//mojo/shell/public/cpp",
@@ -55,6 +55,6 @@ mojo_native_application("shell") {
}
mojo_application_manifest("manifest") {
- application_name = "mash_shell"
+ application_name = "mash_session"
source = "manifest.json"
}
diff --git a/mash/shell/main.cc b/mash/session/main.cc
index 06cdc36..1ca0f5b 100644
--- a/mash/shell/main.cc
+++ b/mash/session/main.cc
@@ -2,11 +2,11 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#include "mash/shell/shell_application_delegate.h"
+#include "mash/session/session.h"
#include "mojo/public/c/system/main.h"
#include "mojo/shell/public/cpp/application_runner.h"
MojoResult MojoMain(MojoHandle shell_handle) {
- mojo::ApplicationRunner runner(new mash::shell::ShellApplicationDelegate);
+ mojo::ApplicationRunner runner(new mash::session::Session);
return runner.Run(shell_handle);
}
diff --git a/mash/session/manifest.json b/mash/session/manifest.json
new file mode 100644
index 0000000..2c91534
--- /dev/null
+++ b/mash/session/manifest.json
@@ -0,0 +1,8 @@
+{
+ "manifest_version": 1,
+ "name": "mojo:mash_session",
+ "display_name": "User Session",
+ "capabilities": {
+ "required": { "*": { "interfaces": [ "*" ] } }
+ }
+}
diff --git a/mash/shell/public/interfaces/BUILD.gn b/mash/session/public/interfaces/BUILD.gn
index a174a64..c4c6875 100644
--- a/mash/shell/public/interfaces/BUILD.gn
+++ b/mash/session/public/interfaces/BUILD.gn
@@ -6,6 +6,6 @@ import("//mojo/public/tools/bindings/mojom.gni")
mojom("interfaces") {
sources = [
- "shell.mojom",
+ "session.mojom",
]
}
diff --git a/mash/shell/public/interfaces/shell.mojom b/mash/session/public/interfaces/session.mojom
index 77d1e80..f81e98d 100644
--- a/mash/shell/public/interfaces/shell.mojom
+++ b/mash/session/public/interfaces/session.mojom
@@ -2,7 +2,7 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-module mash.shell.mojom;
+module mash.session.mojom;
interface ScreenlockStateListener {
// This method is called when the listener is initially added with the current
@@ -10,7 +10,7 @@ interface ScreenlockStateListener {
ScreenlockStateChanged(bool locked);
};
-interface Shell {
+interface Session {
Logout();
SwitchUser();
LockScreen();
diff --git a/mash/shell/shell_application_delegate.cc b/mash/session/session.cc
index 408ec7f..c739db0 100644
--- a/mash/shell/shell_application_delegate.cc
+++ b/mash/session/session.cc
@@ -2,7 +2,7 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#include "mash/shell/shell_application_delegate.h"
+#include "mash/session/session.h"
#include "base/bind.h"
#include "base/command_line.h"
@@ -12,16 +12,14 @@
#include "mojo/shell/public/cpp/connector.h"
namespace mash {
-namespace shell {
+namespace session {
-ShellApplicationDelegate::ShellApplicationDelegate()
- : connector_(nullptr), screen_locked_(false) {}
+Session::Session() : connector_(nullptr), screen_locked_(false) {}
+Session::~Session() {}
-ShellApplicationDelegate::~ShellApplicationDelegate() {}
-
-void ShellApplicationDelegate::Initialize(mojo::Connector* connector,
- const mojo::Identity& identity,
- uint32_t id) {
+void Session::Initialize(mojo::Connector* connector,
+ const mojo::Identity& identity,
+ uint32_t id) {
connector_ = connector;
StartBrowserDriver();
StartWindowManager();
@@ -29,12 +27,12 @@ void ShellApplicationDelegate::Initialize(mojo::Connector* connector,
StartQuickLaunch();
}
-bool ShellApplicationDelegate::AcceptConnection(mojo::Connection* connection) {
- connection->AddInterface<mojom::Shell>(this);
+bool Session::AcceptConnection(mojo::Connection* connection) {
+ connection->AddInterface<mojom::Session>(this);
return true;
}
-void ShellApplicationDelegate::Logout() {
+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;
@@ -44,19 +42,19 @@ void ShellApplicationDelegate::Logout() {
base::MessageLoop::current()->QuitWhenIdle();
}
-void ShellApplicationDelegate::SwitchUser() {
+void Session::SwitchUser() {
mash::login::mojom::LoginPtr login;
connector_->ConnectToInterface("mojo:login", &login);
login->SwitchUser();
}
-void ShellApplicationDelegate::AddScreenlockStateListener(
+void Session::AddScreenlockStateListener(
mojom::ScreenlockStateListenerPtr listener) {
listener->ScreenlockStateChanged(screen_locked_);
screenlock_listeners_.AddInterfacePtr(std::move(listener));
}
-void ShellApplicationDelegate::LockScreen() {
+void Session::LockScreen() {
if (screen_locked_)
return;
screen_locked_ = true;
@@ -66,7 +64,7 @@ void ShellApplicationDelegate::LockScreen() {
});
StartScreenlock();
}
-void ShellApplicationDelegate::UnlockScreen() {
+void Session::UnlockScreen() {
if (!screen_locked_)
return;
screen_locked_ = false;
@@ -77,53 +75,52 @@ void ShellApplicationDelegate::UnlockScreen() {
StopScreenlock();
}
-void ShellApplicationDelegate::Create(
- mojo::Connection* connection,
- mojom::ShellRequest request) {
+void Session::Create(mojo::Connection* connection,
+ mojom::SessionRequest request) {
bindings_.AddBinding(this, std::move(request));
}
-void ShellApplicationDelegate::StartWindowManager() {
+void Session::StartWindowManager() {
StartRestartableService(
"mojo:desktop_wm",
- base::Bind(&ShellApplicationDelegate::StartWindowManager,
+ base::Bind(&Session::StartWindowManager,
base::Unretained(this)));
}
-void ShellApplicationDelegate::StartSystemUI() {
+void Session::StartSystemUI() {
StartRestartableService("mojo:ash_sysui",
- base::Bind(&ShellApplicationDelegate::StartSystemUI,
+ base::Bind(&Session::StartSystemUI,
base::Unretained(this)));
}
-void ShellApplicationDelegate::StartBrowserDriver() {
+void Session::StartBrowserDriver() {
StartRestartableService(
"mojo:browser_driver",
- base::Bind(&ShellApplicationDelegate::StartBrowserDriver,
+ base::Bind(&Session::StartBrowserDriver,
base::Unretained(this)));
}
-void ShellApplicationDelegate::StartQuickLaunch() {
+void Session::StartQuickLaunch() {
StartRestartableService(
"mojo:quick_launch",
- base::Bind(&ShellApplicationDelegate::StartQuickLaunch,
+ base::Bind(&Session::StartQuickLaunch,
base::Unretained(this)));
}
-void ShellApplicationDelegate::StartScreenlock() {
+void Session::StartScreenlock() {
StartRestartableService(
"mojo:screenlock",
- base::Bind(&ShellApplicationDelegate::StartScreenlock,
+ base::Bind(&Session::StartScreenlock,
base::Unretained(this)));
}
-void ShellApplicationDelegate::StopScreenlock() {
+void Session::StopScreenlock() {
auto connection = connections_.find("mojo:screenlock");
DCHECK(connections_.end() != connection);
connections_.erase(connection);
}
-void ShellApplicationDelegate::StartRestartableService(
+void Session::StartRestartableService(
const std::string& url,
const base::Closure& restart_callback) {
// TODO(beng): This would be the place to insert logic that counted restarts
@@ -132,10 +129,10 @@ void ShellApplicationDelegate::StartRestartableService(
// Note: |connection| may be null if we've lost our connection to the shell.
if (connection) {
connection->SetConnectionLostClosure(restart_callback);
- connection->AddInterface<mojom::Shell>(this);
+ connection->AddInterface<mojom::Session>(this);
connections_[url] = std::move(connection);
}
}
-} // namespace shell
+} // namespace session
} // namespace main
diff --git a/mash/shell/shell_application_delegate.h b/mash/session/session.h
index 98c4404..a2a133b 100644
--- a/mash/shell/shell_application_delegate.h
+++ b/mash/session/session.h
@@ -2,15 +2,15 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#ifndef MASH_SHELL_SHELL_APPLICATION_DELEGATE_H_
-#define MASH_SHELL_SHELL_APPLICATION_DELEGATE_H_
+#ifndef MASH_SESSION_SESSION_H_
+#define MASH_SESSION_SESSION_H_
#include <map>
#include "base/callback.h"
#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
-#include "mash/shell/public/interfaces/shell.mojom.h"
+#include "mash/session/public/interfaces/session.mojom.h"
#include "mojo/public/cpp/bindings/binding_set.h"
#include "mojo/public/cpp/bindings/interface_ptr_set.h"
#include "mojo/shell/public/cpp/interface_factory.h"
@@ -21,15 +21,14 @@ class Connection;
}
namespace mash {
-namespace shell {
+namespace session {
-class ShellApplicationDelegate
- : public mojo::ShellClient,
- public mash::shell::mojom::Shell,
- public mojo::InterfaceFactory<mash::shell::mojom::Shell> {
+class Session : public mojo::ShellClient,
+ public mojom::Session,
+ public mojo::InterfaceFactory<mojom::Session> {
public:
- ShellApplicationDelegate();
- ~ShellApplicationDelegate() override;
+ Session();
+ ~Session() override;
private:
// mojo::ShellClient:
@@ -38,7 +37,7 @@ class ShellApplicationDelegate
uint32_t id) override;
bool AcceptConnection(mojo::Connection* connection) override;
- // mash::shell::mojom::Shell:
+ // mojom::Session:
void Logout() override;
void SwitchUser() override;
void AddScreenlockStateListener(
@@ -46,9 +45,9 @@ class ShellApplicationDelegate
void LockScreen() override;
void UnlockScreen() override;
- // mojo::InterfaceFactory<mash::shell::mojom::Shell>:
+ // mojo::InterfaceFactory<mojom::Session>:
void Create(mojo::Connection* connection,
- mojo::InterfaceRequest<mash::shell::mojom::Shell> r) override;
+ mojom::SessionRequest request) override;
void StartWindowManager();
void StartSystemUI();
@@ -66,13 +65,13 @@ class ShellApplicationDelegate
mojo::Connector* connector_;
std::map<std::string, scoped_ptr<mojo::Connection>> connections_;
bool screen_locked_;
- mojo::BindingSet<mash::shell::mojom::Shell> bindings_;
+ mojo::BindingSet<mojom::Session> bindings_;
mojo::InterfacePtrSet<mojom::ScreenlockStateListener> screenlock_listeners_;
- DISALLOW_COPY_AND_ASSIGN(ShellApplicationDelegate);
+ DISALLOW_COPY_AND_ASSIGN(Session);
};
-} // namespace shell
+} // namespace session
} // namespace mash
-#endif // MASH_SHELL_SHELL_APPLICATION_DELEGATE_H_
+#endif // MASH_SESSION_SESSION_H_
diff --git a/mash/shell/manifest.json b/mash/shell/manifest.json
deleted file mode 100644
index 621f6b3..0000000
--- a/mash/shell/manifest.json
+++ /dev/null
@@ -1,5 +0,0 @@
-{
- "name": "mojo:mash_shell",
- "display_name": "System Service Controller",
- "capabilities": { "*": ["*"] }
-}
diff --git a/mash/wm/BUILD.gn b/mash/wm/BUILD.gn
index e51e023..6548409 100644
--- a/mash/wm/BUILD.gn
+++ b/mash/wm/BUILD.gn
@@ -73,7 +73,7 @@ source_set("lib") {
"//components/mus/common:mus_common",
"//components/mus/public/cpp",
"//components/mus/public/interfaces",
- "//mash/shell/public/interfaces",
+ "//mash/session/public/interfaces",
"//mash/wm/public/interfaces",
"//mash/wm/resources",
"//mojo/common:common_base",
@@ -107,7 +107,7 @@ mojo_native_application("wm") {
"//mojo/shell/public/cpp",
]
- # TODO(beng): This target relies on //mash/shell, but there is a cycle so we
+ # TODO(beng): This target relies on //mash/session, but there is a cycle so we
# can't state that dependency here.
data_deps = [
":manifest",
diff --git a/mash/wm/root_window_controller.cc b/mash/wm/root_window_controller.cc
index ca74674..934f364 100644
--- a/mash/wm/root_window_controller.cc
+++ b/mash/wm/root_window_controller.cc
@@ -12,7 +12,7 @@
#include "components/mus/public/cpp/window.h"
#include "components/mus/public/cpp/window_tree_connection.h"
#include "components/mus/public/cpp/window_tree_host_factory.h"
-#include "mash/shell/public/interfaces/shell.mojom.h"
+#include "mash/session/public/interfaces/session.mojom.h"
#include "mash/wm/background_layout.h"
#include "mash/wm/fill_layout.h"
#include "mash/wm/screenlock_layout.h"
@@ -132,7 +132,7 @@ void RootWindowController::OnEmbed(mus::Window* root) {
AddAccelerators();
- window_manager_->Initialize(this, app_->mash_shell());
+ window_manager_->Initialize(this, app_->session());
shadow_controller_.reset(new ShadowController(root->connection()));
diff --git a/mash/wm/window_manager.cc b/mash/wm/window_manager.cc
index d6ff95f..5905469f 100644
--- a/mash/wm/window_manager.cc
+++ b/mash/wm/window_manager.cc
@@ -39,7 +39,7 @@ WindowManager::~WindowManager() {
}
void WindowManager::Initialize(RootWindowController* root_controller,
- mash::shell::mojom::Shell* shell) {
+ session::mojom::Session* session) {
DCHECK(root_controller);
DCHECK(!root_controller_);
root_controller_ = root_controller;
@@ -66,8 +66,8 @@ void WindowManager::Initialize(RootWindowController* root_controller,
window_manager_client_->SetFrameDecorationValues(
std::move(frame_decoration_values));
- if (shell)
- shell->AddScreenlockStateListener(binding_.CreateInterfacePtrAndBind());
+ if (session)
+ session->AddScreenlockStateListener(binding_.CreateInterfacePtrAndBind());
}
gfx::Rect WindowManager::CalculateDefaultBounds(mus::Window* window) const {
diff --git a/mash/wm/window_manager.h b/mash/wm/window_manager.h
index 7542d1b..96c0b8a 100644
--- a/mash/wm/window_manager.h
+++ b/mash/wm/window_manager.h
@@ -12,7 +12,7 @@
#include "components/mus/public/cpp/window_manager_delegate.h"
#include "components/mus/public/cpp/window_observer.h"
#include "components/mus/public/interfaces/window_manager.mojom.h"
-#include "mash/shell/public/interfaces/shell.mojom.h"
+#include "mash/session/public/interfaces/session.mojom.h"
#include "mojo/public/cpp/bindings/binding.h"
namespace mash {
@@ -22,13 +22,13 @@ class RootWindowController;
class WindowManager : public mus::WindowObserver,
public mus::WindowManagerDelegate,
- public mash::shell::mojom::ScreenlockStateListener {
+ public session::mojom::ScreenlockStateListener {
public:
WindowManager();
~WindowManager() override;
void Initialize(RootWindowController* root_controller,
- mash::shell::mojom::Shell* shell);
+ session::mojom::Session* session);
mus::WindowManagerClient* window_manager_client() {
return window_manager_client_;
@@ -61,7 +61,7 @@ class WindowManager : public mus::WindowObserver,
RootWindowController* root_controller_;
mus::WindowManagerClient* window_manager_client_;
- mojo::Binding<mash::shell::mojom::ScreenlockStateListener> binding_;
+ mojo::Binding<session::mojom::ScreenlockStateListener> binding_;
DISALLOW_COPY_AND_ASSIGN(WindowManager);
};
diff --git a/mash/wm/window_manager_application.cc b/mash/wm/window_manager_application.cc
index 4c1bb66..606de45 100644
--- a/mash/wm/window_manager_application.cc
+++ b/mash/wm/window_manager_application.cc
@@ -122,8 +122,8 @@ void WindowManagerApplication::Initialize(mojo::Connector* connector,
bool WindowManagerApplication::AcceptConnection(mojo::Connection* connection) {
connection->AddInterface<mash::wm::mojom::UserWindowController>(this);
connection->AddInterface<mus::mojom::AcceleratorRegistrar>(this);
- if (connection->GetRemoteIdentity().name() == "mojo:mash_shell")
- connection->GetInterface(&mash_shell_);
+ if (connection->GetRemoteIdentity().name() == "mojo:mash_session")
+ connection->GetInterface(&session_);
return true;
}
diff --git a/mash/wm/window_manager_application.h b/mash/wm/window_manager_application.h
index 67b764e..5ca2725 100644
--- a/mash/wm/window_manager_application.h
+++ b/mash/wm/window_manager_application.h
@@ -17,7 +17,7 @@
#include "components/mus/public/interfaces/window_manager.mojom.h"
#include "components/mus/public/interfaces/window_manager_factory.mojom.h"
#include "components/mus/public/interfaces/window_tree_host.mojom.h"
-#include "mash/shell/public/interfaces/shell.mojom.h"
+#include "mash/session/public/interfaces/session.mojom.h"
#include "mash/wm/public/interfaces/user_window_controller.mojom.h"
#include "mojo/public/cpp/bindings/binding.h"
#include "mojo/public/cpp/bindings/binding_set.h"
@@ -79,8 +79,8 @@ class WindowManagerApplication
void AddRootWindowsObserver(RootWindowsObserver* observer);
void RemoveRootWindowsObserver(RootWindowsObserver* observer);
- mash::shell::mojom::Shell* mash_shell() {
- return mash_shell_.get();
+ session::mojom::Session* session() {
+ return session_.get();
}
private:
@@ -129,7 +129,7 @@ class WindowManagerApplication
mojo::Binding<mus::mojom::WindowManagerFactory>
window_manager_factory_binding_;
- mash::shell::mojom::ShellPtr mash_shell_;
+ mash::session::mojom::SessionPtr session_;
base::ObserverList<RootWindowsObserver> root_windows_observers_;