diff options
Diffstat (limited to 'main/src/cgeo/geocaching/maps/google/GoogleMapView.java')
| -rw-r--r-- | main/src/cgeo/geocaching/maps/google/GoogleMapView.java | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/main/src/cgeo/geocaching/maps/google/GoogleMapView.java b/main/src/cgeo/geocaching/maps/google/GoogleMapView.java index 9c23035..8bf7deb 100644 --- a/main/src/cgeo/geocaching/maps/google/GoogleMapView.java +++ b/main/src/cgeo/geocaching/maps/google/GoogleMapView.java @@ -3,6 +3,7 @@ package cgeo.geocaching.maps.google; import static android.view.ViewGroup.LayoutParams.WRAP_CONTENT; import cgeo.geocaching.Settings; +import cgeo.geocaching.geopoint.Viewport; import cgeo.geocaching.maps.CachesOverlay; import cgeo.geocaching.maps.OtherCachersOverlay; import cgeo.geocaching.maps.PositionOverlay; @@ -60,7 +61,7 @@ public class GoogleMapView extends MapView implements MapViewImpl { super.draw(canvas); } catch (Exception e) { - Log.e(Settings.tag, "GoogleMapView.draw: " + e.toString()); + Log.e("GoogleMapView.draw: " + e.toString()); } } @@ -74,7 +75,7 @@ public class GoogleMapView extends MapView implements MapViewImpl { super.displayZoomControls(takeFocus); } catch (Exception e) { - Log.e(Settings.tag, "GoogleMapView.displayZoomControls: " + e.toString()); + Log.e("GoogleMapView.displayZoomControls: " + e.toString()); } } @@ -90,6 +91,11 @@ public class GoogleMapView extends MapView implements MapViewImpl { } @Override + public Viewport getViewport() { + return new Viewport(getMapViewCenter(), getLatitudeSpan() / 1e6, getLongitudeSpan() / 1e6); + } + + @Override public void addOverlay(OverlayImpl ovl) { getOverlays().add((Overlay) ovl); } |
