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

Side by Side Diff: Source/core/platform/chromium/ClipboardUtilitiesChromium.cpp

Issue 22572005: Remove all uses of the ASCIILiteral class. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: rm it from wtf Created 7 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 /* 1 /*
2 * Copyright (c) 2008, 2009, Google Inc. All rights reserved. 2 * Copyright (c) 2008, 2009, Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
42 WebKit::WebClipboard::Buffer currentPasteboardBuffer() 42 WebKit::WebClipboard::Buffer currentPasteboardBuffer()
43 { 43 {
44 return Pasteboard::generalPasteboard()->isSelectionMode() ? 44 return Pasteboard::generalPasteboard()->isSelectionMode() ?
45 WebKit::WebClipboard::BufferSelection : 45 WebKit::WebClipboard::BufferSelection :
46 WebKit::WebClipboard::BufferStandard; 46 WebKit::WebClipboard::BufferStandard;
47 } 47 }
48 48
49 #if OS(WINDOWS) 49 #if OS(WINDOWS)
50 void replaceNewlinesWithWindowsStyleNewlines(String& str) 50 void replaceNewlinesWithWindowsStyleNewlines(String& str)
51 { 51 {
52 DEFINE_STATIC_LOCAL(String, windowsNewline, (ASCIILiteral("\r\n"))); 52 DEFINE_STATIC_LOCAL(String, windowsNewline, ("\r\n"));
53 StringBuilder result; 53 StringBuilder result;
54 for (unsigned index = 0; index < str.length(); ++index) { 54 for (unsigned index = 0; index < str.length(); ++index) {
55 if (str[index] != '\n' || (index > 0 && str[index - 1] == '\r')) 55 if (str[index] != '\n' || (index > 0 && str[index - 1] == '\r'))
56 result.append(str[index]); 56 result.append(str[index]);
57 else 57 else
58 result.append(windowsNewline); 58 result.append(windowsNewline);
59 } 59 }
60 str = result.toString(); 60 str = result.toString();
61 } 61 }
62 #endif 62 #endif
(...skipping 21 matching lines...) Expand all
84 if (line[0] == '#') 84 if (line[0] == '#')
85 continue; 85 continue;
86 KURL url = KURL(ParsedURLString, line); 86 KURL url = KURL(ParsedURLString, line);
87 if (url.isValid()) 87 if (url.isValid())
88 return url; 88 return url;
89 } 89 }
90 return String(); 90 return String();
91 } 91 }
92 92
93 } // namespace WebCore 93 } // namespace WebCore
OLDNEW
« no previous file with comments | « Source/core/platform/animation/CSSAnimationData.cpp ('k') | Source/core/platform/graphics/GraphicsContextAnnotation.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698