OLD | NEW |
1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 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 #ifndef CHROME_BROWSER_UI_BROWSER_WINDOW_H_ | 5 #ifndef CHROME_BROWSER_UI_BROWSER_WINDOW_H_ |
6 #define CHROME_BROWSER_UI_BROWSER_WINDOW_H_ | 6 #define CHROME_BROWSER_UI_BROWSER_WINDOW_H_ |
7 | 7 |
8 #include "base/callback_forward.h" | 8 #include "base/callback_forward.h" |
9 #include "chrome/browser/lifetime/browser_close_manager.h" | 9 #include "chrome/browser/lifetime/browser_close_manager.h" |
10 #include "chrome/browser/ui/bookmarks/bookmark_bar.h" | 10 #include "chrome/browser/ui/bookmarks/bookmark_bar.h" |
(...skipping 330 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
341 virtual void UpdatePreferredSize(content::WebContents* web_contents, | 341 virtual void UpdatePreferredSize(content::WebContents* web_contents, |
342 const gfx::Size& pref_size) {} | 342 const gfx::Size& pref_size) {} |
343 | 343 |
344 // Invoked when the contents auto-resized and the container should match it. | 344 // Invoked when the contents auto-resized and the container should match it. |
345 virtual void ResizeDueToAutoResize(content::WebContents* web_contents, | 345 virtual void ResizeDueToAutoResize(content::WebContents* web_contents, |
346 const gfx::Size& new_size) {} | 346 const gfx::Size& new_size) {} |
347 | 347 |
348 // Construct a BrowserWindow implementation for the specified |browser|. | 348 // Construct a BrowserWindow implementation for the specified |browser|. |
349 static BrowserWindow* CreateBrowserWindow(Browser* browser); | 349 static BrowserWindow* CreateBrowserWindow(Browser* browser); |
350 | 350 |
| 351 // Returns a HostDesktopType that is compatible with the current Chrome window |
| 352 // configuration. On Windows with Ash, this is always HOST_DESKTOP_TYPE_ASH |
| 353 // while Chrome is running in Metro mode. Otherwise returns |desktop_type|. |
| 354 static chrome::HostDesktopType AdjustHostDesktopType( |
| 355 chrome::HostDesktopType desktop_type); |
| 356 |
351 // Shows the avatar bubble inside |web_contents|. The bubble is positioned | 357 // Shows the avatar bubble inside |web_contents|. The bubble is positioned |
352 // relative to |rect|. |rect| should be in the |web_contents| coordinate | 358 // relative to |rect|. |rect| should be in the |web_contents| coordinate |
353 // system. | 359 // system. |
354 virtual void ShowAvatarBubble(content::WebContents* web_contents, | 360 virtual void ShowAvatarBubble(content::WebContents* web_contents, |
355 const gfx::Rect& rect) = 0; | 361 const gfx::Rect& rect) = 0; |
356 | 362 |
357 // Shows the avatar bubble on the window frame off of the avatar button. | 363 // Shows the avatar bubble on the window frame off of the avatar button. |
358 virtual void ShowAvatarBubbleFromAvatarButton() = 0; | 364 virtual void ShowAvatarBubbleFromAvatarButton() = 0; |
359 | 365 |
360 // Show bubble for password generation positioned relative to |rect|. The | 366 // Show bubble for password generation positioned relative to |rect|. The |
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
406 | 412 |
407 // Returns the ToolbarView. | 413 // Returns the ToolbarView. |
408 virtual ToolbarView* GetToolbarView() const = 0; | 414 virtual ToolbarView* GetToolbarView() const = 0; |
409 #endif | 415 #endif |
410 | 416 |
411 protected: | 417 protected: |
412 virtual ~BrowserWindowTesting() {} | 418 virtual ~BrowserWindowTesting() {} |
413 }; | 419 }; |
414 | 420 |
415 #endif // CHROME_BROWSER_UI_BROWSER_WINDOW_H_ | 421 #endif // CHROME_BROWSER_UI_BROWSER_WINDOW_H_ |
OLD | NEW |