2015-10-19 195 views
0

我使用Eclipse Android开发。我在我的应用程序中使用了swipeRefreshLayout。我的问题是,当我滑动戒指(圆形动画)时,不会显示动画,而是显示线条水平类型,但是我固定的滑动的颜色工作正常,而且我想在滑动时拍摄一些距离和时间。请帮助我如何在滑动时显示圆形旋转动画。刷卡刷新布局动画的android

<android.support.v4.widget.SwipeRefreshLayout 
       android:id="@+id/swipe_refresh" 
       android:layout_width="match_parent" 
       android:layout_height="match_parent" 
       android:focusable="true" > 

       <android.support.v4.view.ViewPager 
        android:id="@+id/pager" 
        android:layout_width="match_parent" 
        android:layout_height="match_parent" 
        android:layout_weight="8" /> 
      </android.support.v4.widget.SwipeRefreshLayout> 

,并请参阅下面的图像

enter image description here

我想说明这样

在此先感谢

+0

你在使用添加swipeRefreshLayout?你可以粘贴布局文件吗? –

+0

你会请参考我的编辑帖子刚才我编辑我的问题与代码和图像 – user1784588

+0

什么是你的targetSdkVersion? –

回答

1

你的问题的答案是,你不能与支持库一起使用。 Android将根据您的应用程序正在执行的操作系统版本来处理要显示的动画。

看看这个answer

SwipeRefreshLayout负责在其顶部,以显示其预定的动画你

你可以试试库,如this,但我建议症结到Google上,让动画自行处理。