This patch resolves the issue I was encountering.

Thanks for digging in on this, Philipp.
   -Paul


On Thu, Oct 24, 2013 at 1:24 PM, Philipp Kutin <philipp.kutin@gmail.com> wrote:
Hi list,

The said bug (losing window frame focus on MS Windows) was introduced in r1525.

A look at the diff and consulting of the relevant MSDN page [1] show
why: the LSBit of GetAsyncKeyState() indicates whether "the key was
pressed after the previous call to GetAsyncKeyState". Moreover, it
recommends to "not rely on this (...) behavior", so it's best mask it
out unconditionally.

The attached patch fixes the window frame issue, but fg_main_mswin.c
contains a couple of other instances where that function's return
value is checked as-is -- apparently in the Shift/Alt/Menu handling
code. Personally, I'd AND with ~1 there, too, but it might be sensible
to produce a bug first.

[1] http://msdn.microsoft.com/en-us/library/windows/desktop/ms646293%28v=vs.85%29.aspx

--Philipp

On Wed, Sep 18, 2013 at 8:26 PM, Nigel Stewart <nigels.com@gmail.com> wrote:
> It might be helpful to try a few of the more recent releases to narrow
> down if this
> is some kind of regression.
>
> - Nigel
>
> ------------------------------------------------------------------------------
> LIMITED TIME SALE - Full Year of Microsoft Training For Just $49.99!
> 1,500+ hours of tutorials including VisualStudio 2012, Windows 8, SharePoint
> 2013, SQL 2012, MVC 4, more. BEST VALUE: New Multi-Library Power Pack includes
> Mobile, Cloud, Java, and UX Design. Lowest price ever! Ends 9/20/13.
> http://pubads.g.doubleclick.net/gampad/clk?id=58041151&iu=/4140/ostg.clktrk
> _______________________________________________
> Freeglut-developer mailing list
> Freeglut-developer@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/freeglut-developer

------------------------------------------------------------------------------
October Webinars: Code for Performance
Free Intel webinars can help you accelerate application performance.
Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most from
the latest Intel processors and coprocessors. See abstracts and register >
http://pubads.g.doubleclick.net/gampad/clk?id=60135991&iu=/4140/ostg.clktrk
_______________________________________________
Freeglut-developer mailing list
Freeglut-developer@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/freeglut-developer




--
Paul Martz
Skew Matrix Software LLC