[modular] Cleanup while reading the code.
Un-inline a method that has no reason to be inline.
TESTED=run_modular_tests.sh
Change-Id: I134f962aa0d1c49dace82a1458e0adfa7030a250
diff --git a/bin/basemgr/basemgr_impl.cc b/bin/basemgr/basemgr_impl.cc
index 698b8be..b2b74ac 100644
--- a/bin/basemgr/basemgr_impl.cc
+++ b/bin/basemgr/basemgr_impl.cc
@@ -50,7 +50,7 @@
base_shell_context_binding_(this),
account_provider_context_binding_(this),
authentication_context_provider_binding_(this) {
- update_session_shell_config();
+ UpdateSessionShellConfig();
// TODO(SCN-595): Presentation is now discoverable, so we don't need
// kPresentationService anymore.
@@ -460,7 +460,7 @@
active_session_shell_settings_index_ =
(active_session_shell_settings_index_ + 1) % shell_count;
- update_session_shell_config();
+ UpdateSessionShellConfig();
user_provider_impl_->SwapSessionShell(CloneStruct(session_shell_config_))
->Then([] { FXL_DLOG(INFO) << "Swapped session shell"; });
@@ -522,4 +522,19 @@
presentation_state_.clipping_enabled);
}
+void BasemgrImpl::UpdateSessionShellConfig() {
+ // The session shell settings overrides the session_shell flag passed via
+ // command line. TODO(MF-113): Consolidate the session shell settings.
+ fuchsia::modular::AppConfig session_shell_config;
+ if (session_shell_settings_.empty()) {
+ session_shell_config = CloneStruct(settings_.session_shell);
+ } else {
+ const auto& settings =
+ session_shell_settings_[active_session_shell_settings_index_];
+ session_shell_config.url = settings.name;
+ }
+
+ session_shell_config_ = std::move(session_shell_config);
+}
+
} // namespace modular
diff --git a/bin/basemgr/basemgr_impl.h b/bin/basemgr/basemgr_impl.h
index 586c3b4..a977f3a 100644
--- a/bin/basemgr/basemgr_impl.h
+++ b/bin/basemgr/basemgr_impl.h
@@ -130,20 +130,7 @@
// Updates the session shell app config to the active session shell. Done once
// on initialization and every time the session shells are swapped.
- void update_session_shell_config() {
- // The session shell settings overrides the session_shell flag passed via
- // command line. TODO(MF-113): Consolidate the session shell settings.
- fuchsia::modular::AppConfig session_shell_config;
- if (session_shell_settings_.empty()) {
- session_shell_config = CloneStruct(settings_.session_shell);
- } else {
- const auto& settings =
- session_shell_settings_[active_session_shell_settings_index_];
- session_shell_config.url = settings.name;
- }
-
- session_shell_config_ = std::move(session_shell_config);
- }
+ void UpdateSessionShellConfig();
const modular::BasemgrSettings& settings_; // Not owned nor copied.
const std::vector<SessionShellSettings>& session_shell_settings_;