mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-30 01:29:42 -06:00
Fix a small misspell in OGL config, Fix the toggle fullscreen button when rendering to separate window + a weird issue related to rendering to main.
Code cleanup in nJoy i had around for a while, it also adds code to support SDL 1.3's force feedback API and is more stable (will not crash anymore on stop when rumble is enabled) git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@4459 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
@ -230,7 +230,7 @@ void GFXConfigDialogOGL::CreateGUIControls()
|
||||
m_MSAAModeCB->Append(wxT("16xQ CSAA"));
|
||||
m_MSAAModeCB->SetSelection(g_Config.iMultisampleMode);
|
||||
|
||||
m_OSDHotKey = new wxCheckBox(m_PageGeneral, ID_OSDHOTKEY, wxT("Enabke Hotkeys"), wxDefaultPosition, wxDefaultSize, 0, wxDefaultValidator);
|
||||
m_OSDHotKey = new wxCheckBox(m_PageGeneral, ID_OSDHOTKEY, wxT("Enable Hotkeys"), wxDefaultPosition, wxDefaultSize, 0, wxDefaultValidator);
|
||||
#ifndef _WIN32
|
||||
// JPeterson set the hot key to be Win32-specific
|
||||
m_OSDHotKey->Enable(false);
|
||||
@ -327,8 +327,7 @@ void GFXConfigDialogOGL::CreateGUIControls()
|
||||
sBasic->Add(WMText, wxGBPosition(1, 1), wxGBSpan(1, 1), wxALIGN_CENTER_VERTICAL | wxALL, 5);
|
||||
sBasic->Add(m_WindowResolutionCB, wxGBPosition(2, 1), wxGBSpan(1, 1), wxALL, 5);
|
||||
sBasic->Add(m_Fullscreen, wxGBPosition(1, 2), wxGBSpan(1, 1), wxALIGN_CENTER_VERTICAL | wxALL, 5);
|
||||
sBasic->Add(m_WindowFSResolutionCB, wxGBPosition(2, 2), wxGBSpan(1, 1), wxALL, 5);
|
||||
sBasic->Add(m_Fullscreen, wxGBPosition(2, 3), wxGBSpan(1, 1), wxALL | wxALIGN_CENTER_VERTICAL, 5);
|
||||
sBasic->Add(m_WindowFSResolutionCB, wxGBPosition(2, 2), wxGBSpan(1, 1), wxALL, 5);
|
||||
|
||||
sBasic->Add(KeepARText, wxGBPosition(3, 0), wxGBSpan(1, 1), wxALIGN_CENTER_VERTICAL | wxALL, 5);
|
||||
sBasic->Add(m_KeepAR, wxGBPosition(3, 1), wxGBSpan(1, 1), wxALL, 5);
|
||||
@ -339,7 +338,7 @@ void GFXConfigDialogOGL::CreateGUIControls()
|
||||
sBasic->Add(m_HideCursor, wxGBPosition(5, 0), wxGBSpan(1, 4), wxALL, 5);
|
||||
#endif
|
||||
|
||||
sbBasic->Add(sBasic, 1, wxEXPAND);
|
||||
sbBasic->Add(sBasic);
|
||||
sGeneral->Add(sbBasic, 0, wxEXPAND|wxALL, 5);
|
||||
|
||||
sBasicAdvanced = new wxGridBagSizer(0, 0);
|
||||
@ -357,7 +356,7 @@ void GFXConfigDialogOGL::CreateGUIControls()
|
||||
sEnhancements = new wxGridBagSizer(0, 0);
|
||||
sEnhancements->Add(AnisoText, wxGBPosition(0, 0), wxGBSpan(1, 1), wxALIGN_CENTER_VERTICAL|wxALL, 5);
|
||||
sEnhancements->Add(m_MaxAnisotropyCB, wxGBPosition(0, 1), wxGBSpan(1, 1), wxALL|wxEXPAND, 5);
|
||||
sEnhancements->Add(m_ForceFiltering, wxGBPosition(0, 2), wxGBSpan(1, 2), wxALL, 5);
|
||||
sEnhancements->Add(m_ForceFiltering, wxGBPosition(0, 2), wxGBSpan(1, 2), wxALL|wxALIGN_CENTER_VERTICAL, 5);
|
||||
sEnhancements->Add(MSAAText, wxGBPosition(1, 0), wxGBSpan(1, 1), wxALIGN_CENTER_VERTICAL|wxALL, 5);
|
||||
sEnhancements->Add(m_MSAAModeCB, wxGBPosition(1, 1), wxGBSpan(1, 1), wxALL|wxEXPAND, 5);
|
||||
sEnhancements->Add(PostShaderText, wxGBPosition(2, 0), wxGBSpan(1, 1), wxALIGN_CENTER_VERTICAL|wxALL, 5);
|
||||
|
@ -275,7 +275,7 @@ LRESULT CALLBACK WndProc(HWND hWnd, UINT iMsg, WPARAM wParam, LPARAM lParam)
|
||||
switch (iMsg)
|
||||
{
|
||||
case WM_CREATE:
|
||||
PostMessage(m_hParent, WM_USER, OPENGL_WM_USER_CREATE, (int)m_hParent);
|
||||
PostMessage((HWND)g_VideoInitialize.pWindowHandle, WM_USER, OPENGL_WM_USER_CREATE, (int)m_hParent);
|
||||
break;
|
||||
|
||||
case WM_PAINT:
|
||||
@ -345,6 +345,8 @@ LRESULT CALLBACK WndProc(HWND hWnd, UINT iMsg, WPARAM wParam, LPARAM lParam)
|
||||
}
|
||||
if (wParam == OPENGL_WM_USER_KEYDOWN)
|
||||
OnKeyDown(lParam);
|
||||
if (wParam == TOGGLE_FULLSCREEN)
|
||||
ToggleFullscreen(m_hWnd);
|
||||
break;
|
||||
|
||||
// This is called when we close the window when we render to a separate window
|
||||
@ -418,6 +420,11 @@ HWND OpenWindow(HWND parent, HINSTANCE hInstance, int width, int height, const T
|
||||
// Create new separate window
|
||||
else
|
||||
{
|
||||
// Don't forget to make it NULL, or a broken window will be created in case we
|
||||
// render to main, stop, then render to separate window, as the GUI will still
|
||||
// think we're rendering to main because m_hParent will still contain the old HWND...
|
||||
m_hParent = NULL;
|
||||
|
||||
DWORD style = g_Config.bFullscreen ? WS_POPUP : WS_OVERLAPPEDWINDOW;
|
||||
|
||||
RECT rc = {0, 0, width, height};
|
||||
|
@ -328,8 +328,8 @@ void Initialize(void *init)
|
||||
g_Config.Load(FULL_CONFIG_DIR "gfx_opengl.ini");
|
||||
g_Config.GameIniLoad(globals->game_ini);
|
||||
|
||||
#if defined(HAVE_WX) && HAVE_WX
|
||||
g_Config.UpdateProjectionHack();
|
||||
#if defined(HAVE_WX) && HAVE_WX
|
||||
//Enable support for PNG screenshots.
|
||||
wxImage::AddHandler( new wxPNGHandler );
|
||||
#endif
|
||||
|
Reference in New Issue
Block a user