mirror of
https://github.com/StarCitizenToolBox/app.git
synced 2026-02-06 15:10:20 +00:00
fix: improve Aria2c session handling and adjust translation timer
This commit is contained in:
@@ -171,7 +171,7 @@ class InputMethodDialogUIModel extends _$InputMethodDialogUIModel {
|
||||
if (state.isEnableAutoTranslate) {
|
||||
if (_translateTimer != null) _translateTimer?.cancel();
|
||||
state = state.copyWith(isAutoTranslateWorking: true);
|
||||
_translateTimer = Timer(Duration(milliseconds: webMessage ? 1 : 400), () async {
|
||||
_translateTimer = Timer(Duration(milliseconds: webMessage ? 150 : 400), () async {
|
||||
try {
|
||||
final inputText = sourceText.replaceAll("\n", " ");
|
||||
final r = await doTranslateText(inputText);
|
||||
|
||||
Reference in New Issue
Block a user