|
|
@ -2756,6 +2756,8 @@ public class FragmentCompose extends FragmentBase {
|
|
|
|
|
|
|
|
|
|
|
|
@Override
|
|
|
|
@Override
|
|
|
|
protected void onExecuted(Bundle args, DeepL.Translation translation) {
|
|
|
|
protected void onExecuted(Bundle args, DeepL.Translation translation) {
|
|
|
|
|
|
|
|
if (etSubject == null)
|
|
|
|
|
|
|
|
return;
|
|
|
|
etSubject.setText(translation.translated_text);
|
|
|
|
etSubject.setText(translation.translated_text);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
@ -2763,7 +2765,7 @@ public class FragmentCompose extends FragmentBase {
|
|
|
|
protected void onException(Bundle args, Throwable ex) {
|
|
|
|
protected void onException(Bundle args, Throwable ex) {
|
|
|
|
Log.unexpectedError(getParentFragmentManager(), ex, !(ex instanceof IOException));
|
|
|
|
Log.unexpectedError(getParentFragmentManager(), ex, !(ex instanceof IOException));
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}.serial().execute(FragmentCompose.this, args, "compose:translate");
|
|
|
|
}.execute(FragmentCompose.this, args, "compose:translate");
|
|
|
|
} else {
|
|
|
|
} else {
|
|
|
|
final Pair<Integer, Integer> paragraph = StyleHelper.getParagraph(etBody);
|
|
|
|
final Pair<Integer, Integer> paragraph = StyleHelper.getParagraph(etBody);
|
|
|
|
if (paragraph == null)
|
|
|
|
if (paragraph == null)
|
|
|
@ -2890,7 +2892,7 @@ public class FragmentCompose extends FragmentBase {
|
|
|
|
etBody.setSelection(paragraph.second);
|
|
|
|
etBody.setSelection(paragraph.second);
|
|
|
|
Log.unexpectedError(getParentFragmentManager(), ex, !(ex instanceof IOException));
|
|
|
|
Log.unexpectedError(getParentFragmentManager(), ex, !(ex instanceof IOException));
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}.serial().execute(FragmentCompose.this, args, "compose:translate");
|
|
|
|
}.execute(FragmentCompose.this, args, "compose:translate");
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
});
|
|
|
|
});
|
|
|
@ -2970,7 +2972,7 @@ public class FragmentCompose extends FragmentBase {
|
|
|
|
Log.unexpectedError(getParentFragmentManager(), exex, false);
|
|
|
|
Log.unexpectedError(getParentFragmentManager(), exex, false);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}.serial().execute(this, args, "compose:lt");
|
|
|
|
}.execute(this, args, "compose:lt");
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
private void onActionRecordAudio() {
|
|
|
|
private void onActionRecordAudio() {
|
|
|
|