From 22a2c5e0eefcea8572f2ab5ad2e5a22789b6f555 Mon Sep 17 00:00:00 2001
From: Thomas Bruederli <thomas@roundcube.net>
Date: Mon, 02 Jun 2014 06:57:28 -0400
Subject: [PATCH] Localize title and summary attributes; make message count display box a live area

---
 skins/larry/templates/mail.html        |    5 ++---
 program/include/rcmail_output_html.php |    8 ++++++++
 2 files changed, 10 insertions(+), 3 deletions(-)

diff --git a/program/include/rcmail_output_html.php b/program/include/rcmail_output_html.php
index 19a8d14..1fa0376 100644
--- a/program/include/rcmail_output_html.php
+++ b/program/include/rcmail_output_html.php
@@ -858,6 +858,14 @@
             return '';
         }
 
+        // localize title and summary attributes
+        if (!empty($attrib['title']) && $this->app->text_exists($attrib['title'])) {
+            $attrib['title'] = $this->app->gettext($attrib['title']);
+        }
+        if (!empty($attrib['summary']) && $this->app->text_exists($attrib['summary'])) {
+            $attrib['summary'] = $this->app->gettext($attrib['summary']);
+        }
+
         // execute command
         switch ($command) {
             // return a button
diff --git a/skins/larry/templates/mail.html b/skins/larry/templates/mail.html
index 26cef3f..92b01e0 100644
--- a/skins/larry/templates/mail.html
+++ b/skins/larry/templates/mail.html
@@ -97,7 +97,6 @@
 	id="messagelist"
 	class="records-table messagelist sortheader fixedheader"
 	optionsmenuIcon="true"
-	summary="Email Messages Listing"
 	aria-labelledby="aria-label-messagelist" />
 </div>
 
@@ -116,7 +115,7 @@
 	</div>
 
 	<div id="countcontrols" class="pagenav dark">
-		<roundcube:object name="messageCountDisplay" class="countdisplay" />
+		<roundcube:object name="messageCountDisplay" class="countdisplay" aria-live="polite" aria-relevant="text" />
 		<span class="pagenavbuttons">
 		<roundcube:button command="firstpage" type="link" class="button firstpage disabled" classAct="button firstpage" classSel="button firstpage pressed" innerClass="inner" title="firstpage" label="first" />
 		<roundcube:button command="previouspage" type="link" class="button prevpage disabled" classAct="button prevpage" classSel="button prevpage pressed" innerClass="inner" title="previouspage" label="previous" />
@@ -136,7 +135,7 @@
 
 <div id="mailpreviewframe" class="iframebox" role="complementary" aria-labelledby="aria-label-mailpreviewframe">
 <h2 id="aria-label-mailpreviewframe" class="voice"><roundcube:label name="arialabelmailpreviewframe" /></h2>
-<roundcube:object name="messagecontentframe" id="messagecontframe" style="width:100%; height:100%" frameborder="0" src="/watermark.html" title="Message preview" />
+<roundcube:object name="messagecontentframe" id="messagecontframe" style="width:100%; height:100%" frameborder="0" src="/watermark.html" title="arialabelmailpreviewframe" />
 </div>
 
 </div><!-- end mailview-bottom -->

--
Gitblit v1.9.1