cgeo/c-geo-opensource — pull request #1978 by RuneHL (2012-08-20 20:13:11+00:00)
Title: feature request #1940

OK, here it goes on my attempt to add offline map selection in the map menu.
This is my first attempt at this so I hope that the code is aligned with the principles (and that I managed to get the right code version into GIT).

One thing I struggled with is the abstraction - I ended up implementing the menu handling in the MapActivityImpl and the details on how selecting and switching the data source in MapViewImpl.
Since all the activity knows about the view is the AbstractMap I decided to provide a means to obtain the MapViewImpl so the activity can query and request data sources in a generic way so other maps providers can utilize the same structure.
All this required extending some of the interfaces and abstract classes which I think may be violating the overall structure and therefore I ask for your advice: is it OK or should the base structures be used in a different way? Probably some coding guidelines could have helped here :-)