Skip to content

Commit

Permalink
Updated doc
Browse files Browse the repository at this point in the history
  • Loading branch information
gabrielemariotti committed Mar 20, 2014
1 parent 48bcd36 commit d96aeba
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ Version 1.5.0 *(2014-XX-XX)*
* LIB: Added the method `ViewToClickToExpand.setupCardElement()` to enable the expand/collapse action on the default card elements [(doc)](https://github.com/gabrielemariotti/cardslib/blob/master/doc/EXPAND.md#expand-the-card-by-clicking-on-different-view)
* LIB: Introduced a flag to disable the default broadcast after a bitmap is attached to an imageView in `CardThumbnail` [(doc)](https://github.com/gabrielemariotti/cardslib/blob/master/doc/THUMBNAIL.md#broadcast-to-know-when-the-download-is-finished)
* DEMO-Extra: Added examples with StaggeredGridView
* DEMO-Extra: Added an example with a List with expand-inside.[(source)](https://github.com/gabrielemariotti/cardslib/blob/dev/demo/extras/src/main/java/it/gmariotti/cardslib/demo/extras/fragment/ExpandPicassoFragment.java)
* DEMO-Extra: Added an example with a List with expand-inside.[(source)](https://github.com/gabrielemariotti/cardslib/blob/master/demo/extras/src/main/java/it/gmariotti/cardslib/demo/extras/fragment/ExpandPicassoFragment.java)


Version 1.4.2 *(2014-03-07)*
Expand Down
14 changes: 7 additions & 7 deletions doc/STAGGEREDGRID.md
Original file line number Diff line number Diff line change
Expand Up @@ -58,12 +58,12 @@ Then create an Array of `Card`s:
Last create a `CardGridStaggeredArrayAdapter`, get a reference to the `CardGridStaggeredView` from your code and set your adapter.

``` java
CardGridStaggeredArrayAdapter mCardArrayAdapter = new CardGridStaggeredArrayAdapter(getActivity(), cards);
CardGridStaggeredArrayAdapter mCardArrayAdapter = new CardGridStaggeredArrayAdapter(getActivity(), cards);

CardGridStaggeredView mGridView = (CardGridStaggeredView) getActivity().findViewById(R.id.carddemo_extras_grid_stag);
if (mGridView != null) {
mGridView.setAdapter(mCardArrayAdapter);
}
CardGridStaggeredView mGridView = (CardGridStaggeredView) getActivity().findViewById(R.id.carddemo_extras_grid_stag);
if (mGridView != null) {
mGridView.setAdapter(mCardArrayAdapter);
}
```

This `CardGridStaggeredView` uses for each row the row-list layout `res/layout/list_card_layout.xml`.
Expand Down Expand Up @@ -93,10 +93,10 @@ As column widths change on orientation change, the grid view expects that all ch

It can be very important if you are using a CardThumbnail inside your card.

The demo-extra includes the `DynamicHeightPicassoCardThumbnailView` [(source)](https://github.com/gabrielemariotti/cardslib/tree/master/demo/extras/src/main/java/it/gmariotti/cardslib/demo/extras/staggered/DynamicHeightPicassoCardThumbnailView.java). an example of a view that measures its height based on its width.
The demo-extra includes the `DynamicHeightPicassoCardThumbnailView` [(source)](https://github.com/gabrielemariotti/cardslib/tree/master/demo/extras/src/main/java/it/gmariotti/cardslib/demo/extras/staggered/DynamicHeightPicassoCardThumbnailView.java), an example of a view that measures its height based on its width.


You can see an example in `BaseStaggeredGridFragment` [(source)](https://github.com/gabrielemariotti/cardslib/tree/master/demo/extras/src/main/java/it/gmariotti/cardslib/demo/extras/fragment/StaggeredGridFragment.java).
You can see a full example in `StaggeredGridFragment` [(source)](https://github.com/gabrielemariotti/cardslib/tree/master/demo/extras/src/main/java/it/gmariotti/cardslib/demo/extras/fragment/StaggeredGridFragment.java).


### Use your custom layout for each row
Expand Down

0 comments on commit d96aeba

Please sign in to comment.