1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #ifndef CLOUD_PRINT_COMMON_INSTALL_UTILS_H_
6 #define CLOUD_PRINT_COMMON_INSTALL_UTILS_H_
11 #include "base/files/file_path.h"
12 #include "base/strings/string16.h"
14 namespace cloud_print {
16 // Sets Google Update registry keys after install or update.
17 void SetGoogleUpdateKeys(const string16& product_id,
18 const string16& product_name);
20 // Sets custom error message to show by Google Update installer
21 void SetGoogleUpdateError(const string16& product_id, const string16& message);
23 // Deletes Google Update reg keys on product uninstall.
24 void DeleteGoogleUpdateKeys(const string16& product_id);
26 // Creates control panel uninstall item.
27 void CreateUninstallKey(const string16& uninstall_id,
28 const string16& product_name,
29 const std::string& uninstall_switch);
31 // Deletes control panel uninstall item.
32 void DeleteUninstallKey(const string16& uninstall_id);
34 // Returns install location retrieved from control panel uninstall key.
35 base::FilePath GetInstallLocation(const string16& uninstall_id);
37 // Returns install location retrieved from control panel uninstall key.
38 void DeleteProgramDir(const std::string& delete_switch);
40 // Returns true if path is part of program files.
41 bool IsProgramsFilesParent(const base::FilePath& path);
43 } // namespace cloud_print
45 #endif // CLOUD_PRINT_COMMON_INSTALL_UTILS_H_