1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
|
See http://code.google.com/p/chromium/issues/detail?id=16442
Restore the default Downloads location used on Ubuntu.
---
chrome/common/chrome_paths_linux.cc | 15 ---------------
1 file changed, 15 deletions(-)
Index: src/chrome/common/chrome_paths_linux.cc
===================================================================
--- src.orig/chrome/common/chrome_paths_linux.cc
+++ src/chrome/common/chrome_paths_linux.cc
@@ -41,34 +41,19 @@
}
bool GetUserDocumentsDirectory(FilePath* result) {
scoped_ptr<base::Environment> env(base::Environment::Create());
*result = base::GetXDGUserDirectory(env.get(), "DOCUMENTS", "Documents");
return true;
}
-// We respect the user's preferred download location, unless it is
-// ~ or their desktop directory, in which case we default to ~/Downloads.
bool GetUserDownloadsDirectory(FilePath* result) {
scoped_ptr<base::Environment> env(base::Environment::Create());
*result = base::GetXDGUserDirectory(env.get(), "DOWNLOAD", "Downloads");
-
- FilePath home = file_util::GetHomeDir();
- if (*result == home) {
- *result = home.Append("Downloads");
- return true;
- }
-
- FilePath desktop;
- GetUserDesktop(&desktop);
- if (*result == desktop) {
- *result = home.Append("Downloads");
- }
-
return true;
}
bool GetUserDesktop(FilePath* result) {
scoped_ptr<base::Environment> env(base::Environment::Create());
*result = base::GetXDGUserDirectory(env.get(), "DESKTOP", "Desktop");
return true;
}
|