Skip to content
This repository has been archived by the owner on Nov 1, 2020. It is now read-only.

Commit

Permalink
Remove unused intent in NiNotification
Browse files Browse the repository at this point in the history
Bug: 154319182
Test: manual
Change-Id: I5958a8fb442cf4506e1824243493f91aea34a7cc
Merged-In: I5958a8fb442cf4506e1824243493f91aea34a7cc
(cherry picked from commit 8b7811c)
  • Loading branch information
Yu-Han Yang authored and anisassigoogle committed Aug 7, 2020
1 parent 2b71d2b commit 620bc73
Showing 1 changed file with 1 addition and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@

import android.app.Notification;
import android.app.NotificationManager;
import android.app.PendingIntent;
import android.content.BroadcastReceiver;
import android.content.Context;
import android.content.Intent;
Expand Down Expand Up @@ -402,13 +401,9 @@ private synchronized void setNiNotification(GpsNiNotification notif) {
mNiNotificationBuilder.setDefaults(0);
}

// if not to popup dialog immediately, pending intent will open the dialog
Intent intent = !mPopupImmediately ? getDlgIntent(notif) : new Intent();
PendingIntent pi = PendingIntent.getBroadcast(mContext, 0, intent, 0);
mNiNotificationBuilder.setTicker(getNotifTicker(notif, mContext))
.setContentTitle(title)
.setContentText(message)
.setContentIntent(pi);
.setContentText(message);

notificationManager.notifyAsUser(null, notif.notificationId, mNiNotificationBuilder.build(),
UserHandle.ALL);
Expand Down

0 comments on commit 620bc73

Please sign in to comment.