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

Unified Diff: Source/modules/accessibility/AXMediaControls.cpp

Issue 729343003: Handle AX help-Text for media time slider. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years, 1 month 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | Source/modules/accessibility/AXNodeObject.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/modules/accessibility/AXMediaControls.cpp
diff --git a/Source/modules/accessibility/AXMediaControls.cpp b/Source/modules/accessibility/AXMediaControls.cpp
index 550e4c47fb3d7a25cecaeb7d328030dbe7ade249..39adada9a58eb31e7b9d2f5338c93ecbb8e45bd2 100644
--- a/Source/modules/accessibility/AXMediaControls.cpp
+++ b/Source/modules/accessibility/AXMediaControls.cpp
@@ -30,7 +30,6 @@
#include "config.h"
#include "modules/accessibility/AXMediaControls.h"
-#include "core/html/HTMLMediaElement.h"
#include "platform/text/PlatformLocale.h"
namespace blink {
@@ -205,21 +204,12 @@ PassRefPtr<AXObject> AXMediaControlsContainer::create(RenderObject* renderer)
String AXMediaControlsContainer::accessibilityDescription() const
{
- return queryString(controllingVideoElement() ? WebLocalizedString::AXMediaVideoElement : WebLocalizedString::AXMediaAudioElement);
+ return queryString(isControllingVideoElement() ? WebLocalizedString::AXMediaVideoElement : WebLocalizedString::AXMediaAudioElement);
}
String AXMediaControlsContainer::helpText() const
{
- return queryString(controllingVideoElement() ? WebLocalizedString::AXMediaVideoElementHelp : WebLocalizedString::AXMediaAudioElementHelp);
-}
-
-bool AXMediaControlsContainer::controllingVideoElement() const
-{
- Node* node = m_renderer->node();
- if (!node)
- return true;
-
- return isHTMLVideoElement(toParentMediaElement(node));
+ return queryString(isControllingVideoElement() ? WebLocalizedString::AXMediaVideoElementHelp : WebLocalizedString::AXMediaAudioElementHelp);
}
bool AXMediaControlsContainer::computeAccessibilityIsIgnored() const
@@ -258,7 +248,7 @@ String AccessibilityMediaTimeline::valueDescription() const
String AccessibilityMediaTimeline::helpText() const
{
- return queryString(WebLocalizedString::AXMediaSliderHelp);
+ return queryString(isControllingVideoElement() ? WebLocalizedString::AXMediaVideoSliderHelp : WebLocalizedString::AXMediaAudioSliderHelp);
}
« no previous file with comments | « no previous file | Source/modules/accessibility/AXNodeObject.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698