File tree Expand file tree Collapse file tree 2 files changed +3
-4
lines changed
Expand file tree Collapse file tree 2 files changed +3
-4
lines changed Original file line number Diff line number Diff line change 1212# COM object implementation
1313from _ctypes import CopyComPointer
1414
15- from comtypes import COMError , ReturnHRESULT , instancemethod
15+ from comtypes import COMError , ReturnHRESULT , instancemethod , _encode_idl
1616from comtypes .errorinfo import ISupportErrorInfo , ReportException , ReportError
1717from comtypes .typeinfo import IProvideClassInfo , IProvideClassInfo2
1818from comtypes import IPersist
@@ -466,7 +466,6 @@ def __make_dispentry(self,
466466 # We build a _dispmap_ entry now that maps invkind and
467467 # dispid to implementations that the finder finds;
468468 # IDispatch_Invoke will later call it.
469- from comtypes import _encode_idl
470469 paramflags = [((_encode_idl (x [0 ]), x [1 ]) + tuple (x [3 :])) for x in argspec ]
471470
472471 dispid = idlflags [0 ] # XXX can the dispid be at a different index? Check codegenerator.
Original file line number Diff line number Diff line change 55import comtypes .automation
66import comtypes .typeinfo
77import comtypes .connectionpoints
8+ from comtypes .client ._generate import GetModule
89import logging
910logger = logging .getLogger (__name__ )
1011
@@ -48,7 +49,6 @@ def FindOutgoingInterface(source):
4849 except KeyError :
4950 tinfo = pci .GetClassInfo ()
5051 tlib , index = tinfo .GetContainingTypeLib ()
51- from comtypes .client import GetModule
5252 GetModule (tlib )
5353 interface = comtypes .com_interface_registry [str (guid )]
5454 logger .debug ("%s using sinkinterface %s" , source , interface )
@@ -243,7 +243,7 @@ def PumpEvents(timeout):
243243 # If the calling thread resides in a multithread apartment (MTA),
244244 # CoWaitForMultipleHandles calls the Win32 function
245245 # MsgWaitForMultipleObjects.
246-
246+
247247 hevt = ctypes .windll .kernel32 .CreateEventA (None , True , False , None )
248248 handles = (ctypes .c_void_p * 1 )(hevt )
249249 RPC_S_CALLPENDING = - 2147417835
You can’t perform that action at this time.
0 commit comments