Fix DeepL pro URL

This commit is contained in:
Thomas 2022-12-28 15:01:25 +01:00
parent 2c48032127
commit fc4e7fddbe
3 changed files with 4 additions and 4 deletions

View file

@ -27,7 +27,6 @@ import android.net.Uri;
import android.os.Build; import android.os.Build;
import android.os.Bundle; import android.os.Bundle;
import android.os.Handler; import android.os.Handler;
import android.util.Log;
import android.view.Display; import android.view.Display;
import android.view.Menu; import android.view.Menu;
import android.view.MenuItem; import android.view.MenuItem;
@ -256,7 +255,6 @@ public class MediaActivity extends BaseTransparentActivity implements OnDownload
} }
} }
} else { } else {
Log.v(Helper.TAG, "ici");
if (attachment.type.compareTo("image") == 0) { if (attachment.type.compareTo("image") == 0) {
MediaHelper.manageMove(MediaActivity.this, attachment.url, false); MediaHelper.manageMove(MediaActivity.this, attachment.url, false);
} else { } else {

View file

@ -58,8 +58,10 @@ public class TranslateHelper {
String translatorVersion = sharedpreferences.getString(context.getString(R.string.SET_TRANSLATOR_VERSION), "PRO"); String translatorVersion = sharedpreferences.getString(context.getString(R.string.SET_TRANSLATOR_VERSION), "PRO");
params.setPro(translatorVersion.equals("PRO")); params.setPro(translatorVersion.equals("PRO"));
String apikey = sharedpreferences.getString(context.getString(R.string.SET_TRANSLATOR_API_KEY), null); String apikey = sharedpreferences.getString(context.getString(R.string.SET_TRANSLATOR_API_KEY), null);
if (apikey != null) {
myTransL.setDeeplAPIKey(apikey.trim()); myTransL.setDeeplAPIKey(apikey.trim());
} }
}
String translate = sharedpreferences.getString(context.getString(R.string.SET_LIVE_TRANSLATE), MyTransL.getLocale()); String translate = sharedpreferences.getString(context.getString(R.string.SET_LIVE_TRANSLATE), MyTransL.getLocale());
if (translate.equalsIgnoreCase("default")) { if (translate.equalsIgnoreCase("default")) {

View file

@ -28,7 +28,7 @@ public class Helper {
private static final String YANDEX_BASE_URL = "https://translate.yandex.net/api/v1.5/tr.json/translate?"; private static final String YANDEX_BASE_URL = "https://translate.yandex.net/api/v1.5/tr.json/translate?";
private static final String DEEPL_BASE_URL = "https://free.deepl.com/v2/translate?"; private static final String DEEPL_BASE_URL = "https://api.deepl.com/v2/translate?";
private static final String DEEPL_BASE_FREE_URL = "https://api-free.deepl.com/v2/translate?"; private static final String DEEPL_BASE_FREE_URL = "https://api-free.deepl.com/v2/translate?";
private static final String SYSTRAN_BASE_URL = "https://api-platform.systran.net/translation/text/translate?"; private static final String SYSTRAN_BASE_URL = "https://api-platform.systran.net/translation/text/translate?";
private static final String[] deeplAvailableLang = {"EN", "DE", "FR", "ES", "IT", "NL", "PL"}; private static final String[] deeplAvailableLang = {"EN", "DE", "FR", "ES", "IT", "NL", "PL"};