OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 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 "content/browser/android/content_video_view.h" | 5 #include "content/browser/android/content_video_view.h" |
6 | 6 |
7 #include "base/logging.h" | 7 #include "base/logging.h" |
8 #include "base/message_loop/message_loop.h" | 8 #include "base/message_loop/message_loop.h" |
9 #include "base/metrics/histogram.h" | 9 #include "base/metrics/histogram_macros.h" |
10 #include "content/browser/android/content_view_core_impl.h" | 10 #include "content/browser/android/content_view_core_impl.h" |
11 #include "content/browser/media/android/browser_media_player_manager.h" | 11 #include "content/browser/media/android/browser_media_player_manager.h" |
12 #include "content/public/browser/user_metrics.h" | 12 #include "content/public/browser/user_metrics.h" |
13 #include "content/public/common/content_switches.h" | 13 #include "content/public/common/content_switches.h" |
14 #include "jni/ContentVideoView_jni.h" | 14 #include "jni/ContentVideoView_jni.h" |
15 | 15 |
16 using base::android::AttachCurrentThread; | 16 using base::android::AttachCurrentThread; |
17 using base::android::CheckException; | 17 using base::android::CheckException; |
18 using base::android::JavaParamRef; | 18 using base::android::JavaParamRef; |
19 using base::android::ScopedJavaGlobalRef; | 19 using base::android::ScopedJavaGlobalRef; |
(...skipping 149 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
169 if (j_content_view_core.is_null()) | 169 if (j_content_view_core.is_null()) |
170 return JavaObjectWeakGlobalRef(env, nullptr); | 170 return JavaObjectWeakGlobalRef(env, nullptr); |
171 | 171 |
172 return JavaObjectWeakGlobalRef( | 172 return JavaObjectWeakGlobalRef( |
173 env, Java_ContentVideoView_createContentVideoView( | 173 env, Java_ContentVideoView_createContentVideoView( |
174 env, j_content_view_core, reinterpret_cast<intptr_t>(this), | 174 env, j_content_view_core, reinterpret_cast<intptr_t>(this), |
175 video_natural_size.width(), video_natural_size.height()) | 175 video_natural_size.width(), video_natural_size.height()) |
176 .obj()); | 176 .obj()); |
177 } | 177 } |
178 } // namespace content | 178 } // namespace content |
OLD | NEW |