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

Side by Side Diff: tools/skiaserve/skiaserve.cpp

Issue 1902143002: Adding support for controlling the global sRGB SkColor switch. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 4 years, 8 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
« no previous file with comments | « tools/skiaserve/Request.cpp ('k') | tools/skiaserve/urlhandlers/SRGBModeHandler.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright 2016 Google Inc. 2 * Copyright 2016 Google Inc.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license that can be 4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file. 5 * found in the LICENSE file.
6 */ 6 */
7 7
8 #include "Request.h" 8 #include "Request.h"
9 #include "Response.h" 9 #include "Response.h"
10 10
(...skipping 22 matching lines...) Expand all
33 fHandlers.push_back(new ClipAlphaHandler); 33 fHandlers.push_back(new ClipAlphaHandler);
34 fHandlers.push_back(new EnableGPUHandler); 34 fHandlers.push_back(new EnableGPUHandler);
35 fHandlers.push_back(new CmdHandler); 35 fHandlers.push_back(new CmdHandler);
36 fHandlers.push_back(new InfoHandler); 36 fHandlers.push_back(new InfoHandler);
37 fHandlers.push_back(new DownloadHandler); 37 fHandlers.push_back(new DownloadHandler);
38 fHandlers.push_back(new DataHandler); 38 fHandlers.push_back(new DataHandler);
39 fHandlers.push_back(new BreakHandler); 39 fHandlers.push_back(new BreakHandler);
40 fHandlers.push_back(new BatchesHandler); 40 fHandlers.push_back(new BatchesHandler);
41 fHandlers.push_back(new BatchBoundsHandler); 41 fHandlers.push_back(new BatchBoundsHandler);
42 fHandlers.push_back(new ColorModeHandler); 42 fHandlers.push_back(new ColorModeHandler);
43 fHandlers.push_back(new SRGBModeHandler);
43 } 44 }
44 45
45 ~UrlManager() { 46 ~UrlManager() {
46 for (int i = 0; i < fHandlers.count(); i++) { delete fHandlers[i]; } 47 for (int i = 0; i < fHandlers.count(); i++) { delete fHandlers[i]; }
47 } 48 }
48 49
49 // This is clearly not efficient for a large number of urls and handlers 50 // This is clearly not efficient for a large number of urls and handlers
50 int invoke(Request* request, MHD_Connection* connection, const char* url, co nst char* method, 51 int invoke(Request* request, MHD_Connection* connection, const char* url, co nst char* method,
51 const char* upload_data, size_t* upload_data_size) const { 52 const char* upload_data, size_t* upload_data_size) const {
52 for (int i = 0; i < fHandlers.count(); i++) { 53 for (int i = 0; i < fHandlers.count(); i++) {
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after
112 MHD_stop_daemon(daemon); 113 MHD_stop_daemon(daemon);
113 return 0; 114 return 0;
114 } 115 }
115 116
116 #if !defined SK_BUILD_FOR_IOS 117 #if !defined SK_BUILD_FOR_IOS
117 int main(int argc, char** argv) { 118 int main(int argc, char** argv) {
118 SkCommandLineFlags::Parse(argc, argv); 119 SkCommandLineFlags::Parse(argc, argv);
119 return skiaserve_main(); 120 return skiaserve_main();
120 } 121 }
121 #endif 122 #endif
OLDNEW
« no previous file with comments | « tools/skiaserve/Request.cpp ('k') | tools/skiaserve/urlhandlers/SRGBModeHandler.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698