diff --git a/src/wx/panel.cpp b/src/wx/panel.cpp index c8c9bddb..132b0e8d 100644 --- a/src/wx/panel.cpp +++ b/src/wx/panel.cpp @@ -2501,8 +2501,15 @@ void GameArea::MouseEvent(wxMouseEvent& ev) { mouse_active_time = systemGetClock(); - ShowPointer(); - ShowMenuBar(); + wxPoint cur_pos = wxGetMousePosition(); + + // Ignore small movements. + if (!ev.Moving() || (std::abs(cur_pos.x - mouse_last_pos.x) >= 11 && std::abs(cur_pos.y - mouse_last_pos.y) >= 11)) { + ShowPointer(); + ShowMenuBar(); + } + + mouse_last_pos = cur_pos; ev.Skip(); } diff --git a/src/wx/wxvbam.h b/src/wx/wxvbam.h index 2aed6917..0d386152 100644 --- a/src/wx/wxvbam.h +++ b/src/wx/wxvbam.h @@ -639,6 +639,7 @@ protected: void MouseEvent(wxMouseEvent&); bool pointer_blanked, menu_bar_hidden = false; uint32_t mouse_active_time; + wxPoint mouse_last_pos; #ifdef __WXMSW__ HMENU current_hmenu = nullptr; #endif