| 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/shell_integration.h" | 5 #include "chrome/browser/shell_integration.h" |
| 6 | 6 |
| 7 #include <windows.h> | 7 #include <windows.h> |
| 8 #include <shobjidl.h> | 8 #include <shobjidl.h> |
| 9 #include <propkey.h> | 9 #include <propkey.h> |
| 10 #include <propvarutil.h> | 10 #include <propvarutil.h> |
| (...skipping 18 matching lines...) Expand all Loading... |
| 29 #include "chrome/installer/setup/setup_util.h" | 29 #include "chrome/installer/setup/setup_util.h" |
| 30 #include "chrome/installer/util/browser_distribution.h" | 30 #include "chrome/installer/util/browser_distribution.h" |
| 31 #include "chrome/installer/util/create_reg_key_work_item.h" | 31 #include "chrome/installer/util/create_reg_key_work_item.h" |
| 32 #include "chrome/installer/util/set_reg_value_work_item.h" | 32 #include "chrome/installer/util/set_reg_value_work_item.h" |
| 33 #include "chrome/installer/util/shell_util.h" | 33 #include "chrome/installer/util/shell_util.h" |
| 34 #include "chrome/installer/util/util_constants.h" | 34 #include "chrome/installer/util/util_constants.h" |
| 35 #include "chrome/installer/util/work_item.h" | 35 #include "chrome/installer/util/work_item.h" |
| 36 #include "chrome/installer/util/work_item_list.h" | 36 #include "chrome/installer/util/work_item_list.h" |
| 37 #include "content/public/browser/browser_thread.h" | 37 #include "content/public/browser/browser_thread.h" |
| 38 | 38 |
| 39 using content::BrowserThread; |
| 40 |
| 39 namespace { | 41 namespace { |
| 40 | 42 |
| 41 // Helper function for ShellIntegration::GetAppId to generates profile id | 43 // Helper function for ShellIntegration::GetAppId to generates profile id |
| 42 // from profile path. "profile_id" is composed of sanitized basenames of | 44 // from profile path. "profile_id" is composed of sanitized basenames of |
| 43 // user data dir and profile dir joined by a ".". | 45 // user data dir and profile dir joined by a ".". |
| 44 std::wstring GetProfileIdFromPath(const FilePath& profile_path) { | 46 std::wstring GetProfileIdFromPath(const FilePath& profile_path) { |
| 45 // Return empty string if profile_path is empty | 47 // Return empty string if profile_path is empty |
| 46 if (profile_path.empty()) | 48 if (profile_path.empty()) |
| 47 return std::wstring(); | 49 return std::wstring(); |
| 48 | 50 |
| (...skipping 488 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 537 return icon_path; | 539 return icon_path; |
| 538 } | 540 } |
| 539 | 541 |
| 540 void ShellIntegration::MigrateChromiumShortcuts() { | 542 void ShellIntegration::MigrateChromiumShortcuts() { |
| 541 if (base::win::GetVersion() < base::win::VERSION_WIN7) | 543 if (base::win::GetVersion() < base::win::VERSION_WIN7) |
| 542 return; | 544 return; |
| 543 | 545 |
| 544 BrowserThread::PostTask( | 546 BrowserThread::PostTask( |
| 545 BrowserThread::FILE, FROM_HERE, new MigrateChromiumShortcutsTask()); | 547 BrowserThread::FILE, FROM_HERE, new MigrateChromiumShortcutsTask()); |
| 546 } | 548 } |
| OLD | NEW |