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

Side by Side Diff: chrome/browser/ui/panels/panel_view.h

Issue 10834079: views: Extract Widget observer into its own header file. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 4 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 | « chrome/browser/ui/panels/panel_browser_view.h ('k') | chrome/browser/ui/panels/panel_view.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 #ifndef CHROME_BROWSER_UI_PANELS_PANEL_VIEW_H_ 5 #ifndef CHROME_BROWSER_UI_PANELS_PANEL_VIEW_H_
6 #define CHROME_BROWSER_UI_PANELS_PANEL_VIEW_H_ 6 #define CHROME_BROWSER_UI_PANELS_PANEL_VIEW_H_
7 7
8 #include "base/memory/scoped_ptr.h" 8 #include "base/memory/scoped_ptr.h"
9 #include "chrome/browser/ui/panels/native_panel.h" 9 #include "chrome/browser/ui/panels/native_panel.h"
10 #include "ui/base/animation/animation_delegate.h" 10 #include "ui/base/animation/animation_delegate.h"
11 #include "ui/views/widget/widget.h"
12 #include "ui/views/widget/widget_delegate.h" 11 #include "ui/views/widget/widget_delegate.h"
12 #include "ui/views/widget/widget_observer.h"
13 13
14 class Panel; 14 class Panel;
15 class PanelBoundsAnimation; 15 class PanelBoundsAnimation;
16 class PanelFrameView; 16 class PanelFrameView;
17 class TaskbarWindowThumbnailerWin; 17 class TaskbarWindowThumbnailerWin;
18 18
19 namespace views { 19 namespace views {
20 class WebView; 20 class WebView;
21 } 21 }
22 22
23 class PanelView : public NativePanel, 23 class PanelView : public NativePanel,
24 public views::Widget::Observer, 24 public views::WidgetObserver,
25 public views::WidgetDelegateView, 25 public views::WidgetDelegateView,
26 public ui::AnimationDelegate { 26 public ui::AnimationDelegate {
27 public: 27 public:
28 // The size of inside area used for mouse resizing. 28 // The size of inside area used for mouse resizing.
29 static const int kResizeInsideBoundsSize = 5; 29 static const int kResizeInsideBoundsSize = 5;
30 30
31 PanelView(Panel* panel, const gfx::Rect& bounds); 31 PanelView(Panel* panel, const gfx::Rect& bounds);
32 virtual ~PanelView(); 32 virtual ~PanelView();
33 33
34 // Overridden from NativePanel: 34 // Overridden from NativePanel:
(...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after
121 virtual void DeleteDelegate() OVERRIDE; 121 virtual void DeleteDelegate() OVERRIDE;
122 virtual void OnWindowBeginUserBoundsChange() OVERRIDE; 122 virtual void OnWindowBeginUserBoundsChange() OVERRIDE;
123 virtual void OnWindowEndUserBoundsChange() OVERRIDE; 123 virtual void OnWindowEndUserBoundsChange() OVERRIDE;
124 124
125 // Overridden from views::View: 125 // Overridden from views::View:
126 virtual void Layout() OVERRIDE; 126 virtual void Layout() OVERRIDE;
127 virtual gfx::Size GetMinimumSize() OVERRIDE; 127 virtual gfx::Size GetMinimumSize() OVERRIDE;
128 virtual gfx::Size GetMaximumSize() OVERRIDE; 128 virtual gfx::Size GetMaximumSize() OVERRIDE;
129 virtual bool AcceleratorPressed(const ui::Accelerator& accelerator) OVERRIDE; 129 virtual bool AcceleratorPressed(const ui::Accelerator& accelerator) OVERRIDE;
130 130
131 // Overridden from views::Widget::Observer 131 // Overridden from views::WidgetObserver:
132 virtual void OnWidgetActivationChanged(views::Widget* widget, 132 virtual void OnWidgetActivationChanged(views::Widget* widget,
133 bool active) OVERRIDE; 133 bool active) OVERRIDE;
134 134
135 // Overridden from AnimationDelegate: 135 // Overridden from AnimationDelegate:
136 virtual void AnimationEnded(const ui::Animation* animation) OVERRIDE; 136 virtual void AnimationEnded(const ui::Animation* animation) OVERRIDE;
137 virtual void AnimationProgressed(const ui::Animation* animation) OVERRIDE; 137 virtual void AnimationProgressed(const ui::Animation* animation) OVERRIDE;
138 138
139 void UpdateLoadingAnimations(bool should_animate); 139 void UpdateLoadingAnimations(bool should_animate);
140 void UpdateWindowTitle(); 140 void UpdateWindowTitle();
141 void UpdateWindowIcon(); 141 void UpdateWindowIcon();
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after
193 193
194 #if defined(OS_WIN) && !defined(USE_ASH) && !defined(USE_AURA) 194 #if defined(OS_WIN) && !defined(USE_ASH) && !defined(USE_AURA)
195 // Used to provide custom taskbar thumbnail for Windows 7 and later. 195 // Used to provide custom taskbar thumbnail for Windows 7 and later.
196 scoped_ptr<TaskbarWindowThumbnailerWin> thumbnailer_; 196 scoped_ptr<TaskbarWindowThumbnailerWin> thumbnailer_;
197 #endif 197 #endif
198 198
199 DISALLOW_COPY_AND_ASSIGN(PanelView); 199 DISALLOW_COPY_AND_ASSIGN(PanelView);
200 }; 200 };
201 201
202 #endif // CHROME_BROWSER_UI_PANELS_PANEL_VIEW_H_ 202 #endif // CHROME_BROWSER_UI_PANELS_PANEL_VIEW_H_
OLDNEW
« no previous file with comments | « chrome/browser/ui/panels/panel_browser_view.h ('k') | chrome/browser/ui/panels/panel_view.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698