[xiph-commits] r3990 - in itext: . javascript
silvia at svn.annodex.net
silvia at svn.annodex.net
Thu Aug 27 00:09:02 PDT 2009
Author: silvia
Date: 2009-08-27 00:09:01 -0700 (Thu, 27 Aug 2009)
New Revision: 3990
Modified:
itext/
itext/elephant_no_skin.html
itext/elephant_with_skin.html
itext/index.html
itext/javascript/subtitles.js
Log:
Added more accessibility code.
Property changes on: itext
___________________________________________________________________
Modified: bzr:revision-info
- timestamp: 2009-08-03 00:30:05.724999905 +1000
committer: Silvia Pfeiffer <silvia.pfeiffer at vquence.com>
properties:
branch-nick: silvia
+ timestamp: 2009-08-27 16:19:19.842999935 +1000
committer: Silvia Pfeiffer <silvia.pfeiffer at vquence.com>
properties:
branch-nick: silvia
Modified: bzr:file-ids
- elephant_no_skin.html elephant_no_skin.htm-20090802130343-dlzxqj7cts3o0n1v-1
elephant_with_skin.html elephant.html-20090801091219-j75rjxuqu8rsxt53-1
index.html index.html-20090718094218-d45036mvytq5pecp-3
+ elephant_no_skin.html elephant_no_skin.htm-20090802130343-dlzxqj7cts3o0n1v-1
elephant_with_skin.html elephant.html-20090801091219-j75rjxuqu8rsxt53-1
index.html index.html-20090718094218-d45036mvytq5pecp-3
javascript/subtitles.js subtitles.js-20090718094218-d45036mvytq5pecp-10
Modified: bzr:revision-id:v4
- 1 silvia.pfeiffer at vquence.com-20090713110521-cz7evclxohf4rbs2
2 silvia.pfeiffer at vquence.com-20090714003359-apmpuor2ttarph5n
3 silvia.pfeiffer at vquence.com-20090714143931-q6j8ritt91jn5rhu
4 silvia.pfeiffer at vquence.com-20090718094222-58zgcmsg9gggbnt1
5 silvia.pfeiffer at vquence.com-20090718094708-wb83p9u6jr1xlhm6
6 silvia.pfeiffer at vquence.com-20090718095409-p6en5qufj62m8w3h
7 silvia.pfeiffer at vquence.com-20090718113424-9s8cmt1guxj6qoky
8 silvia.pfeiffer at vquence.com-20090718113445-n0q9c14w4i11pe36
9 silvia.pfeiffer at vquence.com-20090718123622-xdp52y76dvpem2ya
10 silvia.pfeiffer at vquence.com-20090718131644-69y0zml0ccbwc5er
11 silvia.pfeiffer at vquence.com-20090719002119-ekzto9pc7jqs3gw9
12 silvia.pfeiffer at vquence.com-20090719120832-srm8qemvr5jjy67w
13 silvia.pfeiffer at vquence.com-20090719130420-s7xjh35zrfj8117x
14 silvia.pfeiffer at vquence.com-20090720065454-m2g8tcjgpgw8aetr
15 silvia.pfeiffer at vquence.com-20090720131039-ivpstebztd7u3vwx
16 silvia.pfeiffer at vquence.com-20090720190949-r4ahzq2regl7opf1
17 silvia.pfeiffer at vquence.com-20090720210510-i54efp8a9sem4g6g
18 silvia.pfeiffer at vquence.com-20090721063829-4pvft92pnt7k966p
19 silvia.pfeiffer at vquence.com-20090721065410-0miir37pbb73k35r
20 silvia.pfeiffer at vquence.com-20090721065911-9ngk00aeujudpw8p
21 silvia.pfeiffer at vquence.com-20090721121059-uthu2kmvu74zjv06
22 silvia.pfeiffer at vquence.com-20090721125735-lwwo9ivbdhj0jdhp
23 silvia.pfeiffer at vquence.com-20090721130655-sdqdgbs0lexyrwh5
24 silvia.pfeiffer at vquence.com-20090721143346-065b9v0rr1tcmyg0
25 silvia.pfeiffer at vquence.com-20090722010421-9sx8ynfzcoxh1eai
26 silvia.pfeiffer at vquence.com-20090722014433-yrqaapi0kmfec1oh
27 silvia.pfeiffer at vquence.com-20090722062945-586zxe3smxv1gdcw
28 silvia.pfeiffer at vquence.com-20090727123838-lcxe2fb7n2111ipd
29 silvia.pfeiffer at vquence.com-20090728151700-ai24t8itvj8hxs0c
30 silvia.pfeiffer at vquence.com-20090728210031-2n53wzpuledyqg9w
31 silvia.pfeiffer at vquence.com-20090730034353-pcrnaae01i2q5430
32 silvia.pfeiffer at vquence.com-20090731122706-nrrle33ore1cjl87
33 silvia.pfeiffer at vquence.com-20090801092101-zyu1s0ntmio5bihb
34 silvia.pfeiffer at vquence.com-20090801092534-5pvl2ehkqi87p9le
35 silvia.pfeiffer at vquence.com-20090801233833-xa51k548ng1tqxso
36 silvia.pfeiffer at vquence.com-20090802130400-k998eftqulgcrp04
37 silvia.pfeiffer at vquence.com-20090802143005-c1sm52ru0kfed912
+ 1 silvia.pfeiffer at vquence.com-20090713110521-cz7evclxohf4rbs2
2 silvia.pfeiffer at vquence.com-20090714003359-apmpuor2ttarph5n
3 silvia.pfeiffer at vquence.com-20090714143931-q6j8ritt91jn5rhu
4 silvia.pfeiffer at vquence.com-20090718094222-58zgcmsg9gggbnt1
5 silvia.pfeiffer at vquence.com-20090718094708-wb83p9u6jr1xlhm6
6 silvia.pfeiffer at vquence.com-20090718095409-p6en5qufj62m8w3h
7 silvia.pfeiffer at vquence.com-20090718113424-9s8cmt1guxj6qoky
8 silvia.pfeiffer at vquence.com-20090718113445-n0q9c14w4i11pe36
9 silvia.pfeiffer at vquence.com-20090718123622-xdp52y76dvpem2ya
10 silvia.pfeiffer at vquence.com-20090718131644-69y0zml0ccbwc5er
11 silvia.pfeiffer at vquence.com-20090719002119-ekzto9pc7jqs3gw9
12 silvia.pfeiffer at vquence.com-20090719120832-srm8qemvr5jjy67w
13 silvia.pfeiffer at vquence.com-20090719130420-s7xjh35zrfj8117x
14 silvia.pfeiffer at vquence.com-20090720065454-m2g8tcjgpgw8aetr
15 silvia.pfeiffer at vquence.com-20090720131039-ivpstebztd7u3vwx
16 silvia.pfeiffer at vquence.com-20090720190949-r4ahzq2regl7opf1
17 silvia.pfeiffer at vquence.com-20090720210510-i54efp8a9sem4g6g
18 silvia.pfeiffer at vquence.com-20090721063829-4pvft92pnt7k966p
19 silvia.pfeiffer at vquence.com-20090721065410-0miir37pbb73k35r
20 silvia.pfeiffer at vquence.com-20090721065911-9ngk00aeujudpw8p
21 silvia.pfeiffer at vquence.com-20090721121059-uthu2kmvu74zjv06
22 silvia.pfeiffer at vquence.com-20090721125735-lwwo9ivbdhj0jdhp
23 silvia.pfeiffer at vquence.com-20090721130655-sdqdgbs0lexyrwh5
24 silvia.pfeiffer at vquence.com-20090721143346-065b9v0rr1tcmyg0
25 silvia.pfeiffer at vquence.com-20090722010421-9sx8ynfzcoxh1eai
26 silvia.pfeiffer at vquence.com-20090722014433-yrqaapi0kmfec1oh
27 silvia.pfeiffer at vquence.com-20090722062945-586zxe3smxv1gdcw
28 silvia.pfeiffer at vquence.com-20090727123838-lcxe2fb7n2111ipd
29 silvia.pfeiffer at vquence.com-20090728151700-ai24t8itvj8hxs0c
30 silvia.pfeiffer at vquence.com-20090728210031-2n53wzpuledyqg9w
31 silvia.pfeiffer at vquence.com-20090730034353-pcrnaae01i2q5430
32 silvia.pfeiffer at vquence.com-20090731122706-nrrle33ore1cjl87
33 silvia.pfeiffer at vquence.com-20090801092101-zyu1s0ntmio5bihb
34 silvia.pfeiffer at vquence.com-20090801092534-5pvl2ehkqi87p9le
35 silvia.pfeiffer at vquence.com-20090801233833-xa51k548ng1tqxso
36 silvia.pfeiffer at vquence.com-20090802130400-k998eftqulgcrp04
37 silvia.pfeiffer at vquence.com-20090802143005-c1sm52ru0kfed912
38 silvia.pfeiffer at vquence.com-20090827061919-ejpm51zs89ekbd56
Modified: bzr:text-parents
-
+ javascript/subtitles.js silvia.pfeiffer at vquence.com-20090802130400-k998eftqulgcrp04
Modified: itext/elephant_no_skin.html
===================================================================
--- itext/elephant_no_skin.html 2009-08-12 13:25:52 UTC (rev 3989)
+++ itext/elephant_no_skin.html 2009-08-27 07:09:01 UTC (rev 3990)
@@ -44,6 +44,7 @@
<script type="text/javascript" src="javascript/subtitles.js"></script>
<link href="styles/subtitles.css" type="text/css" rel="stylesheet"/>
+ <title>Experiment with video accessibility and time-aligned text</title>
<style>
div.itextMenu ul {
bottom: 0;
@@ -56,18 +57,16 @@
z-index: 500;
}
</style>
-
- <title>Experiment with video accessibility and time-aligned text</title>
</head>
<body>
- <h1>Demo Video Player</h1>
+ <h1>Demo Video Player Accessibility</h1>
<div class="mc" width="440px" height="300px" style="position: relative; display:inline-block;">
<div class="itextcontainer"></div>
- <video class="v" src="elephants_dream/elephant.ogv" poster="elephants_dream/elephant.png" controls>
+ <video class="v" src="elephants_dream/elephant.ogv" poster="elephants_dream/elephant.png" controls aria-label="Elephants Dream video" title="Elephants Dream video">
<!-- Language Tags http://www.iana.org/assignments/language-subtag-registry -->
<itext id="video_af" lang="af" type="text/srt" charset="ISO-8859" display="auto"
src="elephants_dream/elephant.afrikaans.srt" category="SUB"></itext>
@@ -141,14 +140,18 @@
src="elephants_dream/chapters.srt" category="CUE"></itext>
</video>
-<div id="menu"></div>
+ <span id="itext_menu">
+ <button id="itext_btn" wairole="button" aria-haspopup="true" aria-labelledby="itext_btn_label" tabindex="0" type="button" role="button" title="video text menu button" value="">
+ <span id="itext_btn_label" style="display:none;">Video text menu</span>
+ <img class="itextimg" aria-live="off" src="images/itext.png" alt="Access Subtitles, Captions and Audio Descriptions - press space bar"/>
+ </button>
+ <div id="menu"></div>
+ </span>
</div>
</div>
-<a id="itext_btn" href="#itext"><img class="itextimg" aria-live="off" src="skins/schmucker/images/itext.png" alt="Access Subtitles, Captions and Audio Descriptions - press space bar" style="background-color:black;"/></a>
-
<script type="text/javascript">
// get video element
var video = document.getElementsByTagName("video")[0];
@@ -166,7 +169,7 @@
}, false);
// get itext button
- var itext_btn = document.getElementById("itext_btn");
+ var itext_btn = document.getElementById("itext_menu");
var visitext = false;
// hook up event listener to itext button
itext_btn.addEventListener("mouseover", function() {
@@ -174,17 +177,25 @@
if (visitext) {
// make subtitle menu visible
jQuery(".catMenu").css("visibility", "visible");
- jQuery(".catMenu").css("bottom", "20px");
- jQuery(".catMenu").css("right", "-38px");
+ jQuery(".catMenu").css("bottom", "24px");
+ jQuery(".catMenu").css("right", "-10px");
} else {
// make subtitle menu invisible
jQuery(".catMenu").css("visibility", "hidden");
}
}
-
,false);
+ itext_btn.addEventListener("mouseout", function() {
+ if (visitext) {
+ // make subtitle menu invisible
+ visitext=!visitext;
+ jQuery(".catMenu").css("visibility", "hidden");
+ }
+ }
+ ,false);
+
</script>
<p>Note: The demo works best in Firefox version >= 3.5, but also in the latest experimental releases of Safari (with XiphQT installed), Opera and Chrome. It will not work in IE.</p>
Modified: itext/elephant_with_skin.html
===================================================================
--- itext/elephant_with_skin.html 2009-08-12 13:25:52 UTC (rev 3989)
+++ itext/elephant_with_skin.html 2009-08-27 07:09:01 UTC (rev 3990)
@@ -52,7 +52,7 @@
<body>
- <h1>Demo Video Player</h1>
+ <h1>Demo Video Player Accessibility</h1>
<div id="main">
<div class="tinyVidPlayer">
Modified: itext/index.html
===================================================================
--- itext/index.html 2009-08-12 13:25:52 UTC (rev 3989)
+++ itext/index.html 2009-08-27 07:09:01 UTC (rev 3990)
@@ -52,7 +52,7 @@
<body>
- <h1>Demo Video Player</h1>
+ <h1>Demo Video Player Accessibility</h1>
<div id="main">
<div class="tinyVidPlayer">
Modified: itext/javascript/subtitles.js
===================================================================
--- itext/javascript/subtitles.js 2009-08-12 13:25:52 UTC (rev 3989)
+++ itext/javascript/subtitles.js 2009-08-27 07:09:01 UTC (rev 3990)
@@ -552,12 +552,18 @@
},
itextMenu: function (baseEl, elstring) {
var appendText = '<div class="itextMenu">\n';
- appendText += '<ul class="catMenu">\n';
+ appendText += '<ul class="catMenu" role="menu" wairole="menu" tabindex="0">\n';
for (var i in this.tracks) {
- appendText += '<li> < ' + categoryName(i) + '\n';
- appendText += '<ul class="langMenu">\n';
+ appendText += '<li role="menuitem" wairole="menuitem" aria-haspopup="true" tabindex="0"> < ' + categoryName(i) + '\n';
+ appendText += '<ul class="langMenu" role="menu" wairole="menu">\n';
for (var j in this.tracks[i]) {
- appendText += '<li><a href="#" onclick="'+elstring+'.itexts.tracks[\'' + i + '\'][\'' + j + '\'].enable();jQuery(\'.catMenu\').css(\'visibility\', \'hidden\');return false;">' + this.tracks[i][j].langName + '</a></li>\n';
+ appendText += '<li role="menuitemradio" wairole="menuitemradio" tabindex="0"';
+ if (this.tracks[i].display) {
+ appendText += ' aria-checked="true"';
+ } else {
+ appendText += ' aria-checked="false"';
+ }
+ appendText += '><a href="#" onclick="'+elstring+'.itexts.tracks[\'' + i + '\'][\'' + j + '\'].enable();jQuery(\'.catMenu\').css(\'visibility\', \'hidden\');return false;">' + this.tracks[i][j].langName + '</a></li>\n';
}
appendText += '</ul>\n</li>\n';
}
More information about the commits
mailing list