square / android-times-square

Standalone Android widget for picking a single date from a calendar view.
Apache License 2.0
4.45k stars 1.18k forks source link

CalendarPickerView inside ScrollView -> scrolls didn't work on kitkat #401

Closed yaseen-homage closed 7 years ago

yaseen-homage commented 7 years ago
<ScrollView
            android:layout_width="match_parent"
            android:layout_height="match_parent"
            android:padding="20dp"
            android:scrollbars="none">
 <com.squareup.timessquare.CalendarPickerView
                    android:id="@+id/calendar_view"
                    android:layout_width="match_parent"
                    android:layout_height="wrap_content" />
</ScrollView>
edenman commented 7 years ago

CalendarPickerView is a ListView, so you can't put it in a ScrollView. If you just need to show a month or two inside a scrollable view, you can use MonthView directly (although the API is not exactly optimized for this usecase, so you'll have to look around the source to figure out all the MonthView.create params)