News:

Accounts with zero posts and zero activity during the last months will be deleted periodically to fight SPAM!

Main Menu

Glut windows don't catch the focus

Started by jmeuf, September 05, 2018, 07:13:12 PM

Previous topic - Next topic

jmeuf

Hi,

I am developing a GLUT application where I declare 6 sub-windows over the main window that pave completely the main window, meaning that wherever the mouse cursor is, it flies over one of the 6 sub-windows and never over the underlying main window.

Each sub-window has its own keyboard controller (glutKeyboardFunc()) so that whatever sub-window is flown over by the mouse, the focus is on that sub-window and the respective keyboard controller is supposed to be called.

The application is developed on a desktop Windows 10 64 bits, double graphic cards GTX1070. The application is compiled in 32 bits (gcc).

When I run the application on the desktop, the mouse cannot catch the focus of the over flown sub-window, instead the focus is on the underlying main window and the keyboard controller of the main window is called instead of the controller of the sub-window as expected.

If I run the executable on a laptop (also Windows 10 64 bits), the application behaves properly, meaning that the correct over flown sub-window keyboard controller is called instead of the underlying main window keyboard controller.

Is this related to C::B or to the machines themselves ?

Thank you.

JM

stahta01

Run the application without using Code::Blocks and you will know the answer.

Tim S.
C Programmer working to learn more about C++.
On Windows 10 64 bit and Windows 11 64 bit.
--
When in doubt, read the CB WiKi FAQ. [url="http://wiki.codeblocks.org"]http://wiki.codeblocks.org[/url]

jmeuf

Hi Tim,

Thank you for your feedback.

I have done that. I have compiled the application in 'release' mode, closed C::B and ran the app as an executable on both macines.

JM

jmeuf

Hello,

so I finally reinstalled C::B from scratch at the last version (17.12) and reinstalled a fresh version of Glut (3.7.6).
Now the application works properly. It looks like there was a conflict with older version of glut or copied in the wrong windows folder.

Thank you for your support.

In the hope that it will help.

JM