Bug 570258: Some more atom usage cleanup. r=jst

This commit is contained in:
Jonas Sicking
2010-06-08 16:25:27 -07:00
parent 715898edc1
commit a2f1d080e7
12 changed files with 34 additions and 53 deletions

View File

@@ -745,7 +745,6 @@ nsHTMLCSSUtils::ParseLength(const nsAString & aString, float * aValue, nsIAtom *
PRInt8 sign = 1;
PRInt32 i = 0, j = aString.Length();
PRUnichar c;
nsAutoString unit;
PRBool floatingPointFound = PR_FALSE;
c = *iter;
if (PRUnichar('-') == c) { sign = -1; iter++; i++; }
@@ -773,9 +772,8 @@ nsHTMLCSSUtils::ParseLength(const nsAString & aString, float * aValue, nsIAtom *
iter++;
i++;
}
unit = Substring(aString, aString.Length() - (j-i), j-i);
*aValue = value * sign;
*aUnit = NS_NewAtom(unit);
*aUnit = NS_NewAtom(StringTail(aString, j-i));
}
void