Allow overriding ApplyParentThemeBackground

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@26427 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Robin Dunn
2004-03-28 17:01:21 +00:00
parent 27b60fafb8
commit d43da70602
4 changed files with 178 additions and 4 deletions

View File

@@ -1559,6 +1559,28 @@ extern wxPyApp *wxPythonApp;
PCLASS::CBNAME(cell, x, y); \
}
//---------------------------------------------------------------------------
#define DEC_PYCALLBACK__COLOUR(CBNAME) \
void CBNAME(const wxColour& c); \
void base_##CBNAME(const wxColour& c)
#define IMP_PYCALLBACK__COLOUR(CLASS, PCLASS, CBNAME) \
void CLASS::CBNAME(const wxColour& c) { \
bool found; \
bool blocked = wxPyBeginBlockThreads(); \
if ((found = wxPyCBH_findCallback(m_myInst, #CBNAME))) { \
PyObject* obj = wxPyConstructObject((void*)&c, wxT("wxColour"), 0); \
wxPyCBH_callCallbackObj(m_myInst, Py_BuildValue("(O)",obj)); \
Py_DECREF(obj); \
} \
wxPyEndBlockThreads(blocked); \
if (! found) \
PCLASS::CBNAME(c); \
} \
void CLASS::base_##CBNAME(const wxColour& c) { \
PCLASS::CBNAME(c); \
}
//---------------------------------------------------------------------------