Example usage for com.google.gwt.maps.client.control ControlPosition ControlPosition

List of usage examples for com.google.gwt.maps.client.control ControlPosition ControlPosition

Introduction

In this page you can find the example usage for com.google.gwt.maps.client.control ControlPosition ControlPosition.

Prototype

public ControlPosition(ControlAnchor anchor, int offsetX, int offsetY) 

Source Link

Document

Create a new ControlPosition.

Usage

From source file:es.upm.fi.dia.oeg.map4rdf.client.view.MapView.java

License:Open Source License

private Widget createUi() {
    panel = new FlowPanel();
    map = new MapWidget(DEFAULT_CENTER, DEFAULT_ZOOM_LEVEL);
    map.setSize("100%", "100%");

    map.addControl(new LargeMapControl3D());
    map.addControl(new MenuMapTypeControl());
    map.addControl(new ScaleControl());

    map.setScrollWheelZoomEnabled(false);
    map.setCurrentMapType(MapType.getPhysicalMap());

    map.addControl(new Control.CustomControl(new ControlPosition(ControlAnchor.TOP_RIGHT, 100, 8)) {

        @Override//w  w  w. ja va2  s  .c o m
        public boolean isSelectable() {
            return false;
        }

        @Override
        protected Widget initialize(MapWidget map) {
            return kmlButton;
        }
    });

    panel.add(map);
    return panel;
}

From source file:es.upm.fi.dia.oeg.map4rdf.client.widget.mapcontrol.LayerControl.java

License:Open Source License

public LayerControl() {
    super(new ControlPosition(ControlAnchor.BOTTOM_RIGHT, 0, 0), false, false);
}

From source file:es.upm.fi.dia.oeg.map4rdf.client.widget.mapcontrol.TimelineControl.java

License:Open Source License

public TimelineControl(Timeline timeline) {
    super(new ControlPosition(ControlAnchor.BOTTOM_RIGHT, 20, 30), false, false);
    this.timeline = timeline;
}

From source file:org.maps.client.Maps.java

License:Apache License

private void addMap(LayoutContainer mapPanel) {
    setUpMap();//from w  w w. j a v  a2  s  .  c om
    final Image vscale = new Image("/images/vscale.png");
    ControlPosition imagePosition = new ControlPosition(ControlAnchor.BOTTOM_RIGHT, 10, 20);
    Control.CustomControl customScale = new Control.CustomControl(imagePosition) {
        protected Widget initialize(MapWidget map) {
            return vscale;
        }

        public boolean isSelectable() {
            return false;
        }
    };

    map.addControl(customScale, imagePosition);

    BorderLayoutData mapLayoutData = new BorderLayoutData(LayoutRegion.WEST, MAP_WIDTH_INT);
    mapLayoutData.setMargins(new Margins(5));
    mapLayoutData.setSplit(false);
    mapPanel.add(map, mapLayoutData);
}

From source file:org.onebusaway.webapp.gwt.mobile_application.view.LargeButtonMapControl.java

License:Apache License

public LargeButtonMapControl() {
    super(new ControlPosition(ControlAnchor.TOP_LEFT, 5, 5), true, true);
}

From source file:org.onebusaway.webapp.gwt.oba_library.control.ColorGradientControl.java

License:Apache License

public ColorGradientControl() {
    super(new ControlPosition(ControlAnchor.BOTTOM_RIGHT, 10, 20), true, false);
}