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_PUBLIC_RENDERER_RENDER_FRAME_OBSERVER_H_ | 5 #ifndef CONTENT_PUBLIC_RENDERER_RENDER_FRAME_OBSERVER_H_ |
6 #define CONTENT_PUBLIC_RENDERER_RENDER_FRAME_OBSERVER_H_ | 6 #define CONTENT_PUBLIC_RENDERER_RENDER_FRAME_OBSERVER_H_ |
7 | 7 |
8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
9 #include "base/compiler_specific.h" | 9 #include "base/compiler_specific.h" |
10 #include "base/strings/string16.h" | 10 #include "base/strings/string16.h" |
11 #include "content/common/content_export.h" | 11 #include "content/common/content_export.h" |
12 #include "ipc/ipc_listener.h" | 12 #include "ipc/ipc_listener.h" |
13 #include "ipc/ipc_sender.h" | 13 #include "ipc/ipc_sender.h" |
14 #include "url/gurl.h" | |
jochen (gone - plz use gerrit)
2014/10/02 09:24:03
should be enough to forward declare GURL, no?
| |
14 #include "v8/include/v8.h" | 15 #include "v8/include/v8.h" |
15 | 16 |
16 namespace blink { | 17 namespace blink { |
17 class WebFrame; | 18 class WebFrame; |
18 struct WebURLError; | 19 struct WebURLError; |
19 } | 20 } |
20 | 21 |
21 namespace content { | 22 namespace content { |
22 | 23 |
23 class RendererPpapiHost; | 24 class RendererPpapiHost; |
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
67 // "\n at function_name (source:line_number:column_number)"). | 68 // "\n at function_name (source:line_number:column_number)"). |
68 virtual void DetailedConsoleMessageAdded(const base::string16& message, | 69 virtual void DetailedConsoleMessageAdded(const base::string16& message, |
69 const base::string16& source, | 70 const base::string16& source, |
70 const base::string16& stack_trace, | 71 const base::string16& stack_trace, |
71 int32 line_number, | 72 int32 line_number, |
72 int32 severity_level) {} | 73 int32 severity_level) {} |
73 | 74 |
74 // Called when a compositor frame has committed. | 75 // Called when a compositor frame has committed. |
75 virtual void DidCommitCompositorFrame() {} | 76 virtual void DidCommitCompositorFrame() {} |
76 | 77 |
78 // Returns a user agent override specific for |url|, or empty string if | |
79 // default user agent should be used. | |
80 virtual std::string GetUserAgentOverrideForURL(const GURL& url); | |
81 | |
77 // IPC::Listener implementation. | 82 // IPC::Listener implementation. |
78 virtual bool OnMessageReceived(const IPC::Message& message) OVERRIDE; | 83 virtual bool OnMessageReceived(const IPC::Message& message) OVERRIDE; |
79 | 84 |
80 // IPC::Sender implementation. | 85 // IPC::Sender implementation. |
81 virtual bool Send(IPC::Message* message) OVERRIDE; | 86 virtual bool Send(IPC::Message* message) OVERRIDE; |
82 | 87 |
83 RenderFrame* render_frame() const; | 88 RenderFrame* render_frame() const; |
84 int routing_id() const { return routing_id_; } | 89 int routing_id() const { return routing_id_; } |
85 | 90 |
86 protected: | 91 protected: |
(...skipping 10 matching lines...) Expand all Loading... | |
97 RenderFrame* render_frame_; | 102 RenderFrame* render_frame_; |
98 // The routing ID of the associated RenderFrame. | 103 // The routing ID of the associated RenderFrame. |
99 int routing_id_; | 104 int routing_id_; |
100 | 105 |
101 DISALLOW_COPY_AND_ASSIGN(RenderFrameObserver); | 106 DISALLOW_COPY_AND_ASSIGN(RenderFrameObserver); |
102 }; | 107 }; |
103 | 108 |
104 } // namespace content | 109 } // namespace content |
105 | 110 |
106 #endif // CONTENT_PUBLIC_RENDERER_RENDER_FRAME_OBSERVER_H_ | 111 #endif // CONTENT_PUBLIC_RENDERER_RENDER_FRAME_OBSERVER_H_ |
OLD | NEW |