Skip to content
Snippets Groups Projects
Commit 9ab3bdd1 authored by Geoffrey Métais's avatar Geoffrey Métais
Browse files

Simplify code

parent 9d1a6f2f
No related branches found
No related tags found
No related merge requests found
......@@ -235,18 +235,10 @@ public class PopupManager implements PlaybackService.Callback, GestureDetector.O
private Handler mHandler = new Handler(Looper.getMainLooper()) {
@Override
public void handleMessage(Message msg) {
switch (msg.what) {
case SHOW_BUTTONS:
mPlayPauseButton.setVisibility(View.VISIBLE);
mCloseButton.setVisibility(View.VISIBLE);
mExpandButton.setVisibility(View.VISIBLE);
break;
case HIDE_BUTTONS:
mPlayPauseButton.setVisibility(View.GONE);
mCloseButton.setVisibility(View.GONE);
mExpandButton.setVisibility(View.GONE);
break;
}
int visibility = msg.what == SHOW_BUTTONS ? View.VISIBLE : View.GONE;
mPlayPauseButton.setVisibility(visibility);
mCloseButton.setVisibility(visibility);
mExpandButton.setVisibility(visibility);
}
};
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment