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

Side by Side Diff: webkit/api/src/WebMediaPlayerClientImpl.cpp

Issue 114060: Handle mimetype queries for media files... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 years, 6 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 | Annotate | Revision Log
« no previous file with comments | « webkit/api/public/WebMimeRegistry.h ('k') | webkit/glue/simple_webmimeregistry_impl.h » ('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) 2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2009 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 "config.h" 5 #include "config.h"
6 #include "WebMediaPlayerClientImpl.h" 6 #include "WebMediaPlayerClientImpl.h"
7 7
8 #if ENABLE(VIDEO) 8 #if ENABLE(VIDEO)
9 9
10 #include "TemporaryGlue.h" 10 #include "TemporaryGlue.h"
11 #include "WebCanvas.h" 11 #include "WebCanvas.h"
12 #include "WebCString.h" 12 #include "WebCString.h"
13 #include "WebKit.h" 13 #include "WebKit.h"
14 #include "WebKitClient.h" 14 #include "WebKitClient.h"
15 #include "WebMediaPlayer.h" 15 #include "WebMediaPlayer.h"
16 #include "WebMimeRegistry.h"
16 #include "WebRect.h" 17 #include "WebRect.h"
17 #include "WebSize.h" 18 #include "WebSize.h"
18 #include "WebString.h" 19 #include "WebString.h"
19 #include "WebURL.h" 20 #include "WebURL.h"
20 21
21 #include "CString.h" 22 #include "CString.h"
22 #include "Frame.h" 23 #include "Frame.h"
23 #include "GraphicsContext.h" 24 #include "GraphicsContext.h"
24 #include "HTMLMediaElement.h" 25 #include "HTMLMediaElement.h"
25 #include "IntSize.h" 26 #include "IntSize.h"
(...skipping 293 matching lines...) Expand 10 before | Expand all | Expand 10 after
319 320
320 MediaPlayerPrivateInterface* WebMediaPlayerClientImpl::create(MediaPlayer* player) 321 MediaPlayerPrivateInterface* WebMediaPlayerClientImpl::create(MediaPlayer* player)
321 { 322 {
322 WebMediaPlayerClientImpl* client = new WebMediaPlayerClientImpl(); 323 WebMediaPlayerClientImpl* client = new WebMediaPlayerClientImpl();
323 client->m_mediaPlayer = player; 324 client->m_mediaPlayer = player;
324 return client; 325 return client;
325 } 326 }
326 327
327 void WebMediaPlayerClientImpl::getSupportedTypes(HashSet<String>& supportedTypes) 328 void WebMediaPlayerClientImpl::getSupportedTypes(HashSet<String>& supportedTypes)
328 { 329 {
329 // FIXME: decide what to do here, we should fill in the HashSet about 330 // FIXME: integrate this list with WebMediaPlayerClientImpl::supportsType.
330 // codecs that we support.
331 notImplemented(); 331 notImplemented();
332 } 332 }
333 333
334 MediaPlayer::SupportsType WebMediaPlayerClientImpl::supportsType(const String& type, 334 MediaPlayer::SupportsType WebMediaPlayerClientImpl::supportsType(const String& type,
335 const String& codecs) 335 const String& codecs)
336 { 336 {
337 // FIXME: implement this properly. 337 // FIXME: respect codecs, now we only check for mime-type.
338 return MediaPlayer::IsSupported; 338 if (webKitClient()->mimeRegistry()->supportsMediaMIMEType(type))
339 return MediaPlayer::IsSupported;
340 return MediaPlayer::IsNotSupported;
339 } 341 }
340 342
341 WebMediaPlayerClientImpl::WebMediaPlayerClientImpl() 343 WebMediaPlayerClientImpl::WebMediaPlayerClientImpl()
342 : m_mediaPlayer(0) 344 : m_mediaPlayer(0)
343 { 345 {
344 } 346 }
345 347
346 } // namespace WebKit 348 } // namespace WebKit
347 349
348 #endif // ENABLE(VIDEO) 350 #endif // ENABLE(VIDEO)
OLDNEW
« no previous file with comments | « webkit/api/public/WebMimeRegistry.h ('k') | webkit/glue/simple_webmimeregistry_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698