Class of android.widget · MediaController.java · Android's reference
public class MediaController extends FrameLayout
MediaController ← FrameLayout ← ViewGroup ← View
The controls of a media player: play, pause and seek. On Android they show in a window over the anchor view. The runtime has no such window, so the controller keeps its state and the app drives the player.
public MediaController(Context context, AttributeSet attrs) sourcepublic MediaController(Context context, boolean useFastForward) sourcepublic MediaController(Context context) sourcepublic void setMediaPlayer(MediaPlayerControl player) sourcepublic void setAnchorView(View view) empty body sourcepublic void show() sourcepublic void show(int timeout) sourceShows the controls; they hide after the timeout, or stay until hide() when the timeout is 0.
public boolean isShowing() sourcepublic void hide() sourcepublic void setPrevNextListeners(View.OnClickListener next, View.OnClickListener prev) empty body sourcepublic boolean onTouchEvent(MotionEvent event) sourcepublic CharSequence getAccessibilityClassName() sourceMade from ScarletNX's Sail at 166ad3910f80. The framework is ScarletNX's (GPL-3.0-or-later); the parts that follow the Android Open Source Project's sources (Apache-2.0) say so in their files.