Move fullscreen display resolution control to the GUI with the rest of the fullscreen toggling code. This removes redundancy of code that was in several places through the various video plugins. Unfortunately it means the fullscreen resolution setting also had to be moved to the main configuration dialog. I am sure that will meet some resistance.

Also added a window size setting for windowed mode.

Also pulled some X11 specific code out into a separate file.


git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@5395 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
Glenn Rice
2010-04-22 04:28:34 +00:00
parent 8eb21d1bac
commit 140332c02e
30 changed files with 634 additions and 556 deletions

View File

@ -36,8 +36,7 @@
#include "CodeWindow.h"
#include "LogWindow.h"
#if defined(HAVE_X11) && HAVE_X11
#include <gtk/gtk.h>
#include <gdk/gdkx.h>
#include "X11Utils.h"
#endif
// A shortcut to access the bitmaps
@ -99,19 +98,19 @@ class CFrame : public CRenderFrame
bool ShowLogWindow = false,
long style = wxDEFAULT_FRAME_STYLE | wxNO_FULL_REPAINT_ON_RESIZE);
virtual ~CFrame();
void* GetRenderHandle()
{
#ifdef _WIN32
return (void *)m_RenderParent->GetHandle();
#elif defined(HAVE_X11) && HAVE_X11
return (void *)GDK_WINDOW_XID(GTK_WIDGET(m_RenderParent->GetHandle())->window);
return (void *)X11Utils::XWindowFromHandle(m_RenderParent->GetHandle());
#else
return m_RenderParent;
#endif
}
virtual ~CFrame();
// These have to be public
CCodeWindow* g_pCodeWindow;
wxMenuBar* m_MenuBar;
@ -136,6 +135,11 @@ class CFrame : public CRenderFrame
void OnRenderParentMove(wxMoveEvent& event);
bool RendererHasFocus();
void DoFullscreen(bool bF);
void ToggleDisplayMode (bool bFullscreen);
#if defined(HAVE_XRANDR) && HAVE_XRANDR
X11Utils::XRRConfiguration *m_XRRConfig;
#endif
// AUI
wxAuiManager *m_Mgr;
@ -351,10 +355,6 @@ class CFrame : public CRenderFrame
void OnRenderParentResize(wxSizeEvent& event);
bool RendererIsFullscreen();
void StartGame(const std::string& filename);
#if defined HAVE_X11 && HAVE_X11
void X11_SendClientEvent(const char *message,
int data1 = 0, int data2 = 0, int data3 = 0, int data4 = 0);
#endif
// MenuBar
// File - Drive