From cf8a13cfa1b7b47282b4047fc07acfa64b6379dc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=81=8D=E5=85=AE=E6=83=9A=E5=85=AE?= <101191390+HIllya51@users.noreply.github.com> Date: Wed, 24 Apr 2024 18:24:09 +0800 Subject: [PATCH] Update utils.py --- LunaTranslator/LunaTranslator/myutils/utils.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/LunaTranslator/LunaTranslator/myutils/utils.py b/LunaTranslator/LunaTranslator/myutils/utils.py index a2fb8812..672ebf57 100644 --- a/LunaTranslator/LunaTranslator/myutils/utils.py +++ b/LunaTranslator/LunaTranslator/myutils/utils.py @@ -436,7 +436,8 @@ def minmaxmoveobservefunc(self): gobject.baseobject.translation_ui.settop() else: gobject.baseobject.translation_ui.thistimenotsetop = True - gobject.baseobject.translation_ui.canceltop() + if gobject.baseobject.translation_ui.istopmost(): + gobject.baseobject.translation_ui.canceltop() if _focusp != windows.GetWindowThreadProcessId( gobject.baseobject.textsource.hwnd ):