首页 > 解决方案 > 像 BottomAppBar 垂直的东西?

问题描述

我想使用类似com.google.android.material.bottomappbar.BottomAppBar,但垂直的东西来放入land我的相机活动的活动。

我尝试使用,AppBarLayout但结果不一样。

<androidx.coordinatorlayout.widget.CoordinatorLayout
        android:id="@+id/linearLayout"
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        android:layout_gravity="bottom"
        android:layout_marginStart="8dp"
        android:layout_marginEnd="8dp"
        android:layout_marginBottom="8dp"
        android:gravity="center_vertical"
        android:orientation="horizontal"
        android:weightSum="3"
        app:layout_constraintBottom_toBottomOf="parent"
        app:layout_constraintEnd_toEndOf="parent"
        app:layout_constraintStart_toEndOf="@id/camera"
        >


        <com.google.android.material.appbar.AppBarLayout
            android:id="@+id/actuacion_cameraAppBar"
            android:layout_width="80dp"
            android:layout_height="match_parent"
            android:verticalScrollbarPosition="right"
            android:layout_gravity="right"
            app:fabAlignmentMode="center"
            
            />

        <com.google.android.material.floatingactionbutton.FloatingActionButton
            android:id="@+id/actuacion_camara_tomar_foto"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:contentDescription="@string/foto_actuacion"
            android:onClick="onClick"
            app:backgroundTint="@color/colorPrimary"
            app:layout_anchor="@id/actuacion_cameraAppBar"
            app:srcCompat="@drawable/ic_baseline_photo_camera_24"
            app:tint="@color/browser_actions_bg_grey" />

</androidx.coordinatorlayout.widget.CoordinatorLayout>

任何想法?

标签: androidandroid-layout

解决方案


推荐阅读