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

Unified Diff: content/public/browser/web_contents_view_mac_delegate.h

Issue 9307063: Split TabContentsViewMac. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: deps fix Created 8 years, 11 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: content/public/browser/web_contents_view_mac_delegate.h
diff --git a/content/public/browser/web_contents_view_mac_delegate.h b/content/public/browser/web_contents_view_mac_delegate.h
new file mode 100644
index 0000000000000000000000000000000000000000..44867eacc78c3f553e5cdcd67d439e4021e4ae6b
--- /dev/null
+++ b/content/public/browser/web_contents_view_mac_delegate.h
@@ -0,0 +1,47 @@
+// Copyright (c) 2012 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_PUBLIC_BROWSER_WEB_CONTENTS_VIEW_MAC_DELEGATE_H_
+#define CONTENT_PUBLIC_BROWSER_WEB_CONTENTS_VIEW_MAC_DELEGATE_H_
+#pragma once
+
+#import <Cocoa/Cocoa.h>
+
+#include "content/common/content_export.h"
+
+struct ContextMenuParams;
+class RenderWidgetHost;
+@protocol RenderWidgetHostViewMacDelegate;
+
+namespace content {
+
+class WebDragDestDelegate;
+
+// This interface allows a client to extend the functionality of
+// WebContentsViewMac.
+
jochen (gone - plz use gerrit) 2012/02/03 00:13:33 nit. no empty line?
Avi (use Gerrit) 2012/02/03 01:18:53 Done.
+class CONTENT_EXPORT WebContentsViewMacDelegate {
+ public:
+ virtual ~WebContentsViewMacDelegate() {}
+
+ // Returns a newly-created delegate for the RenderWidgetHostViewMac, to handle
+ // events on the responder chain.
+ virtual NSObject<RenderWidgetHostViewMacDelegate>*
+ CreateRenderWidgetHostViewDelegate(
+ RenderWidgetHost* render_widget_host) = 0;
+
+ // Returns a delegate to process drags not handled by content.
+ virtual WebDragDestDelegate* DragDelegate() = 0;
+
+ // Shows a context menu.
+ virtual void ShowContextMenu(const ContextMenuParams& params) = 0;
jam 2012/02/03 00:29:15 i think this isn't needed because WebContentsDeleg
Avi (use Gerrit) 2012/02/03 01:18:53 Look at the implementation of this. It's the TCVs
jam 2012/02/03 07:59:17 RenderViewHost will call TabContentsViewMac::ShowC
+
+ // Notifications that the native view was created/destroyed.
+ virtual void NativeViewCreated(NSView* view) = 0;
+ virtual void NativeViewDestroyed(NSView* view) = 0;
+};
+
+} // namespace content
+
+#endif // CONTENT_PUBLIC_BROWSER_WEB_CONTENTS_VIEW_MAC_DELEGATE_H_

Powered by Google App Engine
This is Rietveld 408576698