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

Side by Side Diff: mojo/services/launcher/launcher.cc

Issue 448143008: Move StringToUpperASCII and LowerCaseEqualsASCII to the base namespace (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « mojo/services/html_viewer/html_document_view.cc ('k') | net/base/host_mapping_rules.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "base/bind.h" 5 #include "base/bind.h"
6 #include "base/compiler_specific.h" 6 #include "base/compiler_specific.h"
7 #include "base/message_loop/message_loop.h" 7 #include "base/message_loop/message_loop.h"
8 #include "base/strings/string_tokenizer.h" 8 #include "base/strings/string_tokenizer.h"
9 #include "base/strings/string_util.h" 9 #include "base/strings/string_util.h"
10 #include "mojo/public/cpp/application/application_connection.h" 10 #include "mojo/public/cpp/application/application_connection.h"
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
51 virtual ~LaunchInstance() {} 51 virtual ~LaunchInstance() {}
52 52
53 private: 53 private:
54 void OnReceivedResponse(URLResponsePtr response); 54 void OnReceivedResponse(URLResponsePtr response);
55 55
56 std::string GetContentType(const Array<String>& headers) { 56 std::string GetContentType(const Array<String>& headers) {
57 for (size_t i = 0; i < headers.size(); ++i) { 57 for (size_t i = 0; i < headers.size(); ++i) {
58 base::StringTokenizer t(headers[i], ": ;="); 58 base::StringTokenizer t(headers[i], ": ;=");
59 while (t.GetNext()) { 59 while (t.GetNext()) {
60 if (!t.token_is_delim() && 60 if (!t.token_is_delim() &&
61 LowerCaseEqualsASCII(t.token(), "content-type")) { 61 base::LowerCaseEqualsASCII(t.token(), "content-type")) {
62 while (t.GetNext()) { 62 while (t.GetNext()) {
63 if (!t.token_is_delim()) 63 if (!t.token_is_delim())
64 return t.token(); 64 return t.token();
65 } 65 }
66 } 66 }
67 } 67 }
68 } 68 }
69 return ""; 69 return "";
70 } 70 }
71 71
(...skipping 101 matching lines...) Expand 10 before | Expand all | Expand 10 after
173 } 173 }
174 ScheduleDestroy(); 174 ScheduleDestroy();
175 } 175 }
176 176
177 // static 177 // static
178 ApplicationDelegate* ApplicationDelegate::Create() { 178 ApplicationDelegate* ApplicationDelegate::Create() {
179 return new LauncherApp; 179 return new LauncherApp;
180 } 180 }
181 181
182 } // namespace mojo 182 } // namespace mojo
OLDNEW
« no previous file with comments | « mojo/services/html_viewer/html_document_view.cc ('k') | net/base/host_mapping_rules.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698