Eliminated the plugin interface. Merged DX9/DX11/OGL video plugins into Dolphin. It could still use a lot of cleanup. Lots of things are still named "plugin". Software renderer is temporarily disabled until it gets some namespaces. I only updated vs08/10, Linux/OSX builds are broken.

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6996 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
Jordan Woyak
2011-01-31 01:28:32 +00:00
parent ae7c64ec13
commit fbaf965995
136 changed files with 1537 additions and 3412 deletions

View File

@ -23,54 +23,13 @@
#include <wx/dialog.h>
#include <wx/aboutdlg.h>
#include "ConfigManager.h"
#include "SWVideoConfig.h"
#include "main.h"
#include "Win32.h"
#include "StringUtil.h"
HINSTANCE g_hInstance;
#if defined(HAVE_WX) && HAVE_WX
class wxDLLApp : public wxApp
{
bool OnInit()
{
return true;
}
};
IMPLEMENT_APP_NO_MAIN(wxDLLApp)
WXDLLIMPEXP_BASE void wxSetInstance(HINSTANCE hInst);
#endif
// ------------------
BOOL APIENTRY DllMain(HINSTANCE hinstDLL, // DLL module handle
DWORD dwReason, // reason called
LPVOID lpvReserved) // reserved
{
switch (dwReason)
{
case DLL_PROCESS_ATTACH:
{
#if defined(HAVE_WX) && HAVE_WX
wxSetInstance((HINSTANCE)hinstDLL);
wxInitialize();
#endif
}
break;
case DLL_PROCESS_DETACH:
#if defined(HAVE_WX) && HAVE_WX
wxUninitialize();
#endif
break;
}
g_hInstance = hinstDLL;
return TRUE;
}
// ----------------------
// The rendering window
// ----------------------
@ -80,11 +39,15 @@ namespace EmuWindow
HWND m_hWnd = NULL; // The new window that is created here
HWND m_hParent = NULL;
HINSTANCE m_hInstance = NULL;
WNDCLASSEX wndClass;
const TCHAR m_szClassName[] = _T("DolphinEmuWnd");
int g_winstyle;
static void*& VideoWindowHandle()
{
return SConfig::GetInstance().m_LocalCoreStartupParameter.hMainWindow;
}
// ------------------------------------------
/* Invisible cursor option. In the lack of a predefined IDC_BLANK we make
an empty transparent cursor */
@ -202,7 +165,7 @@ LRESULT CALLBACK WndProc( HWND hWnd, UINT iMsg, WPARAM wParam, LPARAM lParam )
break;
case WM_DESTROY:
Shutdown();
g_video_backend->Shutdown();
break;
// Called when a screensaver wants to show up while this window is active
@ -241,10 +204,10 @@ HWND OpenWindow(HWND parent, HINSTANCE hInstance, int width, int height, const T
wndClass.lpszClassName = m_szClassName;
wndClass.hIconSm = LoadIcon( NULL, IDI_APPLICATION );
m_hInstance = hInstance;
//m_hInstance = hInstance;
RegisterClassEx( &wndClass );
CreateCursors(m_hInstance);
CreateCursors(/*m_hInstance*/GetModuleHandle(0));
// Create child window
if (parent)
@ -275,7 +238,7 @@ HWND OpenWindow(HWND parent, HINSTANCE hInstance, int width, int height, const T
rc.top = (1024 - h)/2;
rc.bottom = rc.top + h;
m_hParent = (HWND)g_VideoInitialize.pWindowHandle;
m_hParent = (HWND)VideoWindowHandle();
m_hWnd = CreateWindow(m_szClassName, title,
style,
@ -364,7 +327,7 @@ void Close()
{
if (!m_hParent)
DestroyWindow(m_hWnd);
UnregisterClass(m_szClassName, m_hInstance);
UnregisterClass(m_szClassName, /*m_hInstance*/GetModuleHandle(0));
}
// ------------------------------------------