issues/965

This commit is contained in:
恍兮惚兮 2024-08-06 19:57:19 +08:00
parent f91565c72e
commit e9e8005a94
4 changed files with 19 additions and 17 deletions

View File

@ -1,7 +1,8 @@
from myutils.config import globalconfig, savehook_new_data
from myutils.config import globalconfig, savehook_new_data, uid2gamepath
from myutils.utils import postusewhich
from gui.inputdialog import postconfigdialog_
import gobject
from myutils.hwnd import getExeIcon
class Process:
@ -23,7 +24,7 @@ class Process:
"专有名词翻译_sakura_gpt_词典",
["原文", "翻译", "注释"],
dictkeys=["src", "dst", "info"],
)
).setWindowIcon(getExeIcon(uid2gamepath[gameuid], cache=True))
def process_before(self, japanese):

View File

@ -1,12 +1,13 @@
from myutils.config import noundictconfig, savehook_new_data
import gobject, re, functools, winsharedutils, json
import gobject, re, functools
from qtsymbols import *
from traceback import print_exc
import gobject
from gui.usefulwidget import threebuttons, TableViewW
from myutils.wrapper import Singleton_close
from myutils.utils import postusewhich
from gui.dynalang import LDialog, LLabel, LPushButton, LStandardItemModel, LAction
from myutils.config import uid2gamepath
from myutils.hwnd import getExeIcon
@Singleton_close
@ -336,13 +337,11 @@ class Process:
@staticmethod
def get_setting_window_gameprivate(parent_window, gameuid):
return (
noundictconfigdialog_private(
parent_window,
savehook_new_data[gameuid]["noundictconfig"],
"专有名词翻译_占位符",
),
)
return noundictconfigdialog_private(
parent_window,
savehook_new_data[gameuid]["noundictconfig"],
"专有名词翻译_占位符",
).setWindowIcon(getExeIcon(uid2gamepath[gameuid], cache=True))
@staticmethod
def get_setting_window(parent_window):

View File

@ -2,6 +2,8 @@ from myutils.config import transerrorfixdictconfig, savehook_new_data
from myutils.utils import parsemayberegexreplace, postusewhich
from gui.inputdialog import noundictconfigdialog1
import gobject
from myutils.config import uid2gamepath
from myutils.hwnd import getExeIcon
class Process:
@ -22,7 +24,7 @@ class Process:
savehook_new_data[gameuid]["transerrorfix"],
"翻译结果修正_设置",
["正则", "翻译", "替换"],
)
).setWindowIcon(getExeIcon(uid2gamepath[gameuid], cache=True))
def process_after(self, res, mp1):
res = parsemayberegexreplace(self.usewhich(), res)

View File

@ -1,8 +1,8 @@
from myutils.config import savehook_new_data, globalconfig
import gobject, json, functools
from traceback import print_exc
from gui.inputdialog import postconfigdialog_
from myutils.config import globalconfig, savehook_new_data, uid2gamepath
from myutils.utils import postusewhich
from gui.inputdialog import postconfigdialog_
import gobject, json, functools
from myutils.hwnd import getExeIcon
class Process:
@ -33,7 +33,7 @@ class Process:
"专有名词翻译_直接替换_设置",
["原文", "翻译"],
closecallback=functools.partial(checkchange, gameuid, __),
)
).setWindowIcon(getExeIcon(uid2gamepath[gameuid], cache=True))
@property
def using_X(self):