OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 "chrome/browser/web_applications/web_app.h" | 5 #include "chrome/browser/web_applications/web_app.h" |
6 | 6 |
7 #if defined(OS_WIN) | 7 #if defined(OS_WIN) |
8 #include <shlobj.h> | 8 #include <shlobj.h> |
9 #endif // defined(OS_WIN) | 9 #endif // defined(OS_WIN) |
10 | 10 |
(...skipping 13 matching lines...) Expand all Loading... |
24 #include "content/public/browser/browser_thread.h" | 24 #include "content/public/browser/browser_thread.h" |
25 | 25 |
26 #if defined(OS_POSIX) && !defined(OS_MACOSX) | 26 #if defined(OS_POSIX) && !defined(OS_MACOSX) |
27 #include "base/environment.h" | 27 #include "base/environment.h" |
28 #endif | 28 #endif |
29 | 29 |
30 #if defined(OS_WIN) | 30 #if defined(OS_WIN) |
31 #include "ui/gfx/icon_util.h" | 31 #include "ui/gfx/icon_util.h" |
32 #endif // defined(OS_WIN) | 32 #endif // defined(OS_WIN) |
33 | 33 |
| 34 using content::BrowserThread; |
| 35 |
34 namespace { | 36 namespace { |
35 | 37 |
36 #if defined(OS_WIN) | 38 #if defined(OS_WIN) |
37 const FilePath::CharType kIconChecksumFileExt[] = FILE_PATH_LITERAL(".ico.md5"); | 39 const FilePath::CharType kIconChecksumFileExt[] = FILE_PATH_LITERAL(".ico.md5"); |
38 | 40 |
39 // Returns true if |ch| is in visible ASCII range and not one of | 41 // Returns true if |ch| is in visible ASCII range and not one of |
40 // "/ \ : * ? " < > | ; ,". | 42 // "/ \ : * ? " < > | ; ,". |
41 bool IsValidFilePathChar(char16 c) { | 43 bool IsValidFilePathChar(char16 c) { |
42 if (c < 32) | 44 if (c < 32) |
43 return false; | 45 return false; |
(...skipping 486 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
530 | 532 |
531 #if defined(TOOLKIT_USES_GTK) | 533 #if defined(TOOLKIT_USES_GTK) |
532 std::string GetWMClassFromAppName(std::string app_name) { | 534 std::string GetWMClassFromAppName(std::string app_name) { |
533 file_util::ReplaceIllegalCharactersInPath(&app_name, '_'); | 535 file_util::ReplaceIllegalCharactersInPath(&app_name, '_'); |
534 TrimString(app_name, "_", &app_name); | 536 TrimString(app_name, "_", &app_name); |
535 return app_name; | 537 return app_name; |
536 } | 538 } |
537 #endif | 539 #endif |
538 | 540 |
539 } // namespace web_app | 541 } // namespace web_app |
OLD | NEW |