/*
- * freeglut_init_mswin.c
+ * fg_init_mswin.c
*
* The Windows-specific mouse cursor related stuff.
*
extern LRESULT CALLBACK fgPlatformWindowProc( HWND hWnd, UINT uMsg,
WPARAM wParam, LPARAM lParam );
extern void fgPlatformInitSystemTime();
+extern void fghCloseInputDevices(void);
/*
void fgPlatformInitialize( const char* displayName )
{
WNDCLASS wc;
- ATOM atom;
+ BOOL atom;
/* What we need to do is to initialize the fgDisplay global structure here. */
fgDisplay.pDisplay.Instance = GetModuleHandle( NULL );
HDC context = CreateDC(fgDisplay.pDisplay.DisplayName,0,0,0);
if( context )
{
- fgDisplay.ScreenWidth = GetDeviceCaps( context, HORZRES );
- fgDisplay.ScreenHeight = GetDeviceCaps( context, VERTRES );
- fgDisplay.ScreenWidthMM = GetDeviceCaps( context, HORZSIZE );
- fgDisplay.ScreenHeightMM = GetDeviceCaps( context, VERTSIZE );
- DeleteDC(context);
+ fgDisplay.ScreenWidth = GetDeviceCaps( context, HORZRES );
+ fgDisplay.ScreenHeight = GetDeviceCaps( context, VERTRES );
+ fgDisplay.ScreenWidthMM = GetDeviceCaps( context, HORZSIZE );
+ fgDisplay.ScreenHeightMM = GetDeviceCaps( context, VERTSIZE );
+ DeleteDC(context);
}
else
- fgWarning("fgPlatformInitialize: "
- "CreateDC failed, Screen size info may be incorrect\n"
+ fgWarning("fgPlatformInitialize: "
+ "CreateDC failed, Screen size info may be incorrect\n"
"This is quite likely caused by a bad '-display' parameter");
-
+
}
/* Set the timer granularity to 1 ms */
timeBeginPeriod ( 1 );
/* Platform-Specific Deinitialization Functions: */
-extern void fghCloseInputDevices ( void );
-
void fgPlatformDeinitialiseInputDevices ( void )
{
#if !defined(_WIN32_WCE)
- fghCloseInputDevices ();
+ fghCloseInputDevices ();
#endif /* !defined(_WIN32_WCE) */
fgState.JoysticksInitialised = GL_FALSE;
fgState.InputDevsInitialised = GL_FALSE;
void fgPlatformDestroyContext ( SFG_PlatformDisplay pDisplay, SFG_WindowContextType MContext )
{
- /* Do nothing -- this is required for X11 */
+ /* Do nothing -- this is required for X11 */
}
/* -- PLATFORM-SPECIFIC INTERFACE FUNCTION -------------------------------------------------- */