Removed my previous PanicAlert translation hack. Fixed with a better method suggested by BhaaL. The translation is done by a callback in the MsgHandler routine that is set at program start. Added macros PanicAlertT, SuccessAlertT, PanicYesNoT, and AskYesNoT that are identical to the non T versions except those strings will be added by gettext to the po files to be translated. These can and should be used anywhere in the code for strings that should be translated.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6838 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
parent
be5c732254
commit
c6e0ea59b9
1205
Languages/da.po
1205
Languages/da.po
File diff suppressed because it is too large
Load Diff
1210
Languages/de.po
1210
Languages/de.po
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
1206
Languages/el.po
1206
Languages/el.po
File diff suppressed because it is too large
Load Diff
1201
Languages/en.po
1201
Languages/en.po
File diff suppressed because it is too large
Load Diff
1206
Languages/es.po
1206
Languages/es.po
File diff suppressed because it is too large
Load Diff
1206
Languages/fr.po
1206
Languages/fr.po
File diff suppressed because it is too large
Load Diff
|
@ -4,8 +4,8 @@ cd ${0/gettextize/}/..
|
|||
SRCDIR=Source
|
||||
CPP_FILE_LIST=$(find $SRCDIR \( -name '*.cpp' -o -name '*.h' -o -name '*.c' \) \
|
||||
-a ! -path '*Debug*')
|
||||
xgettext -d dolphin-emu -s --keyword=_ --keyword=wxTRANSLATE --keyword=_t \
|
||||
--keyword=_wxt --keyword=_trans \
|
||||
xgettext -d dolphin-emu -s --keyword=_ --keyword=wxTRANSLATE --keyword=SuccessAlertT \
|
||||
--keyword=PanicAlertT --keyword=PanicYesNoT --keyword=AskYesNoT --keyword=_trans \
|
||||
-p ./Languages -o dolphin-emu.pot $CPP_FILE_LIST \
|
||||
--package-name="Dolphin Emu"
|
||||
|
||||
|
|
1201
Languages/he.po
1201
Languages/he.po
File diff suppressed because it is too large
Load Diff
1204
Languages/hu.po
1204
Languages/hu.po
File diff suppressed because it is too large
Load Diff
1360
Languages/it.po
1360
Languages/it.po
File diff suppressed because it is too large
Load Diff
1205
Languages/ja.po
1205
Languages/ja.po
File diff suppressed because it is too large
Load Diff
1206
Languages/ko.po
1206
Languages/ko.po
File diff suppressed because it is too large
Load Diff
1206
Languages/nb.po
1206
Languages/nb.po
File diff suppressed because it is too large
Load Diff
1206
Languages/nl.po
1206
Languages/nl.po
File diff suppressed because it is too large
Load Diff
1206
Languages/pl.po
1206
Languages/pl.po
File diff suppressed because it is too large
Load Diff
1203
Languages/ru.po
1203
Languages/ru.po
File diff suppressed because it is too large
Load Diff
1206
Languages/zh_CN.po
1206
Languages/zh_CN.po
File diff suppressed because it is too large
Load Diff
|
@ -35,7 +35,7 @@ void AOSound::SoundLoop()
|
|||
device = ao_open_live(default_driver, &format, NULL /* no options */);
|
||||
if (!device)
|
||||
{
|
||||
PanicAlert("AudioCommon: Error opening AO device.\n");
|
||||
PanicAlertT("AudioCommon: Error opening AO device.\n");
|
||||
ao_shutdown();
|
||||
Stop();
|
||||
return;
|
||||
|
|
|
@ -65,9 +65,9 @@ namespace AudioCommon
|
|||
*/
|
||||
return soundStream;
|
||||
}
|
||||
PanicAlert("Could not initialize backend %s.", backend.c_str());
|
||||
PanicAlertT("Could not initialize backend %s.", backend.c_str());
|
||||
}
|
||||
PanicAlert("Sound backend %s is not valid.", backend.c_str());
|
||||
PanicAlertT("Sound backend %s is not valid.", backend.c_str());
|
||||
|
||||
delete soundStream;
|
||||
soundStream = NULL;
|
||||
|
|
|
@ -53,7 +53,7 @@ bool DSound::CreateBuffer()
|
|||
else
|
||||
{
|
||||
// Failed.
|
||||
PanicAlert("Sound buffer creation failed: %s", DXGetErrorString(res));
|
||||
PanicAlertT("Sound buffer creation failed: %s", DXGetErrorString(res));
|
||||
dsBuffer = NULL;
|
||||
return false;
|
||||
}
|
||||
|
|
|
@ -182,7 +182,7 @@ void CMixer::PushSamples(short *samples, unsigned int num_samples)
|
|||
else if (m_sampleRate == 48000)
|
||||
Common::AtomicAdd(m_numSamples, num_samples * 3 / 2);
|
||||
else
|
||||
PanicAlert("Mixer: Unsupported sample rate.");
|
||||
PanicAlertT("Mixer: Unsupported sample rate.");
|
||||
|
||||
return;
|
||||
}
|
||||
|
|
|
@ -51,19 +51,19 @@ bool OpenALStream::Start()
|
|||
else
|
||||
{
|
||||
alcCloseDevice(pDevice);
|
||||
PanicAlert("OpenAL: can't create context "
|
||||
PanicAlertT("OpenAL: can't create context "
|
||||
"for device %s", defDevName);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
PanicAlert("OpenAL: can't open device %s", defDevName);
|
||||
PanicAlertT("OpenAL: can't open device %s", defDevName);
|
||||
}
|
||||
delete pDeviceList;
|
||||
}
|
||||
else
|
||||
{
|
||||
PanicAlert("OpenAL: can't find sound devices");
|
||||
PanicAlertT("OpenAL: can't find sound devices");
|
||||
}
|
||||
|
||||
return bReturn;
|
||||
|
|
|
@ -41,14 +41,14 @@ bool WaveFileWriter::Start(const char *filename)
|
|||
// Check if the file is already open
|
||||
if (file)
|
||||
{
|
||||
PanicAlert("The file %s was alrady open, the file header will not be written.", filename);
|
||||
PanicAlertT("The file %s was alrady open, the file header will not be written.", filename);
|
||||
return false;
|
||||
}
|
||||
|
||||
file = fopen(filename, "wb");
|
||||
if (!file)
|
||||
{
|
||||
PanicAlert("The file %s could not be opened for writing. Please check if it's already opened by another program.", filename);
|
||||
PanicAlertT("The file %s could not be opened for writing. Please check if it's already opened by another program.", filename);
|
||||
return false;
|
||||
}
|
||||
|
||||
|
@ -108,7 +108,7 @@ void WaveFileWriter::Write4(const char *ptr)
|
|||
void WaveFileWriter::AddStereoSamples(const short *sample_data, int count)
|
||||
{
|
||||
if (!file)
|
||||
PanicAlert("WaveFileWriter - file not open.");
|
||||
PanicAlertT("WaveFileWriter - file not open.");
|
||||
if (skip_silence) {
|
||||
bool all_zero = true;
|
||||
for (int i = 0; i < count * 2; i++)
|
||||
|
@ -122,7 +122,7 @@ void WaveFileWriter::AddStereoSamples(const short *sample_data, int count)
|
|||
void WaveFileWriter::AddStereoSamplesBE(const short *sample_data, int count)
|
||||
{
|
||||
if (!file)
|
||||
PanicAlert("WaveFileWriter - file not open.");
|
||||
PanicAlertT("WaveFileWriter - file not open.");
|
||||
|
||||
if (count > BUF_SIZE * 2)
|
||||
PanicAlert("WaveFileWriter - buffer too small (count = %i).", count);
|
||||
|
|
|
@ -48,7 +48,7 @@ struct StreamingVoiceContext : public IXAudio2VoiceCallback
|
|||
// create source voice
|
||||
HRESULT hr;
|
||||
if(FAILED(hr = pXAudio2->CreateSourceVoice(&pSourceVoice, (WAVEFORMATEX*)&wfx, XAUDIO2_VOICE_NOSRC, 1.0f, this)))
|
||||
PanicAlert("XAudio2 CreateSourceVoice failed: %#X", hr);
|
||||
PanicAlertT("XAudio2 CreateSourceVoice failed: %#X", hr);
|
||||
|
||||
pSourceVoice->FlushSourceBuffers();
|
||||
pSourceVoice->Start();
|
||||
|
@ -130,7 +130,7 @@ bool XAudio2::Start()
|
|||
HRESULT hr;
|
||||
if(FAILED(hr = XAudio2Create(&pXAudio2, 0, XAUDIO2_ANY_PROCESSOR))) //callback dosent seem to run on a speecific cpu anyways
|
||||
{
|
||||
PanicAlert("XAudio2 init failed: %#X", hr);
|
||||
PanicAlertT("XAudio2 init failed: %#X", hr);
|
||||
CoUninitialize();
|
||||
return false;
|
||||
}
|
||||
|
@ -139,7 +139,7 @@ bool XAudio2::Start()
|
|||
// XAUDIO2_DEFAULT_CHANNELS instead of 2 for expansion?
|
||||
if(FAILED(hr = pXAudio2->CreateMasteringVoice(&pMasteringVoice, 2, m_mixer->GetSampleRate())))
|
||||
{
|
||||
PanicAlert("XAudio2 master voice creation failed: %#X", hr);
|
||||
PanicAlertT("XAudio2 master voice creation failed: %#X", hr);
|
||||
safe_release(pXAudio2);
|
||||
CoUninitialize();
|
||||
return false;
|
||||
|
|
|
@ -117,14 +117,6 @@ private:
|
|||
#include "config.h" // SCons autoconfiguration defines
|
||||
#endif
|
||||
|
||||
#if defined(HAVE_WX) && HAVE_WX
|
||||
// This should be used to mark c strings as translatable in PanicAlerts but only in
|
||||
// wxWidgets portions of the code.
|
||||
#define _wxt(a) (std::string(wxString(wxGetTranslation(wxT(a))).To8BitData()).c_str())
|
||||
#else
|
||||
#define _wxt(a) a
|
||||
#endif
|
||||
|
||||
// Windows compatibility
|
||||
#ifndef _WIN32
|
||||
#include <limits.h>
|
||||
|
|
|
@ -25,15 +25,25 @@ bool DefaultMsgHandler(const char* caption, const char* text, bool yes_no, int S
|
|||
static MsgAlertHandler msg_handler = DefaultMsgHandler;
|
||||
static bool AlertEnabled = true;
|
||||
|
||||
const char* DefaultStringTranslator(const char* text);
|
||||
static StringTranslator str_translator = DefaultStringTranslator;
|
||||
|
||||
/* Select which of these functions that are used for message boxes. If
|
||||
wxWidgets is enabled we will use wxMsgAlert() that is defined in main.cpp */
|
||||
wxWidgets is enabled we will use wxMsgAlert() that is defined in Main.cpp */
|
||||
void RegisterMsgAlertHandler(MsgAlertHandler handler)
|
||||
{
|
||||
msg_handler = handler;
|
||||
}
|
||||
|
||||
// Select translation function. For wxWidgets use wxStringTranslator in Main.cpp
|
||||
void RegisterStringTranslator(StringTranslator translator)
|
||||
{
|
||||
str_translator = translator;
|
||||
}
|
||||
|
||||
// enable/disable the alert handler
|
||||
void SetEnableAlert(bool enable) {
|
||||
void SetEnableAlert(bool enable)
|
||||
{
|
||||
AlertEnabled = enable;
|
||||
}
|
||||
|
||||
|
@ -45,9 +55,11 @@ bool MsgAlert(const char* caption, bool yes_no, int Style, const char* format, .
|
|||
char buffer[2048];
|
||||
bool ret = true;
|
||||
|
||||
const char *tr_format = str_translator(format);
|
||||
|
||||
va_list args;
|
||||
va_start(args, format);
|
||||
CharArrayFromFormatV(buffer, 2047, format, args);
|
||||
CharArrayFromFormatV(buffer, 2047, tr_format, args);
|
||||
va_end(args);
|
||||
|
||||
ERROR_LOG(MASTER_LOG, "%s: %s", caption, buffer);
|
||||
|
@ -74,3 +86,10 @@ bool DefaultMsgHandler(const char* caption, const char* text, bool yes_no, int S
|
|||
return true;
|
||||
#endif
|
||||
}
|
||||
|
||||
// Default (non) translator
|
||||
const char* DefaultStringTranslator(const char* text)
|
||||
{
|
||||
return text;
|
||||
}
|
||||
|
||||
|
|
|
@ -27,7 +27,11 @@ enum MSG_TYPE
|
|||
|
||||
typedef bool (*MsgAlertHandler)(const char* caption, const char* text,
|
||||
bool yes_no, int Style);
|
||||
typedef const char * (*StringTranslator)(const char* text);
|
||||
|
||||
void RegisterMsgAlertHandler(MsgAlertHandler handler);
|
||||
void RegisterStringTranslator(StringTranslator translator);
|
||||
|
||||
extern bool MsgAlert(const char* caption, bool yes_no, int Style, const char* format, ...)
|
||||
#ifdef __GNUC__
|
||||
__attribute__((format(printf, 4, 5)))
|
||||
|
@ -41,11 +45,21 @@ void SetEnableAlert(bool enable);
|
|||
#define PanicAlert(format, ...) MsgAlert("Warning", false, WARNING, format, __VA_ARGS__)
|
||||
#define PanicYesNo(format, ...) MsgAlert("Warning", true, WARNING, format, __VA_ARGS__)
|
||||
#define AskYesNo(format, ...) MsgAlert("Question", true, QUESTION, format, __VA_ARGS__)
|
||||
// Use these macros (that do the same thing) if the message should be translated.
|
||||
#define SuccessAlertT(format, ...) MsgAlert("Information", false, INFORMATION, format, __VA_ARGS__)
|
||||
#define PanicAlertT(format, ...) MsgAlert("Warning", false, WARNING, format, __VA_ARGS__)
|
||||
#define PanicYesNoT(format, ...) MsgAlert("Warning", true, WARNING, format, __VA_ARGS__)
|
||||
#define AskYesNoT(format, ...) MsgAlert("Question", true, QUESTION, format, __VA_ARGS__)
|
||||
#else
|
||||
#define SuccessAlert(format, ...) MsgAlert("Information", false, INFORMATION, format, ##__VA_ARGS__)
|
||||
#define PanicAlert(format, ...) MsgAlert("Warning", false, WARNING, format, ##__VA_ARGS__)
|
||||
#define PanicYesNo(format, ...) MsgAlert("Warning", true, WARNING, format, ##__VA_ARGS__)
|
||||
#define AskYesNo(format, ...) MsgAlert("Question", true, QUESTION, format, ##__VA_ARGS__)
|
||||
// Use these macros (that do the same thing) if the message should be translated.
|
||||
#define SuccessAlertT(format, ...) MsgAlert("Information", false, INFORMATION, format, ##__VA_ARGS__)
|
||||
#define PanicAlertT(format, ...) MsgAlert("Warning", false, WARNING, format, ##__VA_ARGS__)
|
||||
#define PanicYesNoT(format, ...) MsgAlert("Warning", true, WARNING, format, ##__VA_ARGS__)
|
||||
#define AskYesNoT(format, ...) MsgAlert("Question", true, QUESTION, format, ##__VA_ARGS__)
|
||||
#endif
|
||||
#else
|
||||
// GEKKO
|
||||
|
@ -53,6 +67,10 @@ void SetEnableAlert(bool enable);
|
|||
#define PanicAlert(format, ...) ;
|
||||
#define PanicYesNo(format, ...) ;
|
||||
#define AskYesNo(format, ...) ;
|
||||
#define SuccessAlertT(format, ...) ;
|
||||
#define PanicAlertT(format, ...) ;
|
||||
#define PanicYesNoT(format, ...) ;
|
||||
#define AskYesNoT(format, ...) ;
|
||||
#endif
|
||||
|
||||
#endif // _MSGHANDLER_H_
|
||||
|
|
|
@ -47,7 +47,7 @@ bool SysConf::LoadFromFile(const char *filename)
|
|||
return false; //most likely: file does not exist
|
||||
if (size != SYSCONF_SIZE)
|
||||
{
|
||||
PanicAlert("Your SYSCONF file is the wrong size - should be 0x%04x (but is 0x%04llx)",
|
||||
PanicAlertT("Your SYSCONF file is the wrong size - should be 0x%04x (but is 0x%04llx)",
|
||||
SYSCONF_SIZE, size);
|
||||
return false;
|
||||
}
|
||||
|
@ -117,7 +117,7 @@ bool SysConf::LoadFromFileInternal(FILE *f)
|
|||
curEntry.dataLength = 4;
|
||||
break;
|
||||
default:
|
||||
PanicAlert("Unknown entry type %i in SYSCONF (%s@%x)!",
|
||||
PanicAlertT("Unknown entry type %i in SYSCONF (%s@%x)!",
|
||||
curEntry.type, curEntry.name, curEntry.offset);
|
||||
return false;
|
||||
}
|
||||
|
|
|
@ -95,7 +95,7 @@ public:
|
|||
{
|
||||
if (!m_IsValid)
|
||||
{
|
||||
PanicAlert("Trying to read from invalid SYSCONF");
|
||||
PanicAlertT("Trying to read from invalid SYSCONF");
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
@ -107,7 +107,7 @@ public:
|
|||
}
|
||||
if (index == m_Entries.size() - 1)
|
||||
{
|
||||
PanicAlert("Section %s not found in SYSCONF", sectionName);
|
||||
PanicAlertT("Section %s not found in SYSCONF", sectionName);
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
@ -118,7 +118,7 @@ public:
|
|||
{
|
||||
if (!m_IsValid)
|
||||
{
|
||||
PanicAlert("Trying to read from invalid SYSCONF");
|
||||
PanicAlertT("Trying to read from invalid SYSCONF");
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
@ -130,7 +130,7 @@ public:
|
|||
}
|
||||
if (index == m_Entries.size() - 1)
|
||||
{
|
||||
PanicAlert("Section %s not found in SYSCONF", sectionName);
|
||||
PanicAlertT("Section %s not found in SYSCONF", sectionName);
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
@ -150,7 +150,7 @@ public:
|
|||
}
|
||||
if (index == m_Entries.size() - 1)
|
||||
{
|
||||
PanicAlert("Section %s not found in SYSCONF", sectionName);
|
||||
PanicAlertT("Section %s not found in SYSCONF", sectionName);
|
||||
return false;
|
||||
}
|
||||
|
||||
|
@ -171,7 +171,7 @@ public:
|
|||
}
|
||||
if (index == m_Entries.size() - 1)
|
||||
{
|
||||
PanicAlert("Section %s not found in SYSCONF", sectionName);
|
||||
PanicAlertT("Section %s not found in SYSCONF", sectionName);
|
||||
return false;
|
||||
}
|
||||
|
||||
|
|
|
@ -480,7 +480,7 @@ void DecryptARCode(std::vector<std::string> vCodes, std::vector<AREntry> &ops)
|
|||
|
||||
if ((ret=alphatobin(uCodes, vCodes, (int)vCodes.size())))
|
||||
{
|
||||
PanicAlert("Action Replay Code Decryption Error:\nParity Check Failed\n\nCulprit Code:\n%s", vCodes[ret].c_str());
|
||||
PanicAlertT("Action Replay Code Decryption Error:\nParity Check Failed\n\nCulprit Code:\n%s", vCodes[ret].c_str());
|
||||
batchdecrypt(uCodes, (u16)vCodes.size()<<1);
|
||||
}
|
||||
else if (!batchdecrypt(uCodes, (u16)vCodes.size()<<1))
|
||||
|
|
|
@ -193,9 +193,9 @@ void LoadCodes(IniFile &ini, bool forceLoad)
|
|||
bool success_addr = TryParse(std::string("0x") + pieces[0], &op.cmd_addr);
|
||||
bool success_val = TryParse(std::string("0x") + pieces[1], &op.value);
|
||||
if (!(success_addr | success_val)) {
|
||||
PanicAlert("Action Replay Error: invalid AR code line: %s", line.c_str());
|
||||
if (!success_addr) PanicAlert("The address is invalid");
|
||||
if (!success_val) PanicAlert("The value is invalid");
|
||||
PanicAlertT("Action Replay Error: invalid AR code line: %s", line.c_str());
|
||||
if (!success_addr) PanicAlertT("The address is invalid");
|
||||
if (!success_val) PanicAlertT("The value is invalid");
|
||||
}
|
||||
else
|
||||
currentCode.ops.push_back(op);
|
||||
|
@ -353,7 +353,7 @@ bool RunCode(const ARCode &arcode)
|
|||
if (addr >= 0x00002000 && addr < 0x00003000)
|
||||
{
|
||||
LogInfo("This action replay simulator does not support codes that modify Action Replay itself.");
|
||||
PanicAlert("This action replay simulator does not support codes that modify Action Replay itself.");
|
||||
PanicAlertT("This action replay simulator does not support codes that modify Action Replay itself.");
|
||||
return false;
|
||||
}
|
||||
|
||||
|
@ -385,7 +385,7 @@ bool RunCode(const ARCode &arcode)
|
|||
case ZCODE_ROW: // Executes all codes in the same row
|
||||
// Todo: Set register 1BB4 to 1
|
||||
LogInfo("ZCode: Executes all codes in the same row, Set register 1BB4 to 1 (zcode not supported)");
|
||||
PanicAlert("Zero 3 code not supported");
|
||||
PanicAlertT("Zero 3 code not supported");
|
||||
return false;
|
||||
break;
|
||||
|
||||
|
@ -407,7 +407,7 @@ bool RunCode(const ARCode &arcode)
|
|||
|
||||
default:
|
||||
LogInfo("ZCode: Unknown");
|
||||
PanicAlert("Zero code unknown to dolphin: %08x", zcode);
|
||||
PanicAlertT("Zero code unknown to dolphin: %08x", zcode);
|
||||
return false;
|
||||
break;
|
||||
}
|
||||
|
@ -448,7 +448,7 @@ ARCode GetARCode(size_t index)
|
|||
{
|
||||
if (index > arCodes.size())
|
||||
{
|
||||
PanicAlert("GetARCode: Index is greater than "
|
||||
PanicAlertT("GetARCode: Index is greater than "
|
||||
"ar code list size %lu", (unsigned long)index);
|
||||
return ARCode();
|
||||
}
|
||||
|
@ -459,7 +459,7 @@ void SetARCode_IsActive(bool active, size_t index)
|
|||
{
|
||||
if (index > arCodes.size())
|
||||
{
|
||||
PanicAlert("SetARCode_IsActive: Index is greater than "
|
||||
PanicAlertT("SetARCode_IsActive: Index is greater than "
|
||||
"ar code list size %lu", (unsigned long)index);
|
||||
return;
|
||||
}
|
||||
|
@ -546,7 +546,7 @@ bool Subtype_RamWriteAndFill(const ARAddr addr, const u32 data)
|
|||
|
||||
default:
|
||||
LogInfo("Bad Size");
|
||||
PanicAlert("Action Replay Error: Invalid size "
|
||||
PanicAlertT("Action Replay Error: Invalid size "
|
||||
"(%08x : address = %08x) in Ram Write And Fill (%s)",
|
||||
addr.size, addr.gcaddr, current_code->name.c_str());
|
||||
return false;
|
||||
|
@ -606,7 +606,7 @@ bool Subtype_WriteToPointer(const ARAddr addr, const u32 data)
|
|||
|
||||
default:
|
||||
LogInfo("Bad Size");
|
||||
PanicAlert("Action Replay Error: Invalid size "
|
||||
PanicAlertT("Action Replay Error: Invalid size "
|
||||
"(%08x : address = %08x) in Write To Pointer (%s)",
|
||||
addr.size, addr.gcaddr, current_code->name.c_str());
|
||||
return false;
|
||||
|
@ -666,7 +666,7 @@ bool Subtype_AddCode(const ARAddr addr, const u32 data)
|
|||
|
||||
default:
|
||||
LogInfo("Bad Size");
|
||||
PanicAlert("Action Replay Error: Invalid size "
|
||||
PanicAlertT("Action Replay Error: Invalid size "
|
||||
"(%08x : address = %08x) in Add Code (%s)",
|
||||
addr.size, addr.gcaddr, current_code->name.c_str());
|
||||
return false;
|
||||
|
@ -681,7 +681,7 @@ bool Subtype_MasterCodeAndWriteToCCXXXXXX(const ARAddr addr, const u32 data)
|
|||
// u8 mcode_type = (data & 0xFF0000) >> 16;
|
||||
// u8 mcode_count = (data & 0xFF00) >> 8;
|
||||
// u8 mcode_number = data & 0xFF;
|
||||
PanicAlert("Action Replay Error: Master Code and Write To CCXXXXXX not implemented (%s)", current_code->name.c_str());
|
||||
PanicAlertT("Action Replay Error: Master Code and Write To CCXXXXXX not implemented (%s)", current_code->name.c_str());
|
||||
return false;
|
||||
}
|
||||
|
||||
|
@ -753,7 +753,7 @@ bool ZeroCode_FillAndSlide(const u32 val_last, const ARAddr addr, const u32 data
|
|||
|
||||
default:
|
||||
LogInfo("Bad Size");
|
||||
PanicAlert("Action Replay Error: Invalid size (%08x : address = %08x) in Fill and Slide (%s)", size, new_addr, current_code->name.c_str());
|
||||
PanicAlertT("Action Replay Error: Invalid size (%08x : address = %08x) in Fill and Slide (%s)", size, new_addr, current_code->name.c_str());
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
|
@ -800,7 +800,7 @@ bool ZeroCode_MemoryCopy(const u32 val_last, const ARAddr addr, const u32 data)
|
|||
else
|
||||
{
|
||||
LogInfo("Bad Value");
|
||||
PanicAlert("Action Replay Error: Invalid value (%08x) in Memory Copy (%s)", (data & ~0x7FFF), current_code->name.c_str());
|
||||
PanicAlertT("Action Replay Error: Invalid value (%08x) in Memory Copy (%s)", (data & ~0x7FFF), current_code->name.c_str());
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
|
@ -836,7 +836,7 @@ bool NormalCode(const ARAddr addr, const u32 data)
|
|||
|
||||
default:
|
||||
LogInfo("Bad Subtype");
|
||||
PanicAlert("Action Replay: Normal Code 0: Invalid Subtype %08x (%s)", addr.subtype, current_code->name.c_str());
|
||||
PanicAlertT("Action Replay: Normal Code 0: Invalid Subtype %08x (%s)", addr.subtype, current_code->name.c_str());
|
||||
return false;
|
||||
break;
|
||||
}
|
||||
|
@ -870,7 +870,7 @@ bool ConditionalCode(const ARAddr addr, const u32 data, int* const pSkipCount)
|
|||
|
||||
default:
|
||||
LogInfo("Bad Size");
|
||||
PanicAlert("Action Replay: Conditional Code: Invalid Size %08x (%s)", addr.size, current_code->name.c_str());
|
||||
PanicAlertT("Action Replay: Conditional Code: Invalid Size %08x (%s)", addr.size, current_code->name.c_str());
|
||||
return false;
|
||||
break;
|
||||
}
|
||||
|
@ -894,7 +894,7 @@ bool ConditionalCode(const ARAddr addr, const u32 data, int* const pSkipCount)
|
|||
|
||||
default:
|
||||
LogInfo("Bad Subtype");
|
||||
PanicAlert("Action Replay: Normal Code %i: Invalid subtype %08x (%s)", 1, addr.subtype, current_code->name.c_str());
|
||||
PanicAlertT("Action Replay: Normal Code %i: Invalid subtype %08x (%s)", 1, addr.subtype, current_code->name.c_str());
|
||||
return false;
|
||||
break;
|
||||
}
|
||||
|
@ -943,7 +943,7 @@ bool CompareValues(const u32 val1, const u32 val2, const int type)
|
|||
break;
|
||||
|
||||
default: LogInfo("Unknown Compare type");
|
||||
PanicAlert("Action Replay: Invalid Normal Code Type %08x (%s)", type, current_code->name.c_str());
|
||||
PanicAlertT("Action Replay: Invalid Normal Code Type %08x (%s)", type, current_code->name.c_str());
|
||||
return false;
|
||||
break;
|
||||
}
|
||||
|
|
|
@ -178,7 +178,7 @@ bool CBoot::BootUp()
|
|||
bool isoWii = DiscIO::IsVolumeWiiDisc(pVolume);
|
||||
if (isoWii != _StartupPara.bWii)
|
||||
{
|
||||
PanicAlert("Warning - starting ISO in wrong console mode!");
|
||||
PanicAlertT("Warning - starting ISO in wrong console mode!");
|
||||
}
|
||||
|
||||
char gameID[7];
|
||||
|
@ -230,7 +230,7 @@ bool CBoot::BootUp()
|
|||
bool dolWii = CDolLoader::IsDolWii(_StartupPara.m_strFilename.c_str());
|
||||
if (dolWii != _StartupPara.bWii)
|
||||
{
|
||||
PanicAlert("Warning - starting DOL in wrong console mode!");
|
||||
PanicAlertT("Warning - starting DOL in wrong console mode!");
|
||||
}
|
||||
|
||||
bool BS2Success = false;
|
||||
|
@ -271,7 +271,7 @@ bool CBoot::BootUp()
|
|||
{
|
||||
if(!File::Exists(_StartupPara.m_strFilename.c_str()))
|
||||
{
|
||||
PanicAlert("The file you specified (%s) does not exist",
|
||||
PanicAlertT("The file you specified (%s) does not exist",
|
||||
_StartupPara.m_strFilename.c_str());
|
||||
return false;
|
||||
}
|
||||
|
@ -280,7 +280,7 @@ bool CBoot::BootUp()
|
|||
bool elfWii = IsElfWii(_StartupPara.m_strFilename.c_str());
|
||||
if (elfWii != _StartupPara.bWii)
|
||||
{
|
||||
PanicAlert("Warning - starting ELF in wrong console mode!");
|
||||
PanicAlertT("Warning - starting ELF in wrong console mode!");
|
||||
}
|
||||
|
||||
bool BS2Success = false;
|
||||
|
@ -361,7 +361,7 @@ bool CBoot::BootUp()
|
|||
|
||||
default:
|
||||
{
|
||||
PanicAlert("Tried to load an unknown file type.");
|
||||
PanicAlertT("Tried to load an unknown file type.");
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -199,7 +199,7 @@ bool CBoot::SetupWiiMemory(unsigned int _CountryCode)
|
|||
break;
|
||||
|
||||
default:
|
||||
// PanicAlert("SetupWiiMem: Unknown country. Wii boot process will be switched to European settings.");
|
||||
// PanicAlertT("SetupWiiMem: Unknown country. Wii boot process will be switched to European settings.");
|
||||
filename = File::GetSysDirectory() + WII_SYS_DIR + DIR_SEP + WII_EUR_SETTING;
|
||||
break;
|
||||
}
|
||||
|
@ -207,7 +207,7 @@ bool CBoot::SetupWiiMemory(unsigned int _CountryCode)
|
|||
FILE* pTmp = fopen(filename.c_str(), "rb");
|
||||
if (!pTmp)
|
||||
{
|
||||
PanicAlert("SetupWiiMem: Cant find setting file");
|
||||
PanicAlertT("SetupWiiMem: Cant find setting file");
|
||||
return false;
|
||||
}
|
||||
|
||||
|
|
|
@ -107,7 +107,7 @@ bool CBoot::Install_WiiWAD(const char* _pFilename)
|
|||
|
||||
FILE* pTMDFile = fopen(TMDFileName.c_str(), "wb");
|
||||
if (pTMDFile == NULL) {
|
||||
PanicAlert("WAD installation failed: error creating %s", TMDFileName.c_str());
|
||||
PanicAlertT("WAD installation failed: error creating %s", TMDFileName.c_str());
|
||||
return false;
|
||||
}
|
||||
|
||||
|
@ -136,7 +136,7 @@ bool CBoot::Install_WiiWAD(const char* _pFilename)
|
|||
FILE* pAPPFile = fopen(APPFileName, "wb");
|
||||
if (pAPPFile == NULL)
|
||||
{
|
||||
PanicAlert("WAD installation failed: error creating %s", APPFileName);
|
||||
PanicAlertT("WAD installation failed: error creating %s", APPFileName);
|
||||
return false;
|
||||
}
|
||||
|
||||
|
@ -162,7 +162,7 @@ bool CBoot::Install_WiiWAD(const char* _pFilename)
|
|||
|
||||
FILE* pTicketFile = fopen(TicketFileName, "wb");
|
||||
if (pTicketFile == NULL) {
|
||||
PanicAlert("WAD installation failed: error creating %s", TicketFileName);
|
||||
PanicAlertT("WAD installation failed: error creating %s", TicketFileName);
|
||||
return false;
|
||||
}
|
||||
|
||||
|
|
|
@ -175,7 +175,7 @@ bool Init()
|
|||
{
|
||||
if (g_EmuThread != NULL)
|
||||
{
|
||||
PanicAlert("Emu Thread already running");
|
||||
PanicAlertT("Emu Thread already running");
|
||||
return false;
|
||||
}
|
||||
|
||||
|
@ -277,7 +277,7 @@ THREAD_RETURN CpuThread(void *pArg)
|
|||
// Let's run under memory watch
|
||||
EMM::InstallExceptionHandler();
|
||||
#else
|
||||
PanicAlert("32-bit platforms do not support fastmem yet. Report this bug.");
|
||||
PanicAlertT("32-bit platforms do not support fastmem yet. Report this bug.");
|
||||
#endif
|
||||
}
|
||||
|
||||
|
@ -536,7 +536,7 @@ void SetState(EState _State)
|
|||
CCPU::EnableStepping(false);
|
||||
break;
|
||||
default:
|
||||
PanicAlert("Invalid state");
|
||||
PanicAlertT("Invalid state");
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -114,7 +114,7 @@ bool SCoreStartupParameter::AutoSetup(EBootBS2 _BootBS2)
|
|||
// that gave an incorrect file name
|
||||
if (!bootDrive && !File::Exists(m_strFilename.c_str()))
|
||||
{
|
||||
PanicAlert("The specified file \"%s\" does not exist", m_strFilename.c_str());
|
||||
PanicAlertT("The specified file \"%s\" does not exist", m_strFilename.c_str());
|
||||
return false;
|
||||
}
|
||||
|
||||
|
@ -130,11 +130,14 @@ bool SCoreStartupParameter::AutoSetup(EBootBS2 _BootBS2)
|
|||
DiscIO::IVolume* pVolume = DiscIO::CreateVolumeFromFilename(m_strFilename.c_str());
|
||||
if (pVolume == NULL)
|
||||
{
|
||||
PanicAlert(bootDrive ?
|
||||
"Could not read \"%s\". There is no disc in the drive, or it is not a GC/Wii backup. "
|
||||
"Please note that original Gamecube and Wii discs cannot be read by most PC DVD drives." :
|
||||
"\"%s\" is an invalid GCM/ISO file, or is not a GC/Wii ISO."
|
||||
, m_strFilename.c_str());
|
||||
if (bootDrive)
|
||||
PanicAlertT("Could not read \"%s\". "
|
||||
"There is no disc in the drive, or it is not a GC/Wii backup. "
|
||||
"Please note that original Gamecube and Wii discs cannot be read "
|
||||
"by most PC DVD drives.", m_strFilename.c_str());
|
||||
else
|
||||
PanicAlertT("\"%s\" is an invalid GCM/ISO file, or is not a GC/Wii ISO.",
|
||||
m_strFilename.c_str());
|
||||
return false;
|
||||
}
|
||||
m_strName = pVolume->GetName();
|
||||
|
@ -166,7 +169,7 @@ bool SCoreStartupParameter::AutoSetup(EBootBS2 _BootBS2)
|
|||
break;
|
||||
|
||||
default:
|
||||
if (PanicYesNo("Your GCM/ISO file seems to be invalid (invalid country)."
|
||||
if (PanicYesNoT("Your GCM/ISO file seems to be invalid (invalid country)."
|
||||
"\nContinue with PAL region?"))
|
||||
{
|
||||
bNTSC = false;
|
||||
|
@ -201,7 +204,7 @@ bool SCoreStartupParameter::AutoSetup(EBootBS2 _BootBS2)
|
|||
//WAD is valid yet cannot be booted. Install instead.
|
||||
bool installed = CBoot::Install_WiiWAD(m_strFilename.c_str());
|
||||
if (installed)
|
||||
SuccessAlert("The WAD has been installed successfully");
|
||||
SuccessAlertT("The WAD has been installed successfully");
|
||||
return false; //do not boot
|
||||
}
|
||||
|
||||
|
@ -264,7 +267,7 @@ bool SCoreStartupParameter::AutoSetup(EBootBS2 _BootBS2)
|
|||
}
|
||||
else
|
||||
{
|
||||
PanicAlert("Could not recognize ISO file %s", m_strFilename.c_str());
|
||||
PanicAlertT("Could not recognize ISO file %s", m_strFilename.c_str());
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
@ -339,7 +342,7 @@ void SCoreStartupParameter::CheckMemcardPath(std::string& memcardPath, std::stri
|
|||
// If the old file exists we are polite and ask if we should copy it
|
||||
std::string oldFilename = filename;
|
||||
filename.replace(filename.size()-4, 4, ext);
|
||||
if (PanicYesNo("Memory Card filename in Slot %c is incorrect\n"
|
||||
if (PanicYesNoT("Memory Card filename in Slot %c is incorrect\n"
|
||||
"Region not specified\n\n"
|
||||
"Slot %c path was changed to\n"
|
||||
"%s\n"
|
||||
|
@ -347,7 +350,7 @@ void SCoreStartupParameter::CheckMemcardPath(std::string& memcardPath, std::stri
|
|||
isSlotA ? 'A':'B', isSlotA ? 'A':'B', filename.c_str()))
|
||||
{
|
||||
if (!File::Copy(oldFilename.c_str(), filename.c_str()))
|
||||
PanicAlert("Copy failed");
|
||||
PanicAlertT("Copy failed");
|
||||
}
|
||||
}
|
||||
memcardPath = filename; // Always correct the path!
|
||||
|
|
|
@ -114,7 +114,7 @@ int RegisterEvent(const char *name, TimedCallback callback)
|
|||
void UnregisterAllEvents()
|
||||
{
|
||||
if (first)
|
||||
PanicAlert("Cannot unregister events with events pending");
|
||||
PanicAlertT("Cannot unregister events with events pending");
|
||||
event_types.clear();
|
||||
}
|
||||
|
||||
|
@ -162,7 +162,7 @@ void DoState(PointerWrap &p)
|
|||
{
|
||||
ClearPendingEvents();
|
||||
if (first)
|
||||
PanicAlert("Clear failed.");
|
||||
PanicAlertT("Clear failed.");
|
||||
int more_events = 0;
|
||||
Event *prev = 0;
|
||||
while (true) {
|
||||
|
@ -532,7 +532,7 @@ std::string GetScheduledEventsSummary()
|
|||
{
|
||||
unsigned int t = ptr->type;
|
||||
if (t >= event_types.size())
|
||||
PanicAlert("Invalid event type %i", t);
|
||||
PanicAlertT("Invalid event type %i", t);
|
||||
const char *name = event_types[ptr->type].name;
|
||||
if (!name)
|
||||
name = "[unknown]";
|
||||
|
|
|
@ -136,7 +136,7 @@ bool RunGeckoCode(GeckoCode& gecko_code)
|
|||
// code failed
|
||||
if (false == result)
|
||||
{
|
||||
PanicAlert("GeckoCode failed to run (CT%i CST%i) (%s)"
|
||||
PanicAlertT("GeckoCode failed to run (CT%i CST%i) (%s)"
|
||||
"\n(either a bad code or the code type is not yet supported.)"
|
||||
, code.type, code.subtype, gecko_code.name.c_str());
|
||||
return false;
|
||||
|
|
|
@ -246,7 +246,7 @@ bool CEXIETHERNET::activate()
|
|||
if ( !(info[0] > TAP_WIN32_MIN_MAJOR
|
||||
|| (info[0] == TAP_WIN32_MIN_MAJOR && info[1] >= TAP_WIN32_MIN_MINOR)) )
|
||||
{
|
||||
PanicAlert("ERROR: This version of Dolphin requires a TAP-Win32 driver"
|
||||
PanicAlertT("ERROR: This version of Dolphin requires a TAP-Win32 driver"
|
||||
" that is at least version %d.%d -- If you recently upgraded your Dolphin"
|
||||
" distribution, a reboot is probably required at this point to get"
|
||||
" Windows to see the new driver.",
|
||||
|
@ -529,4 +529,4 @@ bool CEXIETHERNET::cbwriteDescriptor(u32 size)
|
|||
|
||||
return true;
|
||||
}
|
||||
//#pragma optimize("",on)
|
||||
//#pragma optimize("",on)
|
||||
|
|
|
@ -311,7 +311,7 @@ void InsertDiscCallback(u64 userdata, int cyclesLate)
|
|||
{
|
||||
// Put back the old one
|
||||
VolumeHandler::SetVolumeName(SavedFileName);
|
||||
PanicAlert("Invalid file");
|
||||
PanicAlertT("Invalid file");
|
||||
}
|
||||
SetLidOpen(false);
|
||||
SetDiscInside(VolumeHandler::IsValid());
|
||||
|
@ -641,7 +641,7 @@ void ExecuteCommand(UDICR& _DICR)
|
|||
// Here is the actual Disk Reading
|
||||
if (!DVDRead(iDVDOffset, m_DIMAR.Address, m_DILENGTH.Length))
|
||||
{
|
||||
PanicAlert("Cant read from DVD_Plugin - DVD-Interface: Fatal Error");
|
||||
PanicAlertT("Cant read from DVD_Plugin - DVD-Interface: Fatal Error");
|
||||
}
|
||||
}
|
||||
break;
|
||||
|
@ -651,7 +651,7 @@ void ExecuteCommand(UDICR& _DICR)
|
|||
_dbg_assert_(DVDINTERFACE, m_DICMDBUF[2].Hex == m_DILENGTH.Length);
|
||||
_dbg_assert_(DVDINTERFACE, m_DILENGTH.Length == 0x20);
|
||||
if (!DVDRead(m_DICMDBUF[1].Hex, m_DIMAR.Address, m_DILENGTH.Length))
|
||||
PanicAlert("Cant read from DVD_Plugin - DVD-Interface: Fatal Error");
|
||||
PanicAlertT("Cant read from DVD_Plugin - DVD-Interface: Fatal Error");
|
||||
WARN_LOG(DVDINTERFACE, "Read DiscID %08x", Memory::Read_U32(m_DIMAR.Address))
|
||||
break;
|
||||
|
||||
|
@ -892,7 +892,7 @@ void ExecuteCommand(UDICR& _DICR)
|
|||
break;
|
||||
|
||||
default:
|
||||
PanicAlert("Unknown DVD command %08x - fatal error", m_DICMDBUF[0].Hex);
|
||||
PanicAlertT("Unknown DVD command %08x - fatal error", m_DICMDBUF[0].Hex);
|
||||
_dbg_assert_(DVDINTERFACE, 0);
|
||||
break;
|
||||
}
|
||||
|
|
|
@ -275,7 +275,7 @@ void CEXIIPL::TransferByte(u8& _uByte)
|
|||
|
||||
if ((position >= 0x001AFF00) && (position <= 0x001FF474) && !m_FontsLoaded)
|
||||
{
|
||||
PanicAlert("Error: Trying to access %s fonts but they are not loaded. Games may not show fonts correctly, or crash.",
|
||||
PanicAlertT("Error: Trying to access %s fonts but they are not loaded. Games may not show fonts correctly, or crash.",
|
||||
(position >= 0x001FCF00)?"ANSI":"SJIS");
|
||||
m_FontsLoaded = true; // Don't be a nag :p
|
||||
}
|
||||
|
|
|
@ -120,7 +120,7 @@ THREAD_RETURN innerFlush(void *pArgs)
|
|||
|
||||
if (!pFile) // Note - pFile changed inside above if
|
||||
{
|
||||
PanicAlert("Could not write memory card file %s.\n\n"
|
||||
PanicAlertT("Could not write memory card file %s.\n\n"
|
||||
"Are you running Dolphin from a CD/DVD, or is the save file maybe write protected?", data->filename.c_str());
|
||||
delete data;
|
||||
return 0;
|
||||
|
|
|
@ -447,7 +447,7 @@ u32 Read_Opcode_JIT_LC(const u32 _Address)
|
|||
(_Address & ~JIT_ICACHE_MASK) != 0x7e000000 && // TLB area
|
||||
(_Address & ~JIT_ICACHEEX_MASK) != 0x90000000 && (_Address & ~JIT_ICACHEEX_MASK) != 0x10000000)
|
||||
{
|
||||
PanicAlert("iCacheJIT: Reading Opcode from %x. Please report.", _Address);
|
||||
PanicAlertT("iCacheJIT: Reading Opcode from %x. Please report.", _Address);
|
||||
ERROR_LOG(MEMMAP, "iCacheJIT: Reading Opcode from %x. Please report.", _Address);
|
||||
return 0;
|
||||
}
|
||||
|
@ -633,7 +633,7 @@ u8 *GetPointer(const u32 _Address)
|
|||
else
|
||||
{
|
||||
if (!Core::g_CoreStartupParameter.bMMU &&
|
||||
!PanicYesNo("Unknown pointer %#08x\nContinue?", _Address))
|
||||
!PanicYesNoT("Unknown pointer %#08x\nContinue?", _Address))
|
||||
Crash();
|
||||
return 0;
|
||||
}
|
||||
|
|
|
@ -59,7 +59,7 @@ inline void init_lib()
|
|||
hid_lib = LoadLibrary(_T("hid.dll"));
|
||||
if (!hid_lib)
|
||||
{
|
||||
PanicAlert("Failed to load hid.dll");
|
||||
PanicAlertT("Failed to load hid.dll");
|
||||
exit(EXIT_FAILURE);
|
||||
}
|
||||
|
||||
|
@ -68,7 +68,7 @@ inline void init_lib()
|
|||
HidD_SetOutputReport = (PHidD_SetOutputReport)GetProcAddress(hid_lib, "HidD_SetOutputReport");
|
||||
if (!HidD_GetHidGuid || !HidD_GetAttributes || !HidD_SetOutputReport)
|
||||
{
|
||||
PanicAlert("Failed to load hid.dll");
|
||||
PanicAlertT("Failed to load hid.dll");
|
||||
exit(EXIT_FAILURE);
|
||||
}
|
||||
|
||||
|
|
|
@ -213,7 +213,7 @@ void CopySettingsFile(std::string& DeviceName)
|
|||
else
|
||||
{
|
||||
ERROR_LOG(WII_IPC_FILEIO, "Could not copy %s to %s", Source.c_str(), Target.c_str());
|
||||
PanicAlert("Could not copy %s to %s", Source.c_str(), Target.c_str());
|
||||
PanicAlertT("Could not copy %s to %s", Source.c_str(), Target.c_str());
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -231,13 +231,13 @@ u32 CWII_IPC_HLE_Device_di::ExecuteCommand(u32 _BufferIn, u32 _BufferInSize, u32
|
|||
|
||||
if (Size > _BufferOutSize)
|
||||
{
|
||||
PanicAlert("Detected attempt to read more data from the DVD than fit inside the out buffer. Clamp.");
|
||||
PanicAlertT("Detected attempt to read more data from the DVD than fit inside the out buffer. Clamp.");
|
||||
Size = _BufferOutSize;
|
||||
}
|
||||
|
||||
if (!VolumeHandler::ReadToPtr(Memory::GetPointer(_BufferOut), DVDAddress, Size))
|
||||
{
|
||||
PanicAlert("Cant read from DVD_Plugin - DVD-Interface: Fatal Error");
|
||||
PanicAlertT("Cant read from DVD_Plugin - DVD-Interface: Fatal Error");
|
||||
}
|
||||
}
|
||||
break;
|
||||
|
@ -326,13 +326,13 @@ u32 CWII_IPC_HLE_Device_di::ExecuteCommand(u32 _BufferIn, u32 _BufferInSize, u32
|
|||
|
||||
if (Size > _BufferOutSize)
|
||||
{
|
||||
PanicAlert("Detected attempt to read more data from the DVD than fit inside the out buffer. Clamp.");
|
||||
PanicAlertT("Detected attempt to read more data from the DVD than fit inside the out buffer. Clamp.");
|
||||
Size = _BufferOutSize;
|
||||
}
|
||||
|
||||
if (!VolumeHandler::RAWReadToPtr(Memory::GetPointer(_BufferOut), DVDAddress, Size))
|
||||
{
|
||||
PanicAlert("Cant read from DVD_Plugin - DVD-Interface: Fatal Error");
|
||||
PanicAlertT("Cant read from DVD_Plugin - DVD-Interface: Fatal Error");
|
||||
}
|
||||
}
|
||||
break;
|
||||
|
@ -444,7 +444,7 @@ u32 CWII_IPC_HLE_Device_di::ExecuteCommand(u32 _BufferIn, u32 _BufferInSize, u32
|
|||
ERROR_LOG(WII_IPC_DVD, "unknown cmd 0x%08x (Buffer 0x%08x, 0x%x)",
|
||||
Command, _BufferOut, _BufferOutSize);
|
||||
|
||||
PanicAlert("unknown cmd 0x%08x", Command);
|
||||
PanicAlertT("unknown cmd 0x%08x", Command);
|
||||
break;
|
||||
}
|
||||
|
||||
|
|
|
@ -117,7 +117,7 @@ bool CWII_IPC_HLE_Device_FileIO::Open(u32 _CommandAddress, u32 _Mode)
|
|||
// "r+b" is technically wrong, but OPEN_WRITE should not truncate the file as "wb" does.
|
||||
case ISFS_OPEN_WRITE: m_pFileHandle = fopen(m_Filename.c_str(), "r+b"); break;
|
||||
case ISFS_OPEN_RW: m_pFileHandle = fopen(m_Filename.c_str(), "r+b"); break;
|
||||
default: PanicAlert("FileIO: Unknown open mode : 0x%02x", _Mode); break;
|
||||
default: PanicAlertT("FileIO: Unknown open mode : 0x%02x", _Mode); break;
|
||||
}
|
||||
}
|
||||
else
|
||||
|
|
|
@ -299,7 +299,7 @@ bool CWII_IPC_HLE_Device_es::IOCtlV(u32 _CommandAddress)
|
|||
memcpy(pDest, pSrc, Size);
|
||||
rContent.m_Position += Size;
|
||||
} else {
|
||||
PanicAlert("IOCTL_ES_READCONTENT - bad destination");
|
||||
PanicAlertT("IOCTL_ES_READCONTENT - bad destination");
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -459,7 +459,7 @@ bool CWII_IPC_HLE_Device_es::IOCtlV(u32 _CommandAddress)
|
|||
{
|
||||
if (TitleID == TITLEID_SYSMENU)
|
||||
{
|
||||
PanicAlert("There must be a ticket for 00000001/00000002. Your NAND dump is probably incomplete.");
|
||||
PanicAlertT("There must be a ticket for 00000001/00000002. Your NAND dump is probably incomplete.");
|
||||
}
|
||||
ViewCount = 0;
|
||||
}
|
||||
|
@ -500,7 +500,7 @@ bool CWII_IPC_HLE_Device_es::IOCtlV(u32 _CommandAddress)
|
|||
}
|
||||
else
|
||||
{
|
||||
PanicAlert("IOCTL_ES_GETVIEWS: Tried to get data from an unknown ticket: %08x/%08x", (u32)(TitleID >> 32), (u32)TitleID);
|
||||
PanicAlertT("IOCTL_ES_GETVIEWS: Tried to get data from an unknown ticket: %08x/%08x", (u32)(TitleID >> 32), (u32)TitleID);
|
||||
}
|
||||
|
||||
INFO_LOG(WII_IPC_ES, "IOCTL_ES_GETVIEWS for titleID: %08x/%08x (MaxViews = %i)", (u32)(TitleID >> 32), (u32)TitleID, maxViews);
|
||||
|
@ -714,7 +714,7 @@ bool CWII_IPC_HLE_Device_es::IOCtlV(u32 _CommandAddress)
|
|||
IOSv = TitleID & 0xffff;
|
||||
}
|
||||
if (!bSuccess)
|
||||
PanicAlert("IOCTL_ES_LAUNCH: Game tried to reload ios or a title that is not available in your nand dump\n"
|
||||
PanicAlertT("IOCTL_ES_LAUNCH: Game tried to reload ios or a title that is not available in your nand dump\n"
|
||||
"TitleID %016llx.\n Dolphin will likely hang now", TitleID);
|
||||
// Pass the "#002 check"
|
||||
// Apploader should write the IOS version and revision to 0x3140, and compare it
|
||||
|
|
|
@ -40,7 +40,7 @@ CWII_IPC_HLE_Device_usb_oh1_57e_305::CWII_IPC_HLE_Device_usb_oh1_57e_305(u32 _De
|
|||
u8 maxWM = 0;
|
||||
if (!SConfig::GetInstance().m_SYSCONF->GetArrayData("BT.DINF", BT_DINF, BTDINFSIZE))
|
||||
{
|
||||
PanicAlert("Trying to read from invalid SYSCONF\nWiimote bt ids are not available");
|
||||
PanicAlertT("Trying to read from invalid SYSCONF\nWiimote bt ids are not available");
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -80,7 +80,7 @@ CWII_IPC_HLE_Device_usb_oh1_57e_305::CWII_IPC_HLE_Device_usb_oh1_57e_305(u32 _De
|
|||
{
|
||||
// save now so that when games load sysconf file it includes the new wiimotes
|
||||
if (!SConfig::GetInstance().m_SYSCONF->SetArrayData("BT.DINF", BT_DINF, BTDINFSIZE) || !SConfig::GetInstance().m_SYSCONF->Save())
|
||||
PanicAlert("Failed to write BT.DINF to SYSCONF");
|
||||
PanicAlertT("Failed to write BT.DINF to SYSCONF");
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1218,7 +1218,7 @@ void CWII_IPC_HLE_Device_usb_oh1_57e_305::ExecuteHCICommandMessage(const SHCICom
|
|||
void CWII_IPC_HLE_Device_usb_oh1_57e_305::CommandInquiry(u8* _Input)
|
||||
{
|
||||
// Inquiry should not be called normally
|
||||
PanicAlert("HCI_CMD_INQUIRY is called, please report!");
|
||||
PanicAlertT("HCI_CMD_INQUIRY is called, please report!");
|
||||
|
||||
hci_inquiry_cp* pInquiry = (hci_inquiry_cp*)_Input;
|
||||
|
||||
|
@ -1824,7 +1824,7 @@ CWII_IPC_HLE_WiiMote* CWII_IPC_HLE_Device_usb_oh1_57e_305::AccessWiiMote(const b
|
|||
|
||||
ERROR_LOG(WII_IPC_WIIMOTE,"Cant find WiiMote by bd: %02x:%02x:%02x:%02x:%02x:%02x",
|
||||
_rAddr.b[0], _rAddr.b[1], _rAddr.b[2], _rAddr.b[3], _rAddr.b[4], _rAddr.b[5]);
|
||||
PanicAlert("Cant find WiiMote by bd: %02x:%02x:%02x:%02x:%02x:%02x",
|
||||
PanicAlertT("Cant find WiiMote by bd: %02x:%02x:%02x:%02x:%02x:%02x",
|
||||
_rAddr.b[0], _rAddr.b[1], _rAddr.b[2], _rAddr.b[3], _rAddr.b[4], _rAddr.b[5]);
|
||||
return NULL;
|
||||
}
|
||||
|
@ -1838,7 +1838,7 @@ CWII_IPC_HLE_WiiMote* CWII_IPC_HLE_Device_usb_oh1_57e_305::AccessWiiMote(u16 _Co
|
|||
}
|
||||
|
||||
ERROR_LOG(WII_IPC_WIIMOTE, "Cant find WiiMote by connection handle %02x", _ConnectionHandle);
|
||||
PanicAlert("Cant find WiiMote by connection handle %02x", _ConnectionHandle);
|
||||
PanicAlertT("Cant find WiiMote by connection handle %02x", _ConnectionHandle);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
|
|
@ -211,7 +211,7 @@ void sigsegv_handler(int signal, siginfo_t *info, void *raw_context)
|
|||
u64 bad_address = (u64)fault_memory_ptr;
|
||||
u64 memspace_bottom = (u64)Memory::base;
|
||||
if (bad_address < memspace_bottom) {
|
||||
PanicAlert("Exception handler - access below memory space. %08llx%08llx",
|
||||
PanicAlertT("Exception handler - access below memory space. %08llx%08llx",
|
||||
bad_address >> 32, bad_address);
|
||||
}
|
||||
u32 em_address = (u32)(bad_address - memspace_bottom);
|
||||
|
@ -245,7 +245,7 @@ void sigsegv_handler(int signal, siginfo_t *info, void *raw_context)
|
|||
void InstallExceptionHandler()
|
||||
{
|
||||
#ifdef _M_IX86
|
||||
PanicAlert("InstallExceptionHandler called, but this platform does not yet support it.");
|
||||
PanicAlertT("InstallExceptionHandler called, but this platform does not yet support it.");
|
||||
return;
|
||||
#endif
|
||||
struct sigaction sa;
|
||||
|
|
|
@ -226,7 +226,7 @@ bool BeginRecordingInput(int controllers)
|
|||
|
||||
g_recordfd = fopen(filename, "wb");
|
||||
if(!g_recordfd) {
|
||||
PanicAlert("Error opening file %s for recording", filename);
|
||||
PanicAlertT("Error opening file %s for recording", filename);
|
||||
return false;
|
||||
}
|
||||
|
||||
|
@ -292,7 +292,7 @@ bool PlayInput(const char *filename)
|
|||
fread(&header, sizeof(DTMHeader), 1, g_recordfd);
|
||||
|
||||
if(header.filetype[0] != 'D' || header.filetype[1] != 'T' || header.filetype[2] != 'M' || header.filetype[3] != 0x1A) {
|
||||
PanicAlert("Invalid recording file");
|
||||
PanicAlertT("Invalid recording file");
|
||||
goto cleanup;
|
||||
}
|
||||
|
||||
|
@ -339,7 +339,7 @@ void LoadInput(const char *filename)
|
|||
fclose(t_record);
|
||||
|
||||
if(header.filetype[0] != 'D' || header.filetype[1] != 'T' || header.filetype[2] != 'M' || header.filetype[3] != 0x1A) {
|
||||
PanicAlert("Savestate movie %s is corrupted, movie recording stopping...", filename);
|
||||
PanicAlertT("Savestate movie %s is corrupted, movie recording stopping...", filename);
|
||||
EndPlayInput();
|
||||
return;
|
||||
}
|
||||
|
|
|
@ -92,20 +92,20 @@ bool CPluginManager::InitPlugins()
|
|||
// Update pluginglobals.
|
||||
if (SConfig::GetInstance().m_LocalCoreStartupParameter.m_strGameIni.size() == 0)
|
||||
{
|
||||
PanicAlert("Bad gameini filename");
|
||||
PanicAlertT("Bad gameini filename");
|
||||
}
|
||||
strcpy(m_PluginGlobals->game_ini, SConfig::GetInstance().m_LocalCoreStartupParameter.m_strGameIni.c_str());
|
||||
strcpy(m_PluginGlobals->unique_id, SConfig::GetInstance().m_LocalCoreStartupParameter.GetUniqueID().c_str());
|
||||
INFO_LOG(CONSOLE, "Before GetVideo\n");
|
||||
|
||||
if (!GetVideo()) {
|
||||
PanicAlert("Can't init Video Plugin");
|
||||
PanicAlertT("Can't init Video Plugin");
|
||||
return false;
|
||||
}
|
||||
INFO_LOG(CONSOLE, "After GetVideo\n");
|
||||
|
||||
if (!GetDSP()) {
|
||||
PanicAlert("Can't init DSP Plugin");
|
||||
PanicAlertT("Can't init DSP Plugin");
|
||||
return false;
|
||||
}
|
||||
|
||||
|
@ -147,7 +147,7 @@ CPluginInfo::CPluginInfo(const char *_rFilename)
|
|||
{
|
||||
if (!File::Exists((File::GetPluginsDirectory() + _rFilename).c_str()))
|
||||
{
|
||||
PanicAlert("Can't find plugin %s", _rFilename);
|
||||
PanicAlertT("Can't find plugin %s", _rFilename);
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -158,7 +158,7 @@ CPluginInfo::CPluginInfo(const char *_rFilename)
|
|||
if (plugin->GetInfo(m_PluginInfo))
|
||||
m_Valid = true;
|
||||
else
|
||||
PanicAlert("Could not get info about plugin %s", _rFilename);
|
||||
PanicAlertT("Could not get info about plugin %s", _rFilename);
|
||||
// We are now done with this plugin and will call FreeLibrary()
|
||||
delete plugin;
|
||||
}
|
||||
|
@ -195,7 +195,7 @@ void CPluginManager::GetPluginInfo(CPluginInfo *&info, std::string Filename)
|
|||
void *CPluginManager::LoadPlugin(const char *_rFilename)
|
||||
{
|
||||
if (!File::Exists((File::GetPluginsDirectory() + _rFilename).c_str())) {
|
||||
PanicAlert("Error loading plugin %s: can't find file. Please re-select your plugins.", _rFilename);
|
||||
PanicAlertT("Error loading plugin %s: can't find file. Please re-select your plugins.", _rFilename);
|
||||
return NULL;
|
||||
}
|
||||
/* Avoid calling LoadLibrary() again and instead point to the plugin info that we found when
|
||||
|
@ -203,7 +203,7 @@ void *CPluginManager::LoadPlugin(const char *_rFilename)
|
|||
CPluginInfo *info = NULL;
|
||||
GetPluginInfo(info, _rFilename);
|
||||
if (!info) {
|
||||
PanicAlert("Error loading %s: can't read info", _rFilename);
|
||||
PanicAlertT("Error loading %s: can't read info", _rFilename);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
@ -221,14 +221,14 @@ void *CPluginManager::LoadPlugin(const char *_rFilename)
|
|||
break;
|
||||
|
||||
default:
|
||||
PanicAlert("Trying to load unsupported type %d", type);
|
||||
PanicAlertT("Trying to load unsupported type %d", type);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
// Check that the plugin has all the common and all the type specific functions
|
||||
if (!plugin->IsValid())
|
||||
{
|
||||
PanicAlert("Can't open %s, it has a missing function", _rFilename);
|
||||
PanicAlertT("Can't open %s, it has a missing function", _rFilename);
|
||||
delete plugin;
|
||||
return NULL;
|
||||
}
|
||||
|
@ -354,7 +354,7 @@ void CPluginManager::OpenConfig(void* _Parent, const char *_rFilename, PLUGIN_TY
|
|||
{
|
||||
if (! File::Exists((File::GetPluginsDirectory() + _rFilename).c_str()))
|
||||
{
|
||||
PanicAlert("Can't find plugin %s", _rFilename);
|
||||
PanicAlertT("Can't find plugin %s", _rFilename);
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -371,7 +371,7 @@ void CPluginManager::OpenConfig(void* _Parent, const char *_rFilename, PLUGIN_TY
|
|||
break;
|
||||
|
||||
default:
|
||||
PanicAlert("Type %d config not supported in plugin %s", Type, _rFilename);
|
||||
PanicAlertT("Type %d config not supported in plugin %s", Type, _rFilename);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -206,7 +206,7 @@ THREAD_RETURN CompressAndDumpState(void *pArgs)
|
|||
cur_len = IN_LEN;
|
||||
|
||||
if (lzo1x_1_compress((buffer + i), cur_len, out, &out_len, wrkmem) != LZO_E_OK)
|
||||
PanicAlert("Internal LZO Error - compression failed");
|
||||
PanicAlertT("Internal LZO Error - compression failed");
|
||||
|
||||
// The size of the data to write is 'out_len'
|
||||
fwrite(&out_len, sizeof(int), 1, f);
|
||||
|
@ -329,7 +329,7 @@ void LoadStateCallback(u64 userdata, int cyclesLate)
|
|||
buffer = new u8[sz];
|
||||
if (!buffer)
|
||||
{
|
||||
PanicAlert("Error allocating buffer");
|
||||
PanicAlertT("Error allocating buffer");
|
||||
// Resume the clock
|
||||
PowerPC::Start();
|
||||
return;
|
||||
|
@ -347,7 +347,7 @@ void LoadStateCallback(u64 userdata, int cyclesLate)
|
|||
if (res != LZO_E_OK)
|
||||
{
|
||||
// This doesn't seem to happen anymore.
|
||||
PanicAlert("Internal LZO Error - decompression failed (%d) (%li, %li) \n"
|
||||
PanicAlertT("Internal LZO Error - decompression failed (%d) (%li, %li) \n"
|
||||
"Try loading the state again", res, i, new_len);
|
||||
fclose(f);
|
||||
delete[] buffer;
|
||||
|
@ -432,7 +432,7 @@ void VerifyStateCallback(u64 userdata, int cyclesLate)
|
|||
lzo_uint i = 0;
|
||||
buffer = new u8[sz];
|
||||
if (!buffer) {
|
||||
PanicAlert("Error allocating buffer");
|
||||
PanicAlertT("Error allocating buffer");
|
||||
return;
|
||||
}
|
||||
while (true)
|
||||
|
@ -448,7 +448,7 @@ void VerifyStateCallback(u64 userdata, int cyclesLate)
|
|||
if (res != LZO_E_OK)
|
||||
{
|
||||
// This doesn't seem to happen anymore.
|
||||
PanicAlert("Internal LZO Error - decompression failed (%d) (%ld, %ld) \n"
|
||||
PanicAlertT("Internal LZO Error - decompression failed (%d) (%ld, %ld) \n"
|
||||
"Try verifying the state again", res, i, new_len);
|
||||
fclose(f);
|
||||
delete [] buffer;
|
||||
|
@ -492,7 +492,7 @@ void State_Init()
|
|||
ev_BufferVerify = CoreTiming::RegisterEvent("VerifyBufferState", &VerifyBufferStateCallback);
|
||||
|
||||
if (lzo_init() != LZO_E_OK)
|
||||
PanicAlert("Internal LZO Error - lzo_init() failed");
|
||||
PanicAlertT("Internal LZO Error - lzo_init() failed");
|
||||
}
|
||||
|
||||
void State_Shutdown()
|
||||
|
|
|
@ -50,7 +50,7 @@ static bool LoadRom(const char *fname, int size_in_words, u16 *rom)
|
|||
size_t read_bytes = fread(rom, 1, size_in_bytes, pFile);
|
||||
if (read_bytes != size_in_bytes)
|
||||
{
|
||||
PanicAlert("ROM %s too short : %i/%i", fname, (int)read_bytes, (int)size_in_bytes);
|
||||
PanicAlertT("ROM %s too short : %i/%i", fname, (int)read_bytes, (int)size_in_bytes);
|
||||
fclose(pFile);
|
||||
return false;
|
||||
}
|
||||
|
@ -62,7 +62,7 @@ static bool LoadRom(const char *fname, int size_in_words, u16 *rom)
|
|||
|
||||
return true;
|
||||
}
|
||||
PanicAlert("Failed to load DSP Rom : %s",fname);
|
||||
PanicAlertT("Failed to load DSP Rom : %s",fname);
|
||||
// Always keep ROMs write protected.
|
||||
WriteProtectMemory(g_dsp.irom, size_in_bytes, false);
|
||||
return false;
|
||||
|
|
|
@ -37,7 +37,7 @@ CBannerLoaderGC::CBannerLoaderGC(DiscIO::IFileSystem& _rFileSystem)
|
|||
_rFileSystem.ReadFile("opening.bnr", m_pBannerFile, FileSize);
|
||||
m_BNRType = getBannerType();
|
||||
if (m_BNRType == BANNER_UNKNOWN)
|
||||
PanicAlert("Invalid opening.bnr found in gcm:\n%s\n You may need to redump this game.",
|
||||
PanicAlertT("Invalid opening.bnr found in gcm:\n%s\n You may need to redump this game.",
|
||||
_rFileSystem.GetVolume()->GetName().c_str());
|
||||
else m_IsValid = true;
|
||||
}
|
||||
|
|
|
@ -158,7 +158,7 @@ bool CompressFileToBlob(const char* infile, const char* outfile, u32 sub_type,
|
|||
|
||||
if (IsCompressedBlob(infile))
|
||||
{
|
||||
PanicAlert("%s is already compressed! Cannot compress it further.", infile);
|
||||
PanicAlertT("%s is already compressed! Cannot compress it further.", infile);
|
||||
return false;
|
||||
}
|
||||
|
||||
|
@ -166,7 +166,7 @@ bool CompressFileToBlob(const char* infile, const char* outfile, u32 sub_type,
|
|||
{
|
||||
if (!DiscScrubber::SetupScrub(infile, block_size))
|
||||
{
|
||||
PanicAlert("%s failed to be scrubbed. Probably the image is corrupt.", infile);
|
||||
PanicAlertT("%s failed to be scrubbed. Probably the image is corrupt.", infile);
|
||||
return false;
|
||||
}
|
||||
|
||||
|
@ -299,7 +299,7 @@ bool DecompressBlobToFile(const char* infile, const char* outfile, CompressCB ca
|
|||
{
|
||||
if (!IsCompressedBlob(infile))
|
||||
{
|
||||
PanicAlert("File not compressed");
|
||||
PanicAlertT("File not compressed");
|
||||
return false;
|
||||
}
|
||||
|
||||
|
|
|
@ -108,7 +108,7 @@ void DriveReader::GetBlock(u64 block_num, u8 *out_ptr)
|
|||
LONG off_high = (LONG)(offset >> 32);
|
||||
SetFilePointer(hDisc, off_low, &off_high, FILE_BEGIN);
|
||||
if (!ReadFile(hDisc, lpSector, m_blocksize, (LPDWORD)&NotUsed, NULL))
|
||||
PanicAlert("Disc Read Error");
|
||||
PanicAlertT("Disc Read Error");
|
||||
#else
|
||||
fseeko(file_, m_blocksize*block_num, SEEK_SET);
|
||||
fread(lpSector, 1, m_blocksize, file_);
|
||||
|
@ -127,7 +127,7 @@ bool DriveReader::ReadMultipleAlignedBlocks(u64 block_num, u64 num_blocks, u8 *o
|
|||
SetFilePointer(hDisc, off_low, &off_high, FILE_BEGIN);
|
||||
if (!ReadFile(hDisc, out_ptr, (DWORD)(m_blocksize * num_blocks), (LPDWORD)&NotUsed, NULL))
|
||||
{
|
||||
PanicAlert("Disc Read Error");
|
||||
PanicAlertT("Disc Read Error");
|
||||
return false;
|
||||
}
|
||||
#else
|
||||
|
|
|
@ -308,13 +308,13 @@ bool CVolumeDirectory::SetApploader(const std::string& _rApploader)
|
|||
std::string data;
|
||||
if (!File::ReadFileToString(false, _rApploader.c_str(), data))
|
||||
{
|
||||
PanicAlert("Apploader unable to load from file");
|
||||
PanicAlertT("Apploader unable to load from file");
|
||||
return false;
|
||||
}
|
||||
m_apploaderSize = 0x20 + Common::swap32(*(u32*)&data.data()[0x14]) + Common::swap32(*(u32*)&data.data()[0x18]);
|
||||
if (m_apploaderSize != data.size())
|
||||
{
|
||||
PanicAlert("Apploader is the wrong size...is it really an apploader?");
|
||||
PanicAlertT("Apploader is the wrong size...is it really an apploader?");
|
||||
return false;
|
||||
}
|
||||
m_apploader = new u8[m_apploaderSize];
|
||||
|
|
|
@ -57,7 +57,7 @@ std::string CVolumeGC::GetUniqueID() const
|
|||
char id[6];
|
||||
if (!Read(0, sizeof(id), reinterpret_cast<u8*>(id)))
|
||||
{
|
||||
PanicAlert("Failed to read unique ID from disc image");
|
||||
PanicAlertT("Failed to read unique ID from disc image");
|
||||
return NO_UID;
|
||||
}
|
||||
|
||||
|
|
|
@ -78,7 +78,7 @@ u8* WiiWAD::CreateWADEntry(DiscIO::IBlobReader& _rReader, u32 _Size, u64 _Offset
|
|||
if (!_rReader.Read(_Offset, _Size, pTmpBuffer))
|
||||
{
|
||||
ERROR_LOG(DISCIO, "WiiWAD: Could not read from file");
|
||||
PanicAlert("WiiWAD: Could not read from file");
|
||||
PanicAlertT("WiiWAD: Could not read from file");
|
||||
}
|
||||
return pTmpBuffer;
|
||||
}
|
||||
|
|
|
@ -151,7 +151,7 @@ bool BootCore(const std::string& _rFilename)
|
|||
// Init the core
|
||||
if (!Core::Init())
|
||||
{
|
||||
PanicAlert("%s", _wxt("Couldn't init the core.\nCheck your configuration."));
|
||||
PanicAlertT("Couldn't init the core.\nCheck your configuration.");
|
||||
return false;
|
||||
}
|
||||
|
||||
|
|
|
@ -345,7 +345,7 @@ void CheatSearchTab::StartNewSearch(wxCommandEvent& WXUNUSED (event))
|
|||
const u8* const memptr = Memory::GetPointer(0);
|
||||
if (NULL == memptr)
|
||||
{
|
||||
PanicAlert("%s", _wxt("A game is not currently running."));
|
||||
PanicAlertT("A game is not currently running.");
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -376,7 +376,7 @@ void CheatSearchTab::FilterCheatSearchResults(wxCommandEvent&)
|
|||
const u8* const memptr = Memory::GetPointer(0);
|
||||
if (NULL == memptr)
|
||||
{
|
||||
PanicAlert("%s", _wxt("A game is not currently running."));
|
||||
PanicAlertT("A game is not currently running.");
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -431,7 +431,7 @@ void CheatSearchTab::FilterCheatSearchResults(wxCommandEvent&)
|
|||
|
||||
if (!x_val.ToLong(&parsed_x_val, val_base))
|
||||
{
|
||||
PanicAlert("%s", _wxt("You must enter a valid decimal or hex value."));
|
||||
PanicAlertT("You must enter a valid decimal or hex value.");
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -598,14 +598,14 @@ void CreateCodeDialog::PressOK(wxCommandEvent&)
|
|||
const wxString code_name = textctrl_name->GetValue();
|
||||
if (code_name.empty())
|
||||
{
|
||||
PanicAlert("%s", _wxt("You must enter a name!"));
|
||||
PanicAlertT("You must enter a name!");
|
||||
return;
|
||||
}
|
||||
|
||||
long code_value;
|
||||
if (!textctrl_value->GetValue().ToLong(&code_value, 10 + checkbox_use_hex->GetValue()*6))
|
||||
{
|
||||
PanicAlert("%s", _wxt("Invalid Value!"));
|
||||
PanicAlertT("Invalid Value!");
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
|
@ -917,7 +917,7 @@ void CConfigMain::DisplaySettingsChanged(wxCommandEvent& event)
|
|||
break;
|
||||
case ID_INTERFACE_LANG:
|
||||
if (SConfig::GetInstance().m_InterfaceLanguage != langIds[InterfaceLang->GetSelection()])
|
||||
SuccessAlert("%s", _wxt("You must restart Dolphin in order for the change to take effect."));
|
||||
SuccessAlertT("You must restart Dolphin in order for the change to take effect.");
|
||||
SConfig::GetInstance().m_InterfaceLanguage = langIds[InterfaceLang->GetSelection()];
|
||||
break;
|
||||
case ID_HOTKEY_CONFIG:
|
||||
|
@ -1000,7 +1000,8 @@ void CConfigMain::ChooseMemcardPath(std::string& strMemcard, bool isSlotA)
|
|||
}
|
||||
else
|
||||
{
|
||||
PanicAlert("%s", _wxt("Cannot use that file as a memory card.\nAre you trying to use the same file in both slots?"));
|
||||
PanicAlertT("Cannot use that file as a memory card.\n"
|
||||
"Are you trying to use the same file in both slots?");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -524,7 +524,7 @@ void CFrame::InitBitmaps()
|
|||
}
|
||||
break;
|
||||
|
||||
default: PanicAlert("%s", _wxt("Theme selection went wrong"));
|
||||
default: PanicAlertT("Theme selection went wrong");
|
||||
}
|
||||
|
||||
// Update in case the bitmap has been updated
|
||||
|
@ -597,7 +597,7 @@ void CFrame::DoOpen(bool Boot)
|
|||
|
||||
if (currentDir != currentDir2)
|
||||
{
|
||||
PanicAlert(_wxt("Current dir changed from %s to %s after wxFileSelector!"),
|
||||
PanicAlertT("Current dir changed from %s to %s after wxFileSelector!",
|
||||
currentDir.c_str(), currentDir2.c_str());
|
||||
File::SetCurrentDir(currentDir.c_str());
|
||||
}
|
||||
|
|
|
@ -276,17 +276,17 @@ void CodeConfigPanel::DownloadCodes(wxCommandEvent&)
|
|||
}
|
||||
}
|
||||
|
||||
PanicAlert(_wxt("Downloaded %lu codes. (added %lu)"),
|
||||
PanicAlertT("Downloaded %lu codes. (added %lu)",
|
||||
(unsigned long)gcodes.size(), added_count);
|
||||
|
||||
// refresh the list
|
||||
UpdateCodeList();
|
||||
}
|
||||
else
|
||||
PanicAlert("%s", _wxt("File contained no codes."));
|
||||
PanicAlertT("File contained no codes.");
|
||||
}
|
||||
else
|
||||
PanicAlert("%s", _wxt("Failed to download codes."));
|
||||
PanicAlertT("Failed to download codes.");
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -553,7 +553,7 @@ void CISOProperties::CreateGUIControls(bool IsWad)
|
|||
void CISOProperties::OnClose(wxCloseEvent& WXUNUSED (event))
|
||||
{
|
||||
if (!SaveGameConfig())
|
||||
PanicAlert(_wxt("Could not save %s"), GameIniFile.c_str());
|
||||
PanicAlertT("Could not save %s", GameIniFile.c_str());
|
||||
|
||||
EndModal(bRefreshList ? wxID_OK : wxID_CANCEL);
|
||||
}
|
||||
|
@ -801,7 +801,7 @@ void CISOProperties::OnExtractDataFromHeader(wxCommandEvent& event)
|
|||
}
|
||||
|
||||
if (!ret)
|
||||
PanicAlert(_wxt("Failed to extract to %s!"), (const char *)Path.mb_str());
|
||||
PanicAlertT("Failed to extract to %s!", (const char *)Path.mb_str());
|
||||
}
|
||||
|
||||
void CISOProperties::SetRefresh(wxCommandEvent& event)
|
||||
|
@ -1052,17 +1052,17 @@ void CISOProperties::OnEditConfig(wxCommandEvent& WXUNUSED (event))
|
|||
filetype = wxTheMimeTypesManager->GetFileTypeFromMimeType(_T("text/plain"));
|
||||
if(filetype == NULL) // MIME type failed, aborting mission
|
||||
{
|
||||
PanicAlert("%s", _wxt("Filetype 'ini' is unknown! Will not open!"));
|
||||
PanicAlertT("Filetype 'ini' is unknown! Will not open!");
|
||||
return;
|
||||
}
|
||||
}
|
||||
wxString OpenCommand;
|
||||
OpenCommand = filetype->GetOpenCommand(wxString::From8BitData(GameIniFile.c_str()));
|
||||
if(OpenCommand.IsEmpty())
|
||||
PanicAlert("%s", _wxt("Couldn't find open command for extension 'ini'!"));
|
||||
PanicAlertT("Couldn't find open command for extension 'ini'!");
|
||||
else
|
||||
if(wxExecute(OpenCommand, wxEXEC_SYNC) == -1)
|
||||
PanicAlert("%s", _wxt("wxExecute returned -1 on application run!"));
|
||||
PanicAlertT("wxExecute returned -1 on application run!");
|
||||
|
||||
GameIni.Load(GameIniFile.c_str());
|
||||
LoadGameConfig();
|
||||
|
|
|
@ -623,7 +623,7 @@ void GamepadPage::SaveProfile(wxCommandEvent&)
|
|||
m_config_dialog->UpdateProfileComboBox();
|
||||
}
|
||||
else
|
||||
PanicAlert("%s", _wxt("You must enter a valid profile name."));
|
||||
PanicAlertT("You must enter a valid profile name.");
|
||||
}
|
||||
|
||||
void GamepadPage::DeleteProfile(wxCommandEvent&)
|
||||
|
@ -634,7 +634,7 @@ void GamepadPage::DeleteProfile(wxCommandEvent&)
|
|||
const char* const fnamecstr = fname.c_str();
|
||||
|
||||
if (File::Exists(fnamecstr) &&
|
||||
AskYesNo(_wxt("Are you sure you want to delete \"%s\"?"),
|
||||
AskYesNoT("Are you sure you want to delete \"%s\"?",
|
||||
STR_FROM_WXSTR(profile_cbox->GetValue()).c_str()))
|
||||
{
|
||||
File::Delete(fnamecstr);
|
||||
|
|
|
@ -56,6 +56,7 @@ END_EVENT_TABLE()
|
|||
|
||||
#include <wx/stdpaths.h>
|
||||
bool wxMsgAlert(const char*, const char*, bool, int);
|
||||
const char *wxStringTranslator(const char *);
|
||||
|
||||
CFrame* main_frame = NULL;
|
||||
|
||||
|
@ -170,6 +171,7 @@ bool DolphinApp::OnInit()
|
|||
#ifndef _WIN32
|
||||
RegisterMsgAlertHandler(&wxMsgAlert);
|
||||
#endif
|
||||
RegisterStringTranslator(&wxStringTranslator);
|
||||
|
||||
// "ExtendedTrace" looks freakin dangerous!!!
|
||||
#ifdef _WIN32
|
||||
|
@ -182,7 +184,9 @@ bool DolphinApp::OnInit()
|
|||
// TODO: if First Boot
|
||||
if (!cpu_info.bSSE2)
|
||||
{
|
||||
PanicAlert("%s", _wxt("Hi,\n\nDolphin requires that your CPU has support for SSE2 extensions.\nUnfortunately your CPU does not support them, so Dolphin will not run.\n\nSayonara!\n"));
|
||||
PanicAlertT("Hi,\n\nDolphin requires that your CPU has support for SSE2 extensions.\n"
|
||||
"Unfortunately your CPU does not support them, so Dolphin will not run.\n\n"
|
||||
"Sayonara!\n");
|
||||
return false;
|
||||
}
|
||||
|
||||
|
@ -200,12 +204,12 @@ bool DolphinApp::OnInit()
|
|||
FILE* workingDir = fopen(tmp, "r");
|
||||
if (!workingDir)
|
||||
{
|
||||
if (PanicYesNo("Dolphin has not been configured with an install location,\nKeep Dolphin portable?"))
|
||||
if (PanicYesNoT("Dolphin has not been configured with an install location,\nKeep Dolphin portable?"))
|
||||
{
|
||||
FILE* portable = fopen((std::string(File::GetUserPath(D_CONFIG_IDX)) + "portable").c_str(), "w");
|
||||
if (!portable)
|
||||
{
|
||||
PanicAlert("Portable Setting could not be saved\n Are you running Dolphin from read only media or from a directory that dolphin is not located in?");
|
||||
PanicAlertT("Portable Setting could not be saved\n Are you running Dolphin from read only media or from a directory that dolphin is not located in?");
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -216,11 +220,11 @@ bool DolphinApp::OnInit()
|
|||
{
|
||||
char CWD[1024];
|
||||
sprintf(CWD, "%s", (const char*)wxGetCwd().mb_str());
|
||||
if (PanicYesNo("Set install location to:\n %s ?", CWD))
|
||||
if (PanicYesNoT("Set install location to:\n %s ?", CWD))
|
||||
{
|
||||
FILE* workingDirF = fopen(tmp, "w");
|
||||
if (!workingDirF)
|
||||
PanicAlert("Install directory could not be saved");
|
||||
PanicAlertT("Install directory could not be saved");
|
||||
else
|
||||
{
|
||||
fwrite(CWD, ((std::string)CWD).size()+1, 1, workingDirF);
|
||||
|
@ -229,7 +233,7 @@ bool DolphinApp::OnInit()
|
|||
}
|
||||
}
|
||||
else
|
||||
PanicAlert("Relaunch Dolphin from the install directory and save from there");
|
||||
PanicAlertT("Relaunch Dolphin from the install directory and save from there");
|
||||
}
|
||||
}
|
||||
else
|
||||
|
@ -390,14 +394,14 @@ void DolphinApp::InitLanguageSupport()
|
|||
|
||||
if(!m_locale->IsOk())
|
||||
{
|
||||
PanicAlert("Error loading selected language. Falling back to system default.\n");
|
||||
PanicAlertT("Error loading selected language. Falling back to system default.\n");
|
||||
delete m_locale;
|
||||
m_locale = new wxLocale(wxLANGUAGE_DEFAULT);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
PanicAlert("The selected language is not supported by your system. Falling back to system default.\n");
|
||||
PanicAlertT("The selected language is not supported by your system. Falling back to system default.\n");
|
||||
m_locale = new wxLocale(wxLANGUAGE_DEFAULT);
|
||||
}
|
||||
}
|
||||
|
@ -469,6 +473,12 @@ bool wxMsgAlert(const char* caption, const char* text, bool yes_no, int /*Style*
|
|||
#endif
|
||||
}
|
||||
|
||||
const char *wxStringTranslator(const char *text)
|
||||
{
|
||||
printf("passing through here\n");
|
||||
return std::string(wxString(wxGetTranslation(wxString::From8BitData(text))).To8BitData()).c_str();
|
||||
}
|
||||
|
||||
// Accessor for the main window class
|
||||
CFrame* DolphinApp::GetCFrame()
|
||||
{
|
||||
|
|
|
@ -294,7 +294,7 @@ void CMemcardManager::ChangePath(int slot)
|
|||
if (!strcasecmp(m_MemcardPath[slot2]->GetPath().mb_str(), m_MemcardPath[slot]->GetPath().mb_str()))
|
||||
{
|
||||
if(m_MemcardPath[slot]->GetPath().length())
|
||||
PanicAlert("%s", _wxt("Memcard already opened"));
|
||||
PanicAlertT("Memcard already opened");
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -420,7 +420,7 @@ bool CMemcardManager::CopyDeleteSwitch(u32 error, int slot)
|
|||
switch (error)
|
||||
{
|
||||
case GCS:
|
||||
SuccessAlert("%s", _wxt("File converted to .gci"));
|
||||
SuccessAlertT("File converted to .gci");
|
||||
break;
|
||||
case SUCCESS:
|
||||
if (slot != -1)
|
||||
|
@ -432,10 +432,10 @@ bool CMemcardManager::CopyDeleteSwitch(u32 error, int slot)
|
|||
}
|
||||
break;
|
||||
case NOMEMCARD:
|
||||
PanicAlert("%s", _wxt("File is not recognized as a memcard"));
|
||||
PanicAlertT("File is not recognized as a memcard");
|
||||
break;
|
||||
case OPENFAIL:
|
||||
PanicAlert("%s", _wxt("File could not be opened\nor does not have a valid extension"));
|
||||
PanicAlertT("File could not be opened\nor does not have a valid extension");
|
||||
break;
|
||||
case OUTOFBLOCKS:
|
||||
if (slot == -1)
|
||||
|
@ -443,39 +443,40 @@ bool CMemcardManager::CopyDeleteSwitch(u32 error, int slot)
|
|||
PanicAlert(E_UNK);
|
||||
break;
|
||||
}
|
||||
PanicAlert(_wxt("Only %d blocks available"), memoryCard[slot]->GetFreeBlocks());
|
||||
PanicAlertT("Only %d blocks available", memoryCard[slot]->GetFreeBlocks());
|
||||
break;
|
||||
case OUTOFDIRENTRIES:
|
||||
PanicAlert("%s", _wxt("No free dir index entries"));
|
||||
PanicAlertT("No free dir index entries");
|
||||
break;
|
||||
case LENGTHFAIL:
|
||||
PanicAlert("%s", _wxt("Imported file has invalid length"));
|
||||
PanicAlertT("Imported file has invalid length");
|
||||
break;
|
||||
case INVALIDFILESIZE:
|
||||
PanicAlert("%s", _wxt("The save you are trying to copy has an invalid file size"));
|
||||
PanicAlertT("The save you are trying to copy has an invalid file size");
|
||||
break;
|
||||
case TITLEPRESENT:
|
||||
PanicAlert("%s", _wxt("Memcard already has a save for this title"));
|
||||
PanicAlertT("Memcard already has a save for this title");
|
||||
break;
|
||||
case SAVFAIL:
|
||||
PanicAlert("%s", _wxt("Imported file has sav extension\nbut does not have a correct header"));
|
||||
PanicAlertT("Imported file has sav extension\nbut does not have a correct header");
|
||||
break;
|
||||
case GCSFAIL:
|
||||
PanicAlert("%s", _wxt("Imported file has gsc extension\nbut does not have a correct header"));
|
||||
PanicAlertT("Imported file has gsc extension\nbut does not have a correct header");
|
||||
break;
|
||||
case FAIL:
|
||||
if (slot == -1)
|
||||
{
|
||||
PanicAlert("%s", _wxt("Export Failed"));
|
||||
PanicAlertT("Export Failed");
|
||||
return false;
|
||||
}
|
||||
PanicAlert("%s", _wxt("Invalid bat.map or dir entry"));
|
||||
PanicAlertT("Invalid bat.map or dir entry");
|
||||
break;
|
||||
case WRITEFAIL:
|
||||
PanicAlert(E_SAVEFAILED);
|
||||
break;
|
||||
case DELETE_FAIL:
|
||||
PanicAlert("%s", _wxt("Order of files in the File Directory do not match the block order\nRight click and export all of the saves,\nand import the the saves to a new memcard\n"));
|
||||
PanicAlertT("Order of files in the File Directory do not match the block order\n"
|
||||
"Right click and export all of the saves,\nand import the the saves to a new memcard\n");
|
||||
break;
|
||||
default:
|
||||
PanicAlert(E_UNK);
|
||||
|
@ -513,7 +514,7 @@ void CMemcardManager::CopyDeleteClick(wxCommandEvent& event)
|
|||
case ID_FIXCHECKSUM_B:
|
||||
if (memoryCard[slot]->FixChecksums() && memoryCard[slot]->Save())
|
||||
{
|
||||
SuccessAlert("%s", _wxt("The checksum was successfully fixed"));
|
||||
SuccessAlertT("The checksum was successfully fixed");
|
||||
}
|
||||
else PanicAlert(E_SAVEFAILED);
|
||||
break;
|
||||
|
@ -586,7 +587,8 @@ void CMemcardManager::CopyDeleteClick(wxCommandEvent& event)
|
|||
SplitPath(mpath, &path1, &path2, NULL);
|
||||
path1 += path2;
|
||||
File::CreateDir(path1.c_str());
|
||||
if(PanicYesNo(_wxt("Warning: This will overwrite any existing saves that are in the folder:\n%s\nand have the same name as a file on your memcard\nContinue?"), path1.c_str()))
|
||||
if(PanicYesNoT("Warning: This will overwrite any existing saves that are in the folder:\n"
|
||||
"%s\nand have the same name as a file on your memcard\nContinue?", path1.c_str()))
|
||||
for (int i = 0; i < DIRLEN; i++)
|
||||
{
|
||||
CopyDeleteSwitch(memoryCard[slot]->ExportGci(i, ".", &path1), -1);
|
||||
|
|
|
@ -71,7 +71,7 @@ GCMemcard::GCMemcard(const char *filename)
|
|||
fail = false;
|
||||
if (!mcd)
|
||||
{
|
||||
if (!AskYesNo("\"%s\" does not exist.\n Create a new 16MB Memcard?", filename))
|
||||
if (!AskYesNoT("\"%s\" does not exist.\n Create a new 16MB Memcard?", filename))
|
||||
{
|
||||
fail = true;
|
||||
return;
|
||||
|
@ -83,7 +83,7 @@ GCMemcard::GCMemcard(const char *filename)
|
|||
return;
|
||||
}
|
||||
mcdFile = mcd;
|
||||
Format(!AskYesNo("Format as ascii (NTSC\\PAL)?\nChoose no for sjis (NTSC-J)"));
|
||||
Format(!AskYesNoT("Format as ascii (NTSC\\PAL)?\nChoose no for sjis (NTSC-J)"));
|
||||
fclose(mcd);
|
||||
mcd = fopen(filename, "r+b");
|
||||
}
|
||||
|
@ -95,7 +95,7 @@ GCMemcard::GCMemcard(const char *filename)
|
|||
if (strcasecmp(fileType.c_str(), ".raw") && strcasecmp(fileType.c_str(), ".gcp"))
|
||||
{
|
||||
fail = true;
|
||||
PanicAlert("File has the extension \"%s\"\nvalid extensions are (.raw/.gcp)", fileType.c_str());
|
||||
PanicAlertT("File has the extension \"%s\"\nvalid extensions are (.raw/.gcp)", fileType.c_str());
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
@ -104,31 +104,31 @@ GCMemcard::GCMemcard(const char *filename)
|
|||
if (fread(&hdr, 1, BLOCK_SIZE, mcd) != BLOCK_SIZE)
|
||||
{
|
||||
fail = true;
|
||||
PanicAlert("Failed to read header correctly\n(0x0000-0x1FFF)");
|
||||
PanicAlertT("Failed to read header correctly\n(0x0000-0x1FFF)");
|
||||
return;
|
||||
}
|
||||
if (fread(&dir, 1, BLOCK_SIZE, mcd) != BLOCK_SIZE)
|
||||
{
|
||||
fail = true;
|
||||
PanicAlert("Failed to read directory correctly\n(0x2000-0x3FFF)");
|
||||
PanicAlertT("Failed to read directory correctly\n(0x2000-0x3FFF)");
|
||||
return;
|
||||
}
|
||||
if (fread(&dir_backup, 1, BLOCK_SIZE, mcd) != BLOCK_SIZE)
|
||||
{
|
||||
fail = true;
|
||||
PanicAlert("Failed to read directory backup correctly\n(0x4000-0x5FFF)");
|
||||
PanicAlertT("Failed to read directory backup correctly\n(0x4000-0x5FFF)");
|
||||
return;
|
||||
}
|
||||
if (fread(&bat, 1, BLOCK_SIZE, mcd) != BLOCK_SIZE)
|
||||
{
|
||||
fail = true;
|
||||
PanicAlert("Failed to read block allocation table correctly\n(0x6000-0x7FFF)");
|
||||
PanicAlertT("Failed to read block allocation table correctly\n(0x6000-0x7FFF)");
|
||||
return;
|
||||
}
|
||||
if (fread(&bat_backup, 1, BLOCK_SIZE, mcd) != BLOCK_SIZE)
|
||||
{
|
||||
fail = true;
|
||||
PanicAlert("Failed to read block allocation table backup correctly\n(0x8000-0x9FFF)");
|
||||
PanicAlertT("Failed to read block allocation table backup correctly\n(0x8000-0x9FFF)");
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -139,7 +139,7 @@ GCMemcard::GCMemcard(const char *filename)
|
|||
// header checksum error!
|
||||
// invalid files do not always get here
|
||||
fail = true;
|
||||
PanicAlert("Header checksum failed");
|
||||
PanicAlertT("Header checksum failed");
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -149,7 +149,7 @@ GCMemcard::GCMemcard(const char *filename)
|
|||
{
|
||||
// backup is also wrong!
|
||||
fail = true;
|
||||
PanicAlert("Directory checksum failed\n and Directory backup checksum failed");
|
||||
PanicAlertT("Directory checksum failed\n and Directory backup checksum failed");
|
||||
return;
|
||||
}
|
||||
else
|
||||
|
@ -169,7 +169,7 @@ GCMemcard::GCMemcard(const char *filename)
|
|||
{
|
||||
// backup is also wrong!
|
||||
fail = true;
|
||||
PanicAlert("Block Allocation Table checksum failed");
|
||||
PanicAlertT("Block Allocation Table checksum failed");
|
||||
return;
|
||||
}
|
||||
else
|
||||
|
@ -211,13 +211,13 @@ GCMemcard::GCMemcard(const char *filename)
|
|||
if (mc_data_size != read)
|
||||
{
|
||||
fail = true;
|
||||
PanicAlert("Failed to read save data\n(0xA000-)\nMemcard may be truncated");
|
||||
PanicAlertT("Failed to read save data\n(0xA000-)\nMemcard may be truncated");
|
||||
}
|
||||
break;
|
||||
}
|
||||
default:
|
||||
fail = true;
|
||||
PanicAlert("Memcard failed to load\n Card size is invalid (%04X)", sizeMb);
|
||||
PanicAlertT("Memcard failed to load\n Card size is invalid (%04X)", sizeMb);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -54,10 +54,10 @@ CWiiSaveCrypted::CWiiSaveCrypted(const char* FileName, u64 title)
|
|||
// TODO: check_sig()
|
||||
if (b_valid)
|
||||
{
|
||||
SuccessAlert("Successfully imported save files");
|
||||
SuccessAlertT("Successfully imported save files");
|
||||
b_tryAgain = false;
|
||||
}
|
||||
else b_tryAgain = AskYesNo("Import failed, try again?");
|
||||
else b_tryAgain = AskYesNoT("Import failed, try again?");
|
||||
}while(b_tryAgain);
|
||||
}
|
||||
else
|
||||
|
@ -75,10 +75,10 @@ CWiiSaveCrypted::CWiiSaveCrypted(const char* FileName, u64 title)
|
|||
do_sig();
|
||||
if (b_valid)
|
||||
{
|
||||
SuccessAlert("Successfully exported file to %s", pathData_bin);
|
||||
SuccessAlertT("Successfully exported file to %s", pathData_bin);
|
||||
b_tryAgain = false;
|
||||
}
|
||||
else b_tryAgain = AskYesNo("Export failed, try again?");
|
||||
else b_tryAgain = AskYesNoT("Export failed, try again?");
|
||||
}while(b_tryAgain);
|
||||
}
|
||||
}
|
||||
|
@ -89,13 +89,13 @@ void CWiiSaveCrypted::ReadHDR()
|
|||
fpData_bin = fopen(pathData_bin, "rb");
|
||||
if (!fpData_bin)
|
||||
{
|
||||
PanicAlert("Cannot open %s", pathData_bin);
|
||||
PanicAlertT("Cannot open %s", pathData_bin);
|
||||
b_valid = false;
|
||||
return;
|
||||
}
|
||||
if (fread(&_encryptedHeader, HEADER_SZ, 1, fpData_bin) != 1)
|
||||
{
|
||||
PanicAlert("failed to read header");
|
||||
PanicAlertT("failed to read header");
|
||||
b_valid = false;
|
||||
return;
|
||||
}
|
||||
|
@ -106,7 +106,7 @@ void CWiiSaveCrypted::ReadHDR()
|
|||
if ((_bannerSize < FULL_BNR_MIN) || (_bannerSize > FULL_BNR_MAX) ||
|
||||
(((_bannerSize - BNR_SZ) % ICON_SZ) != 0))
|
||||
{
|
||||
PanicAlert("not a wii save or read failure for file header size %x", _bannerSize);
|
||||
PanicAlertT("not a wii save or read failure for file header size %x", _bannerSize);
|
||||
b_valid = false;
|
||||
return;
|
||||
}
|
||||
|
@ -117,7 +117,7 @@ void CWiiSaveCrypted::ReadHDR()
|
|||
md5((u8*)&_header, HEADER_SZ, md5_calc);
|
||||
if (memcmp(md5_file, md5_calc, 0x10))
|
||||
{
|
||||
PanicAlert("MD5 mismatch\n %016llx%016llx != %016llx%016llx", Common::swap64(md5_file),Common::swap64(md5_file+8), Common::swap64(md5_calc), Common::swap64(md5_calc+8));
|
||||
PanicAlertT("MD5 mismatch\n %016llx%016llx != %016llx%016llx", Common::swap64(md5_file),Common::swap64(md5_file+8), Common::swap64(md5_calc), Common::swap64(md5_calc+8));
|
||||
b_valid= false;
|
||||
}
|
||||
|
||||
|
@ -126,7 +126,7 @@ void CWiiSaveCrypted::ReadHDR()
|
|||
b_valid = false;
|
||||
return;
|
||||
}
|
||||
if (!File::Exists(pathBanner_bin) || AskYesNo("%s already exists, overwrite?", pathBanner_bin))
|
||||
if (!File::Exists(pathBanner_bin) || AskYesNoT("%s already exists, overwrite?", pathBanner_bin))
|
||||
{
|
||||
INFO_LOG(CONSOLE, "creating file %s", pathBanner_bin);
|
||||
fpBanner_bin = fopen(pathBanner_bin, "wb");
|
||||
|
@ -154,7 +154,7 @@ void CWiiSaveCrypted::WriteHDR()
|
|||
{
|
||||
if (fread(_header.BNR, Common::swap32(_header.hdr.BannerSize), 1, fpBanner_bin) != 1)
|
||||
{
|
||||
PanicAlert("Failed to read banner.bin");
|
||||
PanicAlertT("Failed to read banner.bin");
|
||||
b_valid = false;
|
||||
return;
|
||||
}
|
||||
|
@ -170,7 +170,7 @@ void CWiiSaveCrypted::WriteHDR()
|
|||
{
|
||||
if (fwrite(&_encryptedHeader, HEADER_SZ, 1, fpData_bin) != 1)
|
||||
{
|
||||
PanicAlert("Failed to write header for %s", pathData_bin);
|
||||
PanicAlertT("Failed to write header for %s", pathData_bin);
|
||||
b_valid = false;
|
||||
}
|
||||
fclose(fpData_bin);
|
||||
|
@ -186,14 +186,14 @@ void CWiiSaveCrypted::ReadBKHDR()
|
|||
fpData_bin = fopen(pathData_bin, "rb");
|
||||
if (!fpData_bin)
|
||||
{
|
||||
PanicAlert("Cannot open %s", pathData_bin);
|
||||
PanicAlertT("Cannot open %s", pathData_bin);
|
||||
b_valid = false;
|
||||
return;
|
||||
}
|
||||
fseeko(fpData_bin, HEADER_SZ, SEEK_SET);
|
||||
if (fread(&bkhdr, BK_SZ, 1, fpData_bin) != 1)
|
||||
{
|
||||
PanicAlert("failed to read bk header");
|
||||
PanicAlertT("failed to read bk header");
|
||||
b_valid = false;
|
||||
return;
|
||||
}
|
||||
|
@ -202,7 +202,7 @@ void CWiiSaveCrypted::ReadBKHDR()
|
|||
if (bkhdr.size != Common::swap32(BK_LISTED_SZ) ||
|
||||
bkhdr.magic != Common::swap32(BK_HDR_MAGIC))
|
||||
{
|
||||
PanicAlert("Invalid Size(%x) or Magic word (%x)", bkhdr.size, bkhdr.magic);
|
||||
PanicAlertT("Invalid Size(%x) or Magic word (%x)", bkhdr.size, bkhdr.magic);
|
||||
b_valid = false;
|
||||
return;
|
||||
}
|
||||
|
@ -246,7 +246,7 @@ void CWiiSaveCrypted::WriteBKHDR()
|
|||
{
|
||||
if (fwrite(&bkhdr, BK_SZ, 1, fpData_bin) != 1)
|
||||
{
|
||||
PanicAlert("Failed to write bkhdr");
|
||||
PanicAlertT("Failed to write bkhdr");
|
||||
b_valid = false;
|
||||
}
|
||||
fclose(fpData_bin);
|
||||
|
@ -260,7 +260,7 @@ void CWiiSaveCrypted::ImportWiiSaveFiles()
|
|||
fpData_bin = fopen(pathData_bin, "rb");
|
||||
if (!fpData_bin)
|
||||
{
|
||||
PanicAlert("Cannot open %s", pathData_bin);
|
||||
PanicAlertT("Cannot open %s", pathData_bin);
|
||||
b_valid = false;
|
||||
return;
|
||||
}
|
||||
|
@ -279,14 +279,14 @@ void CWiiSaveCrypted::ImportWiiSaveFiles()
|
|||
|
||||
if (fread(&_tmpFileHDR, FILE_HDR_SZ, 1, fpData_bin) != 1)
|
||||
{
|
||||
PanicAlert("Failed to write header for file %d", i);
|
||||
PanicAlertT("Failed to write header for file %d", i);
|
||||
b_valid = false;
|
||||
}
|
||||
|
||||
lastpos += FILE_HDR_SZ;
|
||||
if(Common::swap32(_tmpFileHDR.magic) != FILE_HDR_MAGIC)
|
||||
{
|
||||
PanicAlert("Bad File Header");
|
||||
PanicAlertT("Bad File Header");
|
||||
break;
|
||||
}
|
||||
else
|
||||
|
@ -308,7 +308,7 @@ void CWiiSaveCrypted::ImportWiiSaveFiles()
|
|||
_data = new u8[_fileSize];
|
||||
if (fread(_encryptedData, _fileSize, 1, fpData_bin) != 1)
|
||||
{
|
||||
PanicAlert("Failed to read data from file %d", i);
|
||||
PanicAlertT("Failed to read data from file %d", i);
|
||||
b_valid = false;
|
||||
break;
|
||||
}
|
||||
|
@ -318,7 +318,7 @@ void CWiiSaveCrypted::ImportWiiSaveFiles()
|
|||
AES_cbc_encrypt((const unsigned char *)_encryptedData, _data, _fileSize, &m_AES_KEY, IV, AES_DECRYPT);
|
||||
delete []_encryptedData;
|
||||
|
||||
if (!File::Exists(pathRawSave) || AskYesNo("%s already exists, overwrite?", pathRawSave))
|
||||
if (!File::Exists(pathRawSave) || AskYesNoT("%s already exists, overwrite?", pathRawSave))
|
||||
{
|
||||
INFO_LOG(CONSOLE, "creating file %s", pathRawSave);
|
||||
|
||||
|
@ -375,7 +375,7 @@ void CWiiSaveCrypted::ExportWiiSaveFiles()
|
|||
|
||||
if (__name.length() > 0x44)
|
||||
{
|
||||
PanicAlert("%s is too long for the filename, max chars is 45", __name.c_str());
|
||||
PanicAlertT("%s is too long for the filename, max chars is 45", __name.c_str());
|
||||
b_valid = false;
|
||||
return;
|
||||
}
|
||||
|
@ -392,14 +392,14 @@ void CWiiSaveCrypted::ExportWiiSaveFiles()
|
|||
{
|
||||
if (_fileSize == 0)
|
||||
{
|
||||
PanicAlert("%s is a 0 byte file", FilesList.at(i).c_str());
|
||||
PanicAlertT("%s is a 0 byte file", FilesList.at(i).c_str());
|
||||
b_valid = false;
|
||||
return;
|
||||
}
|
||||
fpRawSaveFile = fopen(FilesList.at(i).c_str(), "rb");
|
||||
if (!fpRawSaveFile)
|
||||
{
|
||||
PanicAlert("%s failed to open", FilesList.at(i).c_str());
|
||||
PanicAlertT("%s failed to open", FilesList.at(i).c_str());
|
||||
b_valid = false;
|
||||
}
|
||||
__data = new u8[_roundedfileSize];
|
||||
|
@ -407,7 +407,7 @@ void CWiiSaveCrypted::ExportWiiSaveFiles()
|
|||
memset(__data, 0, _roundedfileSize);
|
||||
if (fread(__data, _fileSize, 1, fpRawSaveFile) != 1)
|
||||
{
|
||||
PanicAlert("failed to read data from file: %s", FilesList.at(i).c_str());
|
||||
PanicAlertT("failed to read data from file: %s", FilesList.at(i).c_str());
|
||||
b_valid = false;
|
||||
}
|
||||
fclose(fpRawSaveFile);
|
||||
|
@ -530,14 +530,14 @@ bool CWiiSaveCrypted::getPaths(bool forExport)
|
|||
if(!File::IsDirectory(pathSavedir))
|
||||
{
|
||||
b_valid = false;
|
||||
PanicAlert("No save folder found for title %s", _saveGameString);
|
||||
PanicAlertT("No save folder found for title %s", _saveGameString);
|
||||
return false;
|
||||
}
|
||||
|
||||
if(!File::Exists(pathBanner_bin))
|
||||
{
|
||||
b_valid = false;
|
||||
PanicAlert("No banner file found for title %s", _saveGameString);
|
||||
PanicAlertT("No banner file found for title %s", _saveGameString);
|
||||
return false;
|
||||
}
|
||||
if (strlen(pathData_bin) == 0)
|
||||
|
@ -548,7 +548,7 @@ bool CWiiSaveCrypted::getPaths(bool forExport)
|
|||
else
|
||||
{
|
||||
File::CreateFullPath(pathSavedir);
|
||||
if (!AskYesNo("Warning! it is advised to backup all files in the folder:\n%s\nDo you wish to continue?", pathSavedir))
|
||||
if (!AskYesNoT("Warning! it is advised to backup all files in the folder:\n%s\nDo you wish to continue?", pathSavedir))
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
|
|
|
@ -258,7 +258,7 @@ bool NetPlay::StartGame(const std::string &path)
|
|||
{
|
||||
if (m_is_running)
|
||||
{
|
||||
PanicAlert("%s", _wxt("Game is already running!"));
|
||||
PanicAlertT("Game is already running!");
|
||||
return false;
|
||||
}
|
||||
|
||||
|
@ -288,7 +288,7 @@ bool NetPlay::StopGame()
|
|||
|
||||
if (false == m_is_running)
|
||||
{
|
||||
PanicAlert("%s", _wxt("Game isn't running!"));
|
||||
PanicAlertT("Game isn't running!");
|
||||
return false;
|
||||
}
|
||||
|
||||
|
|
|
@ -40,16 +40,16 @@ NetPlayClient::NetPlayClient(const std::string& address, const u16 port, const s
|
|||
switch (error)
|
||||
{
|
||||
case CON_ERR_SERVER_FULL :
|
||||
PanicAlert("%s", _wxt("The server is full!"));
|
||||
PanicAlertT("The server is full!");
|
||||
break;
|
||||
case CON_ERR_VERSION_MISMATCH :
|
||||
PanicAlert("%s", _wxt("The server and client's NetPlay versions are incompatible!"));
|
||||
PanicAlertT("The server and client's NetPlay versions are incompatible!");
|
||||
break;
|
||||
case CON_ERR_GAME_RUNNING :
|
||||
PanicAlert("%s", _wxt("The server responded: the game is currently running!"));
|
||||
PanicAlertT("The server responded: the game is currently running!");
|
||||
break;
|
||||
default :
|
||||
PanicAlert("%s", _wxt("The server sent an unknown error message!"));
|
||||
PanicAlertT("The server sent an unknown error message!");
|
||||
break;
|
||||
}
|
||||
m_socket.Close();
|
||||
|
@ -69,7 +69,7 @@ NetPlayClient::NetPlayClient(const std::string& address, const u16 port, const s
|
|||
|
||||
UpdateGUI();
|
||||
|
||||
//PanicAlert("Connection successful: assigned player id: %d", m_pid);
|
||||
//PanicAlertT("Connection successful: assigned player id: %d", m_pid);
|
||||
is_connected = true;
|
||||
|
||||
m_selector.Add(m_socket);
|
||||
|
@ -77,7 +77,7 @@ NetPlayClient::NetPlayClient(const std::string& address, const u16 port, const s
|
|||
}
|
||||
}
|
||||
else
|
||||
PanicAlert("%s", _wxt("Failed to Connect!"));
|
||||
PanicAlertT("Failed to Connect!");
|
||||
|
||||
}
|
||||
|
||||
|
@ -207,7 +207,7 @@ unsigned int NetPlayClient::OnData(sf::Packet& packet)
|
|||
|
||||
case NP_MSG_DISABLE_GAME :
|
||||
{
|
||||
PanicAlert("%s", _wxt("Other client disconnected while game is running!! NetPlay is disabled. You manually stop the game."));
|
||||
PanicAlertT("Other client disconnected while game is running!! NetPlay is disabled. You manually stop the game.");
|
||||
CritLocker game_lock(m_crit.game); // lock game state
|
||||
m_is_running = false;
|
||||
NetPlay_Disable();
|
||||
|
@ -229,7 +229,7 @@ unsigned int NetPlayClient::OnData(sf::Packet& packet)
|
|||
break;
|
||||
|
||||
default :
|
||||
PanicAlert(_wxt("Unknown message received with id : %d"), mid);
|
||||
PanicAlertT("Unknown message received with id : %d", mid);
|
||||
break;
|
||||
|
||||
}
|
||||
|
@ -256,7 +256,7 @@ void NetPlayClient::Entry()
|
|||
m_is_running = false;
|
||||
NetPlay_Disable();
|
||||
AppendChatGUI("< LOST CONNECTION TO SERVER >");
|
||||
PanicAlert("%s", _wxt("Lost connection to server!"));
|
||||
PanicAlertT("Lost connection to server!");
|
||||
m_do_loop = false;
|
||||
break;
|
||||
}
|
||||
|
|
|
@ -34,7 +34,7 @@ NetPlayServer::NetPlayServer(const u16 port, const std::string& name, NetPlayDia
|
|||
// add self to player list
|
||||
m_players[m_socket] = player;
|
||||
m_local_player = &m_players[m_socket];
|
||||
//PanicAlert("Listening");
|
||||
//PanicAlertT("Listening");
|
||||
|
||||
UpdateGUI();
|
||||
|
||||
|
@ -55,7 +55,7 @@ void NetPlayServer::Entry()
|
|||
// update pings every so many seconds
|
||||
if ((m_ping_timer.GetTimeElapsed() > (10 * 1000)) || m_update_pings)
|
||||
{
|
||||
//PanicAlert("sending pings");
|
||||
//PanicAlertT("sending pings");
|
||||
|
||||
m_ping_key = Common::Timer::GetTimeMs();
|
||||
|
||||
|
@ -257,7 +257,7 @@ unsigned int NetPlayServer::OnDisconnect(sf::SocketTCP& socket)
|
|||
{
|
||||
if (m_is_running)
|
||||
{
|
||||
PanicAlert("%s", _wxt("Client disconnect while game is running!! NetPlay is disabled. You must manually stop the game."));
|
||||
PanicAlertT("Client disconnect while game is running!! NetPlay is disabled. You must manually stop the game.");
|
||||
CritLocker game_lock(m_crit.game); // lock game state
|
||||
m_is_running = false;
|
||||
NetPlay_Disable();
|
||||
|
@ -487,7 +487,7 @@ unsigned int NetPlayServer::OnData(sf::Packet& packet, sf::SocketTCP& socket)
|
|||
|
||||
if (m_ping_key == ping_key)
|
||||
{
|
||||
//PanicAlert("good pong");
|
||||
//PanicAlertT("good pong");
|
||||
player.ping = ping;
|
||||
}
|
||||
UpdateGUI();
|
||||
|
@ -501,7 +501,7 @@ unsigned int NetPlayServer::OnData(sf::Packet& packet, sf::SocketTCP& socket)
|
|||
break;
|
||||
|
||||
default :
|
||||
PanicAlert(_wxt("Unknown message with id:%d received from player:%d Kicking player!"), mid, player.pid);
|
||||
PanicAlertT("Unknown message with id:%d received from player:%d Kicking player!", mid, player.pid);
|
||||
// unknown message, kick the client
|
||||
return 1;
|
||||
break;
|
||||
|
|
|
@ -174,13 +174,13 @@ void NetPlaySetupDiag::OnHost(wxCommandEvent&)
|
|||
{
|
||||
if (::netplay_ptr)
|
||||
{
|
||||
PanicAlert("%s", _wxt("A NetPlay window is already open!!"));
|
||||
PanicAlertT("A NetPlay window is already open!!");
|
||||
return;
|
||||
}
|
||||
|
||||
if (-1 == m_game_lbox->GetSelection())
|
||||
{
|
||||
PanicAlert("%s", _wxt("You must choose a game!!"));
|
||||
PanicAlertT("You must choose a game!!");
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -199,7 +199,7 @@ void NetPlaySetupDiag::OnHost(wxCommandEvent&)
|
|||
}
|
||||
else
|
||||
{
|
||||
PanicAlert("%s", _wxt("Failed to Listen!!"));
|
||||
PanicAlertT("Failed to Listen!!");
|
||||
npd->Destroy();
|
||||
// dialog will delete netplay
|
||||
//delete ::netplay_ptr;
|
||||
|
@ -210,7 +210,7 @@ void NetPlaySetupDiag::OnJoin(wxCommandEvent&)
|
|||
{
|
||||
if (::netplay_ptr)
|
||||
{
|
||||
PanicAlert("%s", _wxt("A NetPlay window is already open!!"));
|
||||
PanicAlertT("A NetPlay window is already open!!");
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -227,7 +227,7 @@ void NetPlaySetupDiag::OnJoin(wxCommandEvent&)
|
|||
}
|
||||
else
|
||||
{
|
||||
//PanicAlert("Failed to Connect!!");
|
||||
//PanicAlertT("Failed to Connect!!");
|
||||
npd->Destroy();
|
||||
// dialog will delete netplay
|
||||
//delete ::netplay_ptr;
|
||||
|
@ -373,7 +373,7 @@ void NetPlayDiag::OnStart(wxCommandEvent&)
|
|||
if (path.length())
|
||||
::netplay_ptr->StartGame(path);
|
||||
else
|
||||
PanicAlert("%s", _wxt("Game not found!!"));
|
||||
PanicAlertT("Game not found!!");
|
||||
}
|
||||
|
||||
void NetPlayDiag::OnStop(wxCommandEvent&)
|
||||
|
@ -492,7 +492,8 @@ void NetPlayDiag::OnConfigPads(wxCommandEvent&)
|
|||
pmd->Destroy();
|
||||
|
||||
if (false == ((NetPlayServer*)::netplay_ptr)->SetPadMapping(pid, mapping))
|
||||
PanicAlert("%s", _wxt("Could not set pads. The player left or the game is currently running!\n(setting pads while the game is running is not yet supported)"));
|
||||
PanicAlertT("Could not set pads. The player left or the game is currently running!\n"
|
||||
"(setting pads while the game is running is not yet supported)");
|
||||
}
|
||||
|
||||
ChangeGameDiag::ChangeGameDiag(wxWindow* const parent, const CGameListCtrl* const game_list, wxString& game_name)
|
||||
|
|
|
@ -110,12 +110,13 @@ void WiimoteConfigDiag::PairUpRealWiimotes(wxCommandEvent&)
|
|||
if (paired > 0)
|
||||
{
|
||||
// Will this message be anoying?
|
||||
//PanicAlert("Paired %d wiimotes.", paired);
|
||||
//PanicAlertT("Paired %d wiimotes.", paired);
|
||||
WiimoteReal::Refresh();
|
||||
UpdateGUI();
|
||||
}
|
||||
else if (paired < 0)
|
||||
PanicAlert("%s", _wxt("A supported bluetooth device was not found!\n(Only the Microsoft bluetooth stack is supported.)"));
|
||||
PanicAlertT("A supported bluetooth device was not found!\n"
|
||||
"(Only the Microsoft bluetooth stack is supported.)");
|
||||
}
|
||||
#endif
|
||||
|
||||
|
|
|
@ -68,7 +68,7 @@ bool AVIDump::CreateFile()
|
|||
// Ask to delete file
|
||||
if (File::Exists(movie_file_name))
|
||||
{
|
||||
if (AskYesNo("Delete the existing file '%s'?", movie_file_name))
|
||||
if (AskYesNoT("Delete the existing file '%s'?", movie_file_name))
|
||||
File::Delete(movie_file_name);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue