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

Side by Side Diff: third_party/WebKit/Source/core/dom/Text.cpp

Issue 2017053003: Remove StringBuilder::appendLiteral. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase. Created 4 years, 6 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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org)
3 * (C) 1999 Antti Koivisto (koivisto@kde.org) 3 * (C) 1999 Antti Koivisto (koivisto@kde.org)
4 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009 Apple Inc. All rights reserved. 4 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009 Apple Inc. All rights reserved.
5 * 5 *
6 * This library is free software; you can redistribute it and/or 6 * This library is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU Library General Public 7 * modify it under the terms of the GNU Library General Public
8 * License as published by the Free Software Foundation; either 8 * License as published by the Free Software Foundation; either
9 * version 2 of the License, or (at your option) any later version. 9 * version 2 of the License, or (at your option) any later version.
10 * 10 *
(...skipping 440 matching lines...) Expand 10 before | Expand all | Expand 10 after
451 void Text::formatForDebugger(char *buffer, unsigned length) const 451 void Text::formatForDebugger(char *buffer, unsigned length) const
452 { 452 {
453 StringBuilder result; 453 StringBuilder result;
454 String s; 454 String s;
455 455
456 result.append(nodeName()); 456 result.append(nodeName());
457 457
458 s = data(); 458 s = data();
459 if (s.length() > 0) { 459 if (s.length() > 0) {
460 if (result.length()) 460 if (result.length())
461 result.appendLiteral("; "); 461 result.append("; ");
462 result.appendLiteral("value="); 462 result.append("value=");
463 result.append(s); 463 result.append(s);
464 } 464 }
465 465
466 strncpy(buffer, result.toString().utf8().data(), length - 1); 466 strncpy(buffer, result.toString().utf8().data(), length - 1);
467 } 467 }
468 #endif 468 #endif
469 469
470 } // namespace blink 470 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/dom/SandboxFlags.cpp ('k') | third_party/WebKit/Source/core/editing/Position.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698