QtLocation map updates

Lubomir I. Ivanov neolit123 at gmail.com
Tue Aug 1 17:09:23 PDT 2017


On 2 August 2017 at 01:31, Linus Torvalds <torvalds at linux-foundation.org> wrote:
> I didn't really look at the source code very much, but what I looked
> at didn't look horrible. I'm a *bit* worried about things like this:
>
>     // Google version strings
>     _versionGoogleMap            = "m at 338000000";
>     _versionGoogleSatellite      = "198";
>     _versionGoogleLabels         = "h at 336";
>     _versionGoogleTerrain        = "t at 132,r at 338000000";
>     _secGoogleWord               = "Galileo";
>
> which to me implies there is some hardcoded special magic going on,
> but it looks like it updates those strings based on the replies, and
> then never actually *uses* them, so maybe it's just debugging.
>

probably debugging leftovers.
some of those regex-es in
QGeoTileFetcherGooglemaps::_googleVersionCompleted() are kind of scary
but the mentioned variables are unused like you have pointed out.

the important part happens in:
QGeoTileFetcherGooglemaps::_tryCorrectGoogleVersions()

e.g.:
QString url = "http://maps.google.com/maps/api/js?v=3.2&sensor=false";

which is fixing the version to 3.2.

lubomir
--


More information about the subsurface mailing list