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

Side by Side Diff: chrome/browser/views/frame/opaque_frame.h

Issue 10896: Re-do the way browser windows are shown:... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 12 years, 1 month 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
OLDNEW
1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-2008 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_VIEWS_FRAME_OPAQUE_FRAME_H_ 5 #ifndef CHROME_BROWSER_VIEWS_FRAME_OPAQUE_FRAME_H_
6 #define CHROME_BROWSER_VIEWS_FRAME_OPAQUE_FRAME_H_ 6 #define CHROME_BROWSER_VIEWS_FRAME_OPAQUE_FRAME_H_
7 7
8 #include "chrome/browser/views/frame/browser_frame.h" 8 #include "chrome/browser/views/frame/browser_frame.h"
9 #include "chrome/views/custom_frame_window.h" 9 #include "chrome/views/custom_frame_window.h"
10 10
(...skipping 11 matching lines...) Expand all
22 // OpaqueNonClientView provides the window frame on Windows XP and on Windows 22 // OpaqueNonClientView provides the window frame on Windows XP and on Windows
23 // Vista when DWM desktop compositing is disabled. The window title and 23 // Vista when DWM desktop compositing is disabled. The window title and
24 // borders are provided with bitmaps. 24 // borders are provided with bitmaps.
25 // 25 //
26 class OpaqueFrame : public BrowserFrame, 26 class OpaqueFrame : public BrowserFrame,
27 public views::CustomFrameWindow { 27 public views::CustomFrameWindow {
28 public: 28 public:
29 explicit OpaqueFrame(BrowserView* browser_view); 29 explicit OpaqueFrame(BrowserView* browser_view);
30 virtual ~OpaqueFrame(); 30 virtual ~OpaqueFrame();
31 31
32 void Init();
33
32 protected: 34 protected:
33 // Overridden from BrowserFrame: 35 // Overridden from BrowserFrame:
34 virtual gfx::Rect GetWindowBoundsForClientBounds( 36 virtual gfx::Rect GetWindowBoundsForClientBounds(
35 const gfx::Rect& client_bounds); 37 const gfx::Rect& client_bounds);
36 virtual void SizeToContents(const gfx::Rect& contents_bounds); 38 virtual void SizeToContents(const gfx::Rect& contents_bounds);
37 virtual gfx::Rect GetBoundsForTabStrip(TabStrip* tabstrip) const; 39 virtual gfx::Rect GetBoundsForTabStrip(TabStrip* tabstrip) const;
38 virtual void UpdateThrobber(bool running); 40 virtual void UpdateThrobber(bool running);
39 virtual views::Window* GetWindow(); 41 virtual views::Window* GetWindow();
40 42
41 // Overridden from views::CustomFrameWindow: 43 // Overridden from views::CustomFrameWindow:
42 virtual void UpdateWindowIcon(); 44 virtual void UpdateWindowIcon();
45 virtual int GetShowState() const;
43 46
44 // Overridden from views::ContainerWin: 47 // Overridden from views::ContainerWin:
45 virtual bool AcceleratorPressed(views::Accelerator* accelerator); 48 virtual bool AcceleratorPressed(views::Accelerator* accelerator);
46 virtual bool GetAccelerator(int cmd_id, views::Accelerator* accelerator); 49 virtual bool GetAccelerator(int cmd_id, views::Accelerator* accelerator);
47 virtual void OnEndSession(BOOL ending, UINT logoff); 50 virtual void OnEndSession(BOOL ending, UINT logoff);
48 virtual void OnInitMenuPopup(HMENU menu, UINT position, BOOL is_system_menu); 51 virtual void OnInitMenuPopup(HMENU menu, UINT position, BOOL is_system_menu);
49 virtual LRESULT OnMouseActivate(HWND window, 52 virtual LRESULT OnMouseActivate(HWND window,
50 UINT hittest_code, 53 UINT hittest_code,
51 UINT message); 54 UINT message);
52 virtual void OnMove(const CPoint& point); 55 virtual void OnMove(const CPoint& point);
53 virtual void OnMoving(UINT param, const RECT* new_bounds); 56 virtual void OnMoving(UINT param, const RECT* new_bounds);
54 virtual LRESULT OnNCActivate(BOOL active); 57 virtual LRESULT OnNCActivate(BOOL active);
55 virtual void OnSysCommand(UINT notification_code, CPoint click); 58 virtual void OnSysCommand(UINT notification_code, CPoint click);
56 59
57 private: 60 private:
58 // Return a pointer to the concrete type of our non-client view. 61 // Return a pointer to the concrete type of our non-client view.
59 OpaqueNonClientView* GetOpaqueNonClientView() const; 62 OpaqueNonClientView* GetOpaqueNonClientView() const;
60 63
61 // The BrowserView is our ClientView. This is a pointer to it. 64 // The BrowserView is our ClientView. This is a pointer to it.
62 BrowserView* browser_view_; 65 BrowserView* browser_view_;
63 66
64 DISALLOW_EVIL_CONSTRUCTORS(OpaqueFrame); 67 DISALLOW_EVIL_CONSTRUCTORS(OpaqueFrame);
65 }; 68 };
66 69
67 #endif // #ifndef CHROME_BROWSER_VIEWS_FRAME_OPAQUE_FRAME_H_ 70 #endif // #ifndef CHROME_BROWSER_VIEWS_FRAME_OPAQUE_FRAME_H_
68 71
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698