Skip to content

Stop scrolling before notifying InstructionListAdapter#1432

Merged
danesfeder merged 1 commit into
masterfrom
dan-stop-scroll
Oct 17, 2018
Merged

Stop scrolling before notifying InstructionListAdapter#1432
danesfeder merged 1 commit into
masterfrom
dan-stop-scroll

Conversation

@danesfeder
Copy link
Copy Markdown
Contributor

The epic saga of fixing the instruction list RecyclerView continues. Seeing an IllegalStateException occurring when trying to update the InstructionListAdapter while the RecyclerView is still scrolling:

Fatal Exception: java.lang.IllegalStateException
Cannot call this method while RecyclerView is computing a layout or scrolling android.support.v7.widget.RecyclerView{3139e9ac VFED.... ......ID 0,0-480,618 #7f0800bb app:id/rvInstructions}, adapter:com.mapbox.services.android.navigation.ui.v5.summary.list.InstructionListAdapter@10f27ae3, layout:android.support.v7.widget.LinearLayoutManager@741ace0, context:com.mapbox.logistics.ui.LogisticsActivity@2bce6a5d
android.support.v7.widget.RecyclerView.assertNotInLayoutOrScroll (RecyclerView.java:2769)
android.support.v7.widget.RecyclerView$Adapter.notifyDataSetChanged (RecyclerView.java:6961)
com.mapbox.services.android.navigation.ui.v5.instruction.InstructionListTransitionListener.onAnimationFinished (InstructionListTransitionListener.java:34)
com.mapbox.services.android.navigation.ui.v5.instruction.InstructionListTransitionListener.onTransitionEnd (InstructionListTransitionListener.java:24)

@danesfeder danesfeder added bug Defect to be fixed. ✓ ready for review labels Oct 17, 2018
@danesfeder danesfeder added this to the 0.22.0 milestone Oct 17, 2018
@danesfeder danesfeder self-assigned this Oct 17, 2018
Copy link
Copy Markdown
Contributor

@Guardiola31337 Guardiola31337 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems legit :shipit:

@danesfeder danesfeder merged commit 1a0d48a into master Oct 17, 2018
@danesfeder danesfeder deleted the dan-stop-scroll branch October 17, 2018 14:48
@danesfeder danesfeder mentioned this pull request Oct 24, 2018
11 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Defect to be fixed.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants