Fixed stretch to fit for separate render window

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@1094 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
omegadox 2008-11-08 04:09:40 +00:00
parent 825335fc2c
commit 3303639a6e
1 changed files with 12 additions and 4 deletions

View File

@ -539,9 +539,15 @@ void OpenGL_Update()
rcWindow.bottom = GLWin.height; rcWindow.bottom = GLWin.height;
#elif defined(_WIN32) #elif defined(_WIN32)
if (!EmuWindow::GetParentWnd()) return; RECT rcWindow;
RECT rcWindow; if (!EmuWindow::GetParentWnd()) {
GetWindowRect(EmuWindow::GetParentWnd(), &rcWindow); GetWindowRect(EmuWindow::GetWnd(), &rcWindow);
rcWindow.top += 25;
}
else
{
GetWindowRect(EmuWindow::GetParentWnd(), &rcWindow);
}
// --------------------------------------------------------------------------------------- // ---------------------------------------------------------------------------------------
// Get the new window width and height // Get the new window width and height
@ -551,7 +557,9 @@ void OpenGL_Update()
int width = rcWindow.right - rcWindow.left; int width = rcWindow.right - rcWindow.left;
int height = rcWindow.bottom - rcWindow.top; int height = rcWindow.bottom - rcWindow.top;
::MoveWindow(EmuWindow::GetWnd(), 0,0,width,height, FALSE); if (EmuWindow::GetParentWnd() != 0)
::MoveWindow(EmuWindow::GetWnd(), 0,0,width,height, FALSE);
nBackbufferWidth = width; nBackbufferWidth = width;
nBackbufferHeight = height; nBackbufferHeight = height;