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

Side by Side Diff: tools/filtermain.cpp

Issue 327403002: Cleanup: Delete sk_tools::make_filepath() in favor of SkOSPath::SkPathJoin(). (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: fixes Created 6 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
« no previous file with comments | « tools/bench_pictures_main.cpp ('k') | tools/lua/lua_pictures.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 2012 Google Inc. 2 * Copyright 2012 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 "SkDebugCanvas.h" 8 #include "SkDebugCanvas.h"
9 #include "SkDevice.h" 9 #include "SkDevice.h"
10 #include "SkForceLinking.h" 10 #include "SkForceLinking.h"
(...skipping 800 matching lines...) Expand 10 before | Expand all | Expand 10 after
811 return -1; 811 return -1;
812 } 812 }
813 } 813 }
814 814
815 SkOSFile::Iter iter(inDir.c_str(), "skp"); 815 SkOSFile::Iter iter(inDir.c_str(), "skp");
816 816
817 SkString inputFilename, outputFilename; 817 SkString inputFilename, outputFilename;
818 if (iter.next(&inputFilename)) { 818 if (iter.next(&inputFilename)) {
819 819
820 do { 820 do {
821 sk_tools::make_filepath(&inFile, inDir, inputFilename); 821 inFile = SkOSPath::SkPathJoin(inDir.c_str(), inputFilename.c_str());
822 if (!outDir.isEmpty()) { 822 if (!outDir.isEmpty()) {
823 sk_tools::make_filepath(&outFile, outDir, inputFilename); 823 outFile = SkOSPath::SkPathJoin(outDir.c_str(), inputFilename.c_s tr());
824 } 824 }
825 SkDebugf("Executing %s\n", inputFilename.c_str()); 825 SkDebugf("Executing %s\n", inputFilename.c_str());
826 filter_picture(inFile, outFile); 826 filter_picture(inFile, outFile);
827 } while(iter.next(&inputFilename)); 827 } while(iter.next(&inputFilename));
828 828
829 } else if (!inFile.isEmpty()) { 829 } else if (!inFile.isEmpty()) {
830 filter_picture(inFile, outFile); 830 filter_picture(inFile, outFile);
831 } else { 831 } else {
832 usage(); 832 usage();
833 return -1; 833 return -1;
834 } 834 }
835 835
836 for (size_t opt = 0; opt < SK_ARRAY_COUNT(gOptTable); ++opt) { 836 for (size_t opt = 0; opt < SK_ARRAY_COUNT(gOptTable); ++opt) {
837 SkDebugf("opt %d: %d\n", opt, gOptTable[opt].fNumTimesApplied); 837 SkDebugf("opt %d: %d\n", opt, gOptTable[opt].fNumTimesApplied);
838 } 838 }
839 839
840 SkGraphics::Term(); 840 SkGraphics::Term();
841 return 0; 841 return 0;
842 } 842 }
843 843
844 #if !defined SK_BUILD_FOR_IOS 844 #if !defined SK_BUILD_FOR_IOS
845 int main(int argc, char * const argv[]) { 845 int main(int argc, char * const argv[]) {
846 return tool_main(argc, (char**) argv); 846 return tool_main(argc, (char**) argv);
847 } 847 }
848 #endif 848 #endif
OLDNEW
« no previous file with comments | « tools/bench_pictures_main.cpp ('k') | tools/lua/lua_pictures.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698