Bug 1259898: use range-based for loop in AnimValuesStyleRule.h draft
authorRob McAuley <rmcauley@gmail.com>
Sat, 26 Mar 2016 16:50:05 +0900
changeset 344951 c276dd12125c2566d123194ea688a51a0d9cd80e
parent 344895 8a4359ad909fe0cffcfea512770483ffdf8cd4e6
child 517093 bc97bc33b7ae01b923355ff9c73a33c032acb301
push id13974
push userbmo:rmcauley@gmail.com
push dateSat, 26 Mar 2016 07:50:20 +0000
bugs1259898
milestone48.0a1
Bug 1259898: use range-based for loop in AnimValuesStyleRule.h MozReview-Commit-ID: HlJ291yiVEp
dom/animation/AnimValuesStyleRule.h
--- a/dom/animation/AnimValuesStyleRule.h
+++ b/dom/animation/AnimValuesStyleRule.h
@@ -56,18 +56,17 @@ public:
 
   struct PropertyValuePair {
     nsCSSProperty mProperty;
     StyleAnimationValue mValue;
   };
 
   void AddPropertiesToSet(nsCSSPropertySet& aSet) const
   {
-    for (size_t i = 0, i_end = mPropertyValuePairs.Length(); i < i_end; ++i) {
-      const PropertyValuePair &cv = mPropertyValuePairs[i];
+    for (const PropertyValuePair& cv : mPropertyValuePairs) {
       aSet.AddProperty(cv.mProperty);
     }
   }
 
 private:
   ~AnimValuesStyleRule() {}
 
   InfallibleTArray<PropertyValuePair> mPropertyValuePairs;