OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 IOS_CHROME_BROWSER_UI_WEBUI_SYNC_INTERNALS_SYNC_INTERNALS_MESSAGE_HANDLE
R_H_ | 5 #ifndef IOS_CHROME_BROWSER_UI_WEBUI_SYNC_INTERNALS_SYNC_INTERNALS_MESSAGE_HANDLE
R_H_ |
6 #define IOS_CHROME_BROWSER_UI_WEBUI_SYNC_INTERNALS_SYNC_INTERNALS_MESSAGE_HANDLE
R_H_ | 6 #define IOS_CHROME_BROWSER_UI_WEBUI_SYNC_INTERNALS_SYNC_INTERNALS_MESSAGE_HANDLE
R_H_ |
7 | 7 |
8 #include <memory> | 8 #include <memory> |
9 #include <string> | 9 #include <string> |
10 | 10 |
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
60 void OnStateChanged() override; | 60 void OnStateChanged() override; |
61 | 61 |
62 // ProtocolEventObserver implementation. | 62 // ProtocolEventObserver implementation. |
63 void OnProtocolEvent(const syncer::ProtocolEvent& e) override; | 63 void OnProtocolEvent(const syncer::ProtocolEvent& e) override; |
64 | 64 |
65 // TypeDebugInfoObserver implementation. | 65 // TypeDebugInfoObserver implementation. |
66 void OnCommitCountersUpdated(syncer::ModelType type, | 66 void OnCommitCountersUpdated(syncer::ModelType type, |
67 const syncer::CommitCounters& counters) override; | 67 const syncer::CommitCounters& counters) override; |
68 void OnUpdateCountersUpdated(syncer::ModelType type, | 68 void OnUpdateCountersUpdated(syncer::ModelType type, |
69 const syncer::UpdateCounters& counters) override; | 69 const syncer::UpdateCounters& counters) override; |
70 void OnStatusCountersUpdated(syncer::ModelType type, | 70 void OnStatusCountersUpdated( |
71 const syncer::StatusCounters& counters) override; | 71 syncer::ModelType type, |
| 72 std::unique_ptr<syncer::StatusCounters> counters) override; |
72 | 73 |
73 // Helper to emit counter updates. | 74 // Helper to emit counter updates. |
74 // | 75 // |
75 // Used in implementation of On*CounterUpdated methods. Emits the given | 76 // Used in implementation of On*CounterUpdated methods. Emits the given |
76 // dictionary value with additional data to specify the model type and | 77 // dictionary value with additional data to specify the model type and |
77 // counter type. | 78 // counter type. |
78 void EmitCounterUpdate(syncer::ModelType type, | 79 void EmitCounterUpdate(syncer::ModelType type, |
79 const std::string& counter_type, | 80 const std::string& counter_type, |
80 std::unique_ptr<base::DictionaryValue> value); | 81 std::unique_ptr<base::DictionaryValue> value); |
81 | 82 |
(...skipping 12 matching lines...) Expand all Loading... |
94 // A flag used to prevent double-registration as TypeDebugInfoObserver with | 95 // A flag used to prevent double-registration as TypeDebugInfoObserver with |
95 // ProfileSyncService. | 96 // ProfileSyncService. |
96 bool is_registered_for_counters_; | 97 bool is_registered_for_counters_; |
97 | 98 |
98 base::WeakPtrFactory<SyncInternalsMessageHandler> weak_ptr_factory_; | 99 base::WeakPtrFactory<SyncInternalsMessageHandler> weak_ptr_factory_; |
99 | 100 |
100 DISALLOW_COPY_AND_ASSIGN(SyncInternalsMessageHandler); | 101 DISALLOW_COPY_AND_ASSIGN(SyncInternalsMessageHandler); |
101 }; | 102 }; |
102 | 103 |
103 #endif // IOS_CHROME_BROWSER_UI_WEBUI_SYNC_INTERNALS_SYNC_INTERNALS_MESSAGE_HAN
DLER_H_ | 104 #endif // IOS_CHROME_BROWSER_UI_WEBUI_SYNC_INTERNALS_SYNC_INTERNALS_MESSAGE_HAN
DLER_H_ |
OLD | NEW |