[pywin32-checkins] pywin32/Pythonwin/pywin/mfc activex.py,1.2,1.3
OLD project page for the Python extensions for Windows
Brought to you by:
mhammond
From: Mark H. <mha...@us...> - 2005-04-18 13:36:55
|
Update of /cvsroot/pywin32/pywin32/Pythonwin/pywin/mfc In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv15464/pywin/mfc Modified Files: activex.py Log Message: Allow PyCWnd.CreateControl to pass a license strings will NULL characters, and pass missing params to this function from the activex.py framework. Index: activex.py =================================================================== RCS file: /cvsroot/pywin32/pywin32/Pythonwin/pywin/mfc/activex.py,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** activex.py 10 Jan 2003 02:55:09 -0000 1.2 --- activex.py 18 Apr 2005 13:36:47 -0000 1.3 *************** *** 5,9 **** class Control(window.Wnd): ! """An ActiveX control base class. A new class must be derived from both this class and the Events class. See the demos for more details. """ --- 5,9 ---- class Control(window.Wnd): ! """An ActiveX control base class. A new class must be derived from both this class and the Events class. See the demos for more details. """ *************** *** 21,30 **** def CreateControl(self, windowTitle, style, rect, parent, id, lic_string=None): clsid = str(self._GetControlCLSID()) ! self.__dict__["_obj_"] = win32ui.CreateControl(clsid, windowTitle, style, rect, parent, id, lic_string) klass = self._GetDispatchClass() dispobj = klass(win32uiole.GetIDispatchForWindow(self._obj_)) self.HookOleEvents() self.__dict__["_dispobj_"] = dispobj ! def HookOleEvents(self): dict = self._GetEventMap() --- 21,30 ---- def CreateControl(self, windowTitle, style, rect, parent, id, lic_string=None): clsid = str(self._GetControlCLSID()) ! self.__dict__["_obj_"] = win32ui.CreateControl(clsid, windowTitle, style, rect, parent, id, None, False, lic_string) klass = self._GetDispatchClass() dispobj = klass(win32uiole.GetIDispatchForWindow(self._obj_)) self.HookOleEvents() self.__dict__["_dispobj_"] = dispobj ! def HookOleEvents(self): dict = self._GetEventMap() *************** *** 55,59 **** """Given a CoClass in a generated .py file, this function will return a Class object which can be used as an OCX control. ! This function is used when you do not want to handle any events from the OCX control. If you need events, then you should derive a class from both the --- 55,59 ---- """Given a CoClass in a generated .py file, this function will return a Class object which can be used as an OCX control. ! This function is used when you do not want to handle any events from the OCX control. If you need events, then you should derive a class from both the *************** *** 63,67 **** name = controlClass.__name__ return new.classobj("OCX" + name, (Control, controlClass), {}) ! def MakeControlInstance( controlClass, name = None ): """As for MakeControlClass(), but returns an instance of the class. --- 63,67 ---- name = controlClass.__name__ return new.classobj("OCX" + name, (Control, controlClass), {}) ! def MakeControlInstance( controlClass, name = None ): """As for MakeControlClass(), but returns an instance of the class. |