Skip to content

Commit

Permalink
change notification importance to low
Browse files Browse the repository at this point in the history
  • Loading branch information
ashrafzadeh committed Sep 5, 2018
1 parent 8b46512 commit 9513088
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -330,6 +330,7 @@ public void cleanupPlayer(Context context, boolean notify, boolean stopService)
public void cleanupPlayer(boolean notify, boolean stopService) {
handlePauseRequest();
audioPlayback.stop(true);

if (stopService) {
Intent intent = new Intent(context, AudioStreamingService.class);
context.stopService(intent);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,7 @@ public void run() {
}

Bitmap albumArt = null;

Notification notification = null;
private void createNotification(MediaMetaData mSongDetail) {
try {
String songName = mSongDetail.getMediaTitle();
Expand All @@ -192,11 +192,11 @@ private void createNotification(MediaMetaData mSongDetail) {
}


Notification notification = null;

CharSequence name = getString(R.string.app_name);
boolean androidOPlus = false;
if (android.os.Build.VERSION.SDK_INT >= android.os.Build.VERSION_CODES.O) {
int importance = android.app.NotificationManager.IMPORTANCE_HIGH;
int importance = android.app.NotificationManager.IMPORTANCE_LOW;
NotificationChannel mChannel = new NotificationChannel(CHANNEL_ID, name, importance);
android.app.NotificationManager mNotificationManager =
(android.app.NotificationManager) getSystemService(Context.NOTIFICATION_SERVICE);
Expand Down

0 comments on commit 9513088

Please sign in to comment.