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

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

Issue 1737323002: Wire up /batches in skiaserve (Closed) Base URL: https://skia.googlesource.com/skia@skiaserve-1
Patch Set: minor tweak Created 4 years, 10 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/Response.cpp ('k') | tools/skiaserve/urlhandlers/BatchesHandler.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 "GrCaps.h" 8 #include "GrCaps.h"
9 #include "GrContextFactory.h" 9 #include "GrContextFactory.h"
10 10
(...skipping 23 matching lines...) Expand all
34 fHandlers.push_back(new RootHandler); 34 fHandlers.push_back(new RootHandler);
35 fHandlers.push_back(new PostHandler); 35 fHandlers.push_back(new PostHandler);
36 fHandlers.push_back(new ImgHandler); 36 fHandlers.push_back(new ImgHandler);
37 fHandlers.push_back(new ClipAlphaHandler); 37 fHandlers.push_back(new ClipAlphaHandler);
38 fHandlers.push_back(new EnableGPUHandler); 38 fHandlers.push_back(new EnableGPUHandler);
39 fHandlers.push_back(new CmdHandler); 39 fHandlers.push_back(new CmdHandler);
40 fHandlers.push_back(new InfoHandler); 40 fHandlers.push_back(new InfoHandler);
41 fHandlers.push_back(new DownloadHandler); 41 fHandlers.push_back(new DownloadHandler);
42 fHandlers.push_back(new DataHandler); 42 fHandlers.push_back(new DataHandler);
43 fHandlers.push_back(new BreakHandler); 43 fHandlers.push_back(new BreakHandler);
44 fHandlers.push_back(new BatchesHandler);
44 } 45 }
45 46
46 ~UrlManager() { 47 ~UrlManager() {
47 for (int i = 0; i < fHandlers.count(); i++) { delete fHandlers[i]; } 48 for (int i = 0; i < fHandlers.count(); i++) { delete fHandlers[i]; }
48 } 49 }
49 50
50 // This is clearly not efficient for a large number of urls and handlers 51 // This is clearly not efficient for a large number of urls and handlers
51 int invoke(Request* request, MHD_Connection* connection, const char* url, co nst char* method, 52 int invoke(Request* request, MHD_Connection* connection, const char* url, co nst char* method,
52 const char* upload_data, size_t* upload_data_size) const { 53 const char* upload_data, size_t* upload_data_size) const {
53 for (int i = 0; i < fHandlers.count(); i++) { 54 for (int i = 0; i < fHandlers.count(); i++) {
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after
101 MHD_stop_daemon(daemon); 102 MHD_stop_daemon(daemon);
102 return 0; 103 return 0;
103 } 104 }
104 105
105 #if !defined SK_BUILD_FOR_IOS 106 #if !defined SK_BUILD_FOR_IOS
106 int main(int argc, char** argv) { 107 int main(int argc, char** argv) {
107 SkCommandLineFlags::Parse(argc, argv); 108 SkCommandLineFlags::Parse(argc, argv);
108 return skiaserve_main(); 109 return skiaserve_main();
109 } 110 }
110 #endif 111 #endif
OLDNEW
« no previous file with comments | « tools/skiaserve/Response.cpp ('k') | tools/skiaserve/urlhandlers/BatchesHandler.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698