[PATCH v3 1/2] oleacc: Check proper UI thread for window focus.
Piotr Caban
piotr.caban at gmail.com
Sat Aug 28 08:32:59 CDT 2021
Hi Connor,
The patch looks good for me.
On 8/12/21 9:07 PM, Connor McAdams wrote:
> + info.cbSize = sizeof(info);
> + if(GetGUIThreadInfo(GetWindowThreadProcessId(This->hwnd, NULL), &info) &&
> + info.hwndFocus == This->hwnd)
It doesn't really matter but you can just call GetGUIThreadInfo(0,
&info) here. If This->hwnd thread is not foreground the hwnd comparison
will always fail.
While you're fixing the function are you also planning to fix the
STATE_SYSTEM_FOCUSABLE flag? It should probably look like this:
if(GetForegroundWindow() == GetAncestor(This->hwnd, GA_ROOT))
V_I4(pvarState) |= STATE_SYSTEM_FOCUSABLE;
Thanks,
Piotr
More information about the wine-devel
mailing list