Skip to content

Commit

Permalink
[giow] (0) Only enable the first default text track, not all of them,…
Browse files Browse the repository at this point in the history
… except for metadata. For metadata, remove the user preference logic and just always enable them.

Fixing https://www.w3.org/Bugs/Public/show_bug.cgi?id=18853
Affected topics: Video Text Tracks

git-svn-id: http://svn.whatwg.org/webapps@7350 340c8d12-0b0e-0410-8428-c7bf67bfef74
  • Loading branch information
Hixie committed Sep 15, 2012
1 parent 8eff91c commit 3ddd97c
Show file tree
Hide file tree
Showing 3 changed files with 50 additions and 25 deletions.
24 changes: 16 additions & 8 deletions complete.html
Expand Up @@ -34366,7 +34366,14 @@ <h6 id=sourcing-out-of-band-text-tracks><span class=secno>4.8.10.12.3 </span>Sou

<li><p><a href=#perform-automatic-text-track-selection>Perform automatic text track selection</a> for <code title=dom-TextTrack-kind-chapters><a href=#dom-texttrack-kind-chapters>chapters</a></code>.</li>

<li><p><a href=#perform-automatic-text-track-selection>Perform automatic text track selection</a> for <code title=dom-TextTrack-kind-metadata><a href=#dom-texttrack-kind-metadata>metadata</a></code>.</li>
<li><p>If there are any <a href=#text-track title="text track">text tracks</a>
in the <a href=#media-element>media element</a>'s <a href=#list-of-text-tracks>list of text
tracks</a> whose <a href=#text-track-kind>text track kind</a> is <code title=dom-TextTrack-kind-metadata><a href=#dom-texttrack-kind-metadata>metadata</a></code> that correspond
to <code><a href=#the-track-element>track</a></code> elements with a <code title=attr-track-default><a href=#attr-track-default>default</a></code> attribute set whose
<a href=#text-track-mode>text track mode</a> is set to <a href=#text-track-disabled title="text track
disabled">disabled</a>, then set the <a href=#text-track-mode>text track
mode</a> of all such tracks to <a href=#text-track-hidden title="text track
hidden">hidden</a></li>

<li><p>Set the element's
<a href=#did-perform-automatic-track-selection>did-perform-automatic-track-selection</a> flag to
Expand All @@ -34380,7 +34387,8 @@ <h6 id=sourcing-out-of-band-text-tracks><span class=secno>4.8.10.12.3 </span>Sou
the <a href=#text-track title="text track">text tracks</a> in the <a href=#media-element>media
element</a>'s <a href=#list-of-text-tracks>list of text tracks</a> whose <a href=#text-track-kind>text
track kind</a> is one of the kinds that were passed to the
algorithm, if any.</li>
algorithm, if any, in the order given in the <a href=#list-of-text-tracks>list of text
tracks</a>.</li>

<li><p>If <var title="">candidates</var> is empty, then abort these
steps.</li>
Expand All @@ -34402,11 +34410,11 @@ <h6 id=sourcing-out-of-band-text-tracks><span class=secno>4.8.10.12.3 </span>Sou
<code><a href=#the-track-element>track</a></code> elements with a <code title=attr-track-default><a href=#attr-track-default>default</a></code> attribute set whose
<a href=#text-track-mode>text track mode</a> is set to <a href=#text-track-disabled title="text track
disabled">disabled</a>, then additionally set the <a href=#text-track-mode>text
track mode</a> of each such track to <a href=#text-track-hidden title="text track
hidden">hidden</a>.</p> <!-- so that we still get events and
stuff: we can expect authors to forget that default doesn't mean
that it'll always be turned on, and that they'll still rely on
events firing even if it doesn't show -->
track mode</a> of the first such track to <a href=#text-track-hidden title="text
track hidden">hidden</a>.</p> <!-- so that we still get events
and stuff: we can expect authors to forget that default doesn't
mean that it'll always be turned on, and that they'll still rely
on events firing even if it doesn't show -->

<p class=note>For example, the user could have set a browser
preference to the effect of "I want French captions whenever
Expand All @@ -34420,7 +34428,7 @@ <h6 id=sourcing-out-of-band-text-tracks><span class=secno>4.8.10.12.3 </span>Sou
<code><a href=#the-track-element>track</a></code> elements with a <code title=attr-track-default><a href=#attr-track-default>default</a></code> attribute set whose
<a href=#text-track-mode>text track mode</a> is set to <a href=#text-track-disabled title="text track
disabled">disabled</a>, then set the <a href=#text-track-mode>text track
mode</a> of each such track to <a href=#text-track-showing title="text track
mode</a> of the first such track to <a href=#text-track-showing title="text track
showing">showing</a>.</p>

</li>
Expand Down
24 changes: 16 additions & 8 deletions index
Expand Up @@ -34366,7 +34366,14 @@ interface <dfn id=mediacontroller>MediaController</dfn> {

<li><p><a href=#perform-automatic-text-track-selection>Perform automatic text track selection</a> for <code title=dom-TextTrack-kind-chapters><a href=#dom-texttrack-kind-chapters>chapters</a></code>.</li>

<li><p><a href=#perform-automatic-text-track-selection>Perform automatic text track selection</a> for <code title=dom-TextTrack-kind-metadata><a href=#dom-texttrack-kind-metadata>metadata</a></code>.</li>
<li><p>If there are any <a href=#text-track title="text track">text tracks</a>
in the <a href=#media-element>media element</a>'s <a href=#list-of-text-tracks>list of text
tracks</a> whose <a href=#text-track-kind>text track kind</a> is <code title=dom-TextTrack-kind-metadata><a href=#dom-texttrack-kind-metadata>metadata</a></code> that correspond
to <code><a href=#the-track-element>track</a></code> elements with a <code title=attr-track-default><a href=#attr-track-default>default</a></code> attribute set whose
<a href=#text-track-mode>text track mode</a> is set to <a href=#text-track-disabled title="text track
disabled">disabled</a>, then set the <a href=#text-track-mode>text track
mode</a> of all such tracks to <a href=#text-track-hidden title="text track
hidden">hidden</a></li>

<li><p>Set the element's
<a href=#did-perform-automatic-track-selection>did-perform-automatic-track-selection</a> flag to
Expand All @@ -34380,7 +34387,8 @@ interface <dfn id=mediacontroller>MediaController</dfn> {
the <a href=#text-track title="text track">text tracks</a> in the <a href=#media-element>media
element</a>'s <a href=#list-of-text-tracks>list of text tracks</a> whose <a href=#text-track-kind>text
track kind</a> is one of the kinds that were passed to the
algorithm, if any.</li>
algorithm, if any, in the order given in the <a href=#list-of-text-tracks>list of text
tracks</a>.</li>

<li><p>If <var title="">candidates</var> is empty, then abort these
steps.</li>
Expand All @@ -34402,11 +34410,11 @@ interface <dfn id=mediacontroller>MediaController</dfn> {
<code><a href=#the-track-element>track</a></code> elements with a <code title=attr-track-default><a href=#attr-track-default>default</a></code> attribute set whose
<a href=#text-track-mode>text track mode</a> is set to <a href=#text-track-disabled title="text track
disabled">disabled</a>, then additionally set the <a href=#text-track-mode>text
track mode</a> of each such track to <a href=#text-track-hidden title="text track
hidden">hidden</a>.</p> <!-- so that we still get events and
stuff: we can expect authors to forget that default doesn't mean
that it'll always be turned on, and that they'll still rely on
events firing even if it doesn't show -->
track mode</a> of the first such track to <a href=#text-track-hidden title="text
track hidden">hidden</a>.</p> <!-- so that we still get events
and stuff: we can expect authors to forget that default doesn't
mean that it'll always be turned on, and that they'll still rely
on events firing even if it doesn't show -->

<p class=note>For example, the user could have set a browser
preference to the effect of "I want French captions whenever
Expand All @@ -34420,7 +34428,7 @@ interface <dfn id=mediacontroller>MediaController</dfn> {
<code><a href=#the-track-element>track</a></code> elements with a <code title=attr-track-default><a href=#attr-track-default>default</a></code> attribute set whose
<a href=#text-track-mode>text track mode</a> is set to <a href=#text-track-disabled title="text track
disabled">disabled</a>, then set the <a href=#text-track-mode>text track
mode</a> of each such track to <a href=#text-track-showing title="text track
mode</a> of the first such track to <a href=#text-track-showing title="text track
showing">showing</a>.</p>

</li>
Expand Down
27 changes: 18 additions & 9 deletions source
Expand Up @@ -37656,8 +37656,16 @@ interface <dfn>MediaController</dfn> {
<li><p><span>Perform automatic text track selection</span> for <code
title="dom-TextTrack-kind-chapters">chapters</code>.</p></li>

<li><p><span>Perform automatic text track selection</span> for <code
title="dom-TextTrack-kind-metadata">metadata</code>.</p></li>
<li><p>If there are any <span title="text track">text tracks</span>
in the <span>media element</span>'s <span>list of text
tracks</span> whose <span>text track kind</span> is <code
title="dom-TextTrack-kind-metadata">metadata</code> that correspond
to <code>track</code> elements with a <code
title="attr-track-default">default</code> attribute set whose
<span>text track mode</span> is set to <span title="text track
disabled">disabled</span>, then set the <span>text track
mode</span> of all such tracks to <span title="text track
hidden">hidden</span></p></li>

<li><p>Set the element's
<span>did-perform-automatic-track-selection</span> flag to
Expand All @@ -37675,7 +37683,8 @@ interface <dfn>MediaController</dfn> {
the <span title="text track">text tracks</span> in the <span>media
element</span>'s <span>list of text tracks</span> whose <span>text
track kind</span> is one of the kinds that were passed to the
algorithm, if any.</p></li>
algorithm, if any, in the order given in the <span>list of text
tracks</span>.</p></li>

<li><p>If <var title="">candidates</var> is empty, then abort these
steps.</p></li>
Expand All @@ -37698,11 +37707,11 @@ interface <dfn>MediaController</dfn> {
title="attr-track-default">default</code> attribute set whose
<span>text track mode</span> is set to <span title="text track
disabled">disabled</span>, then additionally set the <span>text
track mode</span> of each such track to <span title="text track
hidden">hidden</span>.</p> <!-- so that we still get events and
stuff: we can expect authors to forget that default doesn't mean
that it'll always be turned on, and that they'll still rely on
events firing even if it doesn't show -->
track mode</span> of the first such track to <span title="text
track hidden">hidden</span>.</p> <!-- so that we still get events
and stuff: we can expect authors to forget that default doesn't
mean that it'll always be turned on, and that they'll still rely
on events firing even if it doesn't show -->

<p class="note">For example, the user could have set a browser
preference to the effect of "I want French captions whenever
Expand All @@ -37717,7 +37726,7 @@ interface <dfn>MediaController</dfn> {
title="attr-track-default">default</code> attribute set whose
<span>text track mode</span> is set to <span title="text track
disabled">disabled</span>, then set the <span>text track
mode</span> of each such track to <span title="text track
mode</span> of the first such track to <span title="text track
showing">showing</span>.</p>

</li>
Expand Down

0 comments on commit 3ddd97c

Please sign in to comment.