Releases: lisawray/groupie
v2.10.1
v2.10.0
v2.9.0
In this release:
-
Add
GroupieAdapter
as a default adapter which binds theGroupieViewHolder
as its generic type, removing the need for creating a typealias for it yourself. (thanks @ibado) -
Add
replaceAll()
method toGroupAdapter
,Section
andExpandableGroup
, which allows one to replace items without animations usingnotifyDataSetChanged()
under the hood (thus differing fromupdate()
which runsDiffUtil
and therefore issues animations).
(NOTE: this change required adding a new method to GroupDataObservable
public interface, which typically delegates onDataSetInvalidated()
and in the end resolves to notifyDataSetChanged()
. Theoretically there is no need to use this interface manually, but those who do depend on it will need to update accordingly.)
-
Undeprecate
groupie-databinding
. While databinding is not preferred to viewbinding, those who use it should not need to callinitializeViewBinding
manually. -
Deprecate
groupie-kotlin-android-extensions
due to its dependency onkotlin-android-extensions
, which is also deprecated since Kotlin 1.4.20. -
Update Kotlin to 1.4.21.
v2.8.1
In this release:
- Add
getGroups
function toSection
- Add draggable item example to main example project
- Fix javadoc of groupie-viewbinding's BindableItem.bind methods to refer to
ViewBinding
instead ofViewDataBinding
(#334) - Making Kotlin extensions work with all classes extending GroupieViewHolder. (#350)
- Fix the crash when dragging an item to the top/bottom of the list area in main example (#351 )
- Various version updates and unit test maintenance
❤️ Thank you to the contributors of this release: @rayworks , @herbeth1u , @nashcft & @zsoltvilagos
v2.8.0
This release adds groupie-viewbinding
support. With the addition of this, groupie-databinding
has been deprecated. If you're using the databinding library, please consider updating your AGP to 3.6.0+ and switching to groupie-viewbinding
. (Issue #322, PR #325 )
❤ Thank you to @nashcft & @massanchik for contributing to this release.
v2.7.2
In this release:
- Add fast simple first insert for
GroupAdapter.updateAsync
similar to howandroidx.recyclerview.widget.ListAdapter
behaves. (Issue #311, PR #313 ) - Fix outdated ExpandableContentItem name in documentation (PR #306)
- Add
@NonNull
annotations to payloads argument ofBindableItem.bind
method (PR #307) - Add
@NonNull
annotations toItem.isSameAs
andItem.hasSameContentAs
methods (PR #312) - Update library RecyclerView dependency to 1.1.0
❤ Thank you to @angusholder & @satoshun for contributing to this release.
v2.7.1
This release addresses the breaking changes in 2.7.0 in a less breaking manner as per discussion in #299 (PR #303 ). All old methods that were removed or changed have been returned but marked as deprecated and point to the ones that should be used instead.
Important if you've already updated to 2.7.0: If you now update to 2.7.1 be warned that getGroup(position)
now functions like it did before 2.7.0. If you now want to get a top level group use the method getTopLevelGroup(position)
Other additions to this release:
❤️ Thank you to @ikesyo, @scottschmitz and @amitav13 for contributing to this release
v2.7.0
Edit: PLEASE USE 2.7.1 AS IT INTRODUCES THE BREAKING CHANGES IN A LESS BREAKING WAY
- Added
onViewAttachedToWindow
andonViewDetachedFromWindow
callbacks toItem
(PR #297) - BREAKING CHANGES to
GroupAdapter
- Some method names have been renamed and the functionality of existing ones has changed in order to provide more clarity to the API (PR #296, addresses issue #295):- original
getGroup(position)
has been replaced withgetGroupAtAdapterPosition(position)
.getGroup(position)
will now return a top level GroupAdapter group removeGroup(index)
has been renamed toremoveGroupAtAdapterPosition(position)
to reflect what it was actually doing.getItemCount(groupIndex)
has been renamed togetItemCountForGroup(groupIndex)
. It still returns the number of items contained in a top level GroupAdapter group.
- original
All these methods + some pre-existing ones should now have proper Javadoc.
❤ Thanks to @AllanHasegawa for contributing to this release.
v2.6.0
- BREAKING CHANGE
ViewHolder
has been renamed toGroupieViewHolder
after discussion #287 (PR #293) - Added
Item.hasSameContentAs
method to be used when comparing content equality in the context ofDiffUtil
. It's advised you use this instead of overridingItem.equals
. The default implementation will callitem.equals
so existing code shouldn't break. (Issue #288, PR #292)
v2.5.1
This release fixes issue #235 - Kotlin Synthetic caching. Now calling synthetic properties on the Groupie ViewHolder
will correctly use _findCachedViewById
rather than doing findViewById
. There should be a decent performance boost if you use synthetic properties 🚀.
Other small tweaks: