Merge branch 'master' of ssh://github.com/osmandapp/Osmand into LiveNowSorting

This commit is contained in:
Chumva 2018-09-05 11:02:36 +03:00
commit 3e99f5d829
4 changed files with 12 additions and 5 deletions

View file

@ -28,7 +28,7 @@
android:textColor="?attr/color_dialog_buttons"
android:textSize="@dimen/default_list_text_size"
android:visibility="gone"
tools:text="http://osmand.net/images/123456789012.jpg"
tools:text="https://osmand.net/images/123456789012.jpg"
tools:visibility="visible"/>
<ImageView

View file

@ -7,7 +7,7 @@
1. To not produce duplicate strings (check by name if a string already exists)
2. Every apostrophe (quote) is preceded by a backslash.
3. If you modify the English strings file, please add new strings at the top of the file, this makes periodic reviews before releases easier.
- For wording and consistency, please note http://osmand.net/help-online?id=technical-articles#Creating_a_Consistent_User_Experience
- For wording and consistency, please note https://osmand.net/help-online?id=technical-articles#Creating_a_Consistent_User_Experience
Thx - Hardy
-->

View file

@ -233,8 +233,14 @@ public class DownloadActivityType {
}
public String getBaseUrl(OsmandApplication ctx, String fileName) {
return "http://" + IndexConstants.INDEX_DOWNLOAD_DOMAIN + "/download?event=2&"
String url = "http://" + IndexConstants.INDEX_DOWNLOAD_DOMAIN + "/download?event=2&"
+ Version.getVersionAsURLParam(ctx) + "&file=" + encode(fileName);
if(this == LIVE_UPDATES_FILE && fileName.length() > 16) {
// DATE_AND_EXT_STR_LEN = "_18_06_02.obf.gz".length()
String region = fileName.substring(0, fileName.length() - 16).toLowerCase();
url += "&region=" + encode(region);
}
return url;
}

View file

@ -44,7 +44,8 @@ public class SendSearchQueryBottomSheet extends MenuBottomSheetDialogFragment {
if (Algorithms.isEmpty(searchQuery)) {
return;
}
params.put(searchQuery, searchLocation);
params.put("query", searchQuery);
params.put("location", searchLocation);
items.add(new TitleItem(getString(R.string.send_search_query)));
final int themeRes = nightMode ? R.style.OsmandDarkTheme : R.style.OsmandLightTheme;
final TextView textView = (TextView) View.inflate(new ContextThemeWrapper(getContext(), themeRes),
@ -73,7 +74,7 @@ public class SendSearchQueryBottomSheet extends MenuBottomSheetDialogFragment {
Toast.makeText(app, R.string.internet_not_available, Toast.LENGTH_LONG).show();
dismiss();
} else {
AndroidNetworkUtils.sendRequestAsync(app, "http://osmand.net/api/missing_search", params,
AndroidNetworkUtils.sendRequestAsync(app, "https://osmand.net/api/missing_search", params,
null, true, true, new AndroidNetworkUtils.OnRequestResultListener() {
@Override
public void onResult(String result) {