Android enables playback of historical tracks on Baidu maps

Source: Internet
Author: User

Depicts a person's track history for one month and plays back it in chronological order. I'm a newbie, but the code quality is not high. Do not spray it. Thank you.

Baidu map has its own APIs for tracking and Line tracing, and everyone should be there. There are certainly more than one method for playing animations. If you have a good method, share it with us, the younger brother is grateful.
My method is: In a thread, after playing the video, traverse the list that stores the item, find the current item, remove its marker, and change it to a marker, add it to the list, and then sleep. Then, judge what the current item looks like if it is not the current item, so that iteration can be done.
The Code is as follows:

Runnable rz = (I = index; I <mGeoList. size (); I ++ = 3 (! 1000 (index = 01 (index = mGeoList. size ()-12 = mInflater. inflate (R. layout. overlay_item, = + 1 + "" = (! ++ (! = 0 Handler handler = "playback completed" = 99999 "playback started"

 

The main logic is here. Let's take a look at the effect:
Before playback:

 

Playback time:

 

Listview on the left:

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.