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

Unified Diff: chrome/browser/sync/engine/syncer_thread.h

Issue 2075012: Replace changes_channel with an observer list. (Closed)
Patch Set: Ready for checkin Created 10 years, 6 months 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/sync/engine/syncer_end_command.cc ('k') | chrome/browser/sync/engine/syncer_thread.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/sync/engine/syncer_thread.h
diff --git a/chrome/browser/sync/engine/syncer_thread.h b/chrome/browser/sync/engine/syncer_thread.h
index 5a34b97b22bfcefa1211537191ee30b362aa2612..552f3c8f2bef6ec20fda0b26cc3c82034d035a60 100644
--- a/chrome/browser/sync/engine/syncer_thread.h
+++ b/chrome/browser/sync/engine/syncer_thread.h
@@ -46,7 +46,8 @@ struct SyncerEvent;
struct SyncerShutdownEvent;
class SyncerThread : public base::RefCountedThreadSafe<SyncerThread>,
- public sessions::SyncSession::Delegate {
+ public sessions::SyncSession::Delegate,
+ public ChannelEventHandler<SyncerEvent> {
FRIEND_TEST(SyncerThreadTest, CalculateSyncWaitTime);
FRIEND_TEST(SyncerThreadTest, CalculatePollingWaitTime);
FRIEND_TEST(SyncerThreadWithSyncerTest, Polling);
@@ -220,7 +221,7 @@ class SyncerThread : public base::RefCountedThreadSafe<SyncerThread>,
void* Run();
void HandleDirectoryManagerEvent(
const syncable::DirectoryManagerEvent& event);
- void HandleSyncerEvent(const SyncerEvent& event);
+ void HandleChannelEvent(const SyncerEvent& event);
// SyncSession::Delegate implementation.
virtual void OnSilencedUntil(const base::TimeTicks& silenced_until);
@@ -302,7 +303,7 @@ class SyncerThread : public base::RefCountedThreadSafe<SyncerThread>,
void NudgeSyncImpl(int milliseconds_from_now, NudgeSource source);
scoped_ptr<EventListenerHookup> directory_manager_hookup_;
- scoped_ptr<EventListenerHookup> syncer_events_;
+ scoped_ptr<ChannelHookup<SyncerEvent> > syncer_events_;
#if defined(OS_LINUX)
// On Linux, we need this information in order to query idle time.
« no previous file with comments | « chrome/browser/sync/engine/syncer_end_command.cc ('k') | chrome/browser/sync/engine/syncer_thread.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698