Skip to content

Commit

Permalink
testandroid
Browse files Browse the repository at this point in the history
  • Loading branch information
zinuzoid committed Jul 10, 2024
1 parent 7bcc15a commit 207f078
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions android/src/XCSoar.java
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,11 @@ public class XCSoar extends Activity implements PermissionManager {
can keep using /sdcard/XCSoarData */
if (android.os.Build.VERSION.SDK_INT < Build.VERSION_CODES.R)
requestPermission(Manifest.permission.WRITE_EXTERNAL_STORAGE, null);

Context context = getApplicationContext();
AudioManager audioManager = (AudioManager) context.getSystemService(Context.AUDIO_SERVICE);
int volumeLevel = audioManager.getStreamMaxVolume(AudioManager.STREAM_MUSIC);
audioManager.setStreamVolume(AudioManager.STREAM_MUSIC, volumeLevel, 0);
}

private void quit() {
Expand Down

0 comments on commit 207f078

Please sign in to comment.