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

Side by Side Diff: skia/ext/vector_canvas_unittest.cc

Issue 176843022: Move UTF16ToASCII, remove WideToASCII. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 9 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 | « remoting/host/setup/me2me_native_messaging_host.cc ('k') | ui/base/l10n/l10n_util.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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "build/build_config.h" 5 #include "build/build_config.h"
6 6
7 #if !defined(OS_WIN) 7 #if !defined(OS_WIN)
8 #include <unistd.h> 8 #include <unistd.h>
9 #endif 9 #endif
10 10
(...skipping 236 matching lines...) Expand 10 before | Expand all | Expand 10 after
247 // Make sure the directory exist. 247 // Make sure the directory exist.
248 base::CreateDirectory(test_dir_); 248 base::CreateDirectory(test_dir_);
249 } 249 }
250 } 250 }
251 251
252 // Returns the fully qualified path of a data file. 252 // Returns the fully qualified path of a data file.
253 base::FilePath test_file(const base::FilePath::StringType& filename) const { 253 base::FilePath test_file(const base::FilePath::StringType& filename) const {
254 // Hack for a quick lowercase. We assume all the test data file names are 254 // Hack for a quick lowercase. We assume all the test data file names are
255 // ASCII. 255 // ASCII.
256 #if defined(OS_WIN) 256 #if defined(OS_WIN)
257 std::string tmp = WideToASCII(filename); 257 std::string tmp = base::UTF16ToASCII(filename);
258 #else 258 #else
259 std::string tmp(filename); 259 std::string tmp(filename);
260 #endif 260 #endif
261 for (size_t i = 0; i < tmp.size(); ++i) 261 for (size_t i = 0; i < tmp.size(); ++i)
262 tmp[i] = base::ToLowerASCII(tmp[i]); 262 tmp[i] = base::ToLowerASCII(tmp[i]);
263 263
264 return test_dir_.AppendASCII(tmp); 264 return test_dir_.AppendASCII(tmp);
265 } 265 }
266 266
267 // Compares or saves the bitmap currently loaded in the context, depending on 267 // Compares or saves the bitmap currently loaded in the context, depending on
(...skipping 692 matching lines...) Expand 10 before | Expand all | Expand 10 after
960 pcanvas_->rotate(67); 960 pcanvas_->rotate(67);
961 vcanvas_->drawBitmap(bitmap, 20, -50, NULL); 961 vcanvas_->drawBitmap(bitmap, 20, -50, NULL);
962 pcanvas_->drawBitmap(bitmap, 20, -50, NULL); 962 pcanvas_->drawBitmap(bitmap, 20, -50, NULL);
963 EXPECT_EQ(0., ProcessImage(FILE_PATH_LITERAL("rotate"))); 963 EXPECT_EQ(0., ProcessImage(FILE_PATH_LITERAL("rotate")));
964 } 964 }
965 } 965 }
966 966
967 #endif // !defined(USE_AURA) 967 #endif // !defined(USE_AURA)
968 968
969 } // namespace skia 969 } // namespace skia
OLDNEW
« no previous file with comments | « remoting/host/setup/me2me_native_messaging_host.cc ('k') | ui/base/l10n/l10n_util.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698