diff --git a/app/src/main/java/com/example/sprout/refactor/adapter/RoomMainAdapter.java b/app/src/main/java/com/example/sprout/refactor/adapter/RoomMainAdapter.java index 837a948..4a5e401 100644 --- a/app/src/main/java/com/example/sprout/refactor/adapter/RoomMainAdapter.java +++ b/app/src/main/java/com/example/sprout/refactor/adapter/RoomMainAdapter.java @@ -2,7 +2,6 @@ import android.content.Context; import android.databinding.DataBindingUtil; -import android.support.v7.util.DiffUtil; import android.support.v7.widget.RecyclerView; import android.view.LayoutInflater; import android.view.ViewGroup; @@ -12,7 +11,6 @@ import com.example.sprout.refactor.model.entity.Member; import java.util.ArrayList; -import java.util.List; /** * ルームのアダプター @@ -46,10 +44,9 @@ } public void setDataAndRefresh(ArrayList items) { - List oldItems = this.items; - DiffUtil.DiffResult diffResult = DiffUtil.calculateDiff(new MemberDiffCallBack(oldItems, items)); + this.items.clear(); this.items = items; - diffResult.dispatchUpdatesTo(this); + notifyDataSetChanged(); } @Override