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 "webkit/media/webmediaplayer_ms.h" | 5 #include "webkit/media/webmediaplayer_ms.h" |
6 | 6 |
7 #include <limits> | 7 #include <limits> |
8 | 8 |
9 #include "base/bind.h" | 9 #include "base/bind.h" |
10 #include "base/callback.h" | 10 #include "base/callback.h" |
(...skipping 255 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
266 DCHECK(thread_checker_.CalledOnValidThread()); | 266 DCHECK(thread_checker_.CalledOnValidThread()); |
267 // Don't need to do anything as we use the dimensions passed in via paint(). | 267 // Don't need to do anything as we use the dimensions passed in via paint(). |
268 } | 268 } |
269 | 269 |
270 void WebMediaPlayerMS::paint(WebCanvas* canvas, | 270 void WebMediaPlayerMS::paint(WebCanvas* canvas, |
271 const WebRect& rect, | 271 const WebRect& rect, |
272 uint8_t alpha) { | 272 uint8_t alpha) { |
273 DVLOG(3) << "WebMediaPlayerMS::paint"; | 273 DVLOG(3) << "WebMediaPlayerMS::paint"; |
274 DCHECK(thread_checker_.CalledOnValidThread()); | 274 DCHECK(thread_checker_.CalledOnValidThread()); |
275 | 275 |
276 video_renderer_.Paint(current_frame_, canvas, rect, alpha); | 276 gfx::RectF dest_rect(rect.x, rect.y, rect.width, rect.height); |
| 277 video_renderer_.Paint(current_frame_, canvas, dest_rect, alpha); |
277 } | 278 } |
278 | 279 |
279 bool WebMediaPlayerMS::hasSingleSecurityOrigin() const { | 280 bool WebMediaPlayerMS::hasSingleSecurityOrigin() const { |
280 DCHECK(thread_checker_.CalledOnValidThread()); | 281 DCHECK(thread_checker_.CalledOnValidThread()); |
281 return true; | 282 return true; |
282 } | 283 } |
283 | 284 |
284 bool WebMediaPlayerMS::didPassCORSAccessCheck() const { | 285 bool WebMediaPlayerMS::didPassCORSAccessCheck() const { |
285 DCHECK(thread_checker_.CalledOnValidThread()); | 286 DCHECK(thread_checker_.CalledOnValidThread()); |
286 return true; | 287 return true; |
(...skipping 110 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
397 GetClient()->readyStateChanged(); | 398 GetClient()->readyStateChanged(); |
398 } | 399 } |
399 | 400 |
400 WebKit::WebMediaPlayerClient* WebMediaPlayerMS::GetClient() { | 401 WebKit::WebMediaPlayerClient* WebMediaPlayerMS::GetClient() { |
401 DCHECK(thread_checker_.CalledOnValidThread()); | 402 DCHECK(thread_checker_.CalledOnValidThread()); |
402 DCHECK(client_); | 403 DCHECK(client_); |
403 return client_; | 404 return client_; |
404 } | 405 } |
405 | 406 |
406 } // namespace webkit_media | 407 } // namespace webkit_media |
OLD | NEW |