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

Unified 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: Rebasing and responding to comments Created 7 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 side-by-side diff with in-line comments
Download patch
Index: content/browser/web_contents/aura/constrained_windows_observer.h
diff --git a/content/browser/web_contents/aura/constrained_windows_observer.h b/content/browser/web_contents/aura/constrained_windows_observer.h
new file mode 100644
index 0000000000000000000000000000000000000000..e510b93593f7c9488d13c3929f95ee1be7b33427
--- /dev/null
+++ b/content/browser/web_contents/aura/constrained_windows_observer.h
@@ -0,0 +1,42 @@
+// Copyright (c) 2013 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef CONTENT_BROWSER_WEB_CONTENTS_AURA_CONSTRAINED_WINDOWS_OBSERVER_H__
+#define CONTENT_BROWSER_WEB_CONTENTS_AURA_CONSTRAINED_WINDOWS_OBSERVER_H__
+
+#include "base/compiler_specific.h"
+#include "content/common/content_export.h"
+#include "ui/aura/window_observer.h"
+
+namespace content {
+
+class WebContentsViewAura;
+
rharrison 2013/11/12 22:16:29 jam, Since this class should go away with NPAPI su
+class CONTENT_EXPORT ConstrainedWindowsObserver
+ : public aura::WindowObserver {
+public:
+ ConstrainedWindowsObserver(WebContentsViewAura* view);
+ virtual ~ConstrainedWindowsObserver();
+
+ // Overridden from aura::WindowObserver:
+ virtual void OnWindowAdded(aura::Window* new_window) OVERRIDE;
+ virtual void OnWillRemoveWindow(aura::Window* window) OVERRIDE;
+ virtual void OnWindowVisibilityChanged(aura::Window* window,
+ bool visible) OVERRIDE;
+ virtual void OnWindowParentChanged(aura::Window* window,
+ aura::Window* parent) OVERRIDE;
+ virtual void OnWindowBoundsChanged(aura::Window* window,
+ const gfx::Rect& old_bounds,
+ const gfx::Rect& new_bounds) OVERRIDE;
+private:
+ void UpdateConstrainedWindows(aura::Window* exclude);
+
+ WebContentsViewAura* view_;
+ aura::Window* parent_;
+
+ DISALLOW_COPY_AND_ASSIGN(ConstrainedWindowsObserver);
+};
+
+} //namespace content
+#endif // CONTENT_BROWSER_WEB_CONTENTS_AURA_CONSTRAINED_WINDOWS_OBSERVER_H__

Powered by Google App Engine
This is Rietveld 408576698