+ wxCommandEvent event(wxEVT_COMMAND_BUTTON_CLICKED, button->GetId());
+ event.SetEventObject(button);
+ button->GetEventHandler()->ProcessEvent(event);
+}
+
+//-----------------------------------------------------------------------------
+// "enter"
+//-----------------------------------------------------------------------------
+
+static void gtk_bmpbutton_enter_callback( GtkWidget *WXUNUSED(widget), wxBitmapButton *button )
+{
+ if (!button->m_hasVMT) return;
+ if (g_blockEventsOnDrag) return;
+
+ button->HasFocus();
+}
+
+//-----------------------------------------------------------------------------
+// "leave"
+//-----------------------------------------------------------------------------
+
+static void gtk_bmpbutton_leave_callback( GtkWidget *WXUNUSED(widget), wxBitmapButton *button )
+{
+ if (!button->m_hasVMT) return;
+ if (g_blockEventsOnDrag) return;
+
+ button->NotFocus();
+}
+
+//-----------------------------------------------------------------------------
+// "pressed"
+//-----------------------------------------------------------------------------
+
+static void gtk_bmpbutton_press_callback( GtkWidget *WXUNUSED(widget), wxBitmapButton *button )
+{
+ if (!button->m_hasVMT) return;
+ if (g_blockEventsOnDrag) return;
+
+ button->StartSelect();
+}
+
+//-----------------------------------------------------------------------------
+// "released"
+//-----------------------------------------------------------------------------
+
+static void gtk_bmpbutton_release_callback( GtkWidget *WXUNUSED(widget), wxBitmapButton *button )
+{
+ if (!button->m_hasVMT) return;
+ if (g_blockEventsOnDrag) return;
+
+ button->EndSelect();