mirror of https://github.com/M66B/FairEmail.git
Fixed printing with forced English
This commit is contained in:
parent
852b90ebb7
commit
b40ce24f61
|
@ -47,14 +47,20 @@ import java.util.List;
|
|||
import java.util.Map;
|
||||
|
||||
abstract class ActivityBase extends AppCompatActivity implements SharedPreferences.OnSharedPreferenceChangeListener {
|
||||
private Context originalContext;
|
||||
private boolean contacts;
|
||||
private List<IBackPressedListener> backPressedListeners = new ArrayList<>();
|
||||
|
||||
@Override
|
||||
protected void attachBaseContext(Context base) {
|
||||
originalContext = base;
|
||||
super.attachBaseContext(ApplicationEx.getLocalizedContext(base));
|
||||
}
|
||||
|
||||
Context getOriginalContext() {
|
||||
return originalContext;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void onCreate(Bundle savedInstanceState) {
|
||||
Log.i("Create " + this.getClass().getName() + " version=" + BuildConfig.VERSION_NAME);
|
||||
|
|
|
@ -1277,7 +1277,7 @@ public class ActivityView extends ActivityBilling implements FragmentManager.OnB
|
|||
@Override
|
||||
public void onPageFinished(WebView view, String url) {
|
||||
try {
|
||||
PrintManager printManager = (PrintManager) getSystemService(Context.PRINT_SERVICE);
|
||||
PrintManager printManager = (PrintManager) getOriginalContext().getSystemService(Context.PRINT_SERVICE);
|
||||
String jobName = getString(R.string.app_name);
|
||||
if (!TextUtils.isEmpty(data[0]))
|
||||
jobName += " - " + data[0];
|
||||
|
|
Loading…
Reference in New Issue