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

Unified Diff: chrome/android/java/src/org/chromium/chrome/browser/AppHooks.java

Issue 2797573002: Fix startForegroundService API calls. (Closed)
Patch Set: Addressed comments Created 3 years, 8 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 | « no previous file | chrome/android/java/src/org/chromium/chrome/browser/download/DownloadNotificationService.java » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/android/java/src/org/chromium/chrome/browser/AppHooks.java
diff --git a/chrome/android/java/src/org/chromium/chrome/browser/AppHooks.java b/chrome/android/java/src/org/chromium/chrome/browser/AppHooks.java
index c4d114bf9494e264602d549bfb0ea2670a149cb1..a42905c23f14a1f06b39f66337392acd8548854d 100644
--- a/chrome/android/java/src/org/chromium/chrome/browser/AppHooks.java
+++ b/chrome/android/java/src/org/chromium/chrome/browser/AppHooks.java
@@ -269,19 +269,13 @@ public abstract class AppHooks {
}
/**
- * Starts a service from {@code intent}. Meant to eventually be used by services that want to
- * be put into the foreground with {@code notification} via
- * {@link android.app.Service#startForeground(int, Notification)}.
+ * Starts a service from {@code intent} with the expectation that it will make itself a
+ * foreground service with {@link android.app.Service#startForeground(int, Notification)}.
*
* @param intent The {@link Intent} to fire to start the service.
- * @param notificationId The id of the notification to show.
- * @param notification The {@link Notification} to show.
*/
@SuppressWarnings("Unused")
- public void startServiceWithNotification(
- Intent intent, int notificationId, Notification notification) {
- // TODO(dtrainor): Eventually make sure the service gets put into the foreground with
- // {@link android.app.Service#startForeground(int, Notification)}.
+ public void startForegroundService(Intent intent) {
ContextUtils.getApplicationContext().startService(intent);
}
« no previous file with comments | « no previous file | chrome/android/java/src/org/chromium/chrome/browser/download/DownloadNotificationService.java » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698