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

Unified Diff: Source/core/css/MediaQuery.cpp

Issue 482753002: Use StringBuilder::appendLiteral() / StringBuilder::append(char) when possible (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 4 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 | « Source/core/css/CSSSupportsRule.cpp ('k') | Source/core/css/MediaQueryExp.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/css/MediaQuery.cpp
diff --git a/Source/core/css/MediaQuery.cpp b/Source/core/css/MediaQuery.cpp
index bf819d1b3fe97eb549edab231c29e0829eb20044..14160589d4ae675382ec5d7803e01a18f394a148 100644
--- a/Source/core/css/MediaQuery.cpp
+++ b/Source/core/css/MediaQuery.cpp
@@ -43,10 +43,10 @@ String MediaQuery::serialize() const
StringBuilder result;
switch (m_restrictor) {
case MediaQuery::Only:
- result.append("only ");
+ result.appendLiteral("only ");
break;
case MediaQuery::Not:
- result.append("not ");
+ result.appendLiteral("not ");
break;
case MediaQuery::None:
break;
@@ -59,12 +59,12 @@ String MediaQuery::serialize() const
if (m_mediaType != MediaTypeNames::all || m_restrictor != None) {
result.append(m_mediaType);
- result.append(" and ");
+ result.appendLiteral(" and ");
}
result.append(m_expressions->at(0)->serialize());
for (size_t i = 1; i < m_expressions->size(); ++i) {
- result.append(" and ");
+ result.appendLiteral(" and ");
result.append(m_expressions->at(i)->serialize());
}
return result.toString();
« no previous file with comments | « Source/core/css/CSSSupportsRule.cpp ('k') | Source/core/css/MediaQueryExp.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698