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

Unified Diff: Source/core/html/HTMLMediaElement.cpp

Issue 197213012: Improve media-related exception messages (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: remove redundant TimeRanges test Created 6 years, 9 months 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 | « LayoutTests/media/video-volume-expected.txt ('k') | Source/core/html/TimeRanges.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/html/HTMLMediaElement.cpp
diff --git a/Source/core/html/HTMLMediaElement.cpp b/Source/core/html/HTMLMediaElement.cpp
index 47d690db9e70f8f430bcf19a962089a60015a0bd..fe5779b36c03cbb95e2cce81c9c0be6ce565d33f 100644
--- a/Source/core/html/HTMLMediaElement.cpp
+++ b/Source/core/html/HTMLMediaElement.cpp
@@ -1847,7 +1847,7 @@ double HTMLMediaElement::currentTime() const
void HTMLMediaElement::setCurrentTime(double time, ExceptionState& exceptionState)
{
if (m_mediaController) {
- exceptionState.throwDOMException(InvalidStateError, "No media controller is available.");
+ exceptionState.throwDOMException(InvalidStateError, "The element is slaved to a MediaController.");
return;
}
seek(time, exceptionState);
@@ -2066,7 +2066,7 @@ void HTMLMediaElement::setVolume(double vol, ExceptionState& exceptionState)
WTF_LOG(Media, "HTMLMediaElement::setVolume(%f)", vol);
if (vol < 0.0f || vol > 1.0f) {
- exceptionState.throwDOMException(IndexSizeError, ExceptionMessages::indexOutsideRange("volume", vol, 0.0, ExceptionMessages::ExclusiveBound, 1.0, ExceptionMessages::ExclusiveBound));
+ exceptionState.throwDOMException(IndexSizeError, ExceptionMessages::indexOutsideRange("volume", vol, 0.0, ExceptionMessages::InclusiveBound, 1.0, ExceptionMessages::InclusiveBound));
return;
}
« no previous file with comments | « LayoutTests/media/video-volume-expected.txt ('k') | Source/core/html/TimeRanges.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698