[Webkit-unassigned] [Bug 121303] New: First <source> element is unconditionally selected if it has no type attribute

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Fri Sep 13 08:54:59 PDT 2013


https://bugs.webkit.org/show_bug.cgi?id=121303

           Summary: First <source> element is unconditionally selected if
                    it has no type attribute
           Product: WebKit
           Version: 528+ (Nightly build)
          Platform: Unspecified
        OS/Version: Unspecified
            Status: NEW
          Severity: Normal
          Priority: P2
         Component: Media Elements
        AssignedTo: webkit-unassigned at lists.webkit.org
        ReportedBy: pnormand at igalia.com


Consider the following:

<audio controls autoplay>
   <source src="demo-audio.ogg" />
   <source src="demo-audio.mp3" />
</audio>

For this audio element the media element will instruct the player to use the first source, even if the player doesn't support ogg vorbis. This is because the source has no type attribute so HTMLMediaElement::selectNextSourceChild will not call MediaPlayer::supportsType() for the source and assume that it's supported.

Why not try to guess the mime type if it's not explicitly specified in the tag? That would allow us to call supportsType(). We could use mimeTypeFromURL(mediaURL) in that case.

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list