GLUT_EXEC_STATE_RUNNING should not have been at the top of the loop, but rather
right after glutMainLoopEvent returns, after it processes a single event. As it
was, we would be sleeping, waiting for further events even if the user just
called glutLeaveMainLoop (which sets ExecState to GLUT_EXEC_STATE_STOP).
Also fixed a couple cases if inconsistent use of tabs/spaces for indentation
which was causing gcc to emit bogus warnings about misleading indentation
around braceless ifs.
git-svn-id: https://svn.code.sf.net/p/freeglut/code/trunk@1803 7f0cb862-5218-0410-a997-914c9d46530a
It provides back compatibility with older (autotools based) freeglut versions.
Also it simplifies build rules for crossplatform programs: they may be linked
with -lglut regardless of the system and library type (shared/static).
Patch is originally prepared for MXE project (http://mxe.cc/).
(cherry picked from commit cd9ac605ec4615569121e0e9b6bc058684bebfe3)
git-svn-id: https://svn.code.sf.net/p/freeglut/code/trunk@1793 7f0cb862-5218-0410-a997-914c9d46530a
Irrespective of "FREEGLUT_REPLACE_GLUT" being set to "No" or being on
Win32 where this variable does not even exist, the .pc file contained
Libs: -L${libdir} -lglut
Instead, emit the correct value.
(cherry picked from commit d06589f55c87370d388dec333f4bff35c29762f3)
(cherry picked from commit d06589f55c87370d388dec333f4bff35c29762f3)
git-svn-id: https://svn.code.sf.net/p/freeglut/code/trunk@1781 7f0cb862-5218-0410-a997-914c9d46530a
- Required adding an "argument expansion macro" for each callback (hope to remove eventually)
- Fixed MSVC linking error where glutMenuStatusFuncUCall had the incorrect case and should've been glutMenuStatusFuncUcall
- Updated formatting of some freeglut_ext.h functions
Updated glutCreateMenu, glutIdleFunc, and glutTimerFunc so they handle NULL callback cases.
Removed glutMenuStateFuncUcall (as glutMenuStateFunc is a depreciated function).
Following https://github.com/dcnieho/FreeGLUT/issues/38 ;
mention Wayland support in README, Wayland build
instructions and requirements in README.cmake.
Signed-off-by: Manuel Bachmann <manuel.bachmann@iot.bzh>
(cherry picked from commit 18773bcc818714436e3aeb6229b2f84125d6edc4)
(cherry picked from commit 18773bcc818714436e3aeb6229b2f84125d6edc4)
git-svn-id: https://svn.code.sf.net/p/freeglut/code/trunk@1780 7f0cb862-5218-0410-a997-914c9d46530a
- Known to only affect Visual Studio 2010. Visual Studio 2013 and up may have relaxed the error.
(cherry picked from commit 6b8552edbd715eb77921038c85dda46f90038154)
(cherry picked from commit 6b8552edbd715eb77921038c85dda46f90038154)
git-svn-id: https://svn.code.sf.net/p/freeglut/code/trunk@1779 7f0cb862-5218-0410-a997-914c9d46530a
Added check for if fgCreateWindow cannot allocate a window, it will produce an error.
(cherry picked from commit 0ed05f64589fbcc67f225e1dc3ef6f5181fd319f)
(cherry picked from commit 0ed05f64589fbcc67f225e1dc3ef6f5181fd319f)
git-svn-id: https://svn.code.sf.net/p/freeglut/code/trunk@1776 7f0cb862-5218-0410-a997-914c9d46530a
Following https://github.com/dcnieho/FreeGLUT/issues/38 ;
mention Wayland support in README, Wayland build
instructions and requirements in README.cmake.
Signed-off-by: Manuel Bachmann <manuel.bachmann@iot.bzh>