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 3// found in the LICENSE file. 4 5#ifndef CHROME_BROWSER_UI_VIEWS_FRAME_BROWSER_DESKTOP_WINDOW_TREE_HOST_H_ 6#define CHROME_BROWSER_UI_VIEWS_FRAME_BROWSER_DESKTOP_WINDOW_TREE_HOST_H_ 7 8class BrowserFrame; 9class BrowserView; 10namespace gfx { 11class Rect; 12} 13namespace views { 14class DesktopNativeWidgetAura; 15class DesktopWindowTreeHost; 16namespace internal { 17class NativeWidgetDelegate; 18} 19} 20 21// Interface to a platform specific browser frame implementation. The object 22// implementing this interface will also implement views::DesktopWindowTreeHost. 23class BrowserDesktopWindowTreeHost { 24 public: 25 // BDRWH is owned by the RootWindow. 26 static BrowserDesktopWindowTreeHost* CreateBrowserDesktopWindowTreeHost( 27 views::internal::NativeWidgetDelegate* native_widget_delegate, 28 views::DesktopNativeWidgetAura* desktop_native_widget_aura, 29 BrowserView* browser_view, 30 BrowserFrame* browser_frame); 31 32 virtual views::DesktopWindowTreeHost* AsDesktopWindowTreeHost() = 0; 33 34 virtual int GetMinimizeButtonOffset() const = 0; 35 36 // Returns true if the OS takes care of showing the system menu. Returning 37 // false means BrowserFrame handles showing the system menu. 38 virtual bool UsesNativeSystemMenu() const = 0; 39}; 40 41 42#endif // CHROME_BROWSER_UI_VIEWS_FRAME_BROWSER_DESKTOP_WINDOW_TREE_HOST_H_ 43