我正在尝试使用音乐播放器在我的 android 应用程序中实现上滑面板,就像在 Google Play 音乐中一样。我尝试了 Umano 库来实现上滑面板。我已经成功完成了。但我不知道如何使用音乐播放器、播放按钮等实现播放器。我已经搜索了所有地方,但找不到这样做的方法。
我的布局,包括向上滑动面板
<com.sothree.slidinguppanel.SlidingUpPanelLayout
xmlns:sothree="http://schemas.android.com/apk/res-auto"
android:id="@+id/sliding_layout"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_below="@+id/toolbar_actionbar"
android:gravity="bottom"
sothree:umanoPanelHeight="60dp"
sothree:umanoShadowHeight="4dp">
<android.support.v4.widget.DrawerLayout
android:id="@+id/drawer"
xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
>
<FrameLayout
android:id="@+id/container"
android:layout_width="match_parent"
android:clickable="true"
android:layout_height="match_parent" />
<!-- android:layout_marginTop="?android:attr/actionBarSize"-->
<fragment
android:id="@+id/fragment_drawer"
android:name="com.example.crytal.etunesdev.NavigationDrawerFragment"
android:layout_width="@dimen/navigation_drawer_width"
android:layout_height="match_parent"
android:layout_gravity="start"
app:layout="@layout/fragment_navigation_drawer"
tools:layout="@layout/fragment_navigation_drawer" />
</android.support.v4.widget.DrawerLayout>
<TextView
android:layout_width="match_parent"
android:layout_height="match_parent"
android:gravity="center"
android:text="Music Player"
android:textColor="@color/primary_text_default_material_dark"
android:background="@color/button_material_dark"
android:textStyle="bold"/>
</com.sothree.slidinguppanel.SlidingUpPanelLayout>
我用过的库——Android上滑面板
我期望做的是这样的