// The map's bounds are meaningless until the map has been added to the DOM
// and sized appropriately
if (firstTime) {
firstTime = false;
LatLngBounds bounds = map.getBounds();
LatLng southWest = bounds.getSouthWest();
LatLng northEast = bounds.getNorthEast();
double lngDelta = (northEast.getLongitude() - southWest.getLongitude()) / 4;
double latDelta = (northEast.getLatitude() - southWest.getLatitude()) / 4;
// generate bounds that covers center map with half the width and height
LatLngBounds rectBounds = LatLngBounds.newInstance(LatLng.newInstance(
southWest.getLatitude() + latDelta, southWest.getLongitude()
+ lngDelta), LatLng.newInstance(northEast.getLatitude() - latDelta,
northEast.getLongitude() - lngDelta));
groundOverlay = new GroundOverlay("boot.jpg", rectBounds);
groundOverlay.addGroundOverlayVisibilityChangedHandler(new GroundOverlayVisibilityChangedHandler() {
public void onVisibilityChanged(
GroundOverlayVisibilityChangedEvent event) {