OLD | NEW |
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 #ifndef CHROME_BROWSER_SHELL_INTEGRATION_H_ | 5 #ifndef CHROME_BROWSER_SHELL_INTEGRATION_H_ |
6 #define CHROME_BROWSER_SHELL_INTEGRATION_H_ | 6 #define CHROME_BROWSER_SHELL_INTEGRATION_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
(...skipping 138 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
149 | 149 |
150 // Returns the location (path and index) of the Chromium icon, (e.g., | 150 // Returns the location (path and index) of the Chromium icon, (e.g., |
151 // "C:\path\to\chrome.exe,0"). This is used to specify the icon to use | 151 // "C:\path\to\chrome.exe,0"). This is used to specify the icon to use |
152 // for the taskbar group on Win 7. | 152 // for the taskbar group on Win 7. |
153 static string16 GetChromiumIconLocation(); | 153 static string16 GetChromiumIconLocation(); |
154 | 154 |
155 // Migrates existing chrome shortcuts by tagging them with correct app id. | 155 // Migrates existing chrome shortcuts by tagging them with correct app id. |
156 // see http://crbug.com/28104 | 156 // see http://crbug.com/28104 |
157 static void MigrateChromiumShortcuts(); | 157 static void MigrateChromiumShortcuts(); |
158 | 158 |
| 159 // Migrates all shortcuts in |path| which point to |chrome_exe| such that they |
| 160 // have the appropriate AppUserModelId. Also makes sure those shortcuts have |
| 161 // the dual_mode property set if such is requested by |check_dual_mode|. |
| 162 // Returns the number of shortcuts migrated. |
| 163 // This method should not be called prior to Windows 7. |
| 164 // This method is only public for the sake of tests and shouldn't be called |
| 165 // externally otherwise. |
| 166 static int MigrateShortcutsInPathInternal(const FilePath& chrome_exe, |
| 167 const FilePath& path, |
| 168 bool check_dual_mode); |
| 169 |
159 // Returns the path to the Start Menu shortcut for the given Chrome. | 170 // Returns the path to the Start Menu shortcut for the given Chrome. |
160 static FilePath GetStartMenuShortcut(const FilePath& chrome_exe); | 171 static FilePath GetStartMenuShortcut(const FilePath& chrome_exe); |
161 #endif // defined(OS_WIN) | 172 #endif // defined(OS_WIN) |
162 | 173 |
163 // The current default web client application UI state. This is used when | 174 // The current default web client application UI state. This is used when |
164 // querying if Chrome is the default browser or the default handler | 175 // querying if Chrome is the default browser or the default handler |
165 // application for a url protocol, and communicates the state and result of | 176 // application for a url protocol, and communicates the state and result of |
166 // a request. | 177 // a request. |
167 enum DefaultWebClientUIState { | 178 enum DefaultWebClientUIState { |
168 STATE_PROCESSING, | 179 STATE_PROCESSING, |
(...skipping 132 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
301 // Set Chrome as the default handler for this protocol. | 312 // Set Chrome as the default handler for this protocol. |
302 virtual bool SetAsDefault(bool interactive_permitted) OVERRIDE; | 313 virtual bool SetAsDefault(bool interactive_permitted) OVERRIDE; |
303 | 314 |
304 std::string protocol_; | 315 std::string protocol_; |
305 | 316 |
306 DISALLOW_COPY_AND_ASSIGN(DefaultProtocolClientWorker); | 317 DISALLOW_COPY_AND_ASSIGN(DefaultProtocolClientWorker); |
307 }; | 318 }; |
308 }; | 319 }; |
309 | 320 |
310 #endif // CHROME_BROWSER_SHELL_INTEGRATION_H_ | 321 #endif // CHROME_BROWSER_SHELL_INTEGRATION_H_ |
OLD | NEW |