Search in sources :

Example 1 with LargeMapControl

use of com.google.gwt.maps.client.control.LargeMapControl in project opennms by OpenNMS.

the class GoogleMapsPanel method initializeMapPanel.

private void initializeMapPanel() {
    getMapWidget().setSize("100%", "100%");
    getMapWidget().setUIToDefault();
    getMapWidget().addControl(new LargeMapControl());
    getMapWidget().setScrollWheelZoomEnabled(true);
    Window.addResizeHandler(new ResizeHandler() {

        @Override
        public void onResize(final ResizeEvent resizeEvent) {
            if (getMapWidget() != null) {
                getMapWidget().checkResizeAndCenter();
            }
        }
    });
}
Also used : ResizeHandler(com.google.gwt.event.logical.shared.ResizeHandler) LargeMapControl(com.google.gwt.maps.client.control.LargeMapControl) ResizeEvent(com.google.gwt.event.logical.shared.ResizeEvent)

Aggregations

ResizeEvent (com.google.gwt.event.logical.shared.ResizeEvent)1 ResizeHandler (com.google.gwt.event.logical.shared.ResizeHandler)1 LargeMapControl (com.google.gwt.maps.client.control.LargeMapControl)1