• 微信号:Zh-y9213
您当前的位置:爱资源分享网 > > 网站源码 > 程序源码

一个支持header和footer的gridview

栏目:程序源码时间:2021-11-20 00:32阅读数:60人阅读

GridView的页眉和页脚

该库包含CUBE-SDK:https://github.com/etao-open-source/cube-sdk。该演示是在这里:https://github.com/liaohuqiu/android-cube-app。

Maven

<dependency>
    <groupId>in.srain.cube</groupId>
    <artifactId>grid-view-with-header-footer</artifactId>
    <type>jar</type>
    <version>1.0.12</version>
</dependency>

Gradle

compile 'in.srain.cube:grid-view-with-header-footer:1.0.12'

Usage

 

GridViewWithHeaderAndFooter gridView = (GridViewWithHeaderAndFooter) v.findViewById(R.id.ly_image_list_grid);

LayoutInflater layoutInflater = LayoutInflater.from(this);
View headerView = layoutInflater.inflate(R.layout.test_header_view, null);
View footerView = layoutInflater.inflate(R.layout.test_footer_view, null);
gridView.addHeaderView(headerView);
gridView.addFooterView(footerView);


资源均来自第三方,谨慎下载,前往第三方网站下载

本站所有文章、数据、图片均来自互联网,一切版权均归源网站或源作者所有。

如果侵犯了你的权益请来信告知我们删除。邮箱:737597453@qq.com