Sophii Donnay has worked in various roles in the entertainment industry since 2014. Her first job was as a Professional Creator at OhMySophii. Sophii then moved on to become a Social Media Manager at Midwest eSports in 2019. Prior to that, they were a Social Media Manager at Wizard's Asylum ICT in 2015 and a Expo Models at Amanda Lynn Chainmaille in 2016. Sophii also worked as a Social Media Marketing Manager at CybertronPC in 2016, as a Cosplay Coordinators at Esports Wichita in 2015, and as a Head of Operations/Head of Marketing and Cosplayer/Promotional Model at Ichico Comics in 2014.
package com.example.android.miwok;
import android.content.Context;
import android.media.AudioManager;
import android.media.MediaPlayer;
import android.support.v7.app.AppCompatActivity;
import android.os.Bundle;
import android.view.View;
import android.widget.AdapterView;
import android.widget.ListView;
import java.util.ArrayList;
public class ColorsActivity extends AppCompatActivity {
private MediaPlayer mediaPlayer;
private AudioManager mAudioManager;
AudioManager.OnAudioFocusChangeListener mOnAudioFocusChangeListener =
new AudioManager.OnAudioFocusChangeListener() {
public void onAudioFocusChange(int focusChange) {
if (focusChange == AudioManager.AUDIOFOCUS_LOSS_TRANSIENT ||
focusChange == AudioManager.AUDIOFOCUS_LOSS_TRANSIENT_CAN_DUCK) {
// Pause playback
mediaPlayer.pause();
mediaPlayer.seekTo(0);
} else if (focusChange == AudioManager.AUDIOFOCUS_GAIN) {
// Resume playback
mediaPlayer.start();
} else if (focusChange == AudioManager.AUDIOFOCUS_LOSS) {
// Stop playback
releaseMediaPlayer();
}
}
};
private MediaPlayer.OnCompletionListener mCompletionListener = new MediaPlayer.OnCompletionListener() {
@Override
public void onCompletion(MediaPlayer mediaPlayer) {
// Now that the sound file has finished playing, release the media player resources.
releaseMediaPlayer();
}
};
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.word_list);
// Create and setup the {@link AudioManager} to request audio focus
mAudioManager = (AudioManager) getSystemService(Context.AUDIO_SERVICE);
// Create an array of words
final ArrayList<Word> words = new ArrayList
Sign up to view 0 direct reports
Get started