Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(87)

Side by Side Diff: content/browser/frame_host/render_frame_host_delegate.h

Issue 217183004: Migrate addMessageToConsole API to RenderFrame. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
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 "base/basictypes.h"
8 #include "content/common/content_export.h" 9 #include "content/common/content_export.h"
9 10
11 class GURL;
12
10 namespace IPC { 13 namespace IPC {
11 class Message; 14 class Message;
12 } 15 }
13 16
14 namespace content { 17 namespace content {
15 class RenderFrameHost; 18 class RenderFrameHost;
16 class WebContents; 19 class WebContents;
17 struct ContextMenuParams; 20 struct ContextMenuParams;
18 21
19 // An interface implemented by an object interested in knowing about the state 22 // An interface implemented by an object interested in knowing about the state
20 // of the RenderFrameHost. 23 // of the RenderFrameHost.
21 class CONTENT_EXPORT RenderFrameHostDelegate { 24 class CONTENT_EXPORT RenderFrameHostDelegate {
22 public: 25 public:
23 // This is used to give the delegate a chance to filter IPC messages. 26 // This is used to give the delegate a chance to filter IPC messages.
24 virtual bool OnMessageReceived(RenderFrameHost* render_frame_host, 27 virtual bool OnMessageReceived(RenderFrameHost* render_frame_host,
25 const IPC::Message& message); 28 const IPC::Message& message);
26 29
30 // Gets the URL that is currently being displayed, if there is one.
31 virtual const GURL& GetURL() const;
nasko 2014/03/28 23:05:05 The name of this method should be adjusted to matc
mkosiba (inactive) 2014/03/31 09:48:41 Done.
32
33 // A message was added to to the console.
34 virtual bool AddMessageToConsole(int32 level,
35 const base::string16& message,
36 int32 line_no,
37 const base::string16& source_id);
38
27 // Informs the delegate whenever a RenderFrameHost is created. 39 // Informs the delegate whenever a RenderFrameHost is created.
28 virtual void RenderFrameCreated(RenderFrameHost* render_frame_host) {} 40 virtual void RenderFrameCreated(RenderFrameHost* render_frame_host) {}
29 41
30 // Informs the delegate whenever a RenderFrameHost is deleted. 42 // Informs the delegate whenever a RenderFrameHost is deleted.
31 virtual void RenderFrameDeleted(RenderFrameHost* render_frame_host) {} 43 virtual void RenderFrameDeleted(RenderFrameHost* render_frame_host) {}
32 44
33 // The top-level RenderFrame began loading a new page. This corresponds to 45 // The top-level RenderFrame began loading a new page. This corresponds to
34 // Blink's notion of the throbber starting. 46 // Blink's notion of the throbber starting.
35 virtual void DidStartLoading(RenderFrameHost* render_frame_host) {} 47 virtual void DidStartLoading(RenderFrameHost* render_frame_host) {}
36 48
(...skipping 13 matching lines...) Expand all
50 // not a WebContents, returns NULL. 62 // not a WebContents, returns NULL.
51 virtual WebContents* GetAsWebContents(); 63 virtual WebContents* GetAsWebContents();
52 64
53 protected: 65 protected:
54 virtual ~RenderFrameHostDelegate() {} 66 virtual ~RenderFrameHostDelegate() {}
55 }; 67 };
56 68
57 } // namespace content 69 } // namespace content
58 70
59 #endif // CONTENT_BROWSER_FRAME_HOST_RENDER_FRAME_HOST_DELEGATE_H_ 71 #endif // CONTENT_BROWSER_FRAME_HOST_RENDER_FRAME_HOST_DELEGATE_H_
OLDNEW
« no previous file with comments | « no previous file | content/browser/frame_host/render_frame_host_delegate.cc » ('j') | content/common/frame_messages.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698