#include "chrome/browser/sync/sync_startup_tracker.h"
#include <optional>
#include "base/functional/bind.h"
#include "base/notreached.h"
#include "components/sync/service/sync_service.h"
namespace {
constexpr base::TimeDelta kDefaultWaitTimeout = …;
std::optional<base::TimeDelta> g_wait_timeout = …;
}
SyncStartupTracker::SyncStartupTracker(syncer::SyncService* sync_service,
SyncStartupStateChangedCallback callback)
: … { … }
SyncStartupTracker::~SyncStartupTracker() = default;
void SyncStartupTracker::OnStateChanged(syncer::SyncService* sync) { … }
void SyncStartupTracker::OnStartupTimeout() { … }
void SyncStartupTracker::CheckServiceState() { … }
SyncStartupTracker::ServiceStartupState
SyncStartupTracker::GetServiceStartupState(syncer::SyncService* sync_service) { … }
namespace testing {
ScopedSyncStartupTimeoutOverride::ScopedSyncStartupTimeoutOverride(
std::optional<base::TimeDelta> wait_timeout) { … }
ScopedSyncStartupTimeoutOverride::~ScopedSyncStartupTimeoutOverride() { … }
}