Some improvements and additions for wxListCtrl and logging
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@16007 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
parent
8ac67aa102
commit
be13a6af90
@ -13,7 +13,7 @@ from my_distutils import run_swig, contrib_copy_tree
|
||||
# flags and values that affect this script
|
||||
#----------------------------------------------------------------------
|
||||
|
||||
VERSION = "2.3.3pre4"
|
||||
VERSION = "2.3.3pre5"
|
||||
DESCRIPTION = "Cross platform GUI toolkit for Python"
|
||||
AUTHOR = "Robin Dunn"
|
||||
AUTHOR_EMAIL = "Robin Dunn <robin@alldunn.com>"
|
||||
@ -40,7 +40,6 @@ BUILD_IEWIN = 0 # Internet Explorer wrapper (experimental)
|
||||
|
||||
CORE_ONLY = 0 # if true, don't build any of the above
|
||||
|
||||
|
||||
GL_ONLY = 0 # Only used when making the -gl RPM. See the "b" script
|
||||
# for the ugly details
|
||||
|
||||
|
@ -1 +1 @@
|
||||
ver = '2.3.3pre4'
|
||||
ver = '2.3.3pre5'
|
||||
|
@ -444,6 +444,7 @@ public:
|
||||
%addmethods {
|
||||
%new wxListItem* GetColumn(int col) {
|
||||
wxListItem item;
|
||||
item.SetMask(0xFFFF);
|
||||
if (self->GetColumn(col, item))
|
||||
return new wxListItem(item);
|
||||
else
|
||||
|
@ -617,7 +617,7 @@ public:
|
||||
|
||||
bool GetVerbose() const;
|
||||
|
||||
static wxTraceMask GetTraceMask();
|
||||
static unsigned long GetTraceMask();
|
||||
static bool IsAllowedTraceMask(const wxString& mask);
|
||||
|
||||
// static void TimeStamp(wxString *str);
|
||||
@ -681,15 +681,20 @@ public:
|
||||
|
||||
unsigned long wxSysErrorCode();
|
||||
const wxString wxSysErrorMsg(unsigned long nErrCode = 0);
|
||||
void wxLogFatalError(const wxString& szFormat);
|
||||
void wxLogError(const wxString& szFormat);
|
||||
void wxLogWarning(const wxString& szFormat);
|
||||
void wxLogMessage(const wxString& szFormat);
|
||||
void wxLogInfo(const wxString& szFormat);
|
||||
void wxLogVerbose(const wxString& szFormat);
|
||||
void wxLogStatus(const wxString& szFormat);
|
||||
%name(wxLogStatusFrame)void wxLogStatus(wxFrame *pFrame, const wxString& szFormat);
|
||||
void wxLogSysError(const wxString& szFormat);
|
||||
void wxLogFatalError(const wxString& msg);
|
||||
void wxLogError(const wxString& msg);
|
||||
void wxLogWarning(const wxString& msg);
|
||||
void wxLogMessage(const wxString& msg);
|
||||
void wxLogInfo(const wxString& msg);
|
||||
void wxLogVerbose(const wxString& msg);
|
||||
void wxLogStatus(const wxString& msg);
|
||||
%name(wxLogStatusFrame)void wxLogStatus(wxFrame *pFrame, const wxString& msg);
|
||||
void wxLogSysError(const wxString& msg);
|
||||
|
||||
void wxLogTrace(const wxString& msg);
|
||||
%name(wxLogTraceMask)void wxLogTrace(const wxString& mask, const wxString& msg);
|
||||
|
||||
void wxLogGeneric(unsigned long level, const wxString& msg);
|
||||
|
||||
// wxLogFatalError helper: show the (fatal) error to the user in a safe way,
|
||||
// i.e. without using wxMessageBox() for example because it could crash
|
||||
|
@ -3012,6 +3012,7 @@ static PyObject *_wrap_wxListCtrl_SetBackgroundColour(PyObject *self, PyObject *
|
||||
|
||||
static wxListItem * wxPyListCtrl_GetColumn(wxPyListCtrl *self,int col) {
|
||||
wxListItem item;
|
||||
item.SetMask(0xFFFF);
|
||||
if (self->GetColumn(col, item))
|
||||
return new wxListItem(item);
|
||||
else
|
||||
|
@ -2023,7 +2023,7 @@ static PyObject *_wrap_wxLogFatalError(PyObject *self, PyObject *args, PyObject
|
||||
PyObject * _resultobj;
|
||||
wxString * _arg0;
|
||||
PyObject * _obj0 = 0;
|
||||
char *_kwnames[] = { "szFormat", NULL };
|
||||
char *_kwnames[] = { "msg", NULL };
|
||||
|
||||
self = self;
|
||||
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxLogFatalError",_kwnames,&_obj0))
|
||||
@ -2052,7 +2052,7 @@ static PyObject *_wrap_wxLogError(PyObject *self, PyObject *args, PyObject *kwar
|
||||
PyObject * _resultobj;
|
||||
wxString * _arg0;
|
||||
PyObject * _obj0 = 0;
|
||||
char *_kwnames[] = { "szFormat", NULL };
|
||||
char *_kwnames[] = { "msg", NULL };
|
||||
|
||||
self = self;
|
||||
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxLogError",_kwnames,&_obj0))
|
||||
@ -2081,7 +2081,7 @@ static PyObject *_wrap_wxLogWarning(PyObject *self, PyObject *args, PyObject *kw
|
||||
PyObject * _resultobj;
|
||||
wxString * _arg0;
|
||||
PyObject * _obj0 = 0;
|
||||
char *_kwnames[] = { "szFormat", NULL };
|
||||
char *_kwnames[] = { "msg", NULL };
|
||||
|
||||
self = self;
|
||||
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxLogWarning",_kwnames,&_obj0))
|
||||
@ -2110,7 +2110,7 @@ static PyObject *_wrap_wxLogMessage(PyObject *self, PyObject *args, PyObject *kw
|
||||
PyObject * _resultobj;
|
||||
wxString * _arg0;
|
||||
PyObject * _obj0 = 0;
|
||||
char *_kwnames[] = { "szFormat", NULL };
|
||||
char *_kwnames[] = { "msg", NULL };
|
||||
|
||||
self = self;
|
||||
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxLogMessage",_kwnames,&_obj0))
|
||||
@ -2139,7 +2139,7 @@ static PyObject *_wrap_wxLogInfo(PyObject *self, PyObject *args, PyObject *kwarg
|
||||
PyObject * _resultobj;
|
||||
wxString * _arg0;
|
||||
PyObject * _obj0 = 0;
|
||||
char *_kwnames[] = { "szFormat", NULL };
|
||||
char *_kwnames[] = { "msg", NULL };
|
||||
|
||||
self = self;
|
||||
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxLogInfo",_kwnames,&_obj0))
|
||||
@ -2168,7 +2168,7 @@ static PyObject *_wrap_wxLogVerbose(PyObject *self, PyObject *args, PyObject *kw
|
||||
PyObject * _resultobj;
|
||||
wxString * _arg0;
|
||||
PyObject * _obj0 = 0;
|
||||
char *_kwnames[] = { "szFormat", NULL };
|
||||
char *_kwnames[] = { "msg", NULL };
|
||||
|
||||
self = self;
|
||||
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxLogVerbose",_kwnames,&_obj0))
|
||||
@ -2197,7 +2197,7 @@ static PyObject *_wrap_wxLogStatus(PyObject *self, PyObject *args, PyObject *kwa
|
||||
PyObject * _resultobj;
|
||||
wxString * _arg0;
|
||||
PyObject * _obj0 = 0;
|
||||
char *_kwnames[] = { "szFormat", NULL };
|
||||
char *_kwnames[] = { "msg", NULL };
|
||||
|
||||
self = self;
|
||||
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxLogStatus",_kwnames,&_obj0))
|
||||
@ -2228,7 +2228,7 @@ static PyObject *_wrap_wxLogStatusFrame(PyObject *self, PyObject *args, PyObject
|
||||
wxString * _arg1;
|
||||
PyObject * _argo0 = 0;
|
||||
PyObject * _obj1 = 0;
|
||||
char *_kwnames[] = { "pFrame","szFormat", NULL };
|
||||
char *_kwnames[] = { "pFrame","msg", NULL };
|
||||
|
||||
self = self;
|
||||
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxLogStatusFrame",_kwnames,&_argo0,&_obj1))
|
||||
@ -2264,7 +2264,7 @@ static PyObject *_wrap_wxLogSysError(PyObject *self, PyObject *args, PyObject *k
|
||||
PyObject * _resultobj;
|
||||
wxString * _arg0;
|
||||
PyObject * _obj0 = 0;
|
||||
char *_kwnames[] = { "szFormat", NULL };
|
||||
char *_kwnames[] = { "msg", NULL };
|
||||
|
||||
self = self;
|
||||
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxLogSysError",_kwnames,&_obj0))
|
||||
@ -2289,6 +2289,105 @@ static PyObject *_wrap_wxLogSysError(PyObject *self, PyObject *args, PyObject *k
|
||||
return _resultobj;
|
||||
}
|
||||
|
||||
static PyObject *_wrap_wxLogTrace(PyObject *self, PyObject *args, PyObject *kwargs) {
|
||||
PyObject * _resultobj;
|
||||
wxString * _arg0;
|
||||
PyObject * _obj0 = 0;
|
||||
char *_kwnames[] = { "msg", NULL };
|
||||
|
||||
self = self;
|
||||
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxLogTrace",_kwnames,&_obj0))
|
||||
return NULL;
|
||||
{
|
||||
_arg0 = wxString_in_helper(_obj0);
|
||||
if (_arg0 == NULL)
|
||||
return NULL;
|
||||
}
|
||||
{
|
||||
PyThreadState* __tstate = wxPyBeginAllowThreads();
|
||||
wxLogTrace(*_arg0);
|
||||
|
||||
wxPyEndAllowThreads(__tstate);
|
||||
if (PyErr_Occurred()) return NULL;
|
||||
} Py_INCREF(Py_None);
|
||||
_resultobj = Py_None;
|
||||
{
|
||||
if (_obj0)
|
||||
delete _arg0;
|
||||
}
|
||||
return _resultobj;
|
||||
}
|
||||
|
||||
static PyObject *_wrap_wxLogTraceMask(PyObject *self, PyObject *args, PyObject *kwargs) {
|
||||
PyObject * _resultobj;
|
||||
wxString * _arg0;
|
||||
wxString * _arg1;
|
||||
PyObject * _obj0 = 0;
|
||||
PyObject * _obj1 = 0;
|
||||
char *_kwnames[] = { "mask","msg", NULL };
|
||||
|
||||
self = self;
|
||||
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxLogTraceMask",_kwnames,&_obj0,&_obj1))
|
||||
return NULL;
|
||||
{
|
||||
_arg0 = wxString_in_helper(_obj0);
|
||||
if (_arg0 == NULL)
|
||||
return NULL;
|
||||
}
|
||||
{
|
||||
_arg1 = wxString_in_helper(_obj1);
|
||||
if (_arg1 == NULL)
|
||||
return NULL;
|
||||
}
|
||||
{
|
||||
PyThreadState* __tstate = wxPyBeginAllowThreads();
|
||||
wxLogTrace(*_arg0,*_arg1);
|
||||
|
||||
wxPyEndAllowThreads(__tstate);
|
||||
if (PyErr_Occurred()) return NULL;
|
||||
} Py_INCREF(Py_None);
|
||||
_resultobj = Py_None;
|
||||
{
|
||||
if (_obj0)
|
||||
delete _arg0;
|
||||
}
|
||||
{
|
||||
if (_obj1)
|
||||
delete _arg1;
|
||||
}
|
||||
return _resultobj;
|
||||
}
|
||||
|
||||
static PyObject *_wrap_wxLogGeneric(PyObject *self, PyObject *args, PyObject *kwargs) {
|
||||
PyObject * _resultobj;
|
||||
unsigned long _arg0;
|
||||
wxString * _arg1;
|
||||
PyObject * _obj1 = 0;
|
||||
char *_kwnames[] = { "level","msg", NULL };
|
||||
|
||||
self = self;
|
||||
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"lO:wxLogGeneric",_kwnames,&_arg0,&_obj1))
|
||||
return NULL;
|
||||
{
|
||||
_arg1 = wxString_in_helper(_obj1);
|
||||
if (_arg1 == NULL)
|
||||
return NULL;
|
||||
}
|
||||
{
|
||||
PyThreadState* __tstate = wxPyBeginAllowThreads();
|
||||
wxLogGeneric(_arg0,*_arg1);
|
||||
|
||||
wxPyEndAllowThreads(__tstate);
|
||||
if (PyErr_Occurred()) return NULL;
|
||||
} Py_INCREF(Py_None);
|
||||
_resultobj = Py_None;
|
||||
{
|
||||
if (_obj1)
|
||||
delete _arg1;
|
||||
}
|
||||
return _resultobj;
|
||||
}
|
||||
|
||||
static PyObject *_wrap_wxSafeShowMessage(PyObject *self, PyObject *args, PyObject *kwargs) {
|
||||
PyObject * _resultobj;
|
||||
wxString * _arg0;
|
||||
@ -5036,21 +5135,19 @@ static PyObject *_wrap_wxLog_GetVerbose(PyObject *self, PyObject *args, PyObject
|
||||
|
||||
static PyObject *_wrap_wxLog_GetTraceMask(PyObject *self, PyObject *args, PyObject *kwargs) {
|
||||
PyObject * _resultobj;
|
||||
wxTraceMask * _result;
|
||||
unsigned long _result;
|
||||
char *_kwnames[] = { NULL };
|
||||
char _ptemp[128];
|
||||
|
||||
self = self;
|
||||
if(!PyArg_ParseTupleAndKeywords(args,kwargs,":wxLog_GetTraceMask",_kwnames))
|
||||
return NULL;
|
||||
{
|
||||
PyThreadState* __tstate = wxPyBeginAllowThreads();
|
||||
_result = new wxTraceMask (wxLog::GetTraceMask());
|
||||
_result = (unsigned long )wxLog::GetTraceMask();
|
||||
|
||||
wxPyEndAllowThreads(__tstate);
|
||||
if (PyErr_Occurred()) return NULL;
|
||||
} SWIG_MakePtr(_ptemp, (void *) _result,"_wxTraceMask_p");
|
||||
_resultobj = Py_BuildValue("s",_ptemp);
|
||||
} _resultobj = Py_BuildValue("l",_result);
|
||||
return _resultobj;
|
||||
}
|
||||
|
||||
@ -10401,6 +10498,9 @@ static PyMethodDef misc2cMethods[] = {
|
||||
{ "wxWaveData", (PyCFunction) _wrap_wxWaveData, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxExecute", (PyCFunction) _wrap_wxExecute, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxSafeShowMessage", (PyCFunction) _wrap_wxSafeShowMessage, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxLogGeneric", (PyCFunction) _wrap_wxLogGeneric, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxLogTraceMask", (PyCFunction) _wrap_wxLogTraceMask, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxLogTrace", (PyCFunction) _wrap_wxLogTrace, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxLogSysError", (PyCFunction) _wrap_wxLogSysError, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxLogStatusFrame", (PyCFunction) _wrap_wxLogStatusFrame, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxLogStatus", (PyCFunction) _wrap_wxLogStatus, METH_VARARGS | METH_KEYWORDS },
|
||||
|
@ -1119,6 +1119,12 @@ wxLogStatusFrame = misc2c.wxLogStatusFrame
|
||||
|
||||
wxLogSysError = misc2c.wxLogSysError
|
||||
|
||||
wxLogTrace = misc2c.wxLogTrace
|
||||
|
||||
wxLogTraceMask = misc2c.wxLogTraceMask
|
||||
|
||||
wxLogGeneric = misc2c.wxLogGeneric
|
||||
|
||||
wxSafeShowMessage = misc2c.wxSafeShowMessage
|
||||
|
||||
wxExecute = misc2c.wxExecute
|
||||
|
Loading…
Reference in New Issue
Block a user