huanghaibin-dev / CalendarView

Android上一个优雅、万能自定义UI、仿iOS、支持垂直、水平方向切换、支持周视图、自定义周起始、性能高效的日历控件,支持热插拔实现的UI定制!支持标记、自定义颜色、农历、自定义月视图各种显示模式等。Canvas绘制,速度快、占用内存低,你真的想不到日历居然还可以如此优雅!An elegant, highly customized and high-performance Calendar Widget on Android.
Apache License 2.0
9.04k stars 1.78k forks source link

初始默认隐藏布局:mCalendarLayout.hideCalendarView() 时下方的RecyclerView高度总是wrap_content #838

Open dengzibo504 opened 9 months ago

dengzibo504 commented 9 months ago

我想要让它match_parent

布局文件: <com.haibin.calendarview.CalendarLayout android:layout_width="match_parent" android:layout_height="wrap_content" android:id="@+id/header_calendar_layout" android:orientation="vertical" app:calendar_show_mode="both_month_week_view" app:calendar_content_view_id="@id/recyclerview_task" app:default_status="shrink">

            <com.haibin.calendarview.CalendarView
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                android:id="@+id/calendar_view_bar"
                android:gravity="bottom"
                app:select_mode="single_mode"
                app:week_start_with="mon"
                app:week_bar_view="com.dzb.mytasklist.widget.DateWeekBar"
                app:week_view="com.dzb.mytasklist.widget.DateWeekView"
                app:month_view="com.dzb.mytasklist.widget.DateMonthView"
                app:month_view_show_mode="mode_only_current" />

            <androidx.recyclerview.widget.RecyclerView
                android:id="@+id/recyclerview_task"
                android:layout_width="match_parent"
                android:layout_height="match_parent"
                android:background="@color/WhiteSmoke" />

        </com.haibin.calendarview.CalendarLayout>