GSoC'13 OpenTripPlanner-for-Android Weekly Report #6

36 views
Skip to first unread message

Vreixo González

unread,
Jul 28, 2013, 8:18:02 PM7/28/13
to s...@lists.osgeo.org, opentripp...@googlegroups.com
Hi all,

I'm sorry for the late report but I made it this way because I wanted to get some things finished.

What did I do this week?

In the first part of the week I made same improvements to the UI and repaired some bugs. On the second part I have created a new branch and started started to implement Maps API V2. Also I have made an updated list of my objectives and priorities, in agreement with mentors. 

Regarding the first part:
- I have created an AsyncTask to perform an operation that blocked the UI for a few seconds. I have added also the necessary UI parts to inform about how this task performs.
- I have worked on another task that needed some changes to inform of his results and progress. Also there was an error regarding the dialogs of tasks, that crashed app on pressing back.
- I have corrected the date of refreshed servers, changing all related classes to use a Timestamp and avoid problems with locales.

Regarding the maps API V2:
- I have managed to get the map showed on the app using new API.
- I have added support to change between different OSM tiles, defined in resources, through settings.

What will I be working on next week?

- Continue with the adaptation to API V2, replacing some problematic parts of the actual code by services provided by the API.
- If I can finish first part, make some UI improvements and develop a correct management of app's lifecycle.

Did I meet with any stumbling blocks?

-  It was a nightmare to get maps API V2 showing the map and get rid of the error contacting Google servers. I have lost many hours dealing with keys, permissions and imports.



Kind regards,
Vreixo González

Vreixo González

unread,
Jul 29, 2013, 8:59:02 AM7/29/13
to Pavel Melnikov, s...@lists.osgeo.org, opentripp...@googlegroups.com
Hello Pavel,

I have chose this API because is much newer and offers much more functionality. OSMdroid API is what was used until now in the app and is a replacement of Google's API V1 with almost the same features.

One of the principal advantages for me is that with new API some operations are much easier and elegant. It has an automatic MyOverlay layer to display user's position, markers added and configured in one instruction, the same for route lines, better controls to move the camera, etc.
This things could be done with OSMdroid API but required much more code.

This API uses a fragment natively to display the map and takes care of all lifecycle steps regarding this (no need of save and restore map state onPause and onResume). The fragment is much more adecuate to work with it than the old activity and also is better for future integration with Action bars and other components.

Also this maps are more nice to see, with the possibility to tilt, rotate the map and the MyLocation and compass integrated. Also the possibility to manage indoor mapping is interesting (in OTP there are some people working on this).

For what I have read people was really waiting for the new API and has a lot of promissing features that I didn't have explored yet.

The issues with the keys can provoke same time waste if you're not lucky but after being configured there are no more problems and they don't introduce any limitations and they produce usefull usage statistics.

If you only want OSM tiles is very simple, just set map type to none and add a TileOverlay with an OSM provider. Regarding tiles, I will let the two options in OpenTripPlanner client.


Kind regards,

Vreixo
Reply all
Reply to author
Forward
0 new messages