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 <vector> |
| 9 |
8 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
9 #include "base/i18n/rtl.h" | 11 #include "base/i18n/rtl.h" |
10 #include "content/common/content_export.h" | 12 #include "content/common/content_export.h" |
| 13 #include "content/common/frame_message_enums.h" |
11 #include "content/public/common/javascript_message_type.h" | 14 #include "content/public/common/javascript_message_type.h" |
12 #include "content/public/common/media_stream_request.h" | 15 #include "content/public/common/media_stream_request.h" |
13 #include "net/http/http_response_headers.h" | 16 #include "net/http/http_response_headers.h" |
14 | 17 |
| 18 #if defined(OS_WIN) |
| 19 #include "ui/gfx/native_widget_types.h" |
| 20 #endif |
| 21 |
15 class GURL; | 22 class GURL; |
16 | 23 |
17 namespace IPC { | 24 namespace IPC { |
18 class Message; | 25 class Message; |
19 } | 26 } |
20 | 27 |
21 namespace content { | 28 namespace content { |
22 class RenderFrameHost; | 29 class RenderFrameHost; |
23 class WebContents; | 30 class WebContents; |
| 31 struct AXEventNotificationDetails; |
24 struct ContextMenuParams; | 32 struct ContextMenuParams; |
25 | 33 |
26 // An interface implemented by an object interested in knowing about the state | 34 // An interface implemented by an object interested in knowing about the state |
27 // of the RenderFrameHost. | 35 // of the RenderFrameHost. |
28 class CONTENT_EXPORT RenderFrameHostDelegate { | 36 class CONTENT_EXPORT RenderFrameHostDelegate { |
29 public: | 37 public: |
30 // This is used to give the delegate a chance to filter IPC messages. | 38 // This is used to give the delegate a chance to filter IPC messages. |
31 virtual bool OnMessageReceived(RenderFrameHost* render_frame_host, | 39 virtual bool OnMessageReceived(RenderFrameHost* render_frame_host, |
32 const IPC::Message& message); | 40 const IPC::Message& message); |
33 | 41 |
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
115 // not a WebContents, returns NULL. | 123 // not a WebContents, returns NULL. |
116 virtual WebContents* GetAsWebContents(); | 124 virtual WebContents* GetAsWebContents(); |
117 | 125 |
118 // The render frame has requested access to media devices listed in | 126 // The render frame has requested access to media devices listed in |
119 // |request|, and the client should grant or deny that permission by | 127 // |request|, and the client should grant or deny that permission by |
120 // calling |callback|. | 128 // calling |callback|. |
121 virtual void RequestMediaAccessPermission( | 129 virtual void RequestMediaAccessPermission( |
122 const MediaStreamRequest& request, | 130 const MediaStreamRequest& request, |
123 const MediaResponseCallback& callback); | 131 const MediaResponseCallback& callback); |
124 | 132 |
| 133 // Get the accessibility mode for the WebContents that owns this frame. |
| 134 virtual AccessibilityMode GetAccessibilityMode() const; |
| 135 |
| 136 // Invoked when an accessibility event is received from the renderer. |
| 137 virtual void AccessibilityEventReceived( |
| 138 const std::vector<AXEventNotificationDetails>& details) {} |
| 139 |
| 140 #if defined(OS_WIN) |
| 141 // Returns the frame's parent's NativeViewAccessible. |
| 142 virtual gfx::NativeViewAccessible GetParentNativeViewAccessible(); |
| 143 #endif |
| 144 |
125 protected: | 145 protected: |
126 virtual ~RenderFrameHostDelegate() {} | 146 virtual ~RenderFrameHostDelegate() {} |
127 }; | 147 }; |
128 | 148 |
129 } // namespace content | 149 } // namespace content |
130 | 150 |
131 #endif // CONTENT_BROWSER_FRAME_HOST_RENDER_FRAME_HOST_DELEGATE_H_ | 151 #endif // CONTENT_BROWSER_FRAME_HOST_RENDER_FRAME_HOST_DELEGATE_H_ |
OLD | NEW |