pywin32-checkins Mailing List for Python for Windows Extensions (Page 79)
OLD project page for the Python extensions for Windows
Brought to you by:
mhammond
You can subscribe to this list here.
2003 |
Jan
|
Feb
|
Mar
|
Apr
(2) |
May
(1) |
Jun
(6) |
Jul
(50) |
Aug
(11) |
Sep
(24) |
Oct
(184) |
Nov
(118) |
Dec
(22) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2004 |
Jan
(31) |
Feb
(25) |
Mar
(34) |
Apr
(105) |
May
(49) |
Jun
(38) |
Jul
(39) |
Aug
(7) |
Sep
(98) |
Oct
(79) |
Nov
(20) |
Dec
(17) |
2005 |
Jan
(66) |
Feb
(32) |
Mar
(43) |
Apr
(30) |
May
(58) |
Jun
(30) |
Jul
(16) |
Aug
(4) |
Sep
(21) |
Oct
(42) |
Nov
(11) |
Dec
(14) |
2006 |
Jan
(42) |
Feb
(30) |
Mar
(22) |
Apr
(1) |
May
(9) |
Jun
(15) |
Jul
(20) |
Aug
(9) |
Sep
(8) |
Oct
(1) |
Nov
(9) |
Dec
(43) |
2007 |
Jan
(52) |
Feb
(45) |
Mar
(20) |
Apr
(12) |
May
(59) |
Jun
(39) |
Jul
(35) |
Aug
(31) |
Sep
(17) |
Oct
(20) |
Nov
(4) |
Dec
(4) |
2008 |
Jan
(28) |
Feb
(111) |
Mar
(4) |
Apr
(27) |
May
(40) |
Jun
(27) |
Jul
(32) |
Aug
(94) |
Sep
(87) |
Oct
(153) |
Nov
(336) |
Dec
(331) |
2009 |
Jan
(298) |
Feb
(127) |
Mar
(20) |
Apr
(8) |
May
|
Jun
(10) |
Jul
(6) |
Aug
|
Sep
(2) |
Oct
(2) |
Nov
|
Dec
(1) |
2010 |
Jan
(7) |
Feb
(1) |
Mar
|
Apr
|
May
(15) |
Jun
(4) |
Jul
(3) |
Aug
(28) |
Sep
(1) |
Oct
(19) |
Nov
(16) |
Dec
(6) |
2011 |
Jan
(2) |
Feb
(18) |
Mar
(17) |
Apr
(12) |
May
(5) |
Jun
(11) |
Jul
(7) |
Aug
(2) |
Sep
(2) |
Oct
(4) |
Nov
(4) |
Dec
|
2012 |
Jan
(6) |
Feb
(2) |
Mar
|
Apr
(8) |
May
(4) |
Jun
(3) |
Jul
(13) |
Aug
(27) |
Sep
(8) |
Oct
(9) |
Nov
(3) |
Dec
(2) |
2013 |
Jan
|
Feb
(1) |
Mar
(5) |
Apr
(10) |
May
|
Jun
(2) |
Jul
|
Aug
|
Sep
|
Oct
|
Nov
(1) |
Dec
(9) |
2014 |
Jan
(2) |
Feb
(4) |
Mar
(4) |
Apr
(1) |
May
(4) |
Jun
(2) |
Jul
|
Aug
|
Sep
|
Oct
(2) |
Nov
|
Dec
(1) |
2015 |
Jan
(1) |
Feb
|
Mar
|
Apr
(6) |
May
(2) |
Jun
|
Jul
|
Aug
(1) |
Sep
|
Oct
|
Nov
|
Dec
|
2016 |
Jan
(3) |
Feb
(2) |
Mar
|
Apr
(3) |
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2017 |
Jan
|
Feb
|
Mar
(1) |
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
(1) |
Oct
|
Nov
|
Dec
|
From: Roger U. <ru...@us...> - 2008-02-25 07:46:10
|
Update of /cvsroot/pywin32/pywin32/Pythonwin/pywin/scintilla In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv17377 Modified Files: formatter.py Log Message: Save default backgrounds as -1 Index: formatter.py =================================================================== RCS file: /cvsroot/pywin32/pywin32/Pythonwin/pywin/scintilla/formatter.py,v retrieving revision 1.12 retrieving revision 1.13 diff -C2 -d -r1.12 -r1.13 *** formatter.py 22 Feb 2008 01:22:59 -0000 1.12 --- formatter.py 25 Feb 2008 07:46:13 -0000 1.13 *************** *** 189,207 **** if style.aliased is None: self.SavePreference(style.name, str(style.format)) ! if style.background is not None: ! bg_name = style.name + " background" ! self.SavePreference(bg_name, style.background) # May be None def SavePreference(self, name, value): if value is None: ! hkey = win32ui.GetAppRegistryKey() ! try: ! subkey = win32api.RegOpenKey(hkey, "Format", 0, win32con.KEY_SET_VALUE) ! except win32api.error, (rc, fn, msg): ! if rc != winerror.ERROR_FILE_NOT_FOUND: ! raise ! subkey.Close() ! else: ! win32ui.WriteProfileVal("Format", name, value) # An abstract formatter --- 189,200 ---- if style.aliased is None: self.SavePreference(style.name, str(style.format)) ! bg_name = style.name + " background" ! self.SavePreference(bg_name, style.background) # May be None def SavePreference(self, name, value): + ## LoadPreference uses -1 to indicate default if value is None: ! value=-1 ! win32ui.WriteProfileVal("Format", name, value) # An abstract formatter |
From: Roger U. <ru...@us...> - 2008-02-25 05:31:42
|
Update of /cvsroot/pywin32/pywin32/Pythonwin/pywin/framework/editor In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv1485 Modified Files: configui.py Log Message: Set ranges for line number, marker, and folding width controls Index: configui.py =================================================================== RCS file: /cvsroot/pywin32/pywin32/Pythonwin/pywin/framework/editor/configui.py,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** configui.py 29 Oct 2000 23:42:44 -0000 1.7 --- configui.py 25 Feb 2008 05:31:46 -0000 1.8 *************** *** 95,99 **** self.edgeColor = self.initialEdgeColor = GetEditorOption("Right Edge Color", win32api.RGB(0xef, 0xef, 0xef)) ! self.UpdateUIForState() --- 95,101 ---- self.edgeColor = self.initialEdgeColor = GetEditorOption("Right Edge Color", win32api.RGB(0xef, 0xef, 0xef)) ! for spinner_id in (win32ui.IDC_SPIN1, win32ui.IDC_SPIN2, win32ui.IDC_SPIN3): ! spinner=self.GetDlgItem(spinner_id) ! spinner.SetRange(0,100) self.UpdateUIForState() |
From: Roger U. <ru...@us...> - 2008-02-25 05:27:52
|
Update of /cvsroot/pywin32/pywin32/Pythonwin In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv32521 Modified Files: win32uimodule.cpp Log Message: Add IDC_SPIN3 constant Index: win32uimodule.cpp =================================================================== RCS file: /cvsroot/pywin32/pywin32/Pythonwin/win32uimodule.cpp,v retrieving revision 1.38 retrieving revision 1.39 diff -C2 -d -r1.38 -r1.39 *** win32uimodule.cpp 24 Feb 2008 16:06:09 -0000 1.38 --- win32uimodule.cpp 25 Feb 2008 05:27:55 -0000 1.39 *************** *** 2092,2096 **** ADD_CONSTANT(IDC_SPIN1); // @const win32ui|IDC_SPIN1| ADD_CONSTANT(IDC_SPIN2); // @const win32ui|IDC_SPIN2| ! ADD_CONSTANT(IDC_TAB_SIZE);// @const win32ui|IDC_TAB_SIZE| ADD_CONSTANT(IDC_USE_TABS);// @const win32ui|IDC_USE_TABS| --- 2092,2097 ---- ADD_CONSTANT(IDC_SPIN1); // @const win32ui|IDC_SPIN1| ADD_CONSTANT(IDC_SPIN2); // @const win32ui|IDC_SPIN2| ! ADD_CONSTANT(IDC_SPIN3); // @const win32ui|IDC_SPIN3| ! ADD_CONSTANT(IDC_TAB_SIZE);// @const win32ui|IDC_TAB_SIZE| ADD_CONSTANT(IDC_USE_TABS);// @const win32ui|IDC_USE_TABS| |
From: Roger U. <ru...@us...> - 2008-02-25 03:19:09
|
Update of /cvsroot/pywin32/pywin32/Pythonwin/pywin/framework/editor In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv19484 Modified Files: frame.py Log Message: Don't start tearing down if close is cancelled Index: frame.py =================================================================== RCS file: /cvsroot/pywin32/pywin32/Pythonwin/pywin/framework/editor/frame.py,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** frame.py 3 Apr 2000 12:17:19 -0000 1.5 --- frame.py 25 Feb 2008 03:19:12 -0000 1.6 *************** *** 60,66 **** # XXX - should fix this :-) return self.GetActiveDocument().GetAllViews()[1] def OnClose(self): # Must force the module browser to close itself here (OnDestroy for the view itself is too late!) self.sub_splitter = None # ensure no circles! self.GetBrowserView().DestroyBrowser() ! return self._obj_.OnClose() \ No newline at end of file --- 60,76 ---- # XXX - should fix this :-) return self.GetActiveDocument().GetAllViews()[1] + def OnClose(self): + doc=self.GetActiveDocument() + if not doc.SaveModified(): + ## Cancel button selected from Save dialog, do not actually close + ## print 'close cancelled' + return 0 + ## So the 'Save' dialog doesn't come up twice + doc._obj_.SetModifiedFlag(False) + # Must force the module browser to close itself here (OnDestroy for the view itself is too late!) self.sub_splitter = None # ensure no circles! self.GetBrowserView().DestroyBrowser() ! return self._obj_.OnClose() ! \ No newline at end of file |
From: Roger U. <ru...@us...> - 2008-02-24 16:06:06
|
Update of /cvsroot/pywin32/pywin32/Pythonwin In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv4653 Modified Files: win32assoc.cpp win32cmd.cpp win32uimodule.cpp Log Message: Fix format string in PyCCmdTarget::repr Use CString::Format in place of sprintf Index: win32assoc.cpp =================================================================== RCS file: /cvsroot/pywin32/pywin32/Pythonwin/win32assoc.cpp,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** win32assoc.cpp 20 Nov 2006 12:36:41 -0000 1.8 --- win32assoc.cpp 24 Feb 2008 16:06:09 -0000 1.9 *************** *** 295,302 **** { CString csRet; - char *buf = csRet.GetBuffer(128); PyObject *vi_repr = virtualInst ? PyObject_Repr(virtualInst) : NULL; ! sprintf(buf, " - assoc is %p, vi=%s", assoc, vi_repr ? PyString_AsString(vi_repr) : "<None>" ); ! csRet.ReleaseBuffer(); Py_XDECREF(vi_repr); return ui_base_class::repr() + csRet; --- 295,301 ---- { CString csRet; PyObject *vi_repr = virtualInst ? PyObject_Repr(virtualInst) : NULL; ! // sprintf(buf, " - assoc is %p, vi=%s", assoc, vi_repr ? PyString_AsString(vi_repr) : "<None>" ); ! csRet.Format(" - assoc is %p, vi=%s", assoc, vi_repr ? PyString_AsString(vi_repr) : "<None>" ); Py_XDECREF(vi_repr); return ui_base_class::repr() + csRet; Index: win32uimodule.cpp =================================================================== RCS file: /cvsroot/pywin32/pywin32/Pythonwin/win32uimodule.cpp,v retrieving revision 1.37 retrieving revision 1.38 diff -C2 -d -r1.37 -r1.38 *** win32uimodule.cpp 7 Feb 2008 00:25:29 -0000 1.37 --- win32uimodule.cpp 24 Feb 2008 16:06:09 -0000 1.38 *************** *** 311,322 **** ui_base_class* w = (ui_base_class *)op; CString ret = w->repr(); ! return Py_BuildValue("s",(const char *)ret); } CString ui_base_class::repr() { CString csRet; ! char *buf = csRet.GetBuffer(50); ! sprintf(buf, "object '%s'", ob_type->tp_name); ! csRet.ReleaseBuffer(); return csRet; } --- 311,320 ---- ui_base_class* w = (ui_base_class *)op; CString ret = w->repr(); ! return PyString_FromString(ret); } CString ui_base_class::repr() { CString csRet; ! csRet.Format("object '%s'", ob_type->tp_name); return csRet; } Index: win32cmd.cpp =================================================================== RCS file: /cvsroot/pywin32/pywin32/Pythonwin/win32cmd.cpp,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** win32cmd.cpp 8 Jun 2007 07:20:09 -0000 1.4 --- win32cmd.cpp 24 Feb 2008 16:06:09 -0000 1.5 *************** *** 188,198 **** { CString csRet; - char *buf = csRet.GetBuffer(64); SSIZE_T numCmd = pCommandHookList ? pCommandHookList->GetCount() : 0; SSIZE_T numNotify = pNotifyHookList ? pNotifyHookList->GetCount() : 0; SSIZE_T numCmdUpdate = pCommandUpdateHookList ? pCommandUpdateHookList->GetCount() : 0; SSIZE_T numOle = pOleEventHookList ? pOleEventHookList->GetCount() : 0; ! sprintf(buf, ", notify=%I,ch/u=%I/%I", numNotify, numCmd, numCmdUpdate); ! csRet.ReleaseBuffer(); return ui_assoc_object::repr() + csRet; } --- 188,196 ---- { CString csRet; SSIZE_T numCmd = pCommandHookList ? pCommandHookList->GetCount() : 0; SSIZE_T numNotify = pNotifyHookList ? pNotifyHookList->GetCount() : 0; SSIZE_T numCmdUpdate = pCommandUpdateHookList ? pCommandUpdateHookList->GetCount() : 0; SSIZE_T numOle = pOleEventHookList ? pOleEventHookList->GetCount() : 0; ! csRet.Format(", notify=%Iu,ch/u=%Iu/%Iu", numNotify, numCmd, numCmdUpdate); return ui_assoc_object::repr() + csRet; } |
From: Roger U. <ru...@us...> - 2008-02-24 15:47:16
|
Update of /cvsroot/pywin32/pywin32/Pythonwin In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv30183 Modified Files: win32win.cpp Log Message: Fix format string in repr() to prevent a crash Index: win32win.cpp =================================================================== RCS file: /cvsroot/pywin32/pywin32/Pythonwin/win32win.cpp,v retrieving revision 1.19 retrieving revision 1.20 diff -C2 -d -r1.19 -r1.20 *** win32win.cpp 10 Feb 2008 06:20:51 -0000 1.19 --- win32win.cpp 24 Feb 2008 15:47:20 -0000 1.20 *************** *** 3253,3263 **** { CString csRet; ! char *buf = csRet.GetBuffer(40); UINT_PTR numMsg = pMessageHookList ? pMessageHookList->GetCount() : 0; UINT_PTR numKey = pKeyHookList ? pKeyHookList->GetCount() : 0; char *hookStr = obKeyStrokeHandler ? " (AllKeys Hook Active)" : ""; ! sprintf(buf, ", mh=%I, kh=%I%s", numMsg, numKey, hookStr); ! csRet.ReleaseBuffer(-1); ! return PyCCmdTarget::repr() + csRet; } --- 3253,3262 ---- { CString csRet; ! CString base_repr = PyCCmdTarget::repr(); UINT_PTR numMsg = pMessageHookList ? pMessageHookList->GetCount() : 0; UINT_PTR numKey = pKeyHookList ? pKeyHookList->GetCount() : 0; char *hookStr = obKeyStrokeHandler ? " (AllKeys Hook Active)" : ""; ! csRet.Format("%s, mh=%Iu, kh=%Iu%s", (const char *)base_repr, numMsg, numKey, hookStr); ! return csRet; } |
From: Mark H. <mha...@us...> - 2008-02-23 08:05:08
|
Update of /cvsroot/pywin32/pywin32/Pythonwin/pywin/scintilla In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv12412 Modified Files: control.py Log Message: Use SCI_REPLACESEL instead of EM_REPLACESEL to fix a problem I still can't explain (ie, how did EM_REPLACESEL even get to SCI_REPLACESEL now they have different values??) Index: control.py =================================================================== RCS file: /cvsroot/pywin32/pywin32/Pythonwin/pywin/scintilla/control.py,v retrieving revision 1.15 retrieving revision 1.16 diff -C2 -d -r1.15 -r1.16 *** control.py 6 Sep 2007 06:47:36 -0000 1.15 --- control.py 23 Feb 2008 08:05:07 -0000 1.16 *************** *** 357,361 **** def ReplaceSel(self, str): buff = array.array('c', str + "\0") ! self.SendScintilla(win32con.EM_REPLACESEL, 0, buff.buffer_info()[0]); buff = None --- 357,361 ---- def ReplaceSel(self, str): buff = array.array('c', str + "\0") ! self.SendScintilla(SCI_REPLACESEL, 0, buff.buffer_info()[0]); buff = None |
From: Mark H. <mha...@us...> - 2008-02-22 23:03:05
|
Update of /cvsroot/pywin32/pywin32/isapi/src In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv26622 Modified Files: FilterContext.h PyFilterObjects.cpp PyFilterObjects.h Log Message: Add filter_context.AddResponseHeaders() Index: FilterContext.h =================================================================== RCS file: /cvsroot/pywin32/pywin32/isapi/src/FilterContext.h,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** FilterContext.h 6 Oct 2004 05:11:53 -0000 1.1 --- FilterContext.h 22 Feb 2008 23:03:06 -0000 1.2 *************** *** 44,47 **** --- 44,53 ---- } + BOOL AddResponseHeaders(LPSTR headers, const int reserved=0) + { + return m_pHFC->AddResponseHeaders(m_pHFC, headers, reserved); + } + + bool GetServerVariable(LPCTSTR varName, LPSTR lpBuff, DWORD *pBuffSize) { Index: PyFilterObjects.h =================================================================== RCS file: /cvsroot/pywin32/pywin32/isapi/src/PyFilterObjects.h,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** PyFilterObjects.h 10 Oct 2006 11:05:23 -0000 1.5 --- PyFilterObjects.h 22 Feb 2008 23:03:06 -0000 1.6 *************** *** 64,67 **** --- 64,68 ---- static PyObject * GetData(PyObject *self, PyObject *args); static PyObject * WriteClient(PyObject *self, PyObject *args); + static PyObject * AddResponseHeaders(PyObject *self, PyObject *args); static PyObject * GetServerVariable(PyObject *self, PyObject *args); // ServerSupportFunction implemented functions. Index: PyFilterObjects.cpp =================================================================== RCS file: /cvsroot/pywin32/pywin32/isapi/src/PyFilterObjects.cpp,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** PyFilterObjects.cpp 14 Dec 2006 08:35:34 -0000 1.8 --- PyFilterObjects.cpp 22 Feb 2008 23:03:06 -0000 1.9 *************** *** 212,215 **** --- 212,240 ---- } + // @pymethod |HTTP_FILTER_CONTEXT|AddResponseHeaders| + PyObject * PyHFC::AddResponseHeaders(PyObject *self, PyObject *args) + { + BOOL bRes = FALSE; + char * buffer = NULL; + int reserved = 0; + + PyHFC * phfc = (PyHFC *) self; + // @pyparm string|data|| + // @pyparm int|reserverd|0| + if (!PyArg_ParseTuple(args, "s|l:WriteClient", &buffer, &reserved)) + return NULL; + + if (phfc->m_pfc){ + Py_BEGIN_ALLOW_THREADS + bRes = phfc->m_pfc->AddResponseHeaders(buffer, reserved); + Py_END_ALLOW_THREADS + if (!bRes) + return SetPyHFCError("AddResponseHeaders"); + } + + Py_INCREF(Py_None); + return Py_None; + } + // @pymethod string|HTTP_FILTER_CONTEXT|GetServerVariable| PyObject * PyHFC::GetServerVariable(PyObject *self, PyObject *args) *************** *** 326,329 **** --- 351,355 ---- {"GetServerVariable", PyHFC::GetServerVariable, 1}, // @pymeth GetServerVariable| {"WriteClient", PyHFC::WriteClient, 1}, // @pymeth WriteClient| + {"AddResponseHeaders", PyHFC::AddResponseHeaders, 1}, // @pymeth AddResponseHeaders|Specifies a response header for IIS to send to the client. {"write", PyHFC::WriteClient, 1}, // @pymeth write|A synonym for WriteClient, this allows you to 'print >> fc' {"SendResponseHeader", PyHFC::SendResponseHeader, 1}, // @pymeth SendResponseHeader| |
From: Roger U. <ru...@us...> - 2008-02-22 04:05:22
|
Update of /cvsroot/pywin32/pywin32/Pythonwin/pywin/idle In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv15502 Modified Files: CallTips.py Log Message: Fix for bug 1048325 Index: CallTips.py =================================================================== RCS file: /cvsroot/pywin32/pywin32/Pythonwin/pywin/idle/CallTips.py,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** CallTips.py 13 Aug 2000 13:20:20 -0000 1.1 --- CallTips.py 22 Feb 2008 04:05:26 -0000 1.2 *************** *** 144,152 **** pass # See if we can use the docstring ! if hasattr(ob, "__doc__") and ob.__doc__: ! pos = string.find(ob.__doc__, "\n") ! if pos<0 or pos>70: pos=70 ! if argText: argText = argText + "\n" ! argText = argText + ob.__doc__[:pos] return argText --- 144,159 ---- pass # See if we can use the docstring ! if hasattr(ob, "__doc__"): ! doc=ob.__doc__ ! try: ! pos = doc.find("\n") ! except AttributeError: ! ## New style classes may have __doc__ slot without actually ! ## having a string assigned to it ! pass ! else: ! if pos<0 or pos>70: pos=70 ! if argText: argText = argText + "\n" ! argText = argText + doc[:pos] return argText |
From: Roger U. <ru...@us...> - 2008-02-22 01:22:56
|
Update of /cvsroot/pywin32/pywin32/Pythonwin/pywin/scintilla In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv21178 Modified Files: formatter.py Log Message: Use default window colour for editor background Index: formatter.py =================================================================== RCS file: /cvsroot/pywin32/pywin32/Pythonwin/pywin/scintilla/formatter.py,v retrieving revision 1.11 retrieving revision 1.12 diff -C2 -d -r1.11 -r1.12 *** formatter.py 7 Oct 2004 08:54:01 -0000 1.11 --- formatter.py 22 Feb 2008 01:22:59 -0000 1.12 *************** *** 79,83 **** self.default_background = bg if self.default_background is None: ! self.default_background = win32api.RGB( 0xff, 0xff, 0xff ) def GetDefaultBackground( self ): --- 79,83 ---- self.default_background = bg if self.default_background is None: ! self.default_background = win32api.GetSysColor(win32con.COLOR_WINDOW) def GetDefaultBackground( self ): |
From: Roger U. <ru...@us...> - 2008-02-20 22:35:42
|
Update of /cvsroot/pywin32/pywin32/Pythonwin/pywin/debugger In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv12299 Modified Files: dbgpyapp.py debugger.py Log Message: Remove ToolbarDebugging altogether Index: debugger.py =================================================================== RCS file: /cvsroot/pywin32/pywin32/Pythonwin/pywin/debugger/debugger.py,v retrieving revision 1.15 retrieving revision 1.16 diff -C2 -d -r1.15 -r1.16 *** debugger.py 5 Mar 2005 03:24:12 -0000 1.15 --- debugger.py 20 Feb 2008 22:35:45 -0000 1.16 *************** *** 499,503 **** frame = win32ui.GetMainFrame() - frame.SaveBarState("ToolbarDebugging") # Hide the debuger toolbars (as they wont normally form part of the main toolbar state. for id, klass, float in DebuggerDialogInfos: --- 499,502 ---- *************** *** 510,519 **** pass - # Restore the standard toolbar config - try: - frame.LoadBarState("ToolbarDefault") - except win32ui.error, msg: # When once created toolbars no longer exist. - pass - # print msg # LoadBarState failed (with win32 exception!) self._UnshowCurrentLine() self.set_quit() --- 509,512 ---- *************** *** 786,794 **** w.Init(self) - try: - frame.LoadBarState("ToolbarDebugging") - except win32ui.error, details: - print "LoadBarState failed - %s" % details - # ALWAYS show debugging toolbar, regardless of saved state tb = frame.GetControlBar(win32ui.ID_VIEW_TOOLBAR_DBG) --- 779,782 ---- Index: dbgpyapp.py =================================================================== RCS file: /cvsroot/pywin32/pywin32/Pythonwin/pywin/debugger/dbgpyapp.py,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** dbgpyapp.py 7 Sep 2000 22:48:38 -0000 1.3 --- dbgpyapp.py 20 Feb 2008 22:35:45 -0000 1.4 *************** *** 46,59 **** # win32ui.CreateDebuggerThread() win32ui.EnableControlContainer() - - # Load the ToolBar state near the end of the init process, as - # there may be Toolbar IDs created by the user or other modules. - # By now all these modules should be loaded, so all the toolbar IDs loaded. - try: - self.frame.LoadBarState("ToolbarDefault") - except win32ui.error: - # MFC sucks. It does essentially "GetDlgItem(x)->Something", so if the - # toolbar with ID x does not exist, MFC crashes! Pythonwin has a trap for this - # but I need to investigate more how to prevent it (AFAIK, ensuring all the - # toolbars are created by now _should_ stop it!) - pass --- 46,47 ---- |
From: Roger U. <ru...@us...> - 2008-02-19 22:29:02
|
Update of /cvsroot/pywin32/pywin32/Pythonwin In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv10882 Modified Files: win32template.cpp Log Message: Add a couple of skipLookups (see bug#1092592) Index: win32template.cpp =================================================================== RCS file: /cvsroot/pywin32/pywin32/Pythonwin/win32template.cpp,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** win32template.cpp 28 Jan 2005 22:40:01 -0000 1.3 --- win32template.cpp 19 Feb 2008 22:29:03 -0000 1.4 *************** *** 102,106 **** CPythonDocTemplate *pMFCTemplate = new CPythonDocTemplate(idResource); ! return ui_assoc_object::make(PyCDocTemplate::type, pMFCTemplate); } --- 102,106 ---- CPythonDocTemplate *pMFCTemplate = new CPythonDocTemplate(idResource); ! return ui_assoc_object::make(PyCDocTemplate::type, pMFCTemplate, TRUE); } *************** *** 178,182 **** CFrameWnd *pFrame = new CPythonMDIChildWnd(); GUI_END_SAVE; ! return ui_assoc_object::make(PyCMDIChildWnd::type, pFrame ); } --- 178,182 ---- CFrameWnd *pFrame = new CPythonMDIChildWnd(); GUI_END_SAVE; ! return ui_assoc_object::make(PyCMDIChildWnd::type, pFrame, TRUE ); } |
From: Roger U. <ru...@us...> - 2008-02-19 01:19:26
|
Update of /cvsroot/pywin32/pywin32/Pythonwin/pywin/framework In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv7819 Modified Files: scriptutils.py Log Message: When attempting to import module, catch error if filename itself causes a syntax error Index: scriptutils.py =================================================================== RCS file: /cvsroot/pywin32/pywin32/Pythonwin/pywin/framework/scriptutils.py,v retrieving revision 1.13 retrieving revision 1.14 diff -C2 -d -r1.13 -r1.14 *** scriptutils.py 2 Aug 2002 06:51:24 -0000 1.13 --- scriptutils.py 19 Feb 2008 01:19:30 -0000 1.14 *************** *** 401,408 **** --- 401,413 ---- win32ui.DoWaitCursor(1) # win32ui.GetMainFrame().BeginWaitCursor() + try: # always do an import, as it is cheap is already loaded. This ensures # it is in our name space. codeObj = compile('import '+modName,'<auto import>','exec') + except SyntaxError: + win32ui.SetStatusText('Invalid filename for import: "' +modName+'"') + return + try: exec codeObj in __main__.__dict__ if bNeedReload: |
From: Roger U. <ru...@us...> - 2008-02-17 01:39:33
|
Update of /cvsroot/pywin32/pywin32/Pythonwin In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv32471 Modified Files: win32notify.cpp Log Message: Python 2.3 doesn't recognize "I" format code in Py_BuildValue Index: win32notify.cpp =================================================================== RCS file: /cvsroot/pywin32/pywin32/Pythonwin/win32notify.cpp,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** win32notify.cpp 16 Feb 2008 23:39:57 -0000 1.5 --- win32notify.cpp 17 Feb 2008 01:39:35 -0000 1.6 *************** *** 307,311 **** fmt=NULL; NMTREEVIEW *nmtv=(NMTREEVIEW *)pHdr; ! ob2=Py_BuildValue("INN(ll)", nmtv->action, MakeTV_ITEMTuple(&nmtv->itemOld), --- 307,311 ---- fmt=NULL; NMTREEVIEW *nmtv=(NMTREEVIEW *)pHdr; ! ob2=Py_BuildValue("iNN(ll)", nmtv->action, MakeTV_ITEMTuple(&nmtv->itemOld), |
From: Roger U. <ru...@us...> - 2008-02-16 23:39:53
|
Update of /cvsroot/pywin32/pywin32/Pythonwin In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv21366 Modified Files: win32notify.cpp Log Message: Prevent a crash if an OnNotify handler unexpectedly returns data Index: win32notify.cpp =================================================================== RCS file: /cvsroot/pywin32/pywin32/Pythonwin/win32notify.cpp,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** win32notify.cpp 16 Feb 2008 08:25:44 -0000 1.4 --- win32notify.cpp 16 Feb 2008 23:39:57 -0000 1.5 *************** *** 132,135 **** --- 132,140 ---- BOOL bIgnore; int argNum = 0; + if (fmt==NULL){ + PyErr_Format(PyExc_ValueError, "Notify code %d not expected to return data", ptr->code); + return; + } + while (*fmt) { PyObject *ob = PyTuple_GetItem(args, argNum); *************** *** 352,356 **** // Result should be a tuple of the LRESULT and a tuple to fill the appropriate // struct for this particular message - // ??? What to do if fmt is still NULL at this point ??? if (PyArg_ParseTuple(result, "O&O", PyWinLong_AsVoidPtr, &rc, &obOther)) PyNotifyParseExtraTuple( pHdr, obOther, fmt); --- 357,360 ---- |
From: Roger U. <ru...@us...> - 2008-02-16 08:25:40
|
Update of /cvsroot/pywin32/pywin32/Pythonwin In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv14125 Modified Files: win32notify.cpp Log Message: Fix some 64-bit issues (but not all !) Index: win32notify.cpp =================================================================== RCS file: /cvsroot/pywin32/pywin32/Pythonwin/win32notify.cpp,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** win32notify.cpp 8 Jun 2007 07:20:09 -0000 1.3 --- win32notify.cpp 16 Feb 2008 08:25:44 -0000 1.4 *************** *** 105,108 **** --- 105,113 ---- } */ + case 'V':{ // Pointer-sized number, also used for HANDLE's + ob = bIgnore ? NULL : PyWinLong_FromVoidPtr(*(void **)pUse); + pUse += (sizeof(void *)); + break; + } default: ASSERT(FALSE); *************** *** 218,223 **** PyCCmdTarget *pPyWnd = (PyCCmdTarget *) ui_assoc_CObject::GetPyObject(pFrom); NMHDR *pHdr = (NMHDR *)lParam; ! if (pHdr==NULL) return FALSE; // bad data passed? UINT code = pHdr->code; if (pPyWnd==NULL) return FALSE; // no object. if (!pPyWnd->is_uiobject (&PyCWnd::type)) return FALSE; // unexpected object type. --- 223,231 ---- PyCCmdTarget *pPyWnd = (PyCCmdTarget *) ui_assoc_CObject::GetPyObject(pFrom); NMHDR *pHdr = (NMHDR *)lParam; ! ! if (pHdr==NULL) ! return FALSE; // bad data passed? UINT code = pHdr->code; + if (pPyWnd==NULL) return FALSE; // no object. if (!pPyWnd->is_uiobject (&PyCWnd::type)) return FALSE; // unexpected object type. *************** *** 229,250 **** // have method to call. Build arguments. ! PyObject *ob1 = Py_BuildValue("iii", pHdr->hwndFrom, pHdr->idFrom, pHdr->code); char *fmt; /* ! if (code >= LVN_LAST && code <= LVN_FIRST) // These are negative, hence the reversal. ! fmt = "iiiiiPi"; //this is a NM_LISTVIEW ! else if (code >= TVN_LAST && code <= TVN_FIRST) // These are negative, hence the reversal. ! fmt = "iTTP"; //this is NM_TREEVIEW ! else if (code==TTN_NEEDTEXTA) ! fmt = "-zs80ii"; ! else if (code==TTN_NEEDTEXTW) ! fmt = "-ZS80ii"; ! else ! fmt = NULL; */ if (code >= UDN_LAST && code <= UDN_FIRST) ! fmt = "ii"; //NM_UPDOWN else if (code == TBN_GETBUTTONINFOW) ! fmt = "iiibbiiiZ"; //TBNOTIFY else if (code == TBN_QUERYDELETE || code == TBN_QUERYINSERT || (code >= TBN_ENDDRAG && code <= TBN_FIRST )) fmt = "iiibbiiiz"; --- 237,278 ---- // have method to call. Build arguments. ! PyObject *ob1 = Py_BuildValue("Nii", ! PyWinLong_FromHANDLE(pHdr->hwndFrom), ! pHdr->idFrom, pHdr->code); ! if (ob1==NULL){ ! gui_print_error(); ! return FALSE; ! } char *fmt; /* ! NMTOOLBAR format needs to be adjusted for 64-bit, and already doesn't work ! for 32-bit since PyNotifyMakeExtraTuple doesn't have a case for 'b' ! typedef struct tagNMTOOLBAR { ! NMHDR hdr; ! int iItem; ! TBBUTTON tbButton; ! int cchText; ! LPTSTR pszText; ! RECT rcButton;} NMTOOLBAR ! ! typedef struct _TBBUTTON { ! int iBitmap; ! int idCommand; ! BYTE fsState; ! BYTE fsStyle; ! #ifdef _WIN64 ! BYTE bReserved[6] // padding for alignment ! #elif defined(_WIN32) ! BYTE bReserved[2] // padding for alignment ! #endif ! DWORD_PTR dwData; ! INT_PTR iString;} TBBUTTON */ + + PyObject *ob2=Py_None; // Use None so we can catch NULL for error. if (code >= UDN_LAST && code <= UDN_FIRST) ! fmt = "ii"; // NMUPDOWN else if (code == TBN_GETBUTTONINFOW) ! fmt = "iiibbiiiZ"; // NMTOOLBAR else if (code == TBN_QUERYDELETE || code == TBN_QUERYINSERT || (code >= TBN_ENDDRAG && code <= TBN_FIRST )) fmt = "iiibbiiiz"; *************** *** 252,258 **** fmt = NULL; //NMHDR only else if (code >= TCN_LAST && code <= TCN_SELCHANGE) ! fmt = "i"; //HWND else if (code == TCN_KEYDOWN) ! fmt = "ii"; //TC_KEYDOWN else if (code == TTN_NEEDTEXTW) fmt = "-ZS80ii"; //TOOLTIPTEXT --- 280,286 ---- fmt = NULL; //NMHDR only else if (code >= TCN_LAST && code <= TCN_SELCHANGE) ! fmt = "V"; //HWND else if (code == TCN_KEYDOWN) ! fmt = "ii"; // NMTCKEYDOWN - ??? First element is a WORD, may work due to alignment ??? else if (code == TTN_NEEDTEXTW) fmt = "-ZS80ii"; //TOOLTIPTEXT *************** *** 260,264 **** fmt = NULL; //NMHDR only else if (code == TTN_NEEDTEXTA) ! fmt = "-zs80ii"; //TOOLTIPTEXT else if (code == TVN_ENDLABELEDITW || code == TVN_BEGINLABELEDITW || code == TVN_SETDISPINFOW || code == TVN_GETDISPINFOW || code == TVN_ENDLABELEDITA || code == TVN_BEGINLABELEDITA --- 288,292 ---- fmt = NULL; //NMHDR only else if (code == TTN_NEEDTEXTA) ! fmt = "-zs80Vi"; // NMTTDISPINFO - Third element is HINSTANCE else if (code == TVN_ENDLABELEDITW || code == TVN_BEGINLABELEDITW || code == TVN_SETDISPINFOW || code == TVN_GETDISPINFOW || code == TVN_ENDLABELEDITA || code == TVN_BEGINLABELEDITA *************** *** 266,272 **** fmt = "T"; //TV_DISPINFO else if (code == TVN_KEYDOWN) ! fmt = "ii"; //TV_KEYDOWN ! else if (code >= TVN_LAST && code <= TVN_FIRST) ! fmt = "iTTP"; //NM_TREEVIEW else if (code == HDN_ITEMDBLCLICKW || code == HDN_ITEMDBLCLICKA) fmt = NULL; //NMHDR only --- 294,311 ---- fmt = "T"; //TV_DISPINFO else if (code == TVN_KEYDOWN) ! fmt = "ii"; // NMTVKEYDOWN ??? First element is a WORD ??? ! else if (code >= TVN_LAST && code <= TVN_FIRST){ ! /* NM_TREEVIEW ! On 64-bit, struct alignment prevents the size-based unpacking in PyNotifyMakeExtraTuple ! from correctly converting this struct. ! */ ! fmt=NULL; ! NMTREEVIEW *nmtv=(NMTREEVIEW *)pHdr; ! ob2=Py_BuildValue("INN(ll)", ! nmtv->action, ! MakeTV_ITEMTuple(&nmtv->itemOld), ! MakeTV_ITEMTuple(&nmtv->itemNew), ! nmtv->ptDrag.x, nmtv->ptDrag.y); ! } else if (code == HDN_ITEMDBLCLICKW || code == HDN_ITEMDBLCLICKA) fmt = NULL; //NMHDR only *************** *** 274,325 **** fmt = "iiH"; //HD_NOTIFY else if (code == LVN_KEYDOWN) ! fmt = "ii"; //LV_KEYDOWN else if ((code >= LVN_LAST && code <= LVN_GETDISPINFOW) || code == LVN_ENDLABELEDITA || code == LVN_BEGINLABELEDITA) ! fmt = "L"; //LV_DISPINFO else if (code >= LVN_BEGINRDRAG && code <= LVN_FIRST) ! fmt = "iiiiiPi"; //NM_LISTVIEW else fmt = NULL; ! PyObject *ob2; ! if (fmt==NULL) ! ob2 = PyWinLong_FromVoidPtr(pHdr + 1); ! else ! ob2 = PyNotifyMakeExtraTuple(pHdr, fmt); ! if (ob2==NULL) { gui_print_error(); return FALSE; ! } // make the call with my params. ! PyObject *args = Py_BuildValue("OO", ob1, ob2); ! Py_DECREF(ob1); ! Py_DECREF(ob2); ! int rc = 0; BOOL bPassOn = FALSE; PyObject *obOther; PyObject *result = Python_do_callback(method, args); if (result==NULL) { ! PyErr_SetString(ui_module_error, "Exception in OnNotify() handler"); gui_print_error(); ! } else if (result==Py_None) // allow for None "dont pass on", else result to windows bPassOn = TRUE; ! else if (PyInt_Check(result)) { ! // Simple integer return val ! rc = PyInt_AsLong(result); ! } else if (PyArg_ParseTuple(result, "iO", &rc, &obOther)) { ! // parse off obOther ! PyErr_Clear(); ! PyNotifyParseExtraTuple( pHdr, obOther, fmt); ! if (PyErr_Occurred()) { gui_print_error(); PyErr_SetString(ui_module_error, "Error parsing OnNotify() extra return info"); gui_print_error(); } ! } else { ! PyErr_SetString(ui_module_error, "Unable to parse result from OnNotify()"); gui_print_error(); rc = 0; ! } Py_XDECREF(result); *pResult = rc; --- 313,371 ---- fmt = "iiH"; //HD_NOTIFY else if (code == LVN_KEYDOWN) ! fmt = "ii"; // NMLVKEYDOWN ??? First element is a WORD ??? else if ((code >= LVN_LAST && code <= LVN_GETDISPINFOW) || code == LVN_ENDLABELEDITA || code == LVN_BEGINLABELEDITA) ! fmt = "L"; // NMLVDISPINFO else if (code >= LVN_BEGINRDRAG && code <= LVN_FIRST) ! fmt = "iiiiiPV"; // NMLISTVIEW - Last item is an LPARAM else fmt = NULL; ! if (ob2==Py_None){ ! if (fmt==NULL) ! ob2 = PyWinLong_FromVoidPtr(pHdr + 1); ! else ! ob2 = PyNotifyMakeExtraTuple(pHdr, fmt); ! } ! if (ob2==NULL){ gui_print_error(); return FALSE; ! } // make the call with my params. ! PyObject *args = Py_BuildValue("NN", ob1, ob2); ! if (args==NULL){ ! gui_print_error(); ! return FALSE; ! } ! ! LRESULT rc = 0; BOOL bPassOn = FALSE; PyObject *obOther; PyObject *result = Python_do_callback(method, args); if (result==NULL) { ! PyErr_Warn(ui_module_error, "Exception in OnNotify() handler"); gui_print_error(); ! } ! else if (result==Py_None) // allow for None "dont pass on", else result to windows bPassOn = TRUE; ! else if PyTuple_Check(result){ ! // Result should be a tuple of the LRESULT and a tuple to fill the appropriate ! // struct for this particular message ! // ??? What to do if fmt is still NULL at this point ??? ! if (PyArg_ParseTuple(result, "O&O", PyWinLong_AsVoidPtr, &rc, &obOther)) ! PyNotifyParseExtraTuple( pHdr, obOther, fmt); ! if (PyErr_Occurred()){ gui_print_error(); PyErr_SetString(ui_module_error, "Error parsing OnNotify() extra return info"); gui_print_error(); + } } ! // Otherwise result is just the LRESULT, which can be anything that fits in pointer size ! else if (!PyWinObject_AsPARAM(result, (LPARAM *)&rc)){ ! gui_print_error(); ! PyErr_SetString(ui_module_error, "OnNotify did not return an LRESULT, or a tuple of (LRESULT, notify info tuple)"); gui_print_error(); rc = 0; ! } Py_XDECREF(result); *pResult = rc; |
From: Roger U. <ru...@us...> - 2008-02-16 03:37:26
|
Update of /cvsroot/pywin32/pywin32/Pythonwin In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv7853 Modified Files: win32thread.cpp Log Message: Clean up assocs when MFC thread object is destroyed Index: win32thread.cpp =================================================================== RCS file: /cvsroot/pywin32/pywin32/Pythonwin/win32thread.cpp,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** win32thread.cpp 15 Feb 2008 02:12:59 -0000 1.8 --- win32thread.cpp 16 Feb 2008 03:37:29 -0000 1.9 *************** *** 39,42 **** --- 39,43 ---- Py_XDECREF(obFunc); Py_XDECREF(obArgs); + Python_delete_assoc(this); } virtual BOOL PreTranslateMessage( MSG *pMsg ) { |
From: Roger U. <ru...@us...> - 2008-02-15 02:12:56
|
Update of /cvsroot/pywin32/pywin32/Pythonwin In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv10272 Modified Files: win32thread.cpp Log Message: Add a skipLookup and an Autoduck fix Index: win32thread.cpp =================================================================== RCS file: /cvsroot/pywin32/pywin32/Pythonwin/win32thread.cpp,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** win32thread.cpp 5 Mar 2005 03:16:34 -0000 1.7 --- win32thread.cpp 15 Feb 2008 02:12:59 -0000 1.8 *************** *** 191,195 **** } ! // @pymethod win32ui|win32ui|CreateThread|Creates a new <o PyCWinThread> object PyObject *PyCWinThread::create(PyObject *self, PyObject *args) { --- 191,195 ---- } ! // @pymethod <o PyCWinThread>|win32ui|CreateThread|Creates a new <o PyCWinThread> object PyObject *PyCWinThread::create(PyObject *self, PyObject *args) { *************** *** 214,218 **** return NULL; } ! return ui_assoc_object::make( PyCWinThread::type, pThread ); } --- 214,218 ---- return NULL; } ! return ui_assoc_object::make( PyCWinThread::type, pThread, TRUE); } |
From: Roger U. <ru...@us...> - 2008-02-14 19:05:22
|
Update of /cvsroot/pywin32/pywin32/Pythonwin In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv14141 Modified Files: win32view.cpp Log Message: Add a couple of skipLookup's (see bug 1483482) Index: win32view.cpp =================================================================== RCS file: /cvsroot/pywin32/pywin32/Pythonwin/win32view.cpp,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** win32view.cpp 5 Nov 1999 06:24:29 -0000 1.3 --- win32view.cpp 14 Feb 2008 19:05:23 -0000 1.4 *************** *** 426,430 **** ((CProtectedView *)pView)->SetDocument(pDoc); GUI_END_SAVE; ! return ui_assoc_object::make( PyCScrollView::type, pView ); } --- 426,430 ---- ((CProtectedView *)pView)->SetDocument(pDoc); GUI_END_SAVE; ! return ui_assoc_object::make( PyCScrollView::type, pView, TRUE ); } *************** *** 655,659 **** ((CProtectedView *)pView)->SetDocument(pDoc); GUI_END_SAVE; ! return ui_assoc_object::make( PyCCtrlView::type, pView ); } --- 655,659 ---- ((CProtectedView *)pView)->SetDocument(pDoc); GUI_END_SAVE; ! return ui_assoc_object::make( PyCCtrlView::type, pView, TRUE ); } *************** *** 714,718 **** CPythonEditView *pView = new CPythonEditView(); ((CProtectedView *)pView)->SetDocument(pDoc); ! return ui_assoc_object::make( PyCEditView::type, pView ); } --- 714,718 ---- CPythonEditView *pView = new CPythonEditView(); ((CProtectedView *)pView)->SetDocument(pDoc); ! return ui_assoc_object::make( PyCEditView::type, pView, TRUE ); } *************** *** 940,944 **** ((CProtectedView *)pView)->SetDocument(pDoc); GUI_END_SAVE; ! return ui_assoc_object::make( PyCListView::type, pView ); } --- 940,944 ---- ((CProtectedView *)pView)->SetDocument(pDoc); GUI_END_SAVE; ! return ui_assoc_object::make( PyCListView::type, pView, TRUE ); } *************** *** 1022,1026 **** ((CProtectedView *)pView)->SetDocument(pDoc); GUI_END_SAVE; ! return ui_assoc_object::make( PyCTreeView::type, pView ); } // @pymethod tuple|PyCTreeView|PreCreateWindow|Calls the underlying MFC PreCreateWindow method. --- 1022,1026 ---- ((CProtectedView *)pView)->SetDocument(pDoc); GUI_END_SAVE; ! return ui_assoc_object::make( PyCTreeView::type, pView, TRUE ); } // @pymethod tuple|PyCTreeView|PreCreateWindow|Calls the underlying MFC PreCreateWindow method. *************** *** 1120,1124 **** ((CProtectedView *)pView)->SetDocument(pDoc); GUI_END_SAVE; ! return ui_assoc_object::make( PyCFormView::type, pView ); } --- 1120,1124 ---- ((CProtectedView *)pView)->SetDocument(pDoc); GUI_END_SAVE; ! return ui_assoc_object::make( PyCFormView::type, pView, TRUE ); } |
From: Mark H. <mha...@us...> - 2008-02-13 22:18:08
|
Update of /cvsroot/pywin32/pywin32/com/win32com/server In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv10593 Modified Files: policy.py Log Message: objects implementing "universal" interfaces failed with properties using DISPATCH_PROPERTYPUTREF. From bug 1892592. Index: policy.py =================================================================== RCS file: /cvsroot/pywin32/pywin32/com/win32com/server/policy.py,v retrieving revision 1.22 retrieving revision 1.23 diff -C2 -d -r1.22 -r1.23 *** policy.py 22 Sep 2006 13:31:27 -0000 1.22 --- policy.py 13 Feb 2008 22:18:08 -0000 1.23 *************** *** 492,496 **** if invkind == DISPATCH_METHOD: self._dispid_to_func_[dispid] = name ! elif invkind == DISPATCH_PROPERTYPUT: self._dispid_to_put_[dispid] = name elif invkind == DISPATCH_PROPERTYGET: --- 492,496 ---- if invkind == DISPATCH_METHOD: self._dispid_to_func_[dispid] = name ! elif invkind in (DISPATCH_PROPERTYPUT, DISPATCH_PROPERTYPUTREF): self._dispid_to_put_[dispid] = name elif invkind == DISPATCH_PROPERTYGET: |
From: Roger U. <ru...@us...> - 2008-02-12 19:26:11
|
Update of /cvsroot/pywin32/pywin32/Pythonwin In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv3485 Modified Files: win32dlg.cpp Log Message: Add a couple of skipLookup's (see bug 1483482) Index: win32dlg.cpp =================================================================== RCS file: /cvsroot/pywin32/pywin32/Pythonwin/win32dlg.cpp,v retrieving revision 1.9 retrieving revision 1.10 diff -C2 -d -r1.9 -r1.10 *** win32dlg.cpp 3 Jun 2007 12:35:58 -0000 1.9 --- win32dlg.cpp 12 Feb 2008 19:26:13 -0000 1.10 *************** *** 89,93 **** CDialog *pDlg = new CPythonDlg(); ! PyCDialog *ret = (PyCDialog *)ui_assoc_object::make( PyCDialog::type, pDlg); if (ret) { ret->hTemplate = hGlob; --- 89,93 ---- CDialog *pDlg = new CPythonDlg(); ! PyCDialog *ret = (PyCDialog *)ui_assoc_object::make( PyCDialog::type, pDlg, TRUE); if (ret) { ret->hTemplate = hGlob; *************** *** 490,494 **** CDialog *pDlg = new CPythonDlg(); GUI_END_SAVE; ! PyCDialog *ret = (PyCDialog *)ui_assoc_object::make( PyCDialog::type, pDlg); if (ret) { ret->hTemplate = hGlob; --- 490,494 ---- CDialog *pDlg = new CPythonDlg(); GUI_END_SAVE; ! PyCDialog *ret = (PyCDialog *)ui_assoc_object::make( PyCDialog::type, pDlg, TRUE); if (ret) { ret->hTemplate = hGlob; *************** *** 510,514 **** return NULL; CDialog *pDlg = new CPythonDlg(); ! PyCDialog *ret = (PyCDialog *)ui_assoc_object::make( PyCDialog::type, pDlg); if (ret) { --- 510,514 ---- return NULL; CDialog *pDlg = new CPythonDlg(); ! PyCDialog *ret = (PyCDialog *)ui_assoc_object::make( PyCDialog::type, pDlg, TRUE); if (ret) { *************** *** 795,799 **** RETURN_ERR("Creating CFileDialog failed"); // pyseemfc CFileCialog|CFileDialog PyCFileDialog *newObj = ! (PyCFileDialog *)ui_assoc_object::make( PyCFileDialog::type, pDlg); // if (newObj) // newObj->bManualDelete = TRUE; --- 795,799 ---- RETURN_ERR("Creating CFileDialog failed"); // pyseemfc CFileCialog|CFileDialog PyCFileDialog *newObj = ! (PyCFileDialog *)ui_assoc_object::make( PyCFileDialog::type, pDlg, TRUE); // if (newObj) // newObj->bManualDelete = TRUE; *************** *** 1038,1042 **** } PyCFontDialog *newObj = ! (PyCFontDialog *)ui_assoc_object::make( PyCFontDialog::type, pDlg); if (newObj && pFont) newObj->pInitLogFont = pFont; --- 1038,1042 ---- } PyCFontDialog *newObj = ! (PyCFontDialog *)ui_assoc_object::make( PyCFontDialog::type, pDlg, TRUE); if (newObj && pFont) newObj->pInitLogFont = pFont; *************** *** 1217,1221 **** } PyCColorDialog *newObj = ! (PyCColorDialog *)ui_assoc_object::make( PyCColorDialog::type, pDlg); return newObj; } --- 1217,1221 ---- } PyCColorDialog *newObj = ! (PyCColorDialog *)ui_assoc_object::make( PyCColorDialog::type, pDlg, TRUE); return newObj; } *************** *** 1408,1412 **** CPrintDialog *pDlg = new CPythonPrtDlg(bPrintSetupOnly, dwFlags, pParentWnd); GUI_END_SAVE; ! PyCPrintDialog *ret = (PyCPrintDialog *)ui_assoc_object::make( PyCPrintDialog::type, pDlg); if (ret) { ret->hTemplate = hGlob; --- 1408,1412 ---- CPrintDialog *pDlg = new CPythonPrtDlg(bPrintSetupOnly, dwFlags, pParentWnd); GUI_END_SAVE; ! PyCPrintDialog *ret = (PyCPrintDialog *)ui_assoc_object::make( PyCPrintDialog::type, pDlg, TRUE); if (ret) { ret->hTemplate = hGlob; |
From: Roger U. <ru...@us...> - 2008-02-12 17:39:40
|
Update of /cvsroot/pywin32/pywin32/win32/src In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv28439 Modified Files: win32gui.i Log Message: Fix some 64-bit issues with WPARAM, LPARAM, and LRESULT Index: win32gui.i =================================================================== RCS file: /cvsroot/pywin32/pywin32/win32/src/win32gui.i,v retrieving revision 1.115 retrieving revision 1.116 diff -C2 -d -r1.115 -r1.116 *** win32gui.i 6 Feb 2008 18:42:51 -0000 1.115 --- win32gui.i 12 Feb 2008 17:39:43 -0000 1.116 *************** *** 327,333 **** typedef long COLORREF ! typedef long WPARAM; ! typedef long LPARAM; ! typedef long LRESULT; typedef int UINT; --- 327,333 ---- typedef long COLORREF ! typedef HANDLE WPARAM; ! typedef HANDLE LPARAM; ! typedef HANDLE LRESULT; typedef int UINT; *************** *** 666,670 **** // We are dispatching to Python... ! PyObject *args = Py_BuildValue("Nlll", PyWinLong_FromHANDLE(hWnd), uMsg, wParam, lParam); if (args==NULL){ HandleError("Error building argument tuple for python callback"); --- 666,671 ---- // We are dispatching to Python... ! PyObject *args = Py_BuildValue("NlNN", PyWinLong_FromHANDLE(hWnd), uMsg, ! PyWinObject_FromPARAM(wParam), PyWinObject_FromPARAM(lParam)); if (args==NULL){ HandleError("Error building argument tuple for python callback"); *************** *** 674,682 **** Py_DECREF(args); LRESULT rc = 0; ! if (ret) { ! if (ret != Py_None) // can remain zero for that! ! rc = PyInt_AsLong(ret); Py_DECREF(ret); ! } else HandleError("Python WNDPROC handler failed"); --- 675,683 ---- Py_DECREF(args); LRESULT rc = 0; ! if (ret){ ! if (!PyWinObject_AsPARAM(ret, (LPARAM *)&rc)) ! HandleError("WNDPROC return value cannot be converted to LRESULT"); Py_DECREF(ret); ! } else HandleError("Python WNDPROC handler failed"); *************** *** 1903,1907 **** // @pyswig int|RegisterWindowMessage|Defines a new window message that is guaranteed to be unique throughout the system. The message value can be used when sending or posting messages. // @pyparm string/unicode|name||The string ! LRESULT RegisterWindowMessage(TCHAR *lpString); // @pyswig int|DefWindowProc| --- 1904,1908 ---- // @pyswig int|RegisterWindowMessage|Defines a new window message that is guaranteed to be unique throughout the system. The message value can be used when sending or posting messages. // @pyparm string/unicode|name||The string ! UINT RegisterWindowMessage(TCHAR *lpString); // @pyswig int|DefWindowProc| *************** *** 3553,3557 **** // @pyparm <o PyRECT>|prcRect||Pointer to rec (can be None) ! LRESULT TrackPopupMenu(HMENU hmenu, UINT flags, int x, int y, int reserved, HWND hwnd, const RECT *INPUT_NULLOK); #define TPM_CENTERALIGN TPM_CENTERALIGN --- 3554,3558 ---- // @pyparm <o PyRECT>|prcRect||Pointer to rec (can be None) ! BOOL TrackPopupMenu(HMENU hmenu, UINT flags, int x, int y, int reserved, HWND hwnd, const RECT *INPUT_NULLOK); #define TPM_CENTERALIGN TPM_CENTERALIGN |
From: Mark H. <mha...@us...> - 2008-02-12 12:55:28
|
Update of /cvsroot/pywin32/pywin32 In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv24727 Modified Files: MANIFEST.in Log Message: add a few missing files to the source distro. Index: MANIFEST.in =================================================================== RCS file: /cvsroot/pywin32/pywin32/MANIFEST.in,v retrieving revision 1.12 retrieving revision 1.13 diff -C2 -d -r1.12 -r1.13 *** MANIFEST.in 20 Mar 2006 01:18:39 -0000 1.12 --- MANIFEST.in 12 Feb 2008 12:55:31 -0000 1.13 *************** *** 56,64 **** include com/win32comext/authorization/src/*.h include com/win32comext/axcontrol/src/*.h include com/win32comext/internet/src/*.h include com/win32comext/mapi/src/*.h - include com/win32comext/shell/src/*.h include com/win32comext/mapi/demos/*.py include com/win32comext/shell/demos/servers/*.py include com/win32comext/shell/demos/*.py include com/win32comext/shell/test/*.py --- 56,68 ---- include com/win32comext/authorization/src/*.h include com/win32comext/axcontrol/src/*.h + include com/win32comext/bits/src/*.h + include com/win32comext/bits/test/*.py include com/win32comext/internet/src/*.h include com/win32comext/mapi/src/*.h include com/win32comext/mapi/demos/*.py + include com/win32comext/propsys/test/*.py + include com/win32comext/shell/src/*.h include com/win32comext/shell/demos/servers/*.py + include com/win32comext/shell/demos/servers/*.propdesc include com/win32comext/shell/demos/*.py include com/win32comext/shell/test/*.py *************** *** 112,115 **** --- 116,124 ---- include isapi/src/*.h + # adodbapi + include adodbapi/*.txt + include adodbapi/tests/*.py + include adodbapi/tests/*.bat + # Other tools include SWIG/swig.exe |
From: Mark H. <mha...@us...> - 2008-02-12 12:54:15
|
Update of /cvsroot/pywin32/pywin32 In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv23988 Modified Files: setup.py Log Message: * Add comments and Winresrc.h to the files we scan for version info. * Add adodbapi Index: setup.py =================================================================== RCS file: /cvsroot/pywin32/pywin32/setup.py,v retrieving revision 1.68 retrieving revision 1.69 diff -C2 -d -r1.68 -r1.69 *** setup.py 12 Feb 2008 00:10:57 -0000 1.68 --- setup.py 12 Feb 2008 12:54:19 -0000 1.69 *************** *** 668,673 **** os.environ.get("INCLUDE", "").split(os.pathsep) for d in include_dirs: ! # new platform SDKs stick the version in sdkddkver.h ! for header in ('WINDOWS.H', 'SDKDDKVER.H'): look = os.path.join(d, header) if os.path.isfile(look): --- 668,676 ---- os.environ.get("INCLUDE", "").split(os.pathsep) for d in include_dirs: ! # We look for _WIN32_WINNT instead of WINVER as the Vista ! # SDK defines _WIN32_WINNT as WINVER and we aren't that clever ! # * Windows Server 2003 SDK sticks this version in WinResrc.h ! # * Vista SDKs stick the version in sdkddkver.h ! for header in ('WINDOWS.H', 'SDKDDKVER.H', "WinResrc.h"): look = os.path.join(d, header) if os.path.isfile(look): *************** *** 731,735 **** if sys.hexversion < 0x2040000 and ext.name == 'axdebug' and self.debug: return "axdebug doesn't build in VC6 debug builds (irony!)" ! # We update the .libraries list with the resolved library name. # This is really only so "_d" works. --- 734,738 ---- if sys.hexversion < 0x2040000 and ext.name == 'axdebug' and self.debug: return "axdebug doesn't build in VC6 debug builds (irony!)" ! # We update the .libraries list with the resolved library name. # This is really only so "_d" works. *************** *** 1791,1794 **** --- 1794,1798 ---- 'pythonwin.pywin.tools', 'isapi', + 'adodbapi', ] *************** *** 1893,1896 **** --- 1897,1902 ---- 'isapi/test/*.py', 'isapi/test/*.txt', + 'adodbapi/*.txt', + 'adodbapi/tests/*.py', ]) + # The headers and .lib files |
From: Mark H. <mha...@us...> - 2008-02-12 12:53:04
|
Update of /cvsroot/pywin32/pywin32/win32/Demos/service In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv23628 Modified Files: serviceEvents.py Log Message: tweaks to the messages we write on service events. Index: serviceEvents.py =================================================================== RCS file: /cvsroot/pywin32/pywin32/win32/Demos/service/serviceEvents.py,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** serviceEvents.py 7 Feb 2008 03:33:15 -0000 1.1 --- serviceEvents.py 12 Feb 2008 12:53:07 -0000 1.2 *************** *** 32,44 **** # XXX can't do SERVICE_CONTROL_DEVICEEVENT until we wrap RegisterDeviceNotification. if control == win32service.SERVICE_CONTROL_HARDWAREPROFILECHANGE: ! msg = "A hardware profile changed: change type %d" % (event_type,) elif control == win32service.SERVICE_CONTROL_POWEREVENT: ! msg = "A power event: setting guid=%d, raw_data=%s" % data elif control == win32service.SERVICE_CONTROL_SESSIONCHANGE: # data is a single elt tuple, but this could potentially grow # in the future if the win32 struct does ! msg = "Session event: session ID=%d" % data[:1] else: ! msg = "Other event: code=%d, event_type=%d, data=%s" \ % (control, event_type, data) --- 32,44 ---- # XXX can't do SERVICE_CONTROL_DEVICEEVENT until we wrap RegisterDeviceNotification. if control == win32service.SERVICE_CONTROL_HARDWAREPROFILECHANGE: ! msg = "A hardware profile changed: type=%s, data=%s" % (event_type, data) elif control == win32service.SERVICE_CONTROL_POWEREVENT: ! msg = "A power event: setting %s" % data elif control == win32service.SERVICE_CONTROL_SESSIONCHANGE: # data is a single elt tuple, but this could potentially grow # in the future if the win32 struct does ! msg = "Session event: type=%s, data=%s" % (event_type, data) else: ! msg = "Other event: code=%d, type=%s, data=%s" \ % (control, event_type, data) |