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

Unified Diff: chrome/browser/ui/cocoa/apps/native_app_window_cocoa.h

Issue 23618036: Merge NOTIFICATION_RENDER_VIEW_HOST_CHANGED into NOTIFICATION_WEB_CONTENTS_SWAPPED. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix Created 7 years, 2 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/cocoa/apps/native_app_window_cocoa.h
diff --git a/chrome/browser/ui/cocoa/apps/native_app_window_cocoa.h b/chrome/browser/ui/cocoa/apps/native_app_window_cocoa.h
index a8108a7a0b244fb909b2bc7aa7fa74e7b839c8c9..d4621ddda0879eecfb11ef2973f45ef70336c90a 100644
--- a/chrome/browser/ui/cocoa/apps/native_app_window_cocoa.h
+++ b/chrome/browser/ui/cocoa/apps/native_app_window_cocoa.h
@@ -13,7 +13,7 @@
#include "base/mac/scoped_nsobject.h"
#include "base/memory/scoped_ptr.h"
#import "chrome/browser/ui/cocoa/browser_command_executor.h"
-#include "content/public/browser/notification_registrar.h"
+#include "content/public/browser/web_contents_observer.h"
#include "extensions/common/draggable_region.h"
#include "ui/gfx/rect.h"
@@ -41,7 +41,8 @@ class SkRegion;
@end
// Cocoa bridge to AppWindow.
-class NativeAppWindowCocoa : public apps::NativeAppWindow {
+class NativeAppWindowCocoa : public apps::NativeAppWindow,
+ public content::WebContentsObserver {
public:
NativeAppWindowCocoa(apps::ShellWindow* shell_window,
const apps::ShellWindow::CreateParams& params);
@@ -122,9 +123,13 @@ class NativeAppWindowCocoa : public apps::NativeAppWindow {
const std::vector<extensions::DraggableRegion>& regions) OVERRIDE;
virtual void HandleKeyboardEvent(
const content::NativeWebKeyboardEvent& event) OVERRIDE;
- virtual void RenderViewHostChanged() OVERRIDE;
virtual gfx::Insets GetFrameInsets() const OVERRIDE;
+ // WebContentsObserver implementation.
+ virtual void RenderViewHostChanged(
+ content::RenderViewHost* old_host,
+ content::RenderViewHost* new_host) OVERRIDE;
+
// These are used to simulate Mac-style hide/show. Since windows can be hidden
// and shown using the app.window API, this sets is_hidden_with_app_ to
// differentiate the reason a window was hidden.
« no previous file with comments | « chrome/browser/task_manager/tab_contents_resource_provider.cc ('k') | chrome/browser/ui/cocoa/apps/native_app_window_cocoa.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698