mirror of
https://github.com/ultimatepp/ultimatepp.git
synced 2026-07-11 22:03:01 -06:00
GLCtrl fixed for mingw (thanks koldo)
git-svn-id: svn://ultimatepp.org/upp/trunk@9112 f0d560ea-af0d-0410-9eb7-867de7ffcac7
This commit is contained in:
parent
f02b32938d
commit
7af28a6adf
1 changed files with 5 additions and 2 deletions
|
|
@ -87,13 +87,16 @@ void GLCtrl::GLPane::State(int reason)
|
|||
|
||||
LRESULT GLCtrl::GLPane::WindowProc(UINT message, WPARAM wParam, LPARAM lParam)
|
||||
{
|
||||
if((message == WM_PAINT || message == WM_SIZE || message == WM_ERASEBKGND) && hDC && hRC)
|
||||
if((message == WM_PAINT || message == WM_SIZE || message == WM_ERASEBKGND) && hDC && hRC)
|
||||
{
|
||||
PAINTSTRUCT ps;
|
||||
BeginPaint(GetHWND(), &ps);
|
||||
ActivateContext();
|
||||
ctrl->GLPaint();
|
||||
ctrl->doubleBuffering ? SwapBuffers(hDC) : glFlush();
|
||||
if(ctrl->doubleBuffering)
|
||||
SwapBuffers(hDC);
|
||||
else
|
||||
glFlush();
|
||||
EndPaint(GetHWND(), &ps);
|
||||
return 0;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue