Don't consume context menu events in wxToolbook
This was preventing the application code from receiving them. Closes #22153.
This commit is contained in:
parent
3fa634677c
commit
10ad88cdbe
1 changed files with 4 additions and 1 deletions
|
|
@ -371,7 +371,10 @@ void wxToolbook::OnToolSelected(wxCommandEvent& event)
|
|||
int page = ToolIdToPage(event.GetId());
|
||||
if (page == wxNOT_FOUND)
|
||||
{
|
||||
// this happens only of page id has changed afterwards
|
||||
// we may have gotten an event from something other than our tool, e.g.
|
||||
// a menu item from a context menu shown from the application code, so
|
||||
// take care to avoid consuming it in this case
|
||||
event.Skip();
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue