Index: content/browser/wake_lock/wake_lock_dispatcher_host.h |
diff --git a/content/browser/wake_lock/wake_lock_dispatcher_host.h b/content/browser/wake_lock/wake_lock_dispatcher_host.h |
new file mode 100644 |
index 0000000000000000000000000000000000000000..f16824aa667f9d9a10e634a6f767ec6b5d72a06d |
--- /dev/null |
+++ b/content/browser/wake_lock/wake_lock_dispatcher_host.h |
@@ -0,0 +1,36 @@ |
+// Copyright (c) 2014 The Chromium Authors. All rights reserved. |
+// Use of this source code is governed by a BSD-style license that can be |
+// found in the LICENSE file. |
+ |
+#ifndef CONTENT_BROWSER_WAKE_LOCK_WAKE_LOCK_DISPATCHER_HOST_H_ |
+#define CONTENT_BROWSER_WAKE_LOCK_WAKE_LOCK_DISPATCHER_HOST_H_ |
+ |
+#include "content/public/browser/browser_message_filter.h" |
+ |
+namespace content { |
+class WakeLockPermissionContext; |
+ |
+class WakeLockDispatcherHost |
+ : public content::BrowserMessageFilter { |
+ public: |
+ explicit WakeLockDispatcherHost( |
+ int render_process_id, |
+ WakeLockPermissionContext* wakelock_context); |
+ |
+ private: |
+ virtual ~WakeLockDispatcherHost(); |
+ |
+ // BrowserMessageFilter implementation. |
+ virtual bool OnMessageReceived(const IPC::Message& message) OVERRIDE; |
+ |
+ void OnRequestWakeLockScreen(int routed_id); |
+ void OnRequestWakeUnlockScreen(int routed_id); |
+ |
+ int render_process_id_; |
+ scoped_refptr<WakeLockPermissionContext> wakelock_permission_context_; |
+ |
+ DISALLOW_COPY_AND_ASSIGN(WakeLockDispatcherHost); |
+}; |
+} |
+ |
+#endif // CONTENT_BROWSER_WAKE_LOCK_WAKE_LOCK_DISPATCHER_HOST_H_ |