From 807bfceada33743cad3308af48c538d7d7515495 Mon Sep 17 00:00:00 2001 From: "brettw@google.com" Date: Tue, 14 Oct 2008 16:42:25 +0000 Subject: Move more view stuff out of WebContents. This moves context menus and info bars. I removed the associated functions on TabContents, and have callers call directly through to the view when the care about mucking with the info bar (which is busted, IMO). Review URL: http://codereview.chromium.org/7245 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@3346 0039d316-1c4b-4281-b951-d872f2087c98 --- chrome/browser/web_contents_view_win.h | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'chrome/browser/web_contents_view_win.h') diff --git a/chrome/browser/web_contents_view_win.h b/chrome/browser/web_contents_view_win.h index 09e80ff..75af28b 100644 --- a/chrome/browser/web_contents_view_win.h +++ b/chrome/browser/web_contents_view_win.h @@ -8,6 +8,8 @@ #include "chrome/browser/web_contents_view.h" #include "chrome/views/hwnd_view_container.h" +class InfoBarView; +class InfoBarMessageView; struct WebDropData; class WebDropTarget; @@ -35,10 +37,14 @@ class WebContentsViewWin : public WebContentsView, virtual void GetContainerBounds(gfx::Rect* out) const; virtual void StartDragging(const WebDropData& drop_data); virtual void DetachPluginWindows(); + virtual void DisplayErrorInInfoBar(const std::wstring& text); virtual void SetInfoBarVisible(bool visible); virtual bool IsInfoBarVisible() const; virtual InfoBarView* GetInfoBarView(); virtual void UpdateDragCursor(bool is_drop_target); + virtual void ShowContextMenu( + const ViewHostMsg_ContextMenu_Params& params); + virtual void HandleKeyboardEvent(const WebKeyboardEvent& event); private: // Windows events ------------------------------------------------------------ @@ -77,6 +83,11 @@ class WebContentsViewWin : public WebContentsView, // InfoBarView, lazily created. scoped_ptr info_bar_view_; + // Info bar for crashed plugin message. + // IMPORTANT: This instance is owned by the InfoBarView. It is valid + // only if InfoBarView::GetChildIndex for this view is valid. + InfoBarMessageView* error_info_bar_message_; + // Whether the info bar view is visible. bool info_bar_visible_; -- cgit v1.1