OLD | NEW |
1 # Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 # Copyright (c) 2011 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 """An implementation of the server side of the Chromium sync protocol. | 5 """An implementation of the server side of the Chromium sync protocol. |
6 | 6 |
7 The details of the protocol are described mostly by comments in the protocol | 7 The details of the protocol are described mostly by comments in the protocol |
8 buffer definition at chrome/browser/sync/protocol/sync.proto. | 8 buffer definition at chrome/browser/sync/protocol/sync.proto. |
9 """ | 9 """ |
10 | 10 |
(...skipping 376 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
387 # Specify all the permanent items that a model might need. | 387 # Specify all the permanent items that a model might need. |
388 _PERMANENT_ITEM_SPECS = [ | 388 _PERMANENT_ITEM_SPECS = [ |
389 PermanentItem('google_chrome', name='Google Chrome', | 389 PermanentItem('google_chrome', name='Google Chrome', |
390 parent_tag=ROOT_ID, sync_type=TOP_LEVEL), | 390 parent_tag=ROOT_ID, sync_type=TOP_LEVEL), |
391 PermanentItem('google_chrome_bookmarks', name='Bookmarks', | 391 PermanentItem('google_chrome_bookmarks', name='Bookmarks', |
392 parent_tag='google_chrome', sync_type=BOOKMARK), | 392 parent_tag='google_chrome', sync_type=BOOKMARK), |
393 PermanentItem('bookmark_bar', name='Bookmark Bar', | 393 PermanentItem('bookmark_bar', name='Bookmark Bar', |
394 parent_tag='google_chrome_bookmarks', sync_type=BOOKMARK), | 394 parent_tag='google_chrome_bookmarks', sync_type=BOOKMARK), |
395 PermanentItem('other_bookmarks', name='Other Bookmarks', | 395 PermanentItem('other_bookmarks', name='Other Bookmarks', |
396 parent_tag='google_chrome_bookmarks', sync_type=BOOKMARK), | 396 parent_tag='google_chrome_bookmarks', sync_type=BOOKMARK), |
397 PermanentItem('synced_bookmarks', name='Mobile Bookmarks', | |
398 parent_tag='google_chrome_bookmarks', sync_type=BOOKMARK), | |
399 PermanentItem('google_chrome_preferences', name='Preferences', | 397 PermanentItem('google_chrome_preferences', name='Preferences', |
400 parent_tag='google_chrome', sync_type=PREFERENCE), | 398 parent_tag='google_chrome', sync_type=PREFERENCE), |
401 PermanentItem('google_chrome_autofill', name='Autofill', | 399 PermanentItem('google_chrome_autofill', name='Autofill', |
402 parent_tag='google_chrome', sync_type=AUTOFILL), | 400 parent_tag='google_chrome', sync_type=AUTOFILL), |
403 PermanentItem('google_chrome_autofill_profiles', name='Autofill Profiles', | 401 PermanentItem('google_chrome_autofill_profiles', name='Autofill Profiles', |
404 parent_tag='google_chrome', sync_type=AUTOFILL_PROFILE), | 402 parent_tag='google_chrome', sync_type=AUTOFILL_PROFILE), |
405 PermanentItem('google_chrome_app_settings', | 403 PermanentItem('google_chrome_app_settings', |
406 name='App Settings', | 404 name='App Settings', |
407 parent_tag='google_chrome', sync_type=APP_SETTINGS), | 405 parent_tag='google_chrome', sync_type=APP_SETTINGS), |
408 PermanentItem('google_chrome_extension_settings', | 406 PermanentItem('google_chrome_extension_settings', |
(...skipping 781 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1190 | 1188 |
1191 update_sieve.CheckMigrationState() | 1189 update_sieve.CheckMigrationState() |
1192 | 1190 |
1193 new_timestamp, entries, remaining = self.account.GetChanges(update_sieve) | 1191 new_timestamp, entries, remaining = self.account.GetChanges(update_sieve) |
1194 | 1192 |
1195 update_response.changes_remaining = remaining | 1193 update_response.changes_remaining = remaining |
1196 for entry in entries: | 1194 for entry in entries: |
1197 reply = update_response.entries.add() | 1195 reply = update_response.entries.add() |
1198 reply.CopyFrom(entry) | 1196 reply.CopyFrom(entry) |
1199 update_sieve.SaveProgress(new_timestamp, update_response) | 1197 update_sieve.SaveProgress(new_timestamp, update_response) |
OLD | NEW |