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 #ifndef MEDIA_BASE_ANDROID_MEDIA_PLAYER_BRIDGE_H_ | 5 #ifndef MEDIA_BASE_ANDROID_MEDIA_PLAYER_BRIDGE_H_ |
6 #define MEDIA_BASE_ANDROID_MEDIA_PLAYER_BRIDGE_H_ | 6 #define MEDIA_BASE_ANDROID_MEDIA_PLAYER_BRIDGE_H_ |
7 | 7 |
8 #include <jni.h> | 8 #include <jni.h> |
9 #include <map> | 9 #include <map> |
10 #include <string> | 10 #include <string> |
(...skipping 158 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
169 base::android::ScopedJavaGlobalRef<jobject> j_media_player_bridge_; | 169 base::android::ScopedJavaGlobalRef<jobject> j_media_player_bridge_; |
170 | 170 |
171 base::RepeatingTimer<MediaPlayerBridge> time_update_timer_; | 171 base::RepeatingTimer<MediaPlayerBridge> time_update_timer_; |
172 | 172 |
173 // Listener object that listens to all the media player events. | 173 // Listener object that listens to all the media player events. |
174 scoped_ptr<MediaPlayerListener> listener_; | 174 scoped_ptr<MediaPlayerListener> listener_; |
175 | 175 |
176 // Whether player is currently using a surface. | 176 // Whether player is currently using a surface. |
177 bool is_surface_in_use_; | 177 bool is_surface_in_use_; |
178 | 178 |
| 179 // Volume of playback. |
| 180 double volume_; |
| 181 |
179 // Weak pointer passed to |listener_| for callbacks. | 182 // Weak pointer passed to |listener_| for callbacks. |
180 // NOTE: Weak pointers must be invalidated before all other member variables. | 183 // NOTE: Weak pointers must be invalidated before all other member variables. |
181 base::WeakPtrFactory<MediaPlayerBridge> weak_factory_; | 184 base::WeakPtrFactory<MediaPlayerBridge> weak_factory_; |
182 | 185 |
183 DISALLOW_COPY_AND_ASSIGN(MediaPlayerBridge); | 186 DISALLOW_COPY_AND_ASSIGN(MediaPlayerBridge); |
184 }; | 187 }; |
185 | 188 |
186 } // namespace media | 189 } // namespace media |
187 | 190 |
188 #endif // MEDIA_BASE_ANDROID_MEDIA_PLAYER_BRIDGE_H_ | 191 #endif // MEDIA_BASE_ANDROID_MEDIA_PLAYER_BRIDGE_H_ |
OLD | NEW |