// headers
// ----------------------------------------------------------------------------
-#if defined(__GNUG__) && !defined(NO_GCC_PRAGMA)
- #pragma implementation "univtoolbar.h"
-#endif
-
// For compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h"
// wxToolBar implementation
// ============================================================================
-IMPLEMENT_DYNAMIC_CLASS(wxToolBar, wxControl);
+IMPLEMENT_DYNAMIC_CLASS(wxToolBar, wxControl)
// ----------------------------------------------------------------------------
// wxToolBar creation
PerformAction( wxACTION_BUTTON_RELEASE, numArg );
PerformAction( wxACTION_BUTTON_CLICK, numArg );
+
+ // Write by Danny Raynor to change state again.
+ // Check button still pressed or not
+ if( tool->IsInverted() )
+ {
+ PerformAction( wxACTION_TOOLBAR_RELEASE, numArg );
+ }
+
+ // Set mouse leave toolbar button range (If still in the range,
+ // toolbar button would get focus again
+ PerformAction( wxACTION_TOOLBAR_LEAVE, numArg );
}
else if ( action == wxACTION_TOOLBAR_PRESS )
{