| Index: content/public/browser/web_contents_view_delegate.h
|
| diff --git a/content/public/browser/web_contents_view_delegate.h b/content/public/browser/web_contents_view_delegate.h
|
| index 7be6c6f6fc83ad2d43ee3b316692cecc0646e19f..cbc226781537a43c6c86cb5ab9203ea4504ebd94 100644
|
| --- a/content/public/browser/web_contents_view_delegate.h
|
| +++ b/content/public/browser/web_contents_view_delegate.h
|
| @@ -9,6 +9,8 @@
|
| #import <Cocoa/Cocoa.h>
|
| #endif
|
|
|
| +#include <vector>
|
| +
|
| #include "base/callback_forward.h"
|
| #include "content/common/content_export.h"
|
| #include "ui/gfx/native_widget_types.h"
|
| @@ -32,6 +34,7 @@ class RenderFrameHost;
|
| class RenderWidgetHost;
|
| class WebDragDestDelegate;
|
| struct ContextMenuParams;
|
| +struct MenuItem;
|
|
|
| // This interface allows a client to extend the functionality of the
|
| // WebContentsView implementation.
|
| @@ -59,8 +62,25 @@ class CONTENT_EXPORT WebContentsViewDelegate {
|
| virtual void TakeFocus(bool reverse);
|
| virtual void SizeChanged(const gfx::Size& size);
|
|
|
| - // Returns a newly-created delegate for the RenderWidgetHostViewMac, to handle
|
| - // events on the responder chain.
|
| +#if defined(USE_EXTERNAL_POPUP_MENU) && defined(USE_AURA)
|
| + // Shows a popup menu with the specified items.
|
| + // This method should call RenderFrameHost::DidSelectPopupMenuItem[s]() or
|
| + // RenderFrameHost::DidCancelPopupMenu() based on the user action.
|
| + virtual void ShowPopupMenu(RenderFrameHost* render_frame_host,
|
| + const gfx::Rect& bounds,
|
| + int item_height,
|
| + double item_font_size,
|
| + int selected_item,
|
| + const std::vector<MenuItem>& items,
|
| + bool right_aligned,
|
| + bool allow_multiple_selection) {}
|
| +
|
| + // Hides a popup menu opened by ShowPopupMenu().
|
| + virtual void HidePopupMenu() {}
|
| +#endif
|
| +
|
| +// Returns a newly-created delegate for the RenderWidgetHostViewMac, to handle
|
| +// events on the responder chain.
|
| #if defined(__OBJC__)
|
| virtual NSObject<RenderWidgetHostViewMacDelegate>*
|
| CreateRenderWidgetHostViewDelegate(
|
|
|