Commit 5b202ebd authored by Joel Hockey's avatar Joel Hockey Committed by Commit Bot

TODO to generalize Terminal logic in AppBrowserController

Bug: 1061822
Change-Id: I334d2ff8add76d42dc7aa4f96cc7e7a8a341c0b1
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2102996
Commit-Queue: Joel Hockey <joelhockey@chromium.org>
Commit-Queue: Alan Cutter <alancutter@chromium.org>
Auto-Submit: Joel Hockey <joelhockey@chromium.org>
Reviewed-by: default avatarAlan Cutter <alancutter@chromium.org>
Cr-Commit-Position: refs/heads/master@{#750471}
parent 398256b9
...@@ -111,8 +111,7 @@ AppBrowserController::AppBrowserController( ...@@ -111,8 +111,7 @@ AppBrowserController::AppBrowserController(
->system_web_app_manager() ->system_web_app_manager()
.GetSystemAppTypeForAppId(GetAppId()) .GetSystemAppTypeForAppId(GetAppId())
: base::nullopt), : base::nullopt),
// Show tabs for Terminals only. // TODO(crbug.com/1061822): Generalise has_tab_strip_ as a SystemWebApp
// TODO(crbug.com/846546): Generalise has_tab_strip_ as a SystemWebApp
// capability. // capability.
has_tab_strip_( has_tab_strip_(
system_app_type_ == SystemAppType::TERMINAL || system_app_type_ == SystemAppType::TERMINAL ||
...@@ -211,7 +210,7 @@ bool AppBrowserController::has_tab_strip() const { ...@@ -211,7 +210,7 @@ bool AppBrowserController::has_tab_strip() const {
bool AppBrowserController::HasTitlebarToolbar() const { bool AppBrowserController::HasTitlebarToolbar() const {
// Show titlebar toolbar for Terminal System App, but not other system apps. // Show titlebar toolbar for Terminal System App, but not other system apps.
// TODO(crbug.com/846546): Generalise this as a SystemWebApp capability. // TODO(crbug.com/1061822): Generalise this as a SystemWebApp capability.
if (is_for_system_web_app()) if (is_for_system_web_app())
return system_app_type_ == web_app::SystemAppType::TERMINAL && return system_app_type_ == web_app::SystemAppType::TERMINAL &&
// SWA terminal has a setting window, which has browser type "app // SWA terminal has a setting window, which has browser type "app
...@@ -270,6 +269,8 @@ void AppBrowserController::UpdateCustomTabBarVisibility(bool animate) const { ...@@ -270,6 +269,8 @@ void AppBrowserController::UpdateCustomTabBarVisibility(bool animate) const {
} }
gfx::Rect AppBrowserController::GetDefaultBounds() const { gfx::Rect AppBrowserController::GetDefaultBounds() const {
// TODO(crbug.com/1061822): Generalise default bounds as a SystemWebApp
// capability.
if (system_app_type_ == SystemAppType::TERMINAL) { if (system_app_type_ == SystemAppType::TERMINAL) {
// Terminal settings is centered. // Terminal settings is centered.
if (browser()->is_type_app_popup()) { if (browser()->is_type_app_popup()) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment