Upstream version 7.35.144.0
[platform/framework/web/crosswalk.git] / src / chrome / browser / media / encrypted_media_message_filter_android.h
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
3 // found in the LICENSE file.
4
5 #ifndef CHROME_BROWSER_MEDIA_ENCRYPTED_MEDIA_MESSAGE_FILTER_ANDROID_H_
6 #define CHROME_BROWSER_MEDIA_ENCRYPTED_MEDIA_MESSAGE_FILTER_ANDROID_H_
7
8 #include "base/basictypes.h"
9 #include "content/public/browser/browser_message_filter.h"
10
11 struct SupportedKeySystemRequest;
12 struct SupportedKeySystemResponse;
13
14 namespace chrome {
15
16 // Message filter for EME on android. It is responsible for getting the
17 // SupportedKeySystems information and passing it back to renderer.
18 class EncryptedMediaMessageFilterAndroid
19     : public content::BrowserMessageFilter {
20  public:
21   EncryptedMediaMessageFilterAndroid();
22
23  private:
24   virtual ~EncryptedMediaMessageFilterAndroid();
25
26   // BrowserMessageFilter implementation.
27   virtual bool OnMessageReceived(const IPC::Message& message,
28                                  bool* message_was_ok) OVERRIDE;
29   virtual void OverrideThreadForMessage(
30       const IPC::Message& message,
31       content::BrowserThread::ID* thread) OVERRIDE;
32
33   // Retrieve the supported key systems.
34   void OnGetSupportedKeySystems(
35       const SupportedKeySystemRequest& request,
36       SupportedKeySystemResponse* response);
37
38   DISALLOW_COPY_AND_ASSIGN(EncryptedMediaMessageFilterAndroid);
39 };
40
41 }  // namespace chrome
42
43 #endif  // CHROME_BROWSER_MEDIA_ENCRYPTED_MEDIA_MESSAGE_FILTER_ANDROID_H_