PullToRefreshListView xml 写法
xml 代码 : <com.handmark.pulltorefresh.library.PullToRefreshListView xmlns:ptr="http://schemas.android.com/apk/res-auto"android:id="@+id/pull_refresh_list" android:layout_width="fill_parent" android:layout_height="fill_parent" android:layout_weight="1" android:background="#eeeeee" android:cacheColorHint="#00000000" android:divider="#00000000" android:fadingEdge="none" android:fastScrollEnabled="true" android:footerDividersEnabled="false" android:headerDividersEnabled="false" android:listSelector="#00000000" android:overScrollMode="never" android:scrollbars="none" android:smoothScrollbar="true" ptr:ptrAnimationStyle="flip" ptr:ptrHeaderBackground="#a0ffffff" ptr:ptrHeaderTextColor="#606060" ptr:ptrMode="both" ptr:ptrOverScroll="false" ptr:ptrShowIndicator="false" ptr:ptrDrawable="@drawable/ic_launcher" /> /** *PullToRefreshListView工具类 **/ public class PullToRefreshListViewUtil { /** * 设置操作PullToRefreshListView时提示文字 * @param listView */ public static void setPullText(PullToRefreshListView listView) { listView.getLoadingLayoutProxy().setPullLabel("下拉可刷新"); listView.getLoadingLayoutProxy().setReleaseLabel("释放刷新"); listView.getLoadingLayoutProxy().setRefreshingLabel("正在刷新中..."); listView.getLoadingLayoutProxy(false,true).setPullLabel("上拉加载更多"); listView.getLoadingLayoutProxy(false,true).setReleaseLabel("释放刷新"); listView.getLoadingLayoutProxy(false,true).setRefreshingLabel("正在加载中..."); } } (编辑:李大同) 【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容! |