Package com.google.gwt.maps.client.overlay

Examples of com.google.gwt.maps.client.overlay.Marker


        LatLng point = LatLng.newInstance(entry.getLat(), entry.getLon());

        updatWidgetForResult(result);
        openInfoWindowForResult(result);

        Marker m15 = new Marker(point,
            MarkerOptions.newInstance(getStar15Marker()));
        Marker m20 = new Marker(point,
            MarkerOptions.newInstance(getStar20Marker()));
        Marker m30 = new Marker(point,
            MarkerOptions.newInstance(getStar30Marker()));

        _mapOverlayManager.addOverlay(m15, 0, 14);
        _mapOverlayManager.addOverlay(m20, 14, 17);
        _mapOverlayManager.addOverlay(m30, 17, 20);
View Full Code Here


      icon.setImageURL(resource.getUrl());
      icon.setIconSize(Size.newInstance(20, 34));
      icon.setIconAnchor(Point.newInstance(10, 34));
      MarkerOptions opts = MarkerOptions.newInstance(icon);

      _marker = new Marker(location, opts);
      _mapOverlayManager.addOverlay(_marker);
    }

  }
View Full Code Here

    if (_locationMarker != null) {
      _map.removeOverlay(_locationMarker);
      _locationMarker = null;
    }

    _locationMarker = new Marker(_location);
    _map.addOverlay(_locationMarker);

    _map.setCenter(_location);
    _usingLocation = true;
  }
View Full Code Here

      for (final TripDetailsBean bean : result.getList()) {
        TripStatusBean status = bean.getStatus();
        CoordinatePoint position = status.getLocation();
        final LatLng point = LatLng.newInstance(position.getLat(),
            position.getLon());
        Marker marker = new Marker(point);

        _overlayManager.addOverlay(marker);

        marker.addMarkerClickHandler(new MarkerClickHandler() {
          @Override
          public void onClick(MarkerClickEvent event) {
            FlowPanel panel = new FlowPanel();

            TripBean trip = bean.getTrip();
View Full Code Here

    icon.setIconSize(Size.newInstance(w, h));
    icon.setIconAnchor(Point.newInstance(w2, h2));
    icon.setInfoWindowAnchor(Point.newInstance(w2, h2));

    MarkerOptions options = MarkerOptions.newInstance(icon);
    return new Marker(p, options);
  }
View Full Code Here

    MarkerOptions opts = MarkerOptions.newInstance();
    boolean isSelected = false;

    Icon icon = StopIconFactory.getStopIcon(stop, size, isSelected);
    opts.setIcon(icon);
    return new Marker(p, opts);
  }
View Full Code Here

  }

  private void addPlaceToMap(final Place place,
      final PlaceClickHandler clickHandler) {
    LatLng point = place.getLocation();
    Marker marker = new Marker(point);

    if (clickHandler != null) {
      marker.addMarkerClickHandler(new MarkerClickHandler() {
        @Override
        public void onClick(MarkerClickEvent event) {
          clickHandler.onPlaceClicked(place);
        }
      });
View Full Code Here

        LatLng p = LatLng.newInstance(stop.getLat(), stop.getLon());

        MarkerClickHandler clickHandler = getClickHandlerForStop(stop);

        // Show some close up stops by default
        Marker largerMarker = getStopMarker(stop, p, ESize.LARGE);

        largerMarker.addMarkerClickHandler(clickHandler);

        addOverlayAtZoom(largerMarker, 17, 20);

        stopAndOverlays.addOverlays(largerMarker);

        // If we're not showing stops in our current view, it must mean we're in
        // route view, so we show the stops more zoomed out
        if (!_showStopsInCurrentView) {

          Marker mediumMarker = getStopMarker(stop, p, ESize.MEDIUM);
          mediumMarker.addMarkerClickHandler(clickHandler);
          addOverlayAtZoom(mediumMarker, 16, 17);

          Marker smallMarker = getStopMarker(stop, p, ESize.SMALL);
          smallMarker.addMarkerClickHandler(clickHandler);
          addOverlayAtZoom(smallMarker, 13, 16);

          Marker tinyMarker = getStopMarker(stop, p, ESize.TINY);
          tinyMarker.addMarkerClickHandler(clickHandler);
          addOverlayAtZoom(tinyMarker, 9, 13);

          stopAndOverlays.addOverlays(mediumMarker, smallMarker, tinyMarker);
        }

        if (_selectedStopIds.contains(stop.getId())) {
          Marker big = StopIconFactory.getStopSelectionCircle(p, true);
          Marker small = StopIconFactory.getStopSelectionCircle(p, false);
          addOverlayAtZoom(small, 16, 17);
          addOverlayAtZoom(big, 17, 20);
          stopAndOverlays.addOverlays(big, small);
        }
      }
View Full Code Here

      _map.removeOverlay(_currentLocationMarker);
      _currentLocationMarker = null;
    }

    LatLng center = LatLng.newInstance(lat, lon);
    _currentLocationMarker = new Marker(center);
    _map.addOverlay(_currentLocationMarker);

    _map.panTo(center);
  }
View Full Code Here

TOP

Related Classes of com.google.gwt.maps.client.overlay.Marker

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.