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

Unified Diff: chrome/browser/plugin_service.h

Issue 88020: Allow Flash (and other plugins) to be installed without restarting the browse... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 years, 8 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « base/registry.cc ('k') | chrome/browser/plugin_service.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/plugin_service.h
===================================================================
--- chrome/browser/plugin_service.h (revision 14070)
+++ chrome/browser/plugin_service.h (working copy)
@@ -15,9 +15,14 @@
#include "base/lock.h"
#include "base/ref_counted.h"
#include "base/singleton.h"
+#include "base/waitable_event_watcher.h"
#include "chrome/browser/browser_process.h"
#include "webkit/glue/webplugin.h"
+#if defined(OS_WIN)
+#include "base/registry.h"
+#endif
+
namespace IPC {
class Message;
}
@@ -30,7 +35,7 @@
// This can be called on the main thread and IO thread. However it must
// be created on the main thread.
-class PluginService {
+class PluginService : base::WaitableEventWatcher::Delegate {
public:
// Returns the PluginService singleton.
static PluginService* GetInstance();
@@ -109,6 +114,9 @@
PluginService();
~PluginService();
+ // base::WaitableEventWatcher::Delegate implementation.
+ void OnWaitableEventSignaled(base::WaitableEvent* waitable_event);
+
// mapping between plugin path and PluginProcessHost
typedef base::hash_map<FilePath, PluginProcessHost*> PluginMap;
PluginMap plugin_hosts_;
@@ -129,6 +137,16 @@
// webkit_glue since this class is called on the main and IO thread.
Lock lock_;
+#if defined(OS_WIN)
+ // Registry keys for getting notifications when new plugins are installed.
+ RegKey hkcu_key_;
+ RegKey hklm_key_;
+ scoped_ptr<base::WaitableEvent> hkcu_event_;
+ scoped_ptr<base::WaitableEvent> hklm_event_;
+ base::WaitableEventWatcher hkcu_watcher_;
+ base::WaitableEventWatcher hklm_watcher_;
+#endif
+
DISALLOW_COPY_AND_ASSIGN(PluginService);
};
« no previous file with comments | « base/registry.cc ('k') | chrome/browser/plugin_service.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698