| OLD | NEW |
| 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 #include "sync/internal_api/public/base/model_type.h" | 5 #include "sync/internal_api/public/base/model_type.h" |
| 6 | 6 |
| 7 #include "base/strings/string_split.h" | 7 #include "base/strings/string_split.h" |
| 8 #include "base/values.h" | 8 #include "base/values.h" |
| 9 #include "sync/protocol/app_notification_specifics.pb.h" | 9 #include "sync/protocol/app_notification_specifics.pb.h" |
| 10 #include "sync/protocol/app_setting_specifics.pb.h" | 10 #include "sync/protocol/app_setting_specifics.pb.h" |
| (...skipping 429 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 440 bool IsControlType(ModelType model_type) { | 440 bool IsControlType(ModelType model_type) { |
| 441 return ControlTypes().Has(model_type); | 441 return ControlTypes().Has(model_type); |
| 442 } | 442 } |
| 443 | 443 |
| 444 ModelTypeSet CoreTypes() { | 444 ModelTypeSet CoreTypes() { |
| 445 syncer::ModelTypeSet result; | 445 syncer::ModelTypeSet result; |
| 446 result.PutAll(PriorityCoreTypes()); | 446 result.PutAll(PriorityCoreTypes()); |
| 447 | 447 |
| 448 // The following are low priority core types. | 448 // The following are low priority core types. |
| 449 result.Put(SYNCED_NOTIFICATIONS); | 449 result.Put(SYNCED_NOTIFICATIONS); |
| 450 result.Put(SYNCED_NOTIFICATION_APP_INFO); | 450 // TODO(petewil): Add synced notification app info once crbug.com/339094 is |
| 451 // fixed. |
| 451 | 452 |
| 452 return result; | 453 return result; |
| 453 } | 454 } |
| 454 | 455 |
| 455 ModelTypeSet PriorityCoreTypes() { | 456 ModelTypeSet PriorityCoreTypes() { |
| 456 syncer::ModelTypeSet result; | 457 syncer::ModelTypeSet result; |
| 457 result.PutAll(ControlTypes()); | 458 result.PutAll(ControlTypes()); |
| 458 | 459 |
| 459 // The following are non-control core types. | 460 // The following are non-control core types. |
| 460 result.Put(MANAGED_USERS); | 461 result.Put(MANAGED_USERS); |
| (...skipping 579 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1040 | 1041 |
| 1041 bool IsRealDataType(ModelType model_type) { | 1042 bool IsRealDataType(ModelType model_type) { |
| 1042 return model_type >= FIRST_REAL_MODEL_TYPE && model_type < MODEL_TYPE_COUNT; | 1043 return model_type >= FIRST_REAL_MODEL_TYPE && model_type < MODEL_TYPE_COUNT; |
| 1043 } | 1044 } |
| 1044 | 1045 |
| 1045 bool IsActOnceDataType(ModelType model_type) { | 1046 bool IsActOnceDataType(ModelType model_type) { |
| 1046 return model_type == HISTORY_DELETE_DIRECTIVES; | 1047 return model_type == HISTORY_DELETE_DIRECTIVES; |
| 1047 } | 1048 } |
| 1048 | 1049 |
| 1049 } // namespace syncer | 1050 } // namespace syncer |
| OLD | NEW |