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

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

Issue 11308072: Include v2 packaged apps in sync. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: comment explaining index Created 8 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
« no previous file with comments | « no previous file | chrome/browser/sync/test/integration/apps_helper.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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_APPS_HELPER_H_ 5 #ifndef CHROME_BROWSER_SYNC_TEST_INTEGRATION_APPS_HELPER_H_
6 #define CHROME_BROWSER_SYNC_TEST_INTEGRATION_APPS_HELPER_H_ 6 #define CHROME_BROWSER_SYNC_TEST_INTEGRATION_APPS_HELPER_H_
7 7
8 #include "base/basictypes.h" 8 #include "base/basictypes.h"
9 #include "base/compiler_specific.h" 9 #include "base/compiler_specific.h"
10 #include "chrome/browser/sync/test/integration/sync_test.h" 10 #include "chrome/browser/sync/test/integration/sync_test.h"
11 #include "sync/api/string_ordinal.h" 11 #include "sync/api/string_ordinal.h"
12 12
13 class Profile; 13 class Profile;
14 14
15 namespace apps_helper { 15 namespace apps_helper {
16 16
17 // Returns true iff the profile with index |index| has the same apps as the 17 // Returns true iff the profile with index |index| has the same apps (hosted,
18 // verifier. 18 // legacy packaged and platform) as the verifier.
19 bool HasSameAppsAsVerifier(int index) WARN_UNUSED_RESULT; 19 bool HasSameAppsAsVerifier(int index) WARN_UNUSED_RESULT;
20 20
21 // Returns true iff all existing profiles have the same apps as the verifier. 21 // Returns true iff all existing profiles have the same apps (hosted,
22 // legacy packaged and platform) as the verifier.
22 bool AllProfilesHaveSameAppsAsVerifier() WARN_UNUSED_RESULT; 23 bool AllProfilesHaveSameAppsAsVerifier() WARN_UNUSED_RESULT;
23 24
24 // Installs the app for the given index to |profile|, and returns the extension 25 // Installs the app for the given index to |profile|, and returns the extension
25 // ID of the new app. 26 // ID of the new app.
26 std::string InstallApp(Profile* profile, int index); 27 std::string InstallApp(Profile* profile, int index);
27 28
29 // Installs the platform app for the given index to |profile|, and returns the
30 // extension ID of the new app. Indices passed to this method should be distinct
31 // from indices passed to InstallApp.
32 std::string InstallPlatformApp(Profile* profile, int index);
33
28 // Installs the app for the given index to all profiles (including the 34 // Installs the app for the given index to all profiles (including the
29 // verifier), and returns the extension ID of the new app. 35 // verifier), and returns the extension ID of the new app.
30 std::string InstallAppForAllProfiles(int index); 36 std::string InstallAppForAllProfiles(int index);
31 37
32 // Uninstalls the app for the given index from |profile|. Assumes that it was 38 // Uninstalls the app for the given index from |profile|. Assumes that it was
33 // previously installed. 39 // previously installed.
34 void UninstallApp(Profile* profile, int index); 40 void UninstallApp(Profile* profile, int index);
35 41
36 // Installs all pending synced apps for |profile|. 42 // Installs all pending synced apps for |profile|.
37 void InstallAppsPendingForSync(Profile* profile); 43 void InstallAppsPendingForSync(Profile* profile);
38 44
39 // Enables the app for the given index on |profile|. 45 // Enables the app for the given index on |profile|.
40 void EnableApp(Profile* profile, int index); 46 void EnableApp(Profile* profile, int index);
41 47
42 // Disables the appfor the given index on |profile|. 48 // Disables the app for the given index on |profile|.
43 void DisableApp(Profile* profile, int index); 49 void DisableApp(Profile* profile, int index);
44 50
45 // Enables the app for the given index in incognito mode on |profile|. 51 // Enables the app for the given index in incognito mode on |profile|.
46 void IncognitoEnableApp(Profile* profile, int index); 52 void IncognitoEnableApp(Profile* profile, int index);
47 53
48 // Disables the app for the given index in incognito mode on |profile|. 54 // Disables the app for the given index in incognito mode on |profile|.
49 void IncognitoDisableApp(Profile* profile, int index); 55 void IncognitoDisableApp(Profile* profile, int index);
50 56
51 // Gets the page ordinal value for the application at the given index on 57 // Gets the page ordinal value for the application at the given index on
52 // |profile|. 58 // |profile|.
(...skipping 21 matching lines...) Expand all
74 // The main intention of this is to properly setup the values on the verifier 80 // The main intention of this is to properly setup the values on the verifier
75 // profile in situations where the other profiles have conflicting values. 81 // profile in situations where the other profiles have conflicting values.
76 void CopyNTPOrdinals(Profile* source, Profile* destination, int index); 82 void CopyNTPOrdinals(Profile* source, Profile* destination, int index);
77 83
78 // Fix any NTP icon collisions that are currently in |profile|. 84 // Fix any NTP icon collisions that are currently in |profile|.
79 void FixNTPOrdinalCollisions(Profile* profile); 85 void FixNTPOrdinalCollisions(Profile* profile);
80 86
81 } // namespace apps_helper 87 } // namespace apps_helper
82 88
83 #endif // CHROME_BROWSER_SYNC_TEST_INTEGRATION_APPS_HELPER_H_ 89 #endif // CHROME_BROWSER_SYNC_TEST_INTEGRATION_APPS_HELPER_H_
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/sync/test/integration/apps_helper.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698