OLD | NEW |
1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 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 #include "media/base/media.h" | 5 #include "media/base/media.h" |
6 | 6 |
7 #include "base/logging.h" | 7 #include "base/files/file_path.h" |
8 | |
9 #if defined(OS_ANDROID) | |
10 #include "base/android/jni_android.h" | |
11 #include "media/base/android/media_jni_registrar.h" | |
12 #endif | |
13 | 8 |
14 // This file is intended for platforms that don't need to load any media | 9 // This file is intended for platforms that don't need to load any media |
15 // libraries (e.g., Android and iOS). | 10 // libraries (e.g., iOS). |
16 namespace media { | 11 namespace media { |
| 12 namespace internal { |
17 | 13 |
18 bool InitializeMediaLibrary(const base::FilePath& module_dir) { | 14 bool InitializeMediaLibraryInternal(const base::FilePath& module_dir, |
| 15 bool for_testing) { |
19 return true; | 16 return true; |
20 } | 17 } |
21 | 18 |
22 void InitializeMediaLibraryForTesting() { | 19 } // namespace internal |
23 #if defined(OS_ANDROID) | |
24 // Register JNI bindings for android. | |
25 JNIEnv* env = base::android::AttachCurrentThread(); | |
26 RegisterJni(env); | |
27 #endif | |
28 } | |
29 | |
30 bool IsMediaLibraryInitialized() { | |
31 return true; | |
32 } | |
33 | |
34 } // namespace media | 20 } // namespace media |
OLD | NEW |