mirror of
https://github.com/HIllya51/LunaTranslator.git
synced 2024-12-29 16:44:13 +08:00
fix
This commit is contained in:
parent
1ac57342e8
commit
b806307288
@ -473,6 +473,10 @@ class MAINUI:
|
||||
def starttextsource(self, use=None, checked=True):
|
||||
self.translation_ui.showhidestate = False
|
||||
self.translation_ui.refreshtooliconsignal.emit()
|
||||
|
||||
for button in self.translation_ui.showbuttons:
|
||||
button.show()
|
||||
self.translation_ui.set_color_transparency()
|
||||
try:
|
||||
self.settin_ui.selectbutton.setEnabled(
|
||||
globalconfig["sourcestatus2"]["texthook"]["use"]
|
||||
@ -635,7 +639,7 @@ class MAINUI:
|
||||
|
||||
def createedittextui(self):
|
||||
try:
|
||||
self.edittextui = edittext(self.settin_ui, self.edittextui_cached)
|
||||
self.edittextui = edittext(self.commonstylebase, self.edittextui_cached)
|
||||
if self.edittextui:
|
||||
self.edittextui.show()
|
||||
except:
|
||||
@ -652,7 +656,7 @@ class MAINUI:
|
||||
def createattachprocess(self):
|
||||
try:
|
||||
self.AttachProcessDialog = AttachProcessDialog(
|
||||
self.settin_ui, self.selectprocess, self.hookselectdialog
|
||||
self.commonstylebase, self.selectprocess, self.hookselectdialog
|
||||
)
|
||||
if self.AttachProcessDialog:
|
||||
self.AttachProcessDialog.show()
|
||||
@ -955,7 +959,7 @@ class MAINUI:
|
||||
|
||||
def inittray(self):
|
||||
|
||||
trayMenu = QMenu(self.settin_ui)
|
||||
trayMenu = QMenu(self.commonstylebase)
|
||||
showAction = QAction(
|
||||
_TR("&显示"),
|
||||
trayMenu,
|
||||
@ -965,7 +969,7 @@ class MAINUI:
|
||||
qtawesome.icon("fa.gear"),
|
||||
_TR("&设置"),
|
||||
trayMenu,
|
||||
triggered=lambda: self.settin_ui.showsignal.emit(),
|
||||
triggered=lambda: self.commonstylebase.showsignal.emit(),
|
||||
)
|
||||
quitAction = QAction(
|
||||
qtawesome.icon("fa.times"),
|
||||
@ -1028,7 +1032,7 @@ class MAINUI:
|
||||
+ (globalconfig["settingfonttype"])
|
||||
+ "' ; }"
|
||||
)
|
||||
self.__commonstylebase.setStyleSheet(style)
|
||||
self.commonstylebase.setStyleSheet(style)
|
||||
|
||||
def loadui(self):
|
||||
self.installeventfillter()
|
||||
@ -1043,13 +1047,13 @@ class MAINUI:
|
||||
self.startxiaoxueguan()
|
||||
self.starthira()
|
||||
self.startoutputer()
|
||||
self.__commonstylebase = commonstylebase(self.translation_ui)
|
||||
self.commonstylebase = commonstylebase(self.translation_ui)
|
||||
self.setcommonstylesheet()
|
||||
self.settin_ui = Setting(self.__commonstylebase)
|
||||
self.transhis = transhist(self.settin_ui)
|
||||
self.settin_ui = Setting(self.commonstylebase)
|
||||
self.transhis = transhist(self.commonstylebase)
|
||||
self.startreader()
|
||||
self.searchwordW = searchwordW(self.settin_ui)
|
||||
self.hookselectdialog = hookselect(self.settin_ui)
|
||||
self.searchwordW = searchwordW(self.commonstylebase)
|
||||
self.hookselectdialog = hookselect(self.commonstylebase)
|
||||
self.starttextsource()
|
||||
threading.Thread(target=self.autocheckhwndexists).start()
|
||||
threading.Thread(target=self.autohookmonitorthread).start()
|
||||
@ -1067,7 +1071,7 @@ class MAINUI:
|
||||
# 会触发两次
|
||||
windows.WaitForSingleObject(sema, windows.INFINITE)
|
||||
if globalconfig["darklight2"] == 0:
|
||||
self.__commonstylebase.setstylesheetsignal.emit()
|
||||
self.commonstylebase.setstylesheetsignal.emit()
|
||||
windows.WaitForSingleObject(sema, windows.INFINITE)
|
||||
|
||||
def installeventfillter(self):
|
||||
|
@ -634,7 +634,7 @@ class dialog_setting_game_internal(QWidget):
|
||||
self.editpath,
|
||||
getIconButton(functools.partial(self.selectexe), icon="fa.gear"),
|
||||
getIconButton(
|
||||
lambda: browserdialog(gobject.baseobject.settin_ui, exepath),
|
||||
lambda: browserdialog(gobject.baseobject.commonstylebase, exepath),
|
||||
icon="fa.book",
|
||||
),
|
||||
]
|
||||
|
@ -320,7 +320,7 @@ class QUnFrameWindow(resizableframeless):
|
||||
lambda: winsharedutils.clipboard_set(gobject.baseobject.currenttext),
|
||||
),
|
||||
("edit", gobject.baseobject.createedittextui),
|
||||
("edittrans", lambda: edittrans(gobject.baseobject.settin_ui)),
|
||||
("edittrans", lambda: edittrans(gobject.baseobject.commonstylebase)),
|
||||
("showraw", self.changeshowhideraw),
|
||||
("history", lambda: gobject.baseobject.transhis.showsignal.emit()),
|
||||
(
|
||||
@ -341,7 +341,7 @@ class QUnFrameWindow(resizableframeless):
|
||||
("locktoolsbutton", self.changetoolslockstate),
|
||||
(
|
||||
"gamepad_new",
|
||||
lambda: dialog_savedgame_integrated(gobject.baseobject.settin_ui),
|
||||
lambda: dialog_savedgame_integrated(gobject.baseobject.commonstylebase),
|
||||
),
|
||||
(
|
||||
"selectgame",
|
||||
@ -360,7 +360,7 @@ class QUnFrameWindow(resizableframeless):
|
||||
(
|
||||
"memory",
|
||||
lambda: dialog_memory(
|
||||
gobject.baseobject.settin_ui, gobject.baseobject.currentmd5
|
||||
gobject.baseobject.commonstylebase, gobject.baseobject.currentmd5
|
||||
),
|
||||
),
|
||||
(
|
||||
@ -389,7 +389,7 @@ class QUnFrameWindow(resizableframeless):
|
||||
(
|
||||
"open_relative_link",
|
||||
lambda: browserdialog(
|
||||
gobject.baseobject.settin_ui,
|
||||
gobject.baseobject.commonstylebase,
|
||||
trypass(lambda: gobject.baseobject.textsource.pname)(),
|
||||
),
|
||||
),
|
||||
@ -545,7 +545,7 @@ class QUnFrameWindow(resizableframeless):
|
||||
self.displayraw1.connect(self.showraw)
|
||||
self.refreshtooliconsignal.connect(self.refreshtoolicon)
|
||||
self.showsavegame_signal.connect(
|
||||
lambda: dialog_savedgame_integrated(gobject.baseobject.settin_ui)
|
||||
lambda: dialog_savedgame_integrated(gobject.baseobject.commonstylebase)
|
||||
)
|
||||
self.clickRange_signal.connect(self.clickRange)
|
||||
self.showhide_signal.connect(self.showhideocrrange)
|
||||
|
@ -1114,7 +1114,7 @@ class QWebWrap(abstractwebview):
|
||||
|
||||
def __init__(_self) -> None:
|
||||
super().__init__(
|
||||
gobject.baseobject.settin_ui,
|
||||
gobject.baseobject.commonstylebase,
|
||||
poslist=globalconfig["qwebinspectgeo"],
|
||||
)
|
||||
_self.setWindowTitle("Inspect")
|
||||
|
Loading…
x
Reference in New Issue
Block a user