From 607f5b289f99e5de7aece6c150a63f1918e3034a Mon Sep 17 00:00:00 2001 From: daco65 Date: Thu, 11 Dec 2008 15:12:17 +0000 Subject: [PATCH] build fixings git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@1500 8ced0084-cf51-0410-be5f-012b33b47a6e --- Source/Core/Common/Src/Common.cpp | 24 ++++++++++----------- Source/PluginSpecs/pluginspecs_video.h | 2 +- Source/Plugins/Plugin_VideoDX9/Src/main.cpp | 4 ++-- 3 files changed, 15 insertions(+), 15 deletions(-) diff --git a/Source/Core/Common/Src/Common.cpp b/Source/Core/Common/Src/Common.cpp index ecbec6a360..29982f3748 100644 --- a/Source/Core/Common/Src/Common.cpp +++ b/Source/Core/Common/Src/Common.cpp @@ -46,10 +46,10 @@ void PanicAlert(const char* format, ...) else { #ifdef _WIN32 - std::string msg; - StringFromFormatV(&msg, format, args); - LOG(MASTER_LOG, "PANIC: %s", msg.c_str()); - MessageBox(0, msg.c_str(), "PANIC!", MB_ICONWARNING); + char buffer[2048]; + CharArrayFromFormatV(buffer, 2048, format, args); + LOG(MASTER_LOG, "PANIC: %s", buffer); + MessageBox(0, buffer, "PANIC!", MB_ICONWARNING); #elif __GNUC__ //#error Do a messagebox! vprintf(format, args); @@ -68,10 +68,10 @@ bool PanicYesNo(const char* format, ...) va_start(args, format); bool retval; #ifdef _WIN32 - std::string msg; - StringFromFormatV(&msg, format, args); - LOG(MASTER_LOG, "PANIC: %s", msg.c_str()); - retval = IDYES == MessageBox(0, msg.c_str(), "PANIC! Continue?", MB_ICONQUESTION | MB_YESNO); + char buffer[2048]; + CharArrayFromFormatV(buffer, 2048, format, args); + LOG(MASTER_LOG, "PANIC: %s", buffer); + retval = IDYES == MessageBox(0, buffer, "PANIC! Continue?", MB_ICONQUESTION | MB_YESNO); #elif __GNUC__ //vprintf(format, args); return(true); //#error Do a messagebox! @@ -88,10 +88,10 @@ bool AskYesNo(const char* format, ...) va_start(args, format); bool retval; #ifdef _WIN32 - std::string msg; - StringFromFormatV(&msg, format, args); - LOG(MASTER_LOG, "ASK: %s", msg.c_str()); - retval = IDYES == MessageBox(0, msg.c_str(), "Dolphin", MB_ICONQUESTION | MB_YESNO); + char buffer[2048]; + CharArrayFromFormatV(buffer, 2048, format, args); + LOG(MASTER_LOG, "ASK: %s", buffer); + retval = IDYES == MessageBox(0, buffer, "Dolphin", MB_ICONQUESTION | MB_YESNO); #elif __GNUC__ //vprintf(format, args); return(true); //#error Do a messagebox! diff --git a/Source/PluginSpecs/pluginspecs_video.h b/Source/PluginSpecs/pluginspecs_video.h index 0b8bf673a6..7cce0cb1b8 100644 --- a/Source/PluginSpecs/pluginspecs_video.h +++ b/Source/PluginSpecs/pluginspecs_video.h @@ -18,7 +18,7 @@ typedef void (*TVideoLog)(const char* _pMessage, BOOL _bBreak); typedef void (*TSysMessage)(const char *fmt, ...); typedef void (*TRequestWindowSize)(int _iWidth, int _iHeight, BOOL _bFullscreen); typedef void (*TCopiedToXFB)(void); -typedef BOOL (*TPeekMessages)(void); +typedef unsigned int (*TPeekMessages)(void); typedef void (*TUpdateInterrupts)(void); typedef void (*TUpdateFPSDisplay)(const char* text); // sets the window title typedef void (*TKeyPressed)(int keycode, BOOL shift, BOOL control); // sets the window title diff --git a/Source/Plugins/Plugin_VideoDX9/Src/main.cpp b/Source/Plugins/Plugin_VideoDX9/Src/main.cpp index 0e6dc6bb8c..b9b6aa3b2b 100644 --- a/Source/Plugins/Plugin_VideoDX9/Src/main.cpp +++ b/Source/Plugins/Plugin_VideoDX9/Src/main.cpp @@ -71,7 +71,7 @@ BOOL APIENTRY DllMain( HINSTANCE hinstDLL, // DLL module handle return TRUE; } -BOOL Callback_PeekMessages() +unsigned int Callback_PeekMessages() { //TODO: peek message MSG msg; @@ -308,7 +308,7 @@ HRESULT ScreenShot(TCHAR *File) return S_OK; } -BOOL Video_Screenshot(TCHAR* _szFilename) +unsigned int Video_Screenshot(TCHAR* _szFilename) { if (ScreenShot(_szFilename) == S_OK) return TRUE;