thewaychung / expandablegridview Goto Github PK
View Code? Open in Web Editor NEWAndroid customized expandable GridView
License: Apache License 2.0
Android customized expandable GridView
License: Apache License 2.0
Hi Chung,
excellent work!
I need to add a title to ExpandableGridView. When I expand the item selected the top title disappears, when I close reappears!
Could you please suggest me if is it possible to add a top offset to prevent this type of behavior?
Thanks in advance!
Hi Chung,
Very Great work!!
I need to add a listview as child view.
Can you please suggest me how to do that.
Many Thankful to you in advance.
Hi Chung,
instead of ArrayAdapter adapter I used my custom GridAdapter with a XML layout definition (images and text).
`
<RelativeLayout
android:id="@+id/RelativeLayoutGrid"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:paddingBottom="5dp"
android:paddingLeft="5dp"
android:paddingRight="5dp"
android:paddingTop="5dp">
<CheckBox
android:id="@+id/checkBoxPreferred"
android:layout_width="20dp"
android:layout_height="20dp"
android:layout_alignParentRight="true"
android:layout_marginEnd="5dp"
android:layout_marginTop="5dp"
android:background="@drawable/btn_star_selector"
android:button="@null" />
<LinearLayout
android:id="@+id/type"
android:layout_width="match_parent"
android:layout_height="60dp"
android:layout_alignParentLeft="true"
android:layout_alignParentStart="true"
android:layout_below="@+id/checkBoxPreferred"
android:orientation="horizontal"
android:paddingLeft="20dp"
android:paddingRight="20dp">
<ImageView
android:id="@+id/thumbnail"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_weight="1" />
<android.support.v4.widget.Space
android:layout_width="2dp"
android:layout_height="0dp" />
<ImageView
android:id="@+id/thumbnail2"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_weight="1" />
</LinearLayout>
<TextView
android:id="@+id/title"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_below="@id/type"
android:layout_centerHorizontal="true"
android:paddingLeft="5dp"
android:paddingRight="5dp"
android:paddingTop="5dp"
android:textColor="#4c4c4c"
android:textSize="15sp" />
</RelativeLayout>
`
I don't understand why the ExpandableGridView setOnItemClickListener() not working; have you any idea why not?
Thanks in advance!
Edit
Solved!
It is the CheckBox!
It is necessary to not use clickable objects in the grid. ;)
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.