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

Side by Side Diff: content/browser/web_contents/aura/constrained_windows_observer.h

Issue 54623007: Make code path for bounds changes getting to renderer less brittle (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Experimenting with single observer design Created 7 years 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 | « no previous file | content/browser/web_contents/aura/constrained_windows_observer.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 // Copyright (c) 2013 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 CONTENT_BROWSER_WEB_CONTENTS_AURA_CONSTRAINED_WINDOWS_OBSERVER_H__
6 #define CONTENT_BROWSER_WEB_CONTENTS_AURA_CONSTRAINED_WINDOWS_OBSERVER_H__
7
8 #include "base/compiler_specific.h"
9 #include "content/common/content_export.h"
10 #include "ui/aura/window_observer.h"
11
12 namespace content {
13
14 class WebContentsViewAura;
15
16 class CONTENT_EXPORT ConstrainedWindowsObserver
17 : public aura::WindowObserver {
18 public:
19 ConstrainedWindowsObserver(WebContentsViewAura* view);
20 virtual ~ConstrainedWindowsObserver();
21
22 // Overridden from aura::WindowObserver:
23 virtual void OnWindowAdded(aura::Window* new_window) OVERRIDE;
24 virtual void OnWillRemoveWindow(aura::Window* window) OVERRIDE;
25 virtual void OnWindowVisibilityChanged(aura::Window* window,
26 bool visible) OVERRIDE;
27 virtual void OnWindowParentChanged(aura::Window* window,
28 aura::Window* parent) OVERRIDE;
29 virtual void OnWindowBoundsChanged(aura::Window* window,
30 const gfx::Rect& old_bounds,
31 const gfx::Rect& new_bounds) OVERRIDE;
32 virtual void OnWindowAddedToRootWindow(aura::Window* window) OVERRIDE;
33 virtual void OnWindowRemovingFromRootWindow(aura::Window* window) OVERRIDE;
34
35 private:
36 void UpdateConstrainedWindows(aura::Window* exclude);
37
38 WebContentsViewAura* view_;
39 aura::Window* constrained_parent_;
40
41 DISALLOW_COPY_AND_ASSIGN(ConstrainedWindowsObserver);
42 };
43
44 } //namespace content
45 #endif // CONTENT_BROWSER_WEB_CONTENTS_AURA_CONSTRAINED_WINDOWS_OBSERVER_H__
OLDNEW
« no previous file with comments | « no previous file | content/browser/web_contents/aura/constrained_windows_observer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698