OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 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 | 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_PROFILE_SYNC_SERVICE_ANDROID_H_ | 5 #ifndef CHROME_BROWSER_SYNC_PROFILE_SYNC_SERVICE_ANDROID_H_ |
6 #define CHROME_BROWSER_SYNC_PROFILE_SYNC_SERVICE_ANDROID_H_ | 6 #define CHROME_BROWSER_SYNC_PROFILE_SYNC_SERVICE_ANDROID_H_ |
7 | 7 |
8 #include <jni.h> | 8 #include <jni.h> |
9 #include <map> | 9 #include <map> |
10 | 10 |
(...skipping 28 matching lines...) Expand all Loading... |
39 | 39 |
40 // Called from Java when the user manually disables sync | 40 // Called from Java when the user manually disables sync |
41 void DisableSync(JNIEnv* env, jobject obj); | 41 void DisableSync(JNIEnv* env, jobject obj); |
42 | 42 |
43 // Called from Java when the user signs in to Chrome. Starts up sync. | 43 // Called from Java when the user signs in to Chrome. Starts up sync. |
44 void SignInSync(JNIEnv* env, jobject obj); | 44 void SignInSync(JNIEnv* env, jobject obj); |
45 | 45 |
46 // Called from Java when the user signs out of Chrome | 46 // Called from Java when the user signs out of Chrome |
47 void SignOutSync(JNIEnv* env, jobject obj); | 47 void SignOutSync(JNIEnv* env, jobject obj); |
48 | 48 |
| 49 // Called from Java when we get a signal that the Directory should be saved. |
| 50 void FlushDirectory(JNIEnv* env, jobject obj); |
| 51 |
49 // Returns a string version of browser_sync::SyncBackendHost::StatusSummary | 52 // Returns a string version of browser_sync::SyncBackendHost::StatusSummary |
50 base::android::ScopedJavaLocalRef<jstring> QuerySyncStatusSummary( | 53 base::android::ScopedJavaLocalRef<jstring> QuerySyncStatusSummary( |
51 JNIEnv* env, jobject obj); | 54 JNIEnv* env, jobject obj); |
52 | 55 |
53 // Called from Java early during startup to ensure we use the correct | 56 // Called from Java early during startup to ensure we use the correct |
54 // unique machine tag in session sync. Returns true if the machine tag was | 57 // unique machine tag in session sync. Returns true if the machine tag was |
55 // succesfully set. | 58 // succesfully set. |
56 // This must be called before the |SessionModelAssociator| is initialized. | 59 // This must be called before the |SessionModelAssociator| is initialized. |
57 jboolean SetSyncSessionsId(JNIEnv* env, jobject obj, jstring tag); | 60 jboolean SetSyncSessionsId(JNIEnv* env, jobject obj, jstring tag); |
58 | 61 |
(...skipping 159 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
218 // preferences. | 221 // preferences. |
219 scoped_ptr<sync_driver::SyncPrefs> sync_prefs_; | 222 scoped_ptr<sync_driver::SyncPrefs> sync_prefs_; |
220 | 223 |
221 // Java-side ProfileSyncService object. | 224 // Java-side ProfileSyncService object. |
222 JavaObjectWeakGlobalRef weak_java_profile_sync_service_; | 225 JavaObjectWeakGlobalRef weak_java_profile_sync_service_; |
223 | 226 |
224 DISALLOW_COPY_AND_ASSIGN(ProfileSyncServiceAndroid); | 227 DISALLOW_COPY_AND_ASSIGN(ProfileSyncServiceAndroid); |
225 }; | 228 }; |
226 | 229 |
227 #endif // CHROME_BROWSER_SYNC_PROFILE_SYNC_SERVICE_ANDROID_H_ | 230 #endif // CHROME_BROWSER_SYNC_PROFILE_SYNC_SERVICE_ANDROID_H_ |
OLD | NEW |