Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(33)

Side by Side Diff: chrome/browser/ui/ash/chrome_shell_delegate.cc

Issue 25565002: Make all v1 app windows use the same maximized window frame (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | chrome/browser/ui/ash/chrome_shell_delegate_browsertest.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/ui/ash/chrome_shell_delegate.h" 5 #include "chrome/browser/ui/ash/chrome_shell_delegate.h"
6 6
7 #include "apps/native_app_window.h" 7 #include "apps/native_app_window.h"
8 #include "apps/shell_window.h" 8 #include "apps/shell_window.h"
9 #include "apps/shell_window_registry.h" 9 #include "apps/shell_window_registry.h"
10 #include "ash/host/root_window_host_factory.h" 10 #include "ash/host/root_window_host_factory.h"
(...skipping 167 matching lines...) Expand 10 before | Expand all | Expand 10 after
178 // AppNonClientFrameViewAsh shows only the window controls and no other 178 // AppNonClientFrameViewAsh shows only the window controls and no other
179 // window decorations which is pretty close to fullscreen. Put v1 apps 179 // window decorations which is pretty close to fullscreen. Put v1 apps
180 // into maximized mode instead of fullscreen to avoid showing the ugly 180 // into maximized mode instead of fullscreen to avoid showing the ugly
181 // fullscreen exit bubble. 181 // fullscreen exit bubble.
182 #if defined(OS_WIN) 182 #if defined(OS_WIN)
183 if (browser->host_desktop_type() == chrome::HOST_DESKTOP_TYPE_NATIVE) { 183 if (browser->host_desktop_type() == chrome::HOST_DESKTOP_TYPE_NATIVE) {
184 chrome::ToggleFullscreenMode(browser); 184 chrome::ToggleFullscreenMode(browser);
185 return; 185 return;
186 } 186 }
187 #endif // OS_WIN 187 #endif // OS_WIN
188 if (browser->is_app() && browser->app_type() != Browser::APP_TYPE_CHILD) 188 if (browser->is_app())
189 window_state->ToggleMaximized(); 189 window_state->ToggleMaximized();
190 else 190 else
191 chrome::ToggleFullscreenMode(browser); 191 chrome::ToggleFullscreenMode(browser);
192 return; 192 return;
193 } 193 }
194 194
195 // |window| may belong to a shell window. 195 // |window| may belong to a shell window.
196 apps::ShellWindow* shell_window = apps::ShellWindowRegistry:: 196 apps::ShellWindow* shell_window = apps::ShellWindowRegistry::
197 GetShellWindowForNativeWindowAnyProfile(window); 197 GetShellWindowForNativeWindowAnyProfile(window);
198 if (shell_window) { 198 if (shell_window) {
(...skipping 259 matching lines...) Expand 10 before | Expand all | Expand 10 after
458 } 458 }
459 459
460 Browser* ChromeShellDelegate::GetTargetBrowserIfAvailable() { 460 Browser* ChromeShellDelegate::GetTargetBrowserIfAvailable() {
461 return chrome::FindBrowserWithWindow(ash::wm::GetActiveWindow()); 461 return chrome::FindBrowserWithWindow(ash::wm::GetActiveWindow());
462 } 462 }
463 463
464 keyboard::KeyboardControllerProxy* 464 keyboard::KeyboardControllerProxy*
465 ChromeShellDelegate::CreateKeyboardControllerProxy() { 465 ChromeShellDelegate::CreateKeyboardControllerProxy() {
466 return new AshKeyboardControllerProxy(); 466 return new AshKeyboardControllerProxy();
467 } 467 }
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/ui/ash/chrome_shell_delegate_browsertest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698