// Otherwise make a class that can virtualize CreatePopupMenu
class wxPyTaskBarIcon : public wxTaskBarIcon
{
- DECLARE_ABSTRACT_CLASS(wxPyTaskBarIcon);
+ DECLARE_ABSTRACT_CLASS(wxPyTaskBarIcon)
public:
wxPyTaskBarIcon() : wxTaskBarIcon()
{}
wxMenu* CreatePopupMenu() {
wxMenu *rval = NULL;
bool found;
- bool blocked = wxPyBeginBlockThreads();
+ wxPyBlock_t blocked = wxPyBeginBlockThreads();
if ((found = wxPyCBH_findCallback(m_myInst, "CreatePopupMenu"))) {
PyObject* ro;
wxMenu* ptr;
class wxPyTaskBarIcon : public wxEvtHandler
{
public:
- %pythonAppend wxPyTaskBarIcon "self._setCallbackInfo(self, TaskBarIcon, 0)"
+ %pythonAppend wxPyTaskBarIcon setCallbackInfo(TaskBarIcon)
wxPyTaskBarIcon();
+ ~wxPyTaskBarIcon();
- void _setCallbackInfo(PyObject* self, PyObject* _class, int incref);
+ void _setCallbackInfo(PyObject* self, PyObject* _class, int incref=0);
+ %pythonPrepend Destroy "args[0].this.own(False)";
%extend {
void Destroy() {
self->RemoveIcon();
%constant wxEventType wxEVT_TASKBAR_RIGHT_UP;
%constant wxEventType wxEVT_TASKBAR_LEFT_DCLICK;
%constant wxEventType wxEVT_TASKBAR_RIGHT_DCLICK;
+%constant wxEventType wxEVT_TASKBAR_CLICK;
%pythoncode {
EVT_TASKBAR_RIGHT_UP = wx.PyEventBinder ( wxEVT_TASKBAR_RIGHT_UP )
EVT_TASKBAR_LEFT_DCLICK = wx.PyEventBinder ( wxEVT_TASKBAR_LEFT_DCLICK )
EVT_TASKBAR_RIGHT_DCLICK = wx.PyEventBinder ( wxEVT_TASKBAR_RIGHT_DCLICK )
+EVT_TASKBAR_CLICK = wx.PyEventBinder ( wxEVT_TASKBAR_CLICK )
}
//---------------------------------------------------------------------------