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

Side by Side Diff: base/base_paths_android.cc

Issue 468253002: Move file_util to base/files/ directory. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Forgot to add forwarding header to patch 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 | « base/base_paths.cc ('k') | base/base_paths_mac.mm » ('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 // Defines base::PathProviderAndroid which replaces base::PathProviderPosix for 5 // Defines base::PathProviderAndroid which replaces base::PathProviderPosix for
6 // Android in base/path_service.cc. 6 // Android in base/path_service.cc.
7 7
8 #include <unistd.h> 8 #include <unistd.h>
9 9
10 #include "base/android/jni_android.h" 10 #include "base/android/jni_android.h"
11 #include "base/android/path_utils.h" 11 #include "base/android/path_utils.h"
12 #include "base/base_paths.h" 12 #include "base/base_paths.h"
13 #include "base/file_util.h"
14 #include "base/files/file_path.h" 13 #include "base/files/file_path.h"
14 #include "base/files/file_util.h"
15 #include "base/logging.h" 15 #include "base/logging.h"
16 #include "base/process/process_metrics.h" 16 #include "base/process/process_metrics.h"
17 17
18 namespace base { 18 namespace base {
19 19
20 bool PathProviderAndroid(int key, FilePath* result) { 20 bool PathProviderAndroid(int key, FilePath* result) {
21 switch (key) { 21 switch (key) {
22 case base::FILE_EXE: { 22 case base::FILE_EXE: {
23 char bin_dir[PATH_MAX + 1]; 23 char bin_dir[PATH_MAX + 1];
24 int bin_dir_size = readlink(kProcSelfExe, bin_dir, PATH_MAX); 24 int bin_dir_size = readlink(kProcSelfExe, bin_dir, PATH_MAX);
(...skipping 26 matching lines...) Expand all
51 return base::android::GetExternalStorageDirectory(result); 51 return base::android::GetExternalStorageDirectory(result);
52 default: 52 default:
53 // Note: the path system expects this function to override the default 53 // Note: the path system expects this function to override the default
54 // behavior. So no need to log an error if we don't support a given 54 // behavior. So no need to log an error if we don't support a given
55 // path. The system will just use the default. 55 // path. The system will just use the default.
56 return false; 56 return false;
57 } 57 }
58 } 58 }
59 59
60 } // namespace base 60 } // namespace base
OLDNEW
« no previous file with comments | « base/base_paths.cc ('k') | base/base_paths_mac.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698