Chromium Code Reviews| 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 WEBKIT_MEDIA_ANDROID_WEBMEDIAPLAYER_ANDROID_H_ | 5 #ifndef WEBKIT_MEDIA_ANDROID_WEBMEDIAPLAYER_ANDROID_H_ |
| 6 #define WEBKIT_MEDIA_ANDROID_WEBMEDIAPLAYER_ANDROID_H_ | 6 #define WEBKIT_MEDIA_ANDROID_WEBMEDIAPLAYER_ANDROID_H_ |
| 7 | 7 |
| 8 #include <jni.h> | 8 #include <jni.h> |
| 9 | 9 |
| 10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
| (...skipping 125 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 136 virtual void UpdateNetworkState(WebKit::WebMediaPlayer::NetworkState state); | 136 virtual void UpdateNetworkState(WebKit::WebMediaPlayer::NetworkState state); |
| 137 virtual void UpdateReadyState(WebKit::WebMediaPlayer::ReadyState state); | 137 virtual void UpdateReadyState(WebKit::WebMediaPlayer::ReadyState state); |
| 138 | 138 |
| 139 // Helper method to reestablish the surface texture peer for android | 139 // Helper method to reestablish the surface texture peer for android |
| 140 // media player. | 140 // media player. |
| 141 virtual void EstablishSurfaceTexturePeer(); | 141 virtual void EstablishSurfaceTexturePeer(); |
| 142 | 142 |
| 143 // Requesting whether the surface texture peer needs to be reestablished. | 143 // Requesting whether the surface texture peer needs to be reestablished. |
| 144 virtual void SetNeedsEstablishPeer(bool needs_establish_peer); | 144 virtual void SetNeedsEstablishPeer(bool needs_establish_peer); |
| 145 | 145 |
| 146 void SetIsInVideoView(bool is_in_video_view); | |
|
ycheo (away)
2012/12/13 05:55:00
Please leave some comments.
wonsik2
2012/12/17 04:36:05
Done.
| |
| 147 | |
| 146 // Method to be implemented by child classes. | 148 // Method to be implemented by child classes. |
| 147 // Initialize the media player bridge object. | 149 // Initialize the media player bridge object. |
| 148 virtual void InitializeMediaPlayer(GURL url) = 0; | 150 virtual void InitializeMediaPlayer(GURL url) = 0; |
| 149 | 151 |
| 150 // Inform the media player to start playing. | 152 // Inform the media player to start playing. |
| 151 virtual void PlayInternal() = 0; | 153 virtual void PlayInternal() = 0; |
| 152 | 154 |
| 153 // Inform the media player to pause. | 155 // Inform the media player to pause. |
| 154 virtual void PauseInternal() = 0; | 156 virtual void PauseInternal() = 0; |
| 155 | 157 |
| (...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 221 | 223 |
| 222 // Whether the mediaplayer is playing. | 224 // Whether the mediaplayer is playing. |
| 223 bool is_playing_; | 225 bool is_playing_; |
| 224 | 226 |
| 225 // Whether media player needs to re-establish the surface texture peer. | 227 // Whether media player needs to re-establish the surface texture peer. |
| 226 bool needs_establish_peer_; | 228 bool needs_establish_peer_; |
| 227 | 229 |
| 228 // Whether the video size info is available. | 230 // Whether the video size info is available. |
| 229 bool has_size_info_; | 231 bool has_size_info_; |
| 230 | 232 |
| 233 bool is_in_video_view_; | |
|
ycheo (away)
2012/12/13 05:55:00
Please leave some comments.
wonsik2
2012/12/17 04:36:05
Done.
| |
| 234 | |
| 231 // Object for allocating stream textures. | 235 // Object for allocating stream textures. |
| 232 scoped_ptr<StreamTextureFactory> stream_texture_factory_; | 236 scoped_ptr<StreamTextureFactory> stream_texture_factory_; |
| 233 | 237 |
| 234 // Object for calling back the compositor thread to repaint the video when a | 238 // Object for calling back the compositor thread to repaint the video when a |
| 235 // frame available. It should be initialized on the compositor thread. | 239 // frame available. It should be initialized on the compositor thread. |
| 236 scoped_ptr<StreamTextureProxy> stream_texture_proxy_; | 240 scoped_ptr<StreamTextureProxy> stream_texture_proxy_; |
| 237 | 241 |
| 238 DISALLOW_COPY_AND_ASSIGN(WebMediaPlayerAndroid); | 242 DISALLOW_COPY_AND_ASSIGN(WebMediaPlayerAndroid); |
| 239 }; | 243 }; |
| 240 | 244 |
| 241 } // namespace webkit_media | 245 } // namespace webkit_media |
| 242 | 246 |
| 243 #endif // WEBKIT_MEDIA_ANDROID_WEBMEDIAPLAYER_ANDROID_H_ | 247 #endif // WEBKIT_MEDIA_ANDROID_WEBMEDIAPLAYER_ANDROID_H_ |
| OLD | NEW |