mirror of
https://github.com/wxWidgets/wxWidgets.git
synced 2026-09-22 22:24:56 +08:00
Beginings of wxX11 support. Much more to do but I have no more time
for it today. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@25111 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -390,7 +390,7 @@ int wxRadioBox_GetNextItem(wxRadioBox const *self,int item,wxDirection dir,long
|
||||
static const wxString wxPySliderNameStr(wxSliderNameStr);
|
||||
static const wxString wxPyToggleButtonNameStr(_T("wxToggleButton"));
|
||||
|
||||
#ifdef __WXMAC__
|
||||
#if defined(__WXMAC__) || defined(__WXX11__)
|
||||
// implement dummy classes and such for wxMac
|
||||
|
||||
#define wxEVT_COMMAND_TOGGLEBUTTON_CLICKED 0
|
||||
|
||||
@@ -579,7 +579,7 @@ class Icon(GDIObject):
|
||||
def __repr__(self):
|
||||
return "<%s.%s; proxy of C++ wxIcon instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
|
||||
def __init__(self, *args, **kwargs):
|
||||
"""__init__(String name, long flags, int desiredWidth=-1, int desiredHeight=-1) -> Icon"""
|
||||
"""__init__(String name, int type, int desiredWidth=-1, int desiredHeight=-1) -> Icon"""
|
||||
newobj = _gdi.new_Icon(*args, **kwargs)
|
||||
self.this = newobj.this
|
||||
self.thisown = 1
|
||||
@@ -591,7 +591,7 @@ class Icon(GDIObject):
|
||||
except: pass
|
||||
|
||||
def LoadFile(*args, **kwargs):
|
||||
"""LoadFile(String name, long flags) -> bool"""
|
||||
"""LoadFile(String name, int type) -> bool"""
|
||||
return _gdi.Icon_LoadFile(*args, **kwargs)
|
||||
|
||||
def Ok(*args, **kwargs):
|
||||
|
||||
@@ -2844,17 +2844,17 @@ static PyObject * Mask_swigregister(PyObject *self, PyObject *args) {
|
||||
static PyObject *_wrap_new_Icon(PyObject *self, PyObject *args, PyObject *kwargs) {
|
||||
PyObject *resultobj;
|
||||
wxString *arg1 = 0 ;
|
||||
long arg2 ;
|
||||
int arg2 ;
|
||||
int arg3 = (int) -1 ;
|
||||
int arg4 = (int) -1 ;
|
||||
wxIcon *result;
|
||||
bool temp1 = False ;
|
||||
PyObject * obj0 = 0 ;
|
||||
char *kwnames[] = {
|
||||
(char *) "name",(char *) "flags",(char *) "desiredWidth",(char *) "desiredHeight", NULL
|
||||
(char *) "name",(char *) "type",(char *) "desiredWidth",(char *) "desiredHeight", NULL
|
||||
};
|
||||
|
||||
if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"Ol|ii:new_Icon",kwnames,&obj0,&arg2,&arg3,&arg4)) goto fail;
|
||||
if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"Oi|ii:new_Icon",kwnames,&obj0,&arg2,&arg3,&arg4)) goto fail;
|
||||
{
|
||||
arg1 = wxString_in_helper(obj0);
|
||||
if (arg1 == NULL) SWIG_fail;
|
||||
@@ -2862,7 +2862,7 @@ static PyObject *_wrap_new_Icon(PyObject *self, PyObject *args, PyObject *kwargs
|
||||
}
|
||||
{
|
||||
PyThreadState* __tstate = wxPyBeginAllowThreads();
|
||||
result = (wxIcon *)new wxIcon((wxString const &)*arg1,arg2,arg3,arg4);
|
||||
result = (wxIcon *)new wxIcon((wxString const &)*arg1,(wxBitmapType )arg2,arg3,arg4);
|
||||
|
||||
wxPyEndAllowThreads(__tstate);
|
||||
if (PyErr_Occurred()) SWIG_fail;
|
||||
@@ -3013,16 +3013,16 @@ static PyObject *_wrap_Icon_LoadFile(PyObject *self, PyObject *args, PyObject *k
|
||||
PyObject *resultobj;
|
||||
wxIcon *arg1 = (wxIcon *) 0 ;
|
||||
wxString *arg2 = 0 ;
|
||||
long arg3 ;
|
||||
int arg3 ;
|
||||
bool result;
|
||||
bool temp2 = False ;
|
||||
PyObject * obj0 = 0 ;
|
||||
PyObject * obj1 = 0 ;
|
||||
char *kwnames[] = {
|
||||
(char *) "self",(char *) "name",(char *) "flags", NULL
|
||||
(char *) "self",(char *) "name",(char *) "type", NULL
|
||||
};
|
||||
|
||||
if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"OOl:Icon_LoadFile",kwnames,&obj0,&obj1,&arg3)) goto fail;
|
||||
if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"OOi:Icon_LoadFile",kwnames,&obj0,&obj1,&arg3)) goto fail;
|
||||
if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_wxIcon,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
|
||||
{
|
||||
arg2 = wxString_in_helper(obj1);
|
||||
@@ -3031,7 +3031,7 @@ static PyObject *_wrap_Icon_LoadFile(PyObject *self, PyObject *args, PyObject *k
|
||||
}
|
||||
{
|
||||
PyThreadState* __tstate = wxPyBeginAllowThreads();
|
||||
result = (bool)(arg1)->LoadFile((wxString const &)*arg2,arg3);
|
||||
result = (bool)(arg1)->LoadFile((wxString const &)*arg2,(wxBitmapType )arg3);
|
||||
|
||||
wxPyEndAllowThreads(__tstate);
|
||||
if (PyErr_Occurred()) SWIG_fail;
|
||||
|
||||
@@ -1056,8 +1056,6 @@ public:
|
||||
};
|
||||
|
||||
|
||||
|
||||
|
||||
IMP_PYCALLBACK_BOOL_DR(wxPyDropSource, wxDropSource, GiveFeedback);
|
||||
|
||||
|
||||
|
||||
@@ -414,10 +414,6 @@ class Dialog(TopLevelWindow):
|
||||
"""CreateButtonSizer(long flags) -> Sizer"""
|
||||
return _windows.Dialog_CreateButtonSizer(*args, **kwargs)
|
||||
|
||||
def SetModal(*args, **kwargs):
|
||||
"""SetModal(bool flag)"""
|
||||
return _windows.Dialog_SetModal(*args, **kwargs)
|
||||
|
||||
def IsModal(*args, **kwargs):
|
||||
"""IsModal() -> bool"""
|
||||
return _windows.Dialog_IsModal(*args, **kwargs)
|
||||
|
||||
@@ -3600,34 +3600,6 @@ static PyObject *_wrap_Dialog_CreateButtonSizer(PyObject *self, PyObject *args,
|
||||
}
|
||||
|
||||
|
||||
static PyObject *_wrap_Dialog_SetModal(PyObject *self, PyObject *args, PyObject *kwargs) {
|
||||
PyObject *resultobj;
|
||||
wxDialog *arg1 = (wxDialog *) 0 ;
|
||||
bool arg2 ;
|
||||
PyObject * obj0 = 0 ;
|
||||
PyObject * obj1 = 0 ;
|
||||
char *kwnames[] = {
|
||||
(char *) "self",(char *) "flag", NULL
|
||||
};
|
||||
|
||||
if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"OO:Dialog_SetModal",kwnames,&obj0,&obj1)) goto fail;
|
||||
if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_wxDialog,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
|
||||
arg2 = PyInt_AsLong(obj1) ? true : false;
|
||||
if (PyErr_Occurred()) SWIG_fail;
|
||||
{
|
||||
PyThreadState* __tstate = wxPyBeginAllowThreads();
|
||||
(arg1)->SetModal(arg2);
|
||||
|
||||
wxPyEndAllowThreads(__tstate);
|
||||
if (PyErr_Occurred()) SWIG_fail;
|
||||
}
|
||||
Py_INCREF(Py_None); resultobj = Py_None;
|
||||
return resultobj;
|
||||
fail:
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
||||
static PyObject *_wrap_Dialog_IsModal(PyObject *self, PyObject *args, PyObject *kwargs) {
|
||||
PyObject *resultobj;
|
||||
wxDialog *arg1 = (wxDialog *) 0 ;
|
||||
@@ -20998,7 +20970,6 @@ static PyMethodDef SwigMethods[] = {
|
||||
{ (char *)"Dialog_GetReturnCode", (PyCFunction) _wrap_Dialog_GetReturnCode, METH_VARARGS | METH_KEYWORDS },
|
||||
{ (char *)"Dialog_CreateTextSizer", (PyCFunction) _wrap_Dialog_CreateTextSizer, METH_VARARGS | METH_KEYWORDS },
|
||||
{ (char *)"Dialog_CreateButtonSizer", (PyCFunction) _wrap_Dialog_CreateButtonSizer, METH_VARARGS | METH_KEYWORDS },
|
||||
{ (char *)"Dialog_SetModal", (PyCFunction) _wrap_Dialog_SetModal, METH_VARARGS | METH_KEYWORDS },
|
||||
{ (char *)"Dialog_IsModal", (PyCFunction) _wrap_Dialog_IsModal, METH_VARARGS | METH_KEYWORDS },
|
||||
{ (char *)"Dialog_ShowModal", (PyCFunction) _wrap_Dialog_ShowModal, METH_VARARGS | METH_KEYWORDS },
|
||||
{ (char *)"Dialog_EndModal", (PyCFunction) _wrap_Dialog_EndModal, METH_VARARGS | METH_KEYWORDS },
|
||||
|
||||
Reference in New Issue
Block a user