]> git.saurik.com Git - wxWidgets.git/commitdiff
added changes in order to make at least button events work on mac
authorStefan Csomor <csomor@advancedconcepts.ch>
Sun, 9 Dec 2001 07:41:10 +0000 (07:41 +0000)
committerStefan Csomor <csomor@advancedconcepts.ch>
Sun, 9 Dec 2001 07:41:10 +0000 (07:41 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@12951 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

src/generic/spinctlg.cpp

index 3488d1f07471de39fa2d982add6104f176461345..f61ac2c516e385a9fb25111dbdb980cc7c2bdae3 100644 (file)
@@ -107,11 +107,20 @@ public:
     }
 
 protected:
-    void OnSpinButton(wxSpinEvent& event)
+    void OnSpinButton(wxSpinEvent& eventSpin)
     {
-        m_spin->SetTextValue(event.GetPosition());
+#ifdef __WXMAC__
+      m_spin->SetTextValue(eventSpin.GetPosition());
+
+      wxCommandEvent event(wxEVT_COMMAND_SPINCTRL_UPDATED, m_spin->GetId());
+      event.SetEventObject(m_spin);
+      event.SetInt(eventSpin.GetPosition());
 
+      m_spin->GetEventHandler()->ProcessEvent(event);
+#else
+        m_spin->SetTextValue(event.GetPosition());
         event.Skip();
+#endif
     }
 
 private: