Update ocrtext.py

This commit is contained in:
恍兮惚兮 2024-08-14 19:53:55 +08:00
parent 07fb07ee34
commit fb8969e050

View File

@ -90,9 +90,11 @@ class ocrtext(basetext):
if self.hwnd: if self.hwnd:
if count == len(usehwnds): if count == len(usehwnds):
self.hwnd = hwnd self.hwnd = hwnd
self.pids = [windows.GetWindowThreadProcessId(hwnd)]
else: else:
if count >= len(usehwnds) - 1: if count >= len(usehwnds) - 1:
self.hwnd = hwnd self.hwnd = hwnd
self.pids = [windows.GetWindowThreadProcessId(hwnd)]
def setstyle(self): def setstyle(self):
[_.setstyle() for _ in self.range_ui] [_.setstyle() for _ in self.range_ui]