Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(339)

Side by Side Diff: webkit/glue/webmediaplayer_impl.h

Issue 3026043: Full screen video Chromium patch (Closed)
Patch Set: Rename GetClient/SetClient to client/setClient to match WebKit style. Created 10 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « chrome/renderer/render_widget_fullscreen.cc ('k') | webkit/glue/webmediaplayer_impl.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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 // Delegate calls from WebCore::MediaPlayerPrivate to Chrome's video player. 5 // Delegate calls from WebCore::MediaPlayerPrivate to Chrome's video player.
6 // It contains PipelineImpl which is the actual media player pipeline, it glues 6 // It contains PipelineImpl which is the actual media player pipeline, it glues
7 // the media player pipeline, data source, audio renderer and renderer. 7 // the media player pipeline, data source, audio renderer and renderer.
8 // PipelineImpl would creates multiple threads and access some public methods 8 // PipelineImpl would creates multiple threads and access some public methods
9 // of this class, so we need to be extra careful about concurrent access of 9 // of this class, so we need to be extra careful about concurrent access of
10 // methods and members. 10 // methods and members.
(...skipping 157 matching lines...) Expand 10 before | Expand all | Expand 10 after
168 // |factory| can override the default filters by adding extra filters to 168 // |factory| can override the default filters by adding extra filters to
169 // |factory| before calling this method. 169 // |factory| before calling this method.
170 // 170 //
171 // |video_renderer_factory| is used to construct a factory that should create 171 // |video_renderer_factory| is used to construct a factory that should create
172 // a subclass of WebVideoRenderer. Is deleted by WebMediaPlayerImpl. 172 // a subclass of WebVideoRenderer. Is deleted by WebMediaPlayerImpl.
173 WebMediaPlayerImpl(WebKit::WebMediaPlayerClient* client, 173 WebMediaPlayerImpl(WebKit::WebMediaPlayerClient* client,
174 media::FilterFactoryCollection* factory, 174 media::FilterFactoryCollection* factory,
175 WebVideoRendererFactoryFactory* video_renderer_factory); 175 WebVideoRendererFactoryFactory* video_renderer_factory);
176 virtual ~WebMediaPlayerImpl(); 176 virtual ~WebMediaPlayerImpl();
177 177
178 virtual WebKit::WebMediaPlayerClient* client() const;
179 virtual void setClient(WebKit::WebMediaPlayerClient* new_client);
180
178 virtual void load(const WebKit::WebURL& url); 181 virtual void load(const WebKit::WebURL& url);
179 virtual void cancelLoad(); 182 virtual void cancelLoad();
180 183
181 // Playback controls. 184 // Playback controls.
182 virtual void play(); 185 virtual void play();
183 virtual void pause(); 186 virtual void pause();
184 virtual bool supportsFullscreen() const; 187 virtual bool supportsFullscreen() const;
185 virtual bool supportsSave() const; 188 virtual bool supportsSave() const;
186 virtual void seek(float seconds); 189 virtual void seek(float seconds);
187 virtual void setEndTime(float seconds); 190 virtual void setEndTime(float seconds);
(...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after
254 void SetNetworkState(WebKit::WebMediaPlayer::NetworkState state); 257 void SetNetworkState(WebKit::WebMediaPlayer::NetworkState state);
255 void SetReadyState(WebKit::WebMediaPlayer::ReadyState state); 258 void SetReadyState(WebKit::WebMediaPlayer::ReadyState state);
256 259
257 // Destroy resources held. 260 // Destroy resources held.
258 void Destroy(); 261 void Destroy();
259 262
260 // Callback executed after |pipeline_| stops which signals Destroy() 263 // Callback executed after |pipeline_| stops which signals Destroy()
261 // to continue. 264 // to continue.
262 void PipelineStoppedCallback(); 265 void PipelineStoppedCallback();
263 266
264 // Getter method to |client_|.
265 WebKit::WebMediaPlayerClient* GetClient();
266
267 // TODO(hclam): get rid of these members and read from the pipeline directly. 267 // TODO(hclam): get rid of these members and read from the pipeline directly.
268 WebKit::WebMediaPlayer::NetworkState network_state_; 268 WebKit::WebMediaPlayer::NetworkState network_state_;
269 WebKit::WebMediaPlayer::ReadyState ready_state_; 269 WebKit::WebMediaPlayer::ReadyState ready_state_;
270 270
271 // Keep a list of buffered time ranges. 271 // Keep a list of buffered time ranges.
272 WebKit::WebTimeRanges buffered_; 272 WebKit::WebTimeRanges buffered_;
273 273
274 // Message loops for posting tasks between Chrome's main thread. Also used 274 // Message loops for posting tasks between Chrome's main thread. Also used
275 // for DCHECKs so methods calls won't execute in the wrong thread. 275 // for DCHECKs so methods calls won't execute in the wrong thread.
276 MessageLoop* main_loop_; 276 MessageLoop* main_loop_;
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after
331 WebMediaPlayerImpl::Proxy* proxy) = 0; 331 WebMediaPlayerImpl::Proxy* proxy) = 0;
332 332
333 private: 333 private:
334 DISALLOW_COPY_AND_ASSIGN(WebVideoRendererFactoryFactory); 334 DISALLOW_COPY_AND_ASSIGN(WebVideoRendererFactoryFactory);
335 }; 335 };
336 336
337 337
338 } // namespace webkit_glue 338 } // namespace webkit_glue
339 339
340 #endif // WEBKIT_GLUE_WEBMEDIAPLAYER_IMPL_H_ 340 #endif // WEBKIT_GLUE_WEBMEDIAPLAYER_IMPL_H_
OLDNEW
« no previous file with comments | « chrome/renderer/render_widget_fullscreen.cc ('k') | webkit/glue/webmediaplayer_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698