Use new Constants class name
This commit is contained in:
parent
59ea149528
commit
a22b5f488c
|
@ -8,7 +8,7 @@ import org.microg.nlp.Preferences;
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
import static org.microg.nlp.api.NlpApiConstants.ACTION_GEOCODER_BACKEND;
|
import static org.microg.nlp.api.Constants.ACTION_GEOCODER_BACKEND;
|
||||||
|
|
||||||
class BackendFuser {
|
class BackendFuser {
|
||||||
private final List<BackendHelper> backendHelpers = new ArrayList<BackendHelper>();
|
private final List<BackendHelper> backendHelpers = new ArrayList<BackendHelper>();
|
||||||
|
|
|
@ -4,7 +4,7 @@ import android.content.Context;
|
||||||
import android.content.Intent;
|
import android.content.Intent;
|
||||||
import org.microg.nlp.ProviderService;
|
import org.microg.nlp.ProviderService;
|
||||||
|
|
||||||
import static org.microg.nlp.api.NlpApiConstants.ACTION_RELOAD_SETTINGS;
|
import static org.microg.nlp.api.Constants.ACTION_RELOAD_SETTINGS;
|
||||||
|
|
||||||
public abstract class GeocodeService extends ProviderService<GeocodeProvider> {
|
public abstract class GeocodeService extends ProviderService<GeocodeProvider> {
|
||||||
public static void reloadLocationService(Context context) {
|
public static void reloadLocationService(Context context) {
|
||||||
|
|
|
@ -13,7 +13,7 @@ import java.util.Collections;
|
||||||
import java.util.Comparator;
|
import java.util.Comparator;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
import static org.microg.nlp.api.NlpApiConstants.*;
|
import static org.microg.nlp.api.Constants.*;
|
||||||
|
|
||||||
class BackendFuser {
|
class BackendFuser {
|
||||||
private static final String TAG = BackendFuser.class.getName();
|
private static final String TAG = BackendFuser.class.getName();
|
||||||
|
|
|
@ -12,8 +12,8 @@ import org.microg.nlp.AbstractBackendHelper;
|
||||||
import org.microg.nlp.api.LocationBackend;
|
import org.microg.nlp.api.LocationBackend;
|
||||||
import org.microg.nlp.api.LocationCallback;
|
import org.microg.nlp.api.LocationCallback;
|
||||||
|
|
||||||
import static org.microg.nlp.api.NlpApiConstants.LOCATION_EXTRA_BACKEND_COMPONENT;
|
import static org.microg.nlp.api.Constants.LOCATION_EXTRA_BACKEND_PROVIDER;
|
||||||
import static org.microg.nlp.api.NlpApiConstants.LOCATION_EXTRA_BACKEND_PROVIDER;
|
import static org.microg.nlp.api.Constants.LOCATION_EXTRA_BACKEND_COMPONENT;
|
||||||
|
|
||||||
class BackendHelper extends AbstractBackendHelper {
|
class BackendHelper extends AbstractBackendHelper {
|
||||||
private static final String TAG = BackendHelper.class.getName();
|
private static final String TAG = BackendHelper.class.getName();
|
||||||
|
@ -76,7 +76,7 @@ class BackendHelper extends AbstractBackendHelper {
|
||||||
lastLocation = location;
|
lastLocation = location;
|
||||||
return lastLocation;
|
return lastLocation;
|
||||||
}
|
}
|
||||||
|
|
||||||
@TargetApi(Build.VERSION_CODES.JELLY_BEAN_MR1)
|
@TargetApi(Build.VERSION_CODES.JELLY_BEAN_MR1)
|
||||||
private void updateElapsedRealtimeNanos(Location location) {
|
private void updateElapsedRealtimeNanos(Location location) {
|
||||||
if (location.getElapsedRealtimeNanos() <= 0) {
|
if (location.getElapsedRealtimeNanos() <= 0) {
|
||||||
|
|
|
@ -7,7 +7,7 @@ import android.location.Location;
|
||||||
import android.os.Build;
|
import android.os.Build;
|
||||||
import org.microg.nlp.ProviderService;
|
import org.microg.nlp.ProviderService;
|
||||||
|
|
||||||
import static org.microg.nlp.api.NlpApiConstants.*;
|
import static org.microg.nlp.api.Constants.*;
|
||||||
|
|
||||||
public abstract class LocationService extends ProviderService<LocationProvider> {
|
public abstract class LocationService extends ProviderService<LocationProvider> {
|
||||||
public static void reloadLocationService(Context context) {
|
public static void reloadLocationService(Context context) {
|
||||||
|
|
|
@ -20,7 +20,7 @@ import org.microg.nlp.R;
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
import static org.microg.nlp.api.NlpApiConstants.*;
|
import static org.microg.nlp.api.Constants.*;
|
||||||
|
|
||||||
public abstract class AbstractBackendPreference extends DialogPreference {
|
public abstract class AbstractBackendPreference extends DialogPreference {
|
||||||
private ListView listView;
|
private ListView listView;
|
||||||
|
|
|
@ -7,7 +7,7 @@ import org.microg.nlp.Preferences;
|
||||||
import org.microg.nlp.R;
|
import org.microg.nlp.R;
|
||||||
import org.microg.nlp.geocode.GeocodeService;
|
import org.microg.nlp.geocode.GeocodeService;
|
||||||
|
|
||||||
import static org.microg.nlp.api.NlpApiConstants.ACTION_GEOCODER_BACKEND;
|
import static org.microg.nlp.api.Constants.ACTION_GEOCODER_BACKEND;
|
||||||
|
|
||||||
public class GeocoderBackendPreference extends AbstractBackendPreference {
|
public class GeocoderBackendPreference extends AbstractBackendPreference {
|
||||||
public GeocoderBackendPreference(Context context, AttributeSet attrs) {
|
public GeocoderBackendPreference(Context context, AttributeSet attrs) {
|
||||||
|
|
|
@ -7,7 +7,7 @@ import org.microg.nlp.Preferences;
|
||||||
import org.microg.nlp.R;
|
import org.microg.nlp.R;
|
||||||
import org.microg.nlp.location.LocationService;
|
import org.microg.nlp.location.LocationService;
|
||||||
|
|
||||||
import static org.microg.nlp.api.NlpApiConstants.ACTION_LOCATION_BACKEND;
|
import static org.microg.nlp.api.Constants.ACTION_LOCATION_BACKEND;
|
||||||
|
|
||||||
public class LocationBackendPreference extends AbstractBackendPreference {
|
public class LocationBackendPreference extends AbstractBackendPreference {
|
||||||
public LocationBackendPreference(Context context, AttributeSet attrs) {
|
public LocationBackendPreference(Context context, AttributeSet attrs) {
|
||||||
|
|
Loading…
Reference in a new issue