]> gitweb.factorcode.org Git - factor.git/commitdiff
GdiFlush when selecting gl context to make offscreen rendering work
authorDoug Coleman <doug.coleman@gmail.com>
Wed, 10 Dec 2008 07:05:03 +0000 (01:05 -0600)
committerDoug Coleman <doug.coleman@gmail.com>
Wed, 10 Dec 2008 07:05:03 +0000 (01:05 -0600)
basis/ui/windows/windows.factor
basis/windows/gdi32/gdi32.factor

index 23d410477899ef82854c1a181d1267bc4f7e5369..ca5d77e9f945e722f4f23087f8d39f6c0d945f98 100755 (executable)
@@ -502,7 +502,8 @@ M: windows-ui-backend (open-window) ( world -- )
     hWnd>> show-window ;
 
 M: win-base select-gl-context ( handle -- )
-    [ hDC>> ] keep hRC>> wglMakeCurrent win32-error=0/f ;
+    [ hDC>> ] keep hRC>> wglMakeCurrent win32-error=0/f
+    GdiFlush drop ;
 
 M: win-base flush-gl-context ( handle -- )
     hDC>> SwapBuffers win32-error=0/f ;
index 2ccd6b39f429fa55571d76e0c271b0db63b66939..32e4f3cd8a66232a9b88502f98819a56ab6b64db 100755 (executable)
@@ -321,7 +321,7 @@ FUNCTION: BOOL DeleteObject ( HGDIOBJ hObject ) ;
 ! FUNCTION: GdiEntry8
 ! FUNCTION: GdiEntry9
 ! FUNCTION: GdiFixUpHandle
-! FUNCTION: GdiFlush
+FUNCTION: BOOL GdiFlush ( ) ;
 ! FUNCTION: GdiFullscreenControl
 ! FUNCTION: GdiGetBatchLimit
 ! FUNCTION: GdiGetCharDimensions