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

Side by Side Diff: chrome/browser/plugins/plugin_observer.h

Issue 253013002: Pass RenderFrameHost to WebContentObservers' message handlers (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fixed Android tests Created 6 years, 7 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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 CHROME_BROWSER_PLUGINS_PLUGIN_OBSERVER_H_ 5 #ifndef CHROME_BROWSER_PLUGINS_PLUGIN_OBSERVER_H_
6 #define CHROME_BROWSER_PLUGINS_PLUGIN_OBSERVER_H_ 6 #define CHROME_BROWSER_PLUGINS_PLUGIN_OBSERVER_H_
7 7
8 #include "base/memory/scoped_ptr.h" 8 #include "base/memory/scoped_ptr.h"
9 #include "base/memory/weak_ptr.h" 9 #include "base/memory/weak_ptr.h"
10 #include "content/public/browser/web_contents_observer.h" 10 #include "content/public/browser/web_contents_observer.h"
(...skipping 23 matching lines...) Expand all
34 class PluginObserver : public content::WebContentsObserver, 34 class PluginObserver : public content::WebContentsObserver,
35 public content::WebContentsUserData<PluginObserver> { 35 public content::WebContentsUserData<PluginObserver> {
36 public: 36 public:
37 virtual ~PluginObserver(); 37 virtual ~PluginObserver();
38 38
39 // content::WebContentsObserver implementation. 39 // content::WebContentsObserver implementation.
40 virtual void RenderFrameCreated( 40 virtual void RenderFrameCreated(
41 content::RenderFrameHost* render_frame_host) OVERRIDE; 41 content::RenderFrameHost* render_frame_host) OVERRIDE;
42 virtual void PluginCrashed(const base::FilePath& plugin_path, 42 virtual void PluginCrashed(const base::FilePath& plugin_path,
43 base::ProcessId plugin_pid) OVERRIDE; 43 base::ProcessId plugin_pid) OVERRIDE;
44 virtual bool OnMessageReceived(
45 const IPC::Message& message,
46 content::RenderFrameHost* render_frame_host) OVERRIDE;
44 virtual bool OnMessageReceived(const IPC::Message& message) OVERRIDE; 47 virtual bool OnMessageReceived(const IPC::Message& message) OVERRIDE;
45 48
46 private: 49 private:
47 explicit PluginObserver(content::WebContents* web_contents); 50 explicit PluginObserver(content::WebContents* web_contents);
48 friend class content::WebContentsUserData<PluginObserver>; 51 friend class content::WebContentsUserData<PluginObserver>;
49 52
50 class PluginPlaceholderHost; 53 class PluginPlaceholderHost;
51 54
52 #if defined(ENABLE_PLUGIN_INSTALLATION) 55 #if defined(ENABLE_PLUGIN_INSTALLATION)
53 void InstallMissingPlugin(PluginInstaller* installer, 56 void InstallMissingPlugin(PluginInstaller* installer,
(...skipping 18 matching lines...) Expand all
72 // Stores all PluginPlaceholderHosts, keyed by their routing ID. 75 // Stores all PluginPlaceholderHosts, keyed by their routing ID.
73 std::map<int, PluginPlaceholderHost*> plugin_placeholders_; 76 std::map<int, PluginPlaceholderHost*> plugin_placeholders_;
74 #endif 77 #endif
75 78
76 base::WeakPtrFactory<PluginObserver> weak_ptr_factory_; 79 base::WeakPtrFactory<PluginObserver> weak_ptr_factory_;
77 80
78 DISALLOW_COPY_AND_ASSIGN(PluginObserver); 81 DISALLOW_COPY_AND_ASSIGN(PluginObserver);
79 }; 82 };
80 83
81 #endif // CHROME_BROWSER_PLUGINS_PLUGIN_OBSERVER_H_ 84 #endif // CHROME_BROWSER_PLUGINS_PLUGIN_OBSERVER_H_
OLDNEW
« no previous file with comments | « chrome/browser/guest_view/web_view/plugin_permission_helper.cc ('k') | chrome/browser/plugins/plugin_observer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698