| Index: chrome/browser/ui/views/frame/browser_frame_ash.cc
|
| diff --git a/chrome/browser/ui/views/frame/browser_frame_ash.cc b/chrome/browser/ui/views/frame/browser_frame_ash.cc
|
| index 07f4e332ebbf953b1a7b1912b59e0d2153efdc9b..7dbca82cd8176ca8487f9a911c56c79cc647283b 100644
|
| --- a/chrome/browser/ui/views/frame/browser_frame_ash.cc
|
| +++ b/chrome/browser/ui/views/frame/browser_frame_ash.cc
|
| @@ -86,8 +86,18 @@ BrowserFrameAsh::BrowserFrameAsh(BrowserFrame* browser_frame,
|
| window_property_watcher_(new WindowPropertyWatcher(this, browser_frame)) {
|
| GetNativeWindow()->SetName(kWindowName);
|
| GetNativeWindow()->AddObserver(window_property_watcher_.get());
|
| - if (browser_view->browser()->is_type_tabbed())
|
| - ash::wm::SetAnimateToFullscreen(GetNativeWindow(), false);
|
| + Browser* browser = browser_view->browser();
|
| + ash::wm::WindowState* window_state =
|
| + ash::wm::GetWindowState(GetNativeWindow());
|
| +
|
| + window_state->set_animate_to_fullscreen(!browser->is_type_tabbed());
|
| +
|
| + // AppNonClientFrameViewAsh shows only the window controls and no other
|
| + // window decorations which is pretty close to fullscreen. Put v1 apps
|
| + // into maximized mode instead of fullscreen to avoid showing the ugly
|
| + // fullscreen exit bubble.
|
| + window_state->set_maximize_when_fullscreen(
|
| + browser->is_app() && browser->app_type() != Browser::APP_TYPE_CHILD);
|
|
|
| // Turn on auto window management if we don't need an explicit bounds.
|
| // This way the requested bounds are honored.
|
| @@ -98,10 +108,7 @@ BrowserFrameAsh::BrowserFrameAsh(BrowserFrame* browser_frame,
|
| // For legacy reasons v1 apps (like Secure Shell) are allowed to consume keys
|
| // like brightness, volume, etc. Otherwise these keys are handled by the
|
| // Ash window manager.
|
| - if (browser_view->browser()->is_app()) {
|
| - ash::wm::GetWindowState(GetNativeWindow())->
|
| - set_can_consume_system_keys(true);
|
| - }
|
| + window_state->set_can_consume_system_keys(browser_view->browser()->is_app());
|
| #endif // defined(OS_CHROMEOS)
|
| }
|
|
|
|
|