merlos / iOS-Open-GPX-Tracker

GPS Tracker app for iOS + WatchOS. Log your tracks without limits and share them; Open source GPX tracker app written in Swift
http://www.merlos.org/iOS-Open-GPX-Tracker/
GNU General Public License v3.0
605 stars 149 forks source link

Suggestion: display warning when no points are detected when loading a .GPX file #211

Open sapphire-bt opened 3 years ago

sapphire-bt commented 3 years ago

I recently tried to open in the app a .GPX file which I had downloaded from a hiking routes site. When opening the file, the map moves to "Null Island" and does not display a warning/error message explaining what went wrong.

After creating a .GPX file within the app and comparing it with the file I'd downloaded, I noticed the markup was slightly different:

<rte>
    <rtept lat="x" lon="y">
        <ele>100</ele>
    </rtept>

    ...

Compare the app-generated markup:

<trk>
    <trkseg>
        <trkpt lat="x" lon="y">
            <ele>100</ele>
        </trkpt>

        ...

It would have been useful if the app displayed a warning such as "No track segments detected"; better yet, parsing the rtept elements and creating a new .GPX file on the fly would have been ideal.

After manually editing the file the app worked perfectly, so thank you for all the hard work so far. 👍