Search in sources :

Example 1 with SyncDownloadWayEvent

use of io.jawg.osmcontributor.rest.events.SyncDownloadWayEvent in project osm-contributor by jawg.

the class MapFragment method downloadAreaForEdition.

// get data from overpass
private void downloadAreaForEdition() {
    if (getZoomLevel() >= zoomVectorial) {
        // progressBar.setVisibility(View.VISIBLE);
        LatLngBounds viewLatLngBounds = getViewLatLngBounds();
        eventBus.post(new SyncDownloadWayEvent(viewLatLngBounds));
    } else {
        Toast.makeText(getActivity(), getString(R.string.zoom_to_edit), Toast.LENGTH_SHORT).show();
    }
}
Also used : LatLngBounds(com.mapbox.mapboxsdk.geometry.LatLngBounds) SyncDownloadWayEvent(io.jawg.osmcontributor.rest.events.SyncDownloadWayEvent)

Aggregations

LatLngBounds (com.mapbox.mapboxsdk.geometry.LatLngBounds)1 SyncDownloadWayEvent (io.jawg.osmcontributor.rest.events.SyncDownloadWayEvent)1