Merge pull request #2068 from MeirSD/develop
Fix issue where mini player doesn't show up
This commit is contained in:
commit
ef31878a10
|
@ -209,6 +209,8 @@ public class PlaybackService extends MediaBrowserServiceCompat {
|
||||||
|
|
||||||
private static volatile MediaType currentMediaType = MediaType.UNKNOWN;
|
private static volatile MediaType currentMediaType = MediaType.UNKNOWN;
|
||||||
|
|
||||||
|
private final IBinder mBinder = new LocalBinder();
|
||||||
|
|
||||||
public class LocalBinder extends Binder {
|
public class LocalBinder extends Binder {
|
||||||
public PlaybackService getService() {
|
public PlaybackService getService() {
|
||||||
return PlaybackService.this;
|
return PlaybackService.this;
|
||||||
|
@ -384,7 +386,11 @@ public class PlaybackService extends MediaBrowserServiceCompat {
|
||||||
@Override
|
@Override
|
||||||
public IBinder onBind(Intent intent) {
|
public IBinder onBind(Intent intent) {
|
||||||
Log.d(TAG, "Received onBind event");
|
Log.d(TAG, "Received onBind event");
|
||||||
|
if(intent.getAction() != null && TextUtils.equals(intent.getAction(), MediaBrowserServiceCompat.SERVICE_INTERFACE)) {
|
||||||
return super.onBind(intent);
|
return super.onBind(intent);
|
||||||
|
} else {
|
||||||
|
return mBinder;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
Loading…
Reference in New Issue