Replace http with https
This commit is contained in:
parent
f1f8af3925
commit
b64e83c6ad
19 changed files with 47 additions and 49 deletions
|
@ -10,11 +10,11 @@ import android.content.DialogInterface;
|
|||
import android.content.Intent;
|
||||
import android.content.SharedPreferences;
|
||||
import android.support.v7.app.AlertDialog;
|
||||
|
||||
import net.osmand.IProgress;
|
||||
import net.osmand.IndexConstants;
|
||||
import net.osmand.PlatformUtil;
|
||||
import net.osmand.aidl.OsmandAidlApi;
|
||||
import net.osmand.binary.BinaryMapIndexReader;
|
||||
import net.osmand.map.OsmandRegions;
|
||||
import net.osmand.map.OsmandRegions.RegionTranslation;
|
||||
import net.osmand.map.WorldRegion;
|
||||
|
@ -45,7 +45,6 @@ import net.osmand.plus.voice.MediaCommandPlayerImpl;
|
|||
import net.osmand.plus.voice.TTSCommandPlayerImpl;
|
||||
import net.osmand.render.RenderingRulesStorage;
|
||||
import net.osmand.router.RoutingConfiguration;
|
||||
import net.osmand.search.SearchUICore;
|
||||
import net.osmand.util.Algorithms;
|
||||
|
||||
import org.xmlpull.v1.XmlPullParserException;
|
||||
|
@ -60,6 +59,7 @@ import java.util.List;
|
|||
import java.util.Random;
|
||||
|
||||
import btools.routingapp.BRouterServiceConnection;
|
||||
|
||||
import static net.osmand.plus.liveupdates.LiveUpdatesHelper.getPendingIntent;
|
||||
import static net.osmand.plus.liveupdates.LiveUpdatesHelper.preferenceLastCheck;
|
||||
import static net.osmand.plus.liveupdates.LiveUpdatesHelper.preferenceLiveUpdatesOn;
|
||||
|
@ -86,7 +86,7 @@ public class AppInitializer implements IProgress {
|
|||
private static final String VERSION_INSTALLED = "VERSION_INSTALLED"; //$NON-NLS-1$
|
||||
private static final String EXCEPTION_FILE_SIZE = "EXCEPTION_FS"; //$NON-NLS-1$
|
||||
|
||||
public static final String LATEST_CHANGES_URL = "http://osmand.net/blog?id=osmand-2-7-released";
|
||||
public static final String LATEST_CHANGES_URL = "https://osmand.net/blog?id=osmand-2-7-released";
|
||||
// public static final String LATEST_CHANGES_URL = null; // not enough to read
|
||||
public static final int APP_EXIT_CODE = 4;
|
||||
public static final String APP_EXIT_KEY = "APP_EXIT_KEY";
|
||||
|
|
|
@ -1024,7 +1024,7 @@ public class GPXUtilities {
|
|||
format.setTimeZone(TimeZone.getTimeZone("UTC"));
|
||||
XmlSerializer serializer = PlatformUtil.newSerializer();
|
||||
serializer.setOutput(output);
|
||||
serializer.setFeature("http://xmlpull.org/v1/doc/features.html#indent-output", true); //$NON-NLS-1$
|
||||
serializer.setFeature("https://xmlpull.org/v1/doc/features.html#indent-output", true); //$NON-NLS-1$
|
||||
serializer.startDocument("UTF-8", true); //$NON-NLS-1$
|
||||
serializer.startTag(null, "gpx"); //$NON-NLS-1$
|
||||
serializer.attribute(null, "version", "1.1"); //$NON-NLS-1$ //$NON-NLS-2$
|
||||
|
|
|
@ -1125,7 +1125,7 @@ public class OsmandSettings {
|
|||
|
||||
// this value string is synchronized with settings_pref.xml preference name
|
||||
public final CommonPreference<String> LIVE_MONITORING_URL = new StringPreference("live_monitoring_url",
|
||||
"http://example.com?lat={0}&lon={1}×tamp={2}&hdop={3}&altitude={4}&speed={5}").makeGlobal();
|
||||
"https://example.com?lat={0}&lon={1}×tamp={2}&hdop={3}&altitude={4}&speed={5}").makeGlobal();
|
||||
|
||||
public final CommonPreference<String> GPS_STATUS_APP = new StringPreference("gps_status_app", "").makeGlobal();
|
||||
|
||||
|
|
|
@ -33,7 +33,7 @@ public class Version {
|
|||
} else if (isGooglePlayEnabled(ctx)) {
|
||||
return "market://search?q=pname:";
|
||||
}
|
||||
return "http://osmand.net/apps?id=";
|
||||
return "https://osmand.net/apps?id=";
|
||||
}
|
||||
|
||||
private static boolean isAmazonEnabled(OsmandApplication ctx) {
|
||||
|
|
|
@ -29,11 +29,11 @@ public class HelpActivity extends OsmandActionBarActivity implements AdapterView
|
|||
|
||||
// public static final String DIALOG = "dialog";
|
||||
@IdRes
|
||||
public static final String OSMAND_POLL_HTML = "http://osmand.net/android-poll.html";
|
||||
public static final String OSMAND_POLL_HTML = "https://osmand.net/android-poll.html";
|
||||
public static final int NULL_ID = -1;
|
||||
private ArrayAdapter<ContextMenuItem> mAdapter;
|
||||
|
||||
//public static final String OSMAND_MAP_LEGEND = "http://osmand.net/help/map-legend_default.png";
|
||||
//public static final String OSMAND_MAP_LEGEND = "https://osmand.net/help/map-legend_default.png";
|
||||
|
||||
@Override
|
||||
protected void onCreate(Bundle savedInstanceState) {
|
||||
|
|
|
@ -167,7 +167,7 @@ public class SearchAddressOnlineFragment extends Fragment implements SearchActiv
|
|||
NOMINATIM_API = "https://nominatim.openstreetmap.org/search";
|
||||
}
|
||||
else {
|
||||
NOMINATIM_API = "http://nominatim.openstreetmap.org/search";
|
||||
NOMINATIM_API = "https://nominatim.openstreetmap.org/search";
|
||||
}
|
||||
|
||||
final List<Place> places = new ArrayList<Place>();
|
||||
|
|
|
@ -1,10 +1,8 @@
|
|||
package net.osmand.plus.dialogs;
|
||||
|
||||
import android.annotation.SuppressLint;
|
||||
import android.content.ContentResolver;
|
||||
import android.content.Context;
|
||||
import android.os.Bundle;
|
||||
import android.provider.Settings;
|
||||
import android.support.annotation.NonNull;
|
||||
import android.support.v4.app.DialogFragment;
|
||||
import android.support.v7.widget.Toolbar;
|
||||
|
@ -14,6 +12,7 @@ import android.view.ViewGroup;
|
|||
import android.webkit.WebSettings;
|
||||
import android.webkit.WebView;
|
||||
import android.webkit.WebViewClient;
|
||||
|
||||
import net.osmand.PlatformUtil;
|
||||
import net.osmand.plus.OsmandApplication;
|
||||
import net.osmand.plus.OsmandSettings;
|
||||
|
@ -104,12 +103,12 @@ public class HelpArticleDialogFragment extends DialogFragment {
|
|||
sb.append(fileContents);
|
||||
sb.append(FOOTER_INNER);
|
||||
|
||||
webView.loadDataWithBaseURL("http://osmand.net", sb.toString(), null, "utf-8", null);
|
||||
webView.loadDataWithBaseURL("https://osmand.net", sb.toString(), null, "utf-8", null);
|
||||
webView.setWebViewClient(new WebViewClient() {
|
||||
@Override
|
||||
public boolean shouldOverrideUrlLoading(WebView view, String url) {
|
||||
if (url.startsWith("http://osmand.net/features?id=")) {
|
||||
String id = url.substring("http://osmand.net/features?id=".length());
|
||||
if (url.startsWith("https://osmand.net/features?id=")) {
|
||||
String id = url.substring("https://osmand.net/features?id=".length());
|
||||
dismiss();
|
||||
instantiateWithAsset("feature_articles/" + id + ".html", getString(R.string.shared_string_help))
|
||||
.show(getActivity().getSupportFragmentManager(), "DIALOG_HELP_ARTICLE");
|
||||
|
|
|
@ -1,5 +1,14 @@
|
|||
package net.osmand.plus.download;
|
||||
|
||||
import android.os.Build;
|
||||
|
||||
import net.osmand.PlatformUtil;
|
||||
import net.osmand.osm.io.NetworkUtils;
|
||||
import net.osmand.plus.OsmandApplication;
|
||||
import net.osmand.plus.Version;
|
||||
|
||||
import org.apache.commons.logging.Log;
|
||||
|
||||
import java.io.File;
|
||||
import java.io.IOException;
|
||||
import java.net.HttpURLConnection;
|
||||
|
@ -11,15 +20,6 @@ import java.util.Map;
|
|||
import java.util.Map.Entry;
|
||||
import java.util.Random;
|
||||
|
||||
import net.osmand.PlatformUtil;
|
||||
import net.osmand.osm.io.NetworkUtils;
|
||||
import net.osmand.plus.OsmandApplication;
|
||||
import net.osmand.plus.Version;
|
||||
|
||||
import org.apache.commons.logging.Log;
|
||||
|
||||
import android.os.Build;
|
||||
|
||||
public class DownloadTracker {
|
||||
private static final Log log = PlatformUtil.getLog(DownloadTracker.class);
|
||||
|
||||
|
@ -49,7 +49,7 @@ public class DownloadTracker {
|
|||
Map<String, String> customVariables = getCustomVars(a);
|
||||
parameters.put("AnalyticsVersion", analyticsVersion);
|
||||
parameters.put("utmn", randomNumber());
|
||||
parameters.put("utmhn", "http://app.osmand.net");
|
||||
parameters.put("utmhn", "https://app.osmand.net");
|
||||
parameters.put("utmni", "1");
|
||||
parameters.put("utmt", "event");
|
||||
|
||||
|
|
|
@ -344,7 +344,7 @@ public class FirstUsageWizardFragment extends Fragment implements OsmAndLocation
|
|||
@Override
|
||||
protected String doInBackground(Void... params) {
|
||||
try {
|
||||
return AndroidNetworkUtils.sendRequest(app, "http://osmand.net/api/geo-ip", pms,
|
||||
return AndroidNetworkUtils.sendRequest(app, "https://osmand.net/api/geo-ip", pms,
|
||||
"Requesting location by IP...", false, false);
|
||||
|
||||
} catch (Exception e) {
|
||||
|
|
|
@ -1,9 +1,12 @@
|
|||
package net.osmand.plus.helpers;
|
||||
|
||||
import java.text.SimpleDateFormat;
|
||||
import java.util.Date;
|
||||
import java.util.LinkedHashMap;
|
||||
import java.util.Map;
|
||||
import android.annotation.SuppressLint;
|
||||
import android.content.Intent;
|
||||
import android.net.Uri;
|
||||
import android.os.AsyncTask;
|
||||
import android.provider.Settings.Secure;
|
||||
import android.util.Log;
|
||||
import android.view.View;
|
||||
|
||||
import net.osmand.AndroidNetworkUtils;
|
||||
import net.osmand.plus.OsmandApplication;
|
||||
|
@ -19,13 +22,10 @@ import net.osmand.util.Algorithms;
|
|||
|
||||
import org.json.JSONObject;
|
||||
|
||||
import android.annotation.SuppressLint;
|
||||
import android.content.Intent;
|
||||
import android.net.Uri;
|
||||
import android.os.AsyncTask;
|
||||
import android.provider.Settings.Secure;
|
||||
import android.util.Log;
|
||||
import android.view.View;
|
||||
import java.text.SimpleDateFormat;
|
||||
import java.util.Date;
|
||||
import java.util.LinkedHashMap;
|
||||
import java.util.Map;
|
||||
|
||||
public class DiscountHelper {
|
||||
|
||||
|
@ -38,7 +38,7 @@ public class DiscountHelper {
|
|||
private static String mIcon;
|
||||
private static String mUrl;
|
||||
private static boolean mBannerVisible;
|
||||
private static final String URL = "http://osmand.net/api/motd";
|
||||
private static final String URL = "https://osmand.net/api/motd";
|
||||
private static final String INAPP_PREFIX = "osmand-in-app:";
|
||||
|
||||
|
||||
|
|
|
@ -186,7 +186,7 @@ public class LiveUpdatesFragment extends BaseOsmAndFragment implements InAppList
|
|||
readMoreBtn.setOnClickListener(new View.OnClickListener() {
|
||||
@Override
|
||||
public void onClick(View v) {
|
||||
Uri uri = Uri.parse("http://osmand.net/osm_live.php");
|
||||
Uri uri = Uri.parse("https://osmand.net/osm_live.php");
|
||||
Intent goToOsmLive = new Intent(Intent.ACTION_VIEW, uri);
|
||||
startActivity(goToOsmLive);
|
||||
}
|
||||
|
|
|
@ -41,7 +41,7 @@ import java.util.Locale;
|
|||
|
||||
public class ReportsFragment extends BaseOsmAndFragment implements CountrySelectionFragment.OnFragmentInteractionListener {
|
||||
public static final int TITLE = R.string.report;
|
||||
public static final String DOMAIN = "http://download.osmand.net/";
|
||||
public static final String DOMAIN = "https://download.osmand.net/";
|
||||
public static final String TOTAL_CHANGES_BY_MONTH_URL_PATTERN = DOMAIN +
|
||||
"reports/query_report.php?report=total_changes_by_month&month=%s®ion=%s";
|
||||
public static final String USERS_RANKING_BY_MONTH = DOMAIN +
|
||||
|
@ -51,7 +51,7 @@ public class ReportsFragment extends BaseOsmAndFragment implements CountrySelect
|
|||
|
||||
|
||||
private static final Log LOG = PlatformUtil.getLog(ReportsFragment.class);
|
||||
public static final String OSM_LIVE_URL = "http://osmand.net/osm_live";
|
||||
public static final String OSM_LIVE_URL = "https://osmand.net/osm_live";
|
||||
|
||||
private TextView contributorsTextView;
|
||||
private TextView editsTextView;
|
||||
|
|
|
@ -229,7 +229,7 @@ public class SubscriptionFragment extends BaseOsmAndDialogFragment implements In
|
|||
showProgress();
|
||||
|
||||
AndroidNetworkUtils.sendRequestAsync(getMyApplication(),
|
||||
"http://download.osmand.net/subscription/update.php",
|
||||
"https://download.osmand.net/subscription/update.php",
|
||||
parameters, "Sending data...", true, true, new AndroidNetworkUtils.OnRequestResultListener() {
|
||||
@Override
|
||||
public void onResult(String result) {
|
||||
|
|
|
@ -410,7 +410,7 @@ public abstract class ImageCard extends AbstractCard {
|
|||
if (!Algorithms.isEmpty(preferredLang)) {
|
||||
pms.put("lang", preferredLang);
|
||||
}
|
||||
String response = AndroidNetworkUtils.sendRequest(app, "http://osmand.net/api/cm_place.php", pms,
|
||||
String response = AndroidNetworkUtils.sendRequest(app, "https://osmand.net/api/cm_place.php", pms,
|
||||
"Requesting location images...", false, false);
|
||||
|
||||
if (!Algorithms.isEmpty(response)) {
|
||||
|
|
|
@ -82,7 +82,7 @@ public class ShareMenu extends BaseMenuController {
|
|||
public void share(ShareItem item) {
|
||||
final int zoom = getMapActivity().getMapView().getZoom();
|
||||
final String geoUrl = MapUtils.buildGeoUrl(latLon.getLatitude(), latLon.getLongitude(), zoom);
|
||||
final String httpUrl = "http://osmand.net/go?lat=" + ((float) latLon.getLatitude())
|
||||
final String httpUrl = "https://osmand.net/go?lat=" + ((float) latLon.getLatitude())
|
||||
+ "&lon=" + ((float) latLon.getLongitude()) + "&z=" + zoom;
|
||||
StringBuilder sb = new StringBuilder();
|
||||
if (!Algorithms.isEmpty(title)) {
|
||||
|
|
|
@ -21,7 +21,6 @@ import net.osmand.PlatformUtil;
|
|||
import net.osmand.plus.OsmandApplication;
|
||||
import net.osmand.plus.R;
|
||||
import net.osmand.plus.Version;
|
||||
import net.osmand.plus.notifications.OsmandNotification;
|
||||
import net.osmand.plus.notifications.OsmandNotification.NotificationType;
|
||||
|
||||
import org.apache.commons.logging.Log;
|
||||
|
|
|
@ -443,7 +443,7 @@ public class OsmandRasterMapsPlugin extends OsmandPlugin {
|
|||
final OsmandApplication app = (OsmandApplication) activity.getApplication();
|
||||
final OsmandSettings settings = app.getSettings();
|
||||
final Map<String, String> entriesMap = settings.getTileSourceEntries(false);
|
||||
TileSourceTemplate ts = new TileSourceTemplate("NewMapnik", "http://mapnik.osmand.net/{0}/{1}/{2}.png",
|
||||
TileSourceTemplate ts = new TileSourceTemplate("NewMapnik", "https://mapnik.osmand.net/{0}/{1}/{2}.png",
|
||||
"png", 17, 5, 256, 16, 32000);
|
||||
final TileSourceTemplate[] result = new TileSourceTemplate[]{ts};
|
||||
AlertDialog.Builder bld = new AlertDialog.Builder(activity);
|
||||
|
|
|
@ -580,7 +580,7 @@ public class RouteProvider {
|
|||
ParserConfigurationException, FactoryConfigurationError, SAXException {
|
||||
List<Location> res = new ArrayList<Location>();
|
||||
StringBuilder uri = new StringBuilder();
|
||||
uri.append("http://www.yournavigation.org/api/1.0/gosmore.php?format=kml"); //$NON-NLS-1$
|
||||
uri.append("https://www.yournavigation.org/api/1.0/gosmore.php?format=kml"); //$NON-NLS-1$
|
||||
uri.append("&flat=").append(params.start.getLatitude()); //$NON-NLS-1$
|
||||
uri.append("&flon=").append(params.start.getLongitude()); //$NON-NLS-1$
|
||||
uri.append("&tlat=").append(params.end.getLatitude()); //$NON-NLS-1$
|
||||
|
@ -998,7 +998,7 @@ public class RouteProvider {
|
|||
}
|
||||
|
||||
StringBuilder request = new StringBuilder();
|
||||
request.append("http://openls.geog.uni-heidelberg.de/osm/eu/routing?").append("start=").append(params.start.getLongitude()).append(',')
|
||||
request.append("https://openls.geog.uni-heidelberg.de/osm/eu/routing?").append("start=").append(params.start.getLongitude()).append(',')
|
||||
.append(params.start.getLatitude()).append("&end=").append(params.end.getLongitude()).append(',').append(params.end.getLatitude())
|
||||
.append("&preference=").append(rpref);
|
||||
// TODO if we would get instructions from the service, we could use this language setting
|
||||
|
@ -1170,7 +1170,7 @@ public class RouteProvider {
|
|||
|
||||
protected RouteCalculationResult findOSRMRoute(RouteCalculationParams params)
|
||||
throws MalformedURLException, IOException, JSONException {
|
||||
// http://router.project-osrm.org/route/v1/driving/4.83,52.28;4.95,52.28
|
||||
// https://router.project-osrm.org/route/v1/driving/4.83,52.28;4.95,52.28
|
||||
List<Location> res = new ArrayList<Location>();
|
||||
StringBuilder uri = new StringBuilder();
|
||||
// possibly hide that API key because it is privacy of osmand
|
||||
|
|
|
@ -28,7 +28,7 @@ public class SeekBarPreference extends DialogPreference implements
|
|||
private static final String DEFAULT_VALUE_ID = "defaultValue";
|
||||
private static final String DIALOG_TEXT_ID = "text";
|
||||
private static final String DIALOG_MESSAGE_ID = "dialogMessage";
|
||||
private static final String ANDROID_NS = "http://schemas.android.com/apk/res/android";
|
||||
private static final String ANDROID_NS = "https://schemas.android.com/apk/res/android";
|
||||
|
||||
private SeekBar seekBar;
|
||||
private TextView dialogTextView, valueTextView;
|
||||
|
|
Loading…
Reference in a new issue