Code example for MediaController

Methods: show

0
		setContentView(R.layout.audioplayerwmediacontrol);
	} 
 
	@Override 
	public boolean onTouchEvent(MotionEvent event) {
		controller.show(0);
		return super.onTouchEvent(event);
	} 
 
	///////////////////////////////// 
	// MediaPlayer related methods // 
	///////////////////////////////// 
	private void initializeMediaPlayer() { 
		try { 
			if(mediaReference == null) {
				mediaplayer = MediaPlayer.create(this, R.raw.example);
			} else { 
				mediaplayer = new MediaPlayer();
				mediaplayer.setDataSource(this, mediaReference);
				mediaplayer.prepare();
			}