Skip to content
This repository has been archived by the owner on Aug 8, 2023. It is now read-only.

Use the correct cancelable callback after posting cancel #10871

Merged
merged 1 commit into from
Jan 10, 2018

Conversation

tobrun
Copy link
Member

@tobrun tobrun commented Jan 9, 2018

A user reached out about the change introduced in #10664. When an animation is started while another is ongoing, the onCancel callback of the newer animation will be invoked instead of the callback of the old animation.

@tobrun tobrun added the Android Mapbox Maps SDK for Android label Jan 9, 2018
@tobrun tobrun added this to the android-v5.3.1 milestone Jan 9, 2018
@tobrun tobrun self-assigned this Jan 9, 2018
@tobrun tobrun force-pushed the tvm-cancel-callback branch 2 times, most recently from 7f64b0b to d489154 Compare January 9, 2018 16:15
new Handler().post(new Runnable() {
@Override
public void run() {
invalidateCameraPosition();
Copy link
Member

Choose a reason for hiding this comment

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

Any particular reason for posting invalidateCameraPosition() instead of invoking it right away?
Otherwise looks good! :)

@tobrun tobrun force-pushed the tvm-cancel-callback branch 2 times, most recently from 460e609 to 5d791f8 Compare January 9, 2018 19:05
@tobrun tobrun merged commit 04386db into master Jan 10, 2018
@tobrun tobrun deleted the tvm-cancel-callback branch January 10, 2018 10:04
@tobrun tobrun mentioned this pull request Jan 10, 2018
23 tasks
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Android Mapbox Maps SDK for Android
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants