Yalantis / Phoenix

Phoenix Pull-to-Refresh
https://yalantis.com/
Apache License 2.0
4.01k stars 916 forks source link

problem when scrolling up #35

Closed AhmedDonkl closed 8 years ago

AhmedDonkl commented 8 years ago

i have a problem when try to scroll up as the screenshot

screenshot_2016-07-16-11-22-57 my xml `<?xml version="1.0" encoding="utf-8"?> <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:tools="http://schemas.android.com/tools" android:layout_width="match_parent" android:layout_height="match_parent" android:id="@+id/root" tools:context=".Fragments.Home">

<com.yalantis.phoenix.PullToRefreshView
    android:id="@+id/pull_to_refresh"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    >
    <RelativeLayout
        android:layout_width="match_parent"
        android:layout_height="match_parent">
        <android.support.v7.widget.RecyclerView
            android:id="@+id/home_recycler_view"
            android:layout_width="match_parent"
            android:layout_height="match_parent"

            />
        <View
            android:id="@+id/home_empty"
            android:layout_width="match_parent"
            android:layout_height="match_parent"
            android:background="@drawable/home"
            android:clickable="false"
            android:visibility="gone"
            />
    </RelativeLayout>

</com.yalantis.phoenix.PullToRefreshView>

</RelativeLayout>

`

TeeRawk commented 8 years ago

So the problem is, that when you scroll up during the animation it scrolls below the animation ?

AhmedDonkl commented 8 years ago

@TeeRawk this is the problem

https://cloud.githubusercontent.com/assets/6006148/15767171/933454cc-290b-11e6-84e6-339276c0c0ab.gif

rraayy commented 8 years ago

The same issue! https://github.com/Yalantis/Phoenix/issues/1

TeeRawk commented 8 years ago

@AhmedDonkl the problem is that you have another view besides the recyclerView in PullToRefresh view, remove it if you don't need it , or place it outside the PullToRefreshView viewgroup.