CreateGraphicsWindow is done by ConfigureGraphicsWindow

This commit is contained in:
Glenn Maynard
2006-01-15 00:59:32 +00:00
parent d2f8a2efdf
commit 50b0f360f4
2 changed files with 4 additions and 7 deletions
+1 -4
View File
@@ -499,10 +499,7 @@ CString RageDisplay_D3D::TryVideoMode( const VideoModeParams &_p, bool &bNewDevi
if( FindBackBufferType( p.windowed, p.bpp ) == D3DFMT_UNKNOWN ) // no possible back buffer formats if( FindBackBufferType( p.windowed, p.bpp ) == D3DFMT_UNKNOWN ) // no possible back buffer formats
return ssprintf( "FindBackBufferType(%i,%i) failed", p.windowed, p.bpp ); // failed to set mode return ssprintf( "FindBackBufferType(%i,%i) failed", p.windowed, p.bpp ); // failed to set mode
#if !defined(XBOX) #if defined(XBOX)
if( GraphicsWindow::GetHwnd() == NULL )
GraphicsWindow::CreateGraphicsWindow( p );
#else
p.windowed = false; p.windowed = false;
#endif #endif
@@ -119,7 +119,6 @@ CString LowLevelWindow_Win32::TryVideoMode( const VideoModeParams &p, bool &bNew
/* No. Always create and show the window before changing the video mode. /* No. Always create and show the window before changing the video mode.
* Otherwise, some other window may have focus, and changing the video mode will * Otherwise, some other window may have focus, and changing the video mode will
* cause that window to be resized. */ * cause that window to be resized. */
GraphicsWindow::CreateGraphicsWindow( p );
GraphicsWindow::ConfigureGraphicsWindow( p ); GraphicsWindow::ConfigureGraphicsWindow( p );
} else { } else {
/* We already have a window. Assume that it's pixel format has already been /* We already have a window. Assume that it's pixel format has already been
@@ -176,13 +175,14 @@ CString LowLevelWindow_Win32::TryVideoMode( const VideoModeParams &p, bool &bNew
g_HGLRC = NULL; g_HGLRC = NULL;
} }
GraphicsWindow::CreateGraphicsWindow( p );
// DestroyGraphicsWindowAndOpenGLContext(); // DestroyGraphicsWindowAndOpenGLContext();
// GraphicsWindow::CreateGraphicsWindow( p ); // GraphicsWindow::CreateGraphicsWindow( p );
bNewDeviceOut = true; bNewDeviceOut = true;
} }
GraphicsWindow::ConfigureGraphicsWindow( p ); /* If we deleted the OpenGL context above, also recreate the window. Otherwise, just
* reconfigure it. */
GraphicsWindow::ConfigureGraphicsWindow( p, bNewDeviceOut );
GraphicsWindow::SetVideoModeParams( p ); GraphicsWindow::SetVideoModeParams( p );