Home | History | Annotate | Download | only in frame
      1 // Copyright (c) 2010 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_NON_CLIENT_FRAME_VIEW_H_
      6 #define CHROME_BROWSER_UI_VIEWS_FRAME_BROWSER_NON_CLIENT_FRAME_VIEW_H_
      7 #pragma once
      8 
      9 #include "views/window/non_client_view.h"
     10 
     11 class BrowserFrame;
     12 class BrowserView;
     13 
     14 // A specialization of the NonClientFrameView object that provides additional
     15 // Browser-specific methods.
     16 class BrowserNonClientFrameView : public views::NonClientFrameView {
     17  public:
     18   BrowserNonClientFrameView() : NonClientFrameView() {}
     19   virtual ~BrowserNonClientFrameView() {}
     20 
     21   // Returns the bounds within which the TabStrip should be laid out.
     22   virtual gfx::Rect GetBoundsForTabStrip(views::View* tabstrip) const = 0;
     23 
     24   // Returns the y coordinate within the window at which the horizontal TabStrip
     25   // begins, or (in vertical tabs mode) would begin.  If |restored| is true,
     26   // this is calculated as if we were in restored mode regardless of the current
     27   // mode.  This is used to correctly align theme images.
     28   virtual int GetHorizontalTabStripVerticalOffset(bool restored) const = 0;
     29 
     30   // Updates the throbber.
     31   virtual void UpdateThrobber(bool running) = 0;
     32 };
     33 
     34 namespace browser {
     35 
     36 // Provided by a browser_non_client_frame_view_factory_*.cc implementation
     37 BrowserNonClientFrameView* CreateBrowserNonClientFrameView(
     38     BrowserFrame* frame, BrowserView* browser_view);
     39 
     40 }  // browser
     41 
     42 #endif  // CHROME_BROWSER_UI_VIEWS_FRAME_BROWSER_NON_CLIENT_FRAME_VIEW_H_
     43