OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef CONTENT_BROWSER_FRAME_HOST_RENDER_FRAME_HOST_DELEGATE_H_ | 5 #ifndef CONTENT_BROWSER_FRAME_HOST_RENDER_FRAME_HOST_DELEGATE_H_ |
6 #define CONTENT_BROWSER_FRAME_HOST_RENDER_FRAME_HOST_DELEGATE_H_ | 6 #define CONTENT_BROWSER_FRAME_HOST_RENDER_FRAME_HOST_DELEGATE_H_ |
7 | 7 |
8 #include <stdint.h> | 8 #include <stdint.h> |
9 | 9 |
10 #include <vector> | 10 #include <vector> |
(...skipping 20 matching lines...) Expand all Loading... |
31 | 31 |
32 namespace content { | 32 namespace content { |
33 class GeolocationServiceContext; | 33 class GeolocationServiceContext; |
34 class InterstitialPage; | 34 class InterstitialPage; |
35 class PageState; | 35 class PageState; |
36 class RenderFrameHost; | 36 class RenderFrameHost; |
37 class WakeLockServiceContext; | 37 class WakeLockServiceContext; |
38 class WebContents; | 38 class WebContents; |
39 struct AXEventNotificationDetails; | 39 struct AXEventNotificationDetails; |
40 struct ContextMenuParams; | 40 struct ContextMenuParams; |
| 41 struct FileChooserParams; |
41 struct TransitionLayerData; | 42 struct TransitionLayerData; |
42 | 43 |
43 // An interface implemented by an object interested in knowing about the state | 44 // An interface implemented by an object interested in knowing about the state |
44 // of the RenderFrameHost. | 45 // of the RenderFrameHost. |
45 class CONTENT_EXPORT RenderFrameHostDelegate { | 46 class CONTENT_EXPORT RenderFrameHostDelegate { |
46 public: | 47 public: |
47 // This is used to give the delegate a chance to filter IPC messages. | 48 // This is used to give the delegate a chance to filter IPC messages. |
48 virtual bool OnMessageReceived(RenderFrameHost* render_frame_host, | 49 virtual bool OnMessageReceived(RenderFrameHost* render_frame_host, |
49 const IPC::Message& message); | 50 const IPC::Message& message); |
50 | 51 |
(...skipping 23 matching lines...) Expand all Loading... |
74 const base::string16& message, | 75 const base::string16& message, |
75 const base::string16& default_prompt, | 76 const base::string16& default_prompt, |
76 const GURL& frame_url, | 77 const GURL& frame_url, |
77 JavaScriptMessageType type, | 78 JavaScriptMessageType type, |
78 IPC::Message* reply_msg) {} | 79 IPC::Message* reply_msg) {} |
79 | 80 |
80 virtual void RunBeforeUnloadConfirm(RenderFrameHost* render_frame_host, | 81 virtual void RunBeforeUnloadConfirm(RenderFrameHost* render_frame_host, |
81 bool is_reload, | 82 bool is_reload, |
82 IPC::Message* reply_msg) {} | 83 IPC::Message* reply_msg) {} |
83 | 84 |
| 85 // Called when a file selection is to be done. |
| 86 virtual void RunFileChooser(RenderFrameHost* render_frame_host, |
| 87 const FileChooserParams& params) {} |
| 88 |
84 // Another page accessed the top-level initial empty document, which means it | 89 // Another page accessed the top-level initial empty document, which means it |
85 // is no longer safe to display a pending URL without risking a URL spoof. | 90 // is no longer safe to display a pending URL without risking a URL spoof. |
86 virtual void DidAccessInitialDocument() {} | 91 virtual void DidAccessInitialDocument() {} |
87 | 92 |
88 // The frame changed its window.name property. | 93 // The frame changed its window.name property. |
89 virtual void DidChangeName(RenderFrameHost* render_frame_host, | 94 virtual void DidChangeName(RenderFrameHost* render_frame_host, |
90 const std::string& name) {} | 95 const std::string& name) {} |
91 | 96 |
92 // The onload handler in the frame has completed. Only called for the top- | 97 // The onload handler in the frame has completed. Only called for the top- |
93 // level frame. | 98 // level frame. |
(...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
184 virtual std::unique_ptr<WebUIImpl> CreateWebUIForRenderFrameHost( | 189 virtual std::unique_ptr<WebUIImpl> CreateWebUIForRenderFrameHost( |
185 const GURL& url); | 190 const GURL& url); |
186 | 191 |
187 protected: | 192 protected: |
188 virtual ~RenderFrameHostDelegate() {} | 193 virtual ~RenderFrameHostDelegate() {} |
189 }; | 194 }; |
190 | 195 |
191 } // namespace content | 196 } // namespace content |
192 | 197 |
193 #endif // CONTENT_BROWSER_FRAME_HOST_RENDER_FRAME_HOST_DELEGATE_H_ | 198 #endif // CONTENT_BROWSER_FRAME_HOST_RENDER_FRAME_HOST_DELEGATE_H_ |
OLD | NEW |