add translations disabled toast

This commit is contained in:
Kasun 2019-04-21 22:19:11 +05:30
parent 220275dc54
commit 20d8464bdf
2 changed files with 5 additions and 1 deletions

View File

@ -2395,7 +2395,10 @@ public class StatusListAdapter extends RecyclerView.Adapter implements OnPostAct
doAction = API.StatusAction.BLOCK;
break;
case R.id.action_translate:
translateToot(status);
if (translator == Helper.TRANS_NONE)
Toasty.info(context, R.string.toast_error_translations_disabled, Toast.LENGTH_SHORT).show();
else
translateToot(status);
return true;
case R.id.action_report:
builderInner = new AlertDialog.Builder(context, style);

View File

@ -294,6 +294,7 @@
<string name="nothing_to_do">No action can be taken</string>
<string name="toast_saved">The media has been saved!</string>
<string name="toast_error_translate">An error occurred while translating!</string>
<string name="toast_error_translations_disabled">Translations are disabled in settings</string>
<string name="toast_toot_saved">Draft saved!</string>
<string name="toast_error_char_limit">Are you sure this instance allows this number of characters? Usually, this value is close to 500 characters.</string>
<string name="toast_visibility_changed">Visibility of the toots has been changed for the account %1$s</string>