+ // Because in some cases wxScrollArrowTimer can cause
+ // m_captureData to be destructed we need to test if it
+ // is still valid before using.
+ if (m_captureData)
+ {
+#if wxUSE_TIMER
+ m_captureData->m_timerScroll = tmpTimerScroll;
+#endif // wxUSE_TIMER
+
+ m_control->SetArrowFlag(arrow, wxCONTROL_PRESSED, true);
+ }
+ else
+ {
+#if wxUSE_TIMER
+ delete tmpTimerScroll;
+#endif // wxUSE_TIMER
+ }