aboutsummaryrefslogtreecommitdiffstats
path: root/main/src/cgeo/geocaching/apps/cache/navi/OruxMapsApp.java
blob: b3e21a316b9ff56b6cf5b7e876a66dcb30d7c6d9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
package cgeo.geocaching.apps.cache.navi;

import cgeo.geocaching.R;
import cgeo.geocaching.location.Geopoint;

import android.app.Activity;
import android.content.Intent;

class OruxMapsApp extends AbstractPointNavigationApp {

    private static final String ORUXMAPS_EXTRA_LONGITUDE = "longitude";
    private static final String ORUXMAPS_EXTRA_LATITUDE = "latitude";
    private static final String INTENT = "com.oruxmaps.VIEW_MAP_ONLINE";

    OruxMapsApp() {
        super(getString(R.string.cache_menu_oruxmaps), R.id.cache_app_orux_maps, INTENT);
    }

    @Override
    public void navigate(final Activity activity, final Geopoint point) {
        final Intent intent = new Intent(INTENT);
        intent.putExtra(ORUXMAPS_EXTRA_LATITUDE, point.getLatitude());//latitude, wgs84 datum
        intent.putExtra(ORUXMAPS_EXTRA_LONGITUDE, point.getLongitude());//longitude, wgs84 datum

        activity.startActivity(intent);
    }

}