Skip to content

Commit

Permalink
For commit ionic-team#2676, changing audio attribute to USAGE_NOTIFIC…
Browse files Browse the repository at this point in the history
…ATION instead of USAGE_ALARM, to sync volume control as per notification volume
  • Loading branch information
dibyendusaha committed Apr 10, 2020
1 parent f012078 commit 82b84a6
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ public void createChannel(JSObject channel) {
}
AudioAttributes audioAttributes = new AudioAttributes.Builder()
.setContentType(AudioAttributes.CONTENT_TYPE_SONIFICATION)
.setUsage(AudioAttributes.USAGE_ALARM).build();
.setUsage(AudioAttributes.USAGE_NOTIFICATION).build();
Uri soundUri = Uri.parse(ContentResolver.SCHEME_ANDROID_RESOURCE + "://" + context.getPackageName() + "/raw/" + sound);
notificationChannel.setSound(soundUri, audioAttributes);
}
Expand Down

0 comments on commit 82b84a6

Please sign in to comment.