+ case WXK_TAB:
+ //
+ // Always produce navigation event - even if we process TAB
+ // ourselves the fact that we got here means that the user code
+ // decided to skip processing of this TAB - probably to let it
+ // do its default job.
+ //
+ {
+ wxNavigationKeyEvent vEventNav;
+
+ vEventNav.SetDirection(!rEvent.ShiftDown());
+ vEventNav.SetWindowChange(rEvent.ControlDown());
+ vEventNav.SetEventObject(this);
+ if (GetParent()->GetEventHandler()->ProcessEvent(vEventNav))
+ return;
+ }
+ break;
+ }
+
+ //
+ // No, we didn't process it
+ //
+ rEvent.Skip();
+} // end of wxSpinCtrl::OnChar
+
+void wxSpinCtrl::OnSpinChange(
+ wxSpinEvent& rEventSpin
+)
+{
+ wxCommandEvent vEvent( wxEVT_COMMAND_SPINCTRL_UPDATED
+ ,GetId()
+ );
+
+ vEvent.SetEventObject(this);
+ vEvent.SetInt(rEventSpin.GetPosition());
+ (void)GetEventHandler()->ProcessEvent(vEvent);
+ if (rEventSpin.GetSkipped())
+ {
+ vEvent.Skip();
+ }
+} // end of wxSpinCtrl::OnSpinChange
+
+bool wxSpinCtrl::ProcessTextCommand(
+ WXWORD wCmd
+, WXWORD wId
+)
+{
+ switch (wCmd)
+ {
+ case SPBN_CHANGE:
+ {
+ wxCommandEvent vEvent( wxEVT_COMMAND_TEXT_UPDATED
+ ,GetId()
+ );
+ vEvent.SetEventObject(this);
+
+ wxString sVal = wxGetWindowText(m_hWndBuddy);
+
+ vEvent.SetString((char*)sVal.c_str());
+ vEvent.SetInt(GetValue());
+ return (GetEventHandler()->ProcessEvent(vEvent));
+ }
+
+ case SPBN_SETFOCUS:
+ case SPBN_KILLFOCUS:
+ {
+ wxFocusEvent vEvent( wCmd == EN_KILLFOCUS ? wxEVT_KILL_FOCUS : wxEVT_SET_FOCUS
+ ,m_windowId
+ );
+
+ vEvent.SetEventObject(this);
+ return(GetEventHandler()->ProcessEvent(vEvent));
+ }
+ default:
+ break;
+ }
+
+ //
+ // Not processed
+ //