]> git.saurik.com Git - wxWidgets.git/blobdiff - wxPython/src/_timer.i
blind compilation fix for 64 bit systems after last commit
[wxWidgets.git] / wxPython / src / _timer.i
index 910a3864cad50475c662ded96c665c76c7cc67ed..f86f692c765cf581dcf61cd0b79f7e0ad56b62d3 100644 (file)
@@ -32,7 +32,7 @@ enum {
 
 
 %{
-//IMP_PYCALLBACK__(wxPyTimer, wxTimer, Notify);
+IMP_PYCALLBACK__(wxPyTimer, wxTimer, Notify);
 
 IMPLEMENT_ABSTRACT_CLASS(wxPyTimer, wxTimer);
 
@@ -41,28 +41,14 @@ wxPyTimer::wxPyTimer(wxEvtHandler *owner, int id)
 {
     if (owner == NULL) SetOwner(this);
 }
-
-
-void wxPyTimer::Notify() {
-    bool found;
-    bool blocked = wxPyBeginBlockThreads();
-    if ((found = wxPyCBH_findCallback(m_myInst, "Notify")))
-        wxPyCBH_callCallback(m_myInst, Py_BuildValue("()"));
-    wxPyEndBlockThreads(blocked);
-    if (! found)
-        wxTimer::Notify();
-}   
-void wxPyTimer::base_Notify() {
-    wxTimer::Notify();
-}
-
 %}
 
 
 
 MustHaveApp(wxPyTimer);
 
-%name(Timer) class wxPyTimer : public wxEvtHandler
+%rename(Timer) wxPyTimer;
+class wxPyTimer : public wxEvtHandler
 {
 public:
     // Don't let the OOR or callback info hold references to the object so
@@ -100,7 +86,7 @@ public:
 
     // override this in your wxTimer-derived class if you want to process timer
     // messages in it, use non default ctor or SetOwner() otherwise
-    //virtual void Notify();
+    virtual void Notify();
 
     // return True if the timer is running
     virtual bool IsRunning() const;
@@ -115,7 +101,7 @@ public:
     int GetId() const;
 
     %pythoncode {
-        def Destroy():
+        def Destroy(self):
             """NO-OP: Timers must be destroyed by normal refrence counting"""
             pass
     }