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

Unified Diff: chrome/browser/background_sync/background_sync_controller_impl.cc

Issue 1324173002: [Background Sync] Use GcmNetworkManager to start the browser for sync events. (Closed) Base URL: https://chromium.googlesource.com/chromium/src@bgsync-fix-background5
Patch Set: Make BackgroundSyncLauncher testable Created 5 years, 2 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
Index: chrome/browser/background_sync/background_sync_controller_impl.cc
diff --git a/chrome/browser/background_sync/background_sync_controller_impl.cc b/chrome/browser/background_sync/background_sync_controller_impl.cc
index 7668229690e3eeca3f654ef0cb9ff39102c5b878..7412eddf265ce863b5da8155e9a5e7d96ff823b4 100644
--- a/chrome/browser/background_sync/background_sync_controller_impl.cc
+++ b/chrome/browser/background_sync/background_sync_controller_impl.cc
@@ -8,6 +8,10 @@
#include "chrome/browser/profiles/profile.h"
#include "components/rappor/rappor_utils.h"
+#if defined(OS_ANDROID)
+#include "chrome/browser/android/background_sync_launcher_android.h"
+#endif
+
BackgroundSyncControllerImpl::BackgroundSyncControllerImpl(Profile* profile)
: profile_(profile) {}
@@ -28,3 +32,13 @@ void BackgroundSyncControllerImpl::NotifyBackgroundSyncRegistered(
rappor::SampleDomainAndRegistryFromGURL(
GetRapporService(), "BackgroundSync.Register.Origin", origin);
}
+
+#if defined(OS_ANDROID)
+void BackgroundSyncControllerImpl::LaunchBrowserWhenNextOnline(
+ const content::BackgroundSyncManager* registrant,
+ bool launch_when_next_online) {
+ DCHECK_CURRENTLY_ON(content::BrowserThread::UI);
+ BackgroundSyncLauncherAndroid::LaunchBrowserWhenNextOnline(
+ registrant, launch_when_next_online);
+}
+#endif

Powered by Google App Engine
This is Rietveld 408576698