Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(260)

Side by Side Diff: chrome/browser/sync/test/integration/extensions_helper.h

Issue 65983002: Revert 231221 - "Remove enabled/disabled state from extension and app sync." (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
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_SYNC_TEST_INTEGRATION_EXTENSIONS_HELPER_H_ 5 #ifndef CHROME_BROWSER_SYNC_TEST_INTEGRATION_EXTENSIONS_HELPER_H_
6 #define CHROME_BROWSER_SYNC_TEST_INTEGRATION_EXTENSIONS_HELPER_H_ 6 #define CHROME_BROWSER_SYNC_TEST_INTEGRATION_EXTENSIONS_HELPER_H_
7 7
8 #include <string> 8 #include <string>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 28 matching lines...) Expand all
39 // it was previously installed. 39 // it was previously installed.
40 void UninstallExtension(Profile* profile, int index); 40 void UninstallExtension(Profile* profile, int index);
41 41
42 // Returns a vector containing the indices of all currently installed 42 // Returns a vector containing the indices of all currently installed
43 // test extensions on |profile|. 43 // test extensions on |profile|.
44 std::vector<int> GetInstalledExtensions(Profile* profile); 44 std::vector<int> GetInstalledExtensions(Profile* profile);
45 45
46 // Installs all pending synced extensions for |profile|. 46 // Installs all pending synced extensions for |profile|.
47 void InstallExtensionsPendingForSync(Profile* profile); 47 void InstallExtensionsPendingForSync(Profile* profile);
48 48
49 // Enables the extension for the given index on |profile|.
50 void EnableExtension(Profile* profile, int index);
51
52 // Disables the extension for the given index on |profile|.
53 void DisableExtension(Profile* profile, int index);
54
49 // Returns true if the extension with index |index| is enabled on |profile|. 55 // Returns true if the extension with index |index| is enabled on |profile|.
50 bool IsExtensionEnabled(Profile* profile, int index); 56 bool IsExtensionEnabled(Profile* profile, int index);
51 57
52 // Enables the extension for the given index in incognito mode on |profile|. 58 // Enables the extension for the given index in incognito mode on |profile|.
53 void IncognitoEnableExtension(Profile* profile, int index); 59 void IncognitoEnableExtension(Profile* profile, int index);
54 60
55 // Disables the extension for the given index in incognito mode on |profile|. 61 // Disables the extension for the given index in incognito mode on |profile|.
56 void IncognitoDisableExtension(Profile* profile, int index); 62 void IncognitoDisableExtension(Profile* profile, int index);
57 63
58 // Returns true if the extension with index |index| is enabled in incognito 64 // Returns true if the extension with index |index| is enabled in incognito
59 // mode on |profile|. 65 // mode on |profile|.
60 bool IsIncognitoEnabled(Profile* profile, int index); 66 bool IsIncognitoEnabled(Profile* profile, int index);
61 67
62 // Returns a unique extension name based in the integer |index|. 68 // Returns a unique extension name based in the integer |index|.
63 std::string CreateFakeExtensionName(int index); 69 std::string CreateFakeExtensionName(int index);
64 70
65 // Converts a fake extension name back into the index used to generate it. 71 // Converts a fake extension name back into the index used to generate it.
66 // Returns true if successful, false on failure. 72 // Returns true if successful, false on failure.
67 bool ExtensionNameToIndex(const std::string& name, int* index); 73 bool ExtensionNameToIndex(const std::string& name, int* index);
68 74
69 } // namespace extensions_helper 75 } // namespace extensions_helper
70 76
71 #endif // CHROME_BROWSER_SYNC_TEST_INTEGRATION_EXTENSIONS_HELPER_H_ 77 #endif // CHROME_BROWSER_SYNC_TEST_INTEGRATION_EXTENSIONS_HELPER_H_
OLDNEW
« no previous file with comments | « chrome/browser/sync/test/integration/apps_helper.cc ('k') | chrome/browser/sync/test/integration/extensions_helper.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698