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

MyLocationTrackingMode changes unexpectedly #8560

Closed

Description

@rlaendle

Platform: Android 7.1.1
Mapbox SDK version: 5.0.1

Steps to trigger behavior

  1. In mapbox-android-demo project open the LocationTrackingActivity class (see https://github.com/mapbox/mapbox-android-demo/blob/master/MapboxAndroidDemo/src/main/java/com/mapbox/mapboxandroiddemo/examples/location/LocationTrackingActivity.java )
  2. In method enableLocationTracking() replace map.getTrackingSettings().setDismissAllTrackingOnGesture(false); by map.getTrackingSettings().setDismissAllTrackingOnGesture(true);
  3. Start the LocationTrackingActivity and additional start a mock location app (e.g. Fake GPS).

Expected behavior

If I do not execute any gesture on the screen of the android device, MyLocationTrackingMode should not change.

Actual behavior

After a short time, without touching anything on the screen, MyLocationTrackingMode changes from TRACKING_FOLLOW to TRACKING_NONE.
Note that this behavior does not appear, when MyBearingTrackingMode is set to NONE.

Activity

  1. added
    Android
    on Mar 29, 2017
  2. rlaendle commented on Apr 4, 2017

    @rlaendle
    Author

    The issue still is reproducible with latest Mapbox SDK release 5.0.2.

  3. added this to the android-v5.1.0 milestone on Apr 4, 2017
  4. added
    good first issue
    on Apr 4, 2017
  5. tobrun commented on Apr 13, 2017

    @tobrun
    Member

    Thank you for providing the information to reproduce. There is a race condition when MyLocationView sets dismissing tracking to disable while performing the animation (this animation is posted to the end of message queue). Posting dismissing the tracking mode resolves this. Ran a test for 10+ minutes without seeing the issue from OP.

  6. self-assigned this
    on Apr 13, 2017
  7. SylvainHocq commented on May 22, 2017

    @SylvainHocq
    Contributor

    Hello,
    i reproduce the bug again with v5.1.0-beta-1, in android 7.0

    I have configured map to TRACKING_FOLLOW.
    And after 5mn the tracking was automatically set to NONE.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

Androidbuggood first issue

Type

No type

Projects

No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions