mirror of
https://github.com/python/cpython.git
synced 2025-08-04 17:08:35 +00:00
gh-118293: Suppress mouse cursor feedback when launching Windows processes with multiprocessing (GH-118315)
This commit is contained in:
parent
f5b7e397c0
commit
133c1a7cdb
5 changed files with 71 additions and 1 deletions
|
@ -3,6 +3,7 @@ import msvcrt
|
|||
import signal
|
||||
import sys
|
||||
import _winapi
|
||||
from subprocess import STARTUPINFO, STARTF_FORCEOFFFEEDBACK
|
||||
|
||||
from .context import reduction, get_spawning_popen, set_spawning_popen
|
||||
from . import spawn
|
||||
|
@ -74,7 +75,8 @@ class Popen(object):
|
|||
try:
|
||||
hp, ht, pid, tid = _winapi.CreateProcess(
|
||||
python_exe, cmd,
|
||||
None, None, False, 0, env, None, None)
|
||||
None, None, False, 0, env, None,
|
||||
STARTUPINFO(dwFlags=STARTF_FORCEOFFFEEDBACK))
|
||||
_winapi.CloseHandle(ht)
|
||||
except:
|
||||
_winapi.CloseHandle(rhandle)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue