OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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 // CEEE module-wide utilities. | 5 // CEEE module-wide utilities. |
6 | 6 |
7 #ifndef CEEE_IE_COMMON_TOOLBAND_MODULE_UTIL_H__ | 7 #ifndef CEEE_IE_COMMON_TOOLBAND_MODULE_UTIL_H__ |
8 #define CEEE_IE_COMMON_TOOLBAND_MODULE_UTIL_H__ | 8 #define CEEE_IE_COMMON_TOOLBAND_MODULE_UTIL_H__ |
9 | 9 |
10 #include <wtypes.h> | 10 #include <wtypes.h> |
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
44 // installed. | 44 // installed. |
45 // | 45 // |
46 // If the returned path does not have a .crx extension, it should be | 46 // If the returned path does not have a .crx extension, it should be |
47 // assumed to be an exploded extension directory rather than a .crx | 47 // assumed to be an exploded extension directory rather than a .crx |
48 std::wstring GetExtensionPath(); | 48 std::wstring GetExtensionPath(); |
49 | 49 |
50 // Return the path and time of the last installation that occurred. | 50 // Return the path and time of the last installation that occurred. |
51 FilePath GetInstalledExtensionPath(); | 51 FilePath GetInstalledExtensionPath(); |
52 base::Time GetInstalledExtensionTime(); | 52 base::Time GetInstalledExtensionTime(); |
53 | 53 |
54 // Return true if the extension is outdated compared to the registry | 54 // Return true if extension installation should be attempted according |
| 55 // to the registry. Note that Chrome will silently fail installation of |
| 56 // an extension version older than what is already installed. |
55 bool NeedToInstallExtension(); | 57 bool NeedToInstallExtension(); |
56 | 58 |
57 // Install an extension and sets the right registry values | 59 // Sets the right registry values to cache the fact that we asked |
| 60 // Chrome to install an extension. |
58 void SetInstalledExtensionPath(const FilePath& path); | 61 void SetInstalledExtensionPath(const FilePath& path); |
59 | 62 |
60 // Returns true if the given path ends with .crx or is empty (as an | 63 // Returns true if the given path ends with .crx or is empty (as an |
61 // unset "what to load/install" preference means we should expect | 64 // unset "what to load/install" preference means we should expect |
62 // an extension to already be installed). | 65 // an extension to already be installed). |
63 bool IsCrxOrEmpty(const std::wstring& path); | 66 bool IsCrxOrEmpty(const std::wstring& path); |
64 | 67 |
65 // Stores/reads a registry entry that tracks whether the user has made the | 68 // Stores/reads a registry entry that tracks whether the user has made the |
66 // toolband visible or hidden. | 69 // toolband visible or hidden. |
67 void SetOptionToolbandIsHidden(bool isHidden); | 70 void SetOptionToolbandIsHidden(bool isHidden); |
(...skipping 24 matching lines...) Expand all Loading... |
92 | 95 |
93 // The name of the Internet Explorer executable. | 96 // The name of the Internet Explorer executable. |
94 extern const wchar_t kInternetExplorerModuleName[]; | 97 extern const wchar_t kInternetExplorerModuleName[]; |
95 | 98 |
96 // The name of the CEEE Broker executable. | 99 // The name of the CEEE Broker executable. |
97 extern const wchar_t kCeeeBrokerModuleName[]; | 100 extern const wchar_t kCeeeBrokerModuleName[]; |
98 | 101 |
99 } // namespace | 102 } // namespace |
100 | 103 |
101 #endif // CEEE_IE_COMMON_TOOLBAND_MODULE_UTIL_H__ | 104 #endif // CEEE_IE_COMMON_TOOLBAND_MODULE_UTIL_H__ |
OLD | NEW |