android-nestedscrollview

Child inside NestedScrollView not cover full height of screen

ぐ巨炮叔叔 提交于 2020-12-01 08:22:52
问题 I am using NestedScrollView in my fragment. In my xml inside a RelativeLayout but it is not covering full height of screen. Below is my code - <?xml version="1.0" encoding="utf-8"?> <android.support.v4.widget.NestedScrollView xmlns:android="http://schemas.android.com/apk/res/android" android:orientation="vertical" android:fitsSystemWindows="true" android:background="@color/black" android:layout_width="match_parent" android:layout_height="match_parent"> <RelativeLayout android:background="

Saving scroll state of NestedScrollView

自作多情 提交于 2020-08-24 06:27:26
问题 My application revolves around a HomeActivity which contains 4 tabs at the bottom. Each of these tabs is a fragment, all of them are added (not replaced) from the start, and they are hidden/shown upon tapping the appropriate tab. My problem is that whenever I change tab, the state of my scroll is lost. Each fragment which exhibits that issue uses a android.support.v4.widget.NestedScrollView (see below for an example). Note: My fragments that use a RecyclerView or ListView keep their scroll

Part of the content of a CollapsingToolbarLayout is getting sticky on top, when used with viewpager and recyclerview

社会主义新天地 提交于 2020-05-23 04:31:45
问题 I am trying to implement a layout like this: The issue is that when scrolling up the card touches the toolbar and it does not go up anymore like this: I want it to scroll up till the viewpager to fills the screen ie, at least the rectangle card, should scroll up beyond the toolbar(Even the tabLayout can also scroll up). But I don't want it to stay sticky at the top. The main layout is here: <?xml version="1.0" encoding="utf-8"?> <androidx.coordinatorlayout.widget.CoordinatorLayout xmlns

BottomSheet fly away with visibility change

℡╲_俬逩灬. 提交于 2020-05-09 19:40:45
问题 I have a bottom sheet with a NestedScrollView inside (see below). When I press on a FAB button, I want to make some parts in this NestedScrollView invisible. But when I change some linearlayouts visibilities to GONE, bottomsheet fly aways from the top. See here: You can get the whole code from https://github.com/Tanrikut/BottomSheetExample My change visibility method: private void changeVisibility() { subtitleLayout.setVisibility(View.GONE); coordinateLayout.setVisibility(View.GONE);

BottomSheet fly away with visibility change

谁说我不能喝 提交于 2020-05-09 19:38:36
问题 I have a bottom sheet with a NestedScrollView inside (see below). When I press on a FAB button, I want to make some parts in this NestedScrollView invisible. But when I change some linearlayouts visibilities to GONE, bottomsheet fly aways from the top. See here: You can get the whole code from https://github.com/Tanrikut/BottomSheetExample My change visibility method: private void changeVisibility() { subtitleLayout.setVisibility(View.GONE); coordinateLayout.setVisibility(View.GONE);

How to set the Maximum Height for a NestedScrollView in Android?

非 Y 不嫁゛ 提交于 2020-01-23 06:52:34
问题 I have a NestedScrollView within a ScrollView . the NestedScrollView contains a TextView . So when the TextView expands above 4 or n lineas, I need to make it Scrollable TextView . Any help is much appreciated!! 回答1: I have face the same problem, and a fixed height wouldn't help because it could be bigger than my TextView, so i created this class import android.content.Context; import android.util.AttributeSet; import androidx.annotation.NonNull; import androidx.annotation.Nullable; import

Android -FAB Behaviour with half list

百般思念 提交于 2020-01-17 06:09:53
问题 I have the FAB working when recyclerview has enough items to scroll, but i need to handle the case when recyclerview does not scroll (the total of items do not cover the screen). At the moment this is how I handle the scroll: public class FABBehavior extends FloatingActionButton.Behavior { public FABBehavior() { super(); } public FABBehavior(final Context context, final AttributeSet attrs) { super(context, attrs); } @Override public void onNestedScroll(final CoordinatorLayout

BottomSheet: issue with nested scrolling (RecyclerView & NestedScrollView)

流过昼夜 提交于 2020-01-16 16:48:15
问题 I have a rather complex BottomSheetLayout which layout is as follow The root view of my bottom sheet is a custom FrameLayout that allows to round it's corner (both background and children). Nothing else (nothing touch-related) Then, I use the usual ConstraintLayout in order to layout my Bottom sheet. This ConstraintLayout contains, amongst other views, a vertical RecyclerView : <androidx.constraintlayout.widget.ConstraintLayout android:layout_width="match_parent" android:layout_height="match

android : NestedScrollview bottom two button attached

亡梦爱人 提交于 2020-01-12 10:15:34
问题 I am trying to create Android product layout. In footer have two buttons it is fixed button. you can see images when I am scrolling up bottom two buttons attached in my layout. Please help how can i do? Image 1 Image 2 after scrolling xml <?xml version="1.0" encoding="utf-8"?> <android.support.design.widget.CoordinatorLayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:app="http://schemas.android.com/apk/res-auto" xmlns:tools="http://schemas.android.com/tools" android:id="