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

Side by Side Diff: ios/chrome/browser/ui/sync/sync_util.h

Issue 2587023002: Upstream Chrome on iOS source code [8/11]. (Closed)
Patch Set: Created 4 years 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
OLDNEW
(Empty)
1 // Copyright 2012 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.
4
5 #ifndef IOS_CHROME_BROWSER_UI_SYNC_SYNC_UTIL_H_
6 #define IOS_CHROME_BROWSER_UI_SYNC_SYNC_UTIL_H_
7
8 #include <Foundation/Foundation.h>
9
10 #include "google_apis/gaia/google_service_auth_error.h"
11 #include "ios/chrome/browser/sync/sync_setup_service.h"
12
13 @class GenericChromeCommand;
14 @class Tab;
15
16 namespace ios {
17 class ChromeBrowserState;
18 }
19
20 namespace ios_internal {
21 namespace sync {
22
23 // Gets the top-level description message associated with the sync error state
24 // of |browserState|. Returns nil if there is no sync error.
25 NSString* GetSyncErrorDescriptionForBrowserState(
26 ios::ChromeBrowserState* browserState);
27
28 // Gets the string message associated with the sync error state of
29 // |browserState|. The returned error message does not contain any links.
30 // Returns nil if there is no sync error.
31 NSString* GetSyncErrorMessageForBrowserState(
32 ios::ChromeBrowserState* browserState);
33
34 // Gets the title of the button to fix the sync error of |browserState|.
35 // Returns nil if there is no sync error or it can't be fixed by a user action.
36 NSString* GetSyncErrorButtonTitleForBrowserState(
37 ios::ChromeBrowserState* browserState);
38
39 // Gets the command associated with the sync state of |browserState|.
40 GenericChromeCommand* GetSyncCommandForBrowserState(
41 ios::ChromeBrowserState* browserState);
42
43 // Check for sync errors, and display any that ought to be shown to the user.
44 // Returns true if an infobar was brought up.
45 bool displaySyncErrors(ios::ChromeBrowserState* browser_state, Tab* tab);
46
47 // Returns true if |errorState| corresponds to a transient sync error.
48 bool IsTransientSyncError(SyncSetupService::SyncServiceState errorState);
49
50 } // namespace sync
51 } // namespace ios_internal
52
53 #endif // IOS_CHROME_BROWSER_UI_SYNC_SYNC_UTIL_H_
OLDNEW
« no previous file with comments | « ios/chrome/browser/ui/sync/sync_fake_server_egtest.mm ('k') | ios/chrome/browser/ui/sync/sync_util.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698