#endif
class GURL;
-class InfoBarDelegate;
class PluginFinder;
class PluginMetadata;
class WebContents;
}
+namespace infobars {
+class InfoBarDelegate;
+}
+
class PluginObserver : public content::WebContentsObserver,
public content::WebContentsUserData<PluginObserver> {
public:
- virtual ~PluginObserver();
+ ~PluginObserver() override;
// content::WebContentsObserver implementation.
- virtual void RenderViewCreated(
- content::RenderViewHost* render_view_host) OVERRIDE;
- virtual void PluginCrashed(const base::FilePath& plugin_path,
- base::ProcessId plugin_pid) OVERRIDE;
- virtual bool OnMessageReceived(const IPC::Message& message) OVERRIDE;
+ void RenderFrameCreated(content::RenderFrameHost* render_frame_host) override;
+ void PluginCrashed(const base::FilePath& plugin_path,
+ base::ProcessId plugin_pid) override;
+ bool OnMessageReceived(const IPC::Message& message,
+ content::RenderFrameHost* render_frame_host) override;
+ bool OnMessageReceived(const IPC::Message& message) override;
private:
explicit PluginObserver(content::WebContents* web_contents);
#endif
// Message handlers:
- void OnBlockedUnauthorizedPlugin(const string16& name,
+ void OnBlockedUnauthorizedPlugin(const base::string16& name,
const std::string& identifier);
void OnBlockedOutdatedPlugin(int placeholder_id,
const std::string& identifier);
void OnCouldNotLoadPlugin(const base::FilePath& plugin_path);
void OnNPAPINotSupported(const std::string& identifier);
- base::WeakPtrFactory<PluginObserver> weak_ptr_factory_;
-
#if defined(ENABLE_PLUGIN_INSTALLATION)
// Stores all PluginPlaceholderHosts, keyed by their routing ID.
std::map<int, PluginPlaceholderHost*> plugin_placeholders_;
#endif
+ base::WeakPtrFactory<PluginObserver> weak_ptr_factory_;
+
DISALLOW_COPY_AND_ASSIGN(PluginObserver);
};