Bug 1253470 - Part 2: Produce console warnings for invalid iterationStart. r=birtles
authorDaisuke Akatsuka <daisuke@mozilla-japan.org>
Fri, 18 Mar 2016 10:11:07 +0900
changeset 289742 ad28fd60184e2719acd520164860d0e7322e3f58
parent 289741 5cdab04704f1a10a8ee278e594fc22b9d560d26f
child 289743 b798c62e43652ecc167d39c020f430f302716a2e
push id30108
push usercbook@mozilla.com
push dateTue, 22 Mar 2016 11:14:31 +0000
treeherdermozilla-central@ea6298e1b4f7 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersbirtles
bugs1253470
milestone48.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1253470 - Part 2: Produce console warnings for invalid iterationStart. r=birtles
dom/animation/TimingParams.h
--- a/dom/animation/TimingParams.h
+++ b/dom/animation/TimingParams.h
@@ -62,17 +62,18 @@ struct TimingParams
     }
     return result;
   }
 
   static void ValidateIterationStart(double aIterationStart,
                                      ErrorResult& aRv)
   {
     if (aIterationStart < 0) {
-      aRv.Throw(NS_ERROR_DOM_TYPE_ERR);
+      aRv.ThrowTypeError<dom::MSG_ENFORCE_RANGE_OUT_OF_RANGE>(
+        NS_LITERAL_STRING("iterationStart"));
     }
   }
 
   // mDuration.isNothing() represents the "auto" value
   Maybe<StickyTimeDuration> mDuration;
   TimeDuration mDelay;      // Initializes to zero
   TimeDuration mEndDelay;
   double mIterations = 1.0; // Can be NaN, negative, +/-Infinity