Enable frame's accelerator keys when a ctrl has captured mouse in Windows

Do you have a typical platform dependent issue you're battling with ? Ask it here. Make sure you mention your platform, compiler, and wxWidgets version.
Post Reply
thoray
Knows some wx things
Knows some wx things
Posts: 42
Joined: Sun Oct 18, 2015 9:31 am

Enable frame's accelerator keys when a ctrl has captured mouse in Windows

Post by thoray » Mon Mar 09, 2020 11:59 pm

I set up accelerator keys when creating top menu items like this:

menu->Append(item_id,wxT("&Description\tCtrl-C",wxT("Long desciption",wxITEM_NORMAL);

Then later I call CaptureMouse() inside wxGLCanvas.

Now, in Linux and OS X, menu accelerator keys continue to work as normal. In Windows, however, these keys not only stop working but don't trigger OnChar() events either in that wxGLCanvas - making it impossible to process them except at application's FilterEvent().

Is it possible to somehow enable these keys in Windows too?

thoray
Knows some wx things
Knows some wx things
Posts: 42
Joined: Sun Oct 18, 2015 9:31 am

Re: Enable frame's accelerator keys when a ctrl has captured mouse in Windows

Post by thoray » Tue Mar 10, 2020 2:40 pm

While not a solution to the problem stated in the topic - I just realized that since I'm already hiding the mouse cursor and warping mouse cursor at the ctrl's edges, I only need to disable mouse capturing in Windows to make it work similar to Linux and OS X.

Post Reply