こんにちは、 id:numanuma08 です。 最近、recyclerview-selectionを利用する機会がありました。recyclerview-selectionのドキュメントには、Viewの選択状態はsetActivated
を使って変更するべきと書かれています。
In Adapter#onBindViewHolder, set the "activated" status on view. Note that the status should be "activated" not "selected". See View.html#setActivated for details.
しかし、Viewには似たような用途っぽいメソッドにsetSelected
も用意されています。なぜsetActivated
を使うべきなのか調べました。