s/throw RageException/RageException::Throw/

This commit is contained in:
Glenn Maynard
2002-12-21 19:34:02 +00:00
parent a3c6b12981
commit 49f05c9ab8
16 changed files with 38 additions and 42 deletions
-5
View File
@@ -1296,11 +1296,6 @@ RageColor GameManager::GetMetricC( CString sClassName, CString sValueName )
return RageColor(r,g,b,a); return RageColor(r,g,b,a);
} }
__declspec(noreturn) void blah()
{
}
CString GameManager::GetPathTo( const int col, CString sElementName ) // looks in GAMESTATE for the current Style CString GameManager::GetPathTo( const int col, CString sElementName ) // looks in GAMESTATE for the current Style
{ {
const StyleDef* pStyleDef = GAMESTATE->GetCurrentStyleDef(); const StyleDef* pStyleDef = GAMESTATE->GetCurrentStyleDef();
+1 -1
View File
@@ -38,7 +38,7 @@ void GrayArrowRow::Load( PlayerNumber pn )
CString sPath = GAMEMAN->GetPathTo(c, "receptor"); CString sPath = GAMEMAN->GetPathTo(c, "receptor");
m_GrayArrow[c].Load( sPath ); m_GrayArrow[c].Load( sPath );
if( m_GrayArrow[c].GetNumStates() != 2 ) if( m_GrayArrow[c].GetNumStates() != 2 )
throw RageException( "'%s' must have two frames", sPath.GetString() ); RageException::Throw( "'%s' must have two frames", sPath.GetString() );
m_GrayArrow[c].SetX( pStyleDef->m_ColumnInfo[pn][c].fXOffset ); m_GrayArrow[c].SetX( pStyleDef->m_ColumnInfo[pn][c].fXOffset );
} }
} }
+1 -1
View File
@@ -617,7 +617,7 @@ void NoteDataUtil::LoadFromSMNoteDataString( NoteData &out, CString sSMNoteData
const int iIndex = BeatToNoteRow( fBeat ); const int iIndex = BeatToNoteRow( fBeat );
// if( m_iNumTracks != sMeasureLine.GetLength() ) // if( m_iNumTracks != sMeasureLine.GetLength() )
// throw RageException( "Actual number of note columns (%d) is different from the NotesType (%d).", m_iNumTracks, sMeasureLine.GetLength() ); // RageException::Throw( "Actual number of note columns (%d) is different from the NotesType (%d).", m_iNumTracks, sMeasureLine.GetLength() );
for( int c=0; c<min(sMeasureLine.GetLength(),out.m_iNumTracks); c++ ) for( int c=0; c<min(sMeasureLine.GetLength(),out.m_iNumTracks); c++ )
{ {
+3 -3
View File
@@ -46,14 +46,14 @@ void NoteDisplay::Load( int iColNum, PlayerNumber pn )
CString sTapPartsPath = GAMEMAN->GetPathTo(iColNum, "tap parts"); CString sTapPartsPath = GAMEMAN->GetPathTo(iColNum, "tap parts");
m_sprTapParts.Load( sTapPartsPath ); m_sprTapParts.Load( sTapPartsPath );
if( m_sprTapParts.GetNumStates() % 2 != 0 ) if( m_sprTapParts.GetNumStates() % 2 != 0 )
throw RageException( "Tap Parts '%s' must have an even number of frames.", sTapPartsPath.GetString() ); RageException::Throw( "Tap Parts '%s' must have an even number of frames.", sTapPartsPath.GetString() );
m_sprTapParts.StopAnimating(); m_sprTapParts.StopAnimating();
m_sprTapParts.TurnShadowOff(); m_sprTapParts.TurnShadowOff();
CString sHoldPartsPath = GAMEMAN->GetPathTo(iColNum, "hold parts"); CString sHoldPartsPath = GAMEMAN->GetPathTo(iColNum, "hold parts");
m_sprHoldParts.Load( sHoldPartsPath ); m_sprHoldParts.Load( sHoldPartsPath );
if( m_sprHoldParts.GetTexture()->GetFramesWide() != 4 || m_sprHoldParts.GetTexture()->GetFramesHigh() != 2 ) if( m_sprHoldParts.GetTexture()->GetFramesWide() != 4 || m_sprHoldParts.GetTexture()->GetFramesHigh() != 2 )
throw RageException( "Hold Parts '%s' must have 4x2 frames.", sHoldPartsPath.GetString() ); RageException::Throw( "Hold Parts '%s' must have 4x2 frames.", sHoldPartsPath.GetString() );
m_sprHoldParts.StopAnimating(); m_sprHoldParts.StopAnimating();
m_sprHoldParts.TurnShadowOff(); m_sprHoldParts.TurnShadowOff();
@@ -62,7 +62,7 @@ void NoteDisplay::Load( int iColNum, PlayerNumber pn )
const CString sColorsFilePath = GAMEMAN->GetPathTo( iColNum, "Tap.colors" ); const CString sColorsFilePath = GAMEMAN->GetPathTo( iColNum, "Tap.colors" );
FILE* fp = fopen( sColorsFilePath, "r" ); FILE* fp = fopen( sColorsFilePath, "r" );
if( fp == NULL ) if( fp == NULL )
throw RageException( "Couldn't open .colors file '%s'", sColorsFilePath.GetString() ); RageException::Throw( "Couldn't open .colors file '%s'", sColorsFilePath.GetString() );
bool bSuccess; bool bSuccess;
do do
+2 -2
View File
@@ -130,7 +130,7 @@ void RageBitmapTexture::Create()
/* XXX: Wait, we don't want to throw for all images; in particular, we /* XXX: Wait, we don't want to throw for all images; in particular, we
* want to tolerate corrupt/unknown background images. */ * want to tolerate corrupt/unknown background images. */
if(img == NULL) if(img == NULL)
throw RageException( "Couldn't load %s: %s", m_sFilePath, SDL_GetError() ); RageException::Throw( "Couldn't load %s: %s", m_sFilePath, SDL_GetError() );
/* Figure out which texture format to use. */ /* Figure out which texture format to use. */
GLenum fmtTexture; GLenum fmtTexture;
@@ -167,7 +167,7 @@ void RageBitmapTexture::Create()
else if( TEXTUREMAN->GetTextureColorDepth() == 32 ) else if( TEXTUREMAN->GetTextureColorDepth() == 32 )
fmtTexture = GL_RGBA8; fmtTexture = GL_RGBA8;
else else
throw RageException( "Invalid color depth: %d bits", TEXTUREMAN->GetTextureColorDepth() ); RageException::Throw( "Invalid color depth: %d bits", TEXTUREMAN->GetTextureColorDepth() );
/* Cap the max texture size to the hardware max. */ /* Cap the max texture size to the hardware max. */
m_prefs.iMaxSize = min( m_prefs.iMaxSize, DISPLAY->GetMaxTextureSize() ); m_prefs.iMaxSize = min( m_prefs.iMaxSize, DISPLAY->GetMaxTextureSize() );
+1 -1
View File
@@ -235,7 +235,7 @@ bool RageDisplay::SetVideoMode( bool windowed, int width, int height, int bpp, i
if(!g_screen || need_reload) { if(!g_screen || need_reload) {
g_screen = SDL_SetVideoMode(width, height, bpp, g_flags); g_screen = SDL_SetVideoMode(width, height, bpp, g_flags);
if(!g_screen) if(!g_screen)
throw RageException("SDL_SetVideoMode failed: %s", SDL_GetError()); RageException::Throw("SDL_SetVideoMode failed: %s", SDL_GetError());
SDL_WM_SetCaption("StepMania", "StepMania"); SDL_WM_SetCaption("StepMania", "StepMania");
} }
+12 -12
View File
@@ -125,7 +125,7 @@ void HandleDivXError()
/* Actually, we might need XviD; we might want to look /* Actually, we might need XviD; we might want to look
* at the file and try to figure out if it's something * at the file and try to figure out if it's something
* common: DIV3, DIV4, DIV5, XVID, or maybe even MPEG2. */ * common: DIV3, DIV4, DIV5, XVID, or maybe even MPEG2. */
throw RageException( RageException::Throw(
"Could not locate the DivX video codec.\n" "Could not locate the DivX video codec.\n"
"DivX is required to movie textures and must\n" "DivX is required to movie textures and must\n"
"be installed before running the application.\n\n" "be installed before running the application.\n\n"
@@ -138,11 +138,11 @@ void RageMovieTexture::Create()
HRESULT hr; HRESULT hr;
if( FAILED( hr=CoInitialize(NULL) ) ) if( FAILED( hr=CoInitialize(NULL) ) )
throw RageException( hr_ssprintf(hr, "Could not CoInitialize") ); RageException::Throw( hr_ssprintf(hr, "Could not CoInitialize") );
// Create the filter graph // Create the filter graph
if( FAILED( hr=m_pGB.CoCreateInstance(CLSID_FilterGraph, NULL, CLSCTX_INPROC) ) ) if( FAILED( hr=m_pGB.CoCreateInstance(CLSID_FilterGraph, NULL, CLSCTX_INPROC) ) )
throw RageException( hr_ssprintf(hr, "Could not create CLSID_FilterGraph!") ); RageException::Throw( hr_ssprintf(hr, "Could not create CLSID_FilterGraph!") );
// Create the Texture Renderer object // Create the Texture Renderer object
CTextureRenderer *pCTR = new CTextureRenderer; CTextureRenderer *pCTR = new CTextureRenderer;
@@ -151,7 +151,7 @@ void RageMovieTexture::Create()
* graph. When m_pGB is released, it will free pFTR. */ * graph. When m_pGB is released, it will free pFTR. */
CComPtr<IBaseFilter> pFTR = pCTR; CComPtr<IBaseFilter> pFTR = pCTR;
if( FAILED( hr = m_pGB->AddFilter(pFTR, L"TEXTURERENDERER" ) ) ) if( FAILED( hr = m_pGB->AddFilter(pFTR, L"TEXTURERENDERER" ) ) )
throw RageException( hr_ssprintf(hr, "Could not add renderer filter to graph!") ); RageException::Throw( hr_ssprintf(hr, "Could not add renderer filter to graph!") );
// Add the source filter // Add the source filter
CComPtr<IBaseFilter> pFSrc; // Source Filter CComPtr<IBaseFilter> pFSrc; // Source Filter
@@ -162,23 +162,23 @@ void RageMovieTexture::Create()
if( FAILED( hr = m_pGB->AddSourceFilter( wFileName, L"SOURCE", &pFSrc ) ) ) if( FAILED( hr = m_pGB->AddSourceFilter( wFileName, L"SOURCE", &pFSrc ) ) )
{ {
HandleDivXError(); HandleDivXError();
throw RageException( hr_ssprintf(hr, "Could not create source filter to graph!") ); RageException::Throw( hr_ssprintf(hr, "Could not create source filter to graph!") );
} }
// Find the source's output and the renderer's input // Find the source's output and the renderer's input
CComPtr<IPin> pFTRPinIn; // Texture Renderer Input Pin CComPtr<IPin> pFTRPinIn; // Texture Renderer Input Pin
if( FAILED( hr = pFTR->FindPin( L"In", &pFTRPinIn ) ) ) if( FAILED( hr = pFTR->FindPin( L"In", &pFTRPinIn ) ) )
throw RageException( hr_ssprintf(hr, "Could not find input pin!") ); RageException::Throw( hr_ssprintf(hr, "Could not find input pin!") );
CComPtr<IPin> pFSrcPinOut; // Source Filter Output Pin CComPtr<IPin> pFSrcPinOut; // Source Filter Output Pin
if( FAILED( hr = pFSrc->FindPin( L"Output", &pFSrcPinOut ) ) ) if( FAILED( hr = pFSrc->FindPin( L"Output", &pFSrcPinOut ) ) )
throw RageException( hr_ssprintf(hr, "Could not find output pin!") ); RageException::Throw( hr_ssprintf(hr, "Could not find output pin!") );
// Connect these two filters // Connect these two filters
if( FAILED( hr = m_pGB->Connect( pFSrcPinOut, pFTRPinIn ) ) ) if( FAILED( hr = m_pGB->Connect( pFSrcPinOut, pFTRPinIn ) ) )
{ {
HandleDivXError(); HandleDivXError();
throw RageException( hr_ssprintf(hr, "Could not connect pins!") ); RageException::Throw( hr_ssprintf(hr, "Could not connect pins!") );
} }
// Pass us to our TextureRenderer. // Pass us to our TextureRenderer.
@@ -195,7 +195,7 @@ void RageMovieTexture::Create()
// Start the graph running // Start the graph running
if( !PlayMovie() ) if( !PlayMovie() )
throw RageException( "Could not run the DirectShow graph." ); RageException::Throw( "Could not run the DirectShow graph." );
} }
void RageMovieTexture::NewData(char *data) void RageMovieTexture::NewData(char *data)
@@ -238,7 +238,7 @@ bool RageMovieTexture::PlayMovie()
// Start the graph running; // Start the graph running;
HRESULT hr; HRESULT hr;
if( FAILED( hr = pMC->Run() ) ) if( FAILED( hr = pMC->Run() ) )
throw RageException( hr_ssprintf(hr, "Could not run the DirectShow graph.") ); RageException::Throw( hr_ssprintf(hr, "Could not run the DirectShow graph.") );
m_bPlaying = true; m_bPlaying = true;
@@ -275,7 +275,7 @@ void RageMovieTexture::Pause()
HRESULT hr; HRESULT hr;
if( FAILED( hr = pMC->Pause() ) ) if( FAILED( hr = pMC->Pause() ) )
throw RageException( hr_ssprintf(hr, "Could not pause the DirectShow graph.") ); RageException::Throw( hr_ssprintf(hr, "Could not pause the DirectShow graph.") );
} }
void RageMovieTexture::Stop() void RageMovieTexture::Stop()
@@ -285,7 +285,7 @@ void RageMovieTexture::Stop()
HRESULT hr; HRESULT hr;
if( FAILED( hr = pMC->Stop() ) ) if( FAILED( hr = pMC->Stop() ) )
throw RageException( hr_ssprintf(hr, "Could not stop the DirectShow graph.") ); RageException::Throw( hr_ssprintf(hr, "Could not stop the DirectShow graph.") );
m_bPlaying = false; m_bPlaying = false;
} }
+1 -1
View File
@@ -15,7 +15,7 @@ CTextureRenderer::CTextureRenderer()
NAME("Texture Renderer"), NULL, &CBV_ret) NAME("Texture Renderer"), NULL, &CBV_ret)
{ {
if( FAILED(CBV_ret) ) if( FAILED(CBV_ret) )
throw RageException( hr_ssprintf(CBV_ret, "Could not create texture renderer object!") ); RageException::Throw( hr_ssprintf(CBV_ret, "Could not create texture renderer object!") );
// Store and ARageef the texture for our use. // Store and ARageef the texture for our use.
m_pTexture = NULL; m_pTexture = NULL;
+3 -2
View File
@@ -50,12 +50,12 @@ RageNetworkClient::RageNetworkClient()
// SDL_Init(0); // this may have already been init'd somewhere else // SDL_Init(0); // this may have already been init'd somewhere else
if( SDLNet_Init() < 0 ) if( SDLNet_Init() < 0 )
throw RageException("SDLNet_Init: %s\n", SDLNet_GetError()); RageException::Throw("SDLNet_Init: %s\n", SDLNet_GetError());
// allocate socket sets // allocate socket sets
m_priSockSet = SDLNet_AllocSocketSet(1); m_priSockSet = SDLNet_AllocSocketSet(1);
if(!m_priSockSet) if(!m_priSockSet)
throw RageException("SDLNet_AllocSocketSet: %s\n", SDLNet_GetError()); RageException::Throw("SDLNet_AllocSocketSet: %s\n", SDLNet_GetError());
} }
RageNetworkClient::~RageNetworkClient() RageNetworkClient::~RageNetworkClient()
@@ -108,6 +108,7 @@ void RageNetworkClient::Update( float fDeltaTime )
int numready = SDLNet_CheckSockets(m_priSockSet, 0); int numready = SDLNet_CheckSockets(m_priSockSet, 0);
if(numready==-1) if(numready==-1)
{ {
// XXX sorry, this was really noisy ... - glenn
// LOG->Warn("SDLNet_CheckSockets: %s\n", SDLNet_GetError()); // LOG->Warn("SDLNet_CheckSockets: %s\n", SDLNet_GetError());
} }
else if( numready ) else if( numready )
+1 -1
View File
@@ -17,7 +17,7 @@ RageSoundManager::RageSoundManager(CString drivers)
{ {
driver = MakeRageSoundDriver(drivers); driver = MakeRageSoundDriver(drivers);
if(!driver) if(!driver)
throw RageException("Couldn't find a sound driver that works"); RageException::Throw("Couldn't find a sound driver that works");
} }
RageSoundManager::~RageSoundManager() RageSoundManager::~RageSoundManager()
+1 -1
View File
@@ -153,7 +153,7 @@ void RageTextureManager::UnloadTexture( CString sTexturePath )
std::map<CString, RageTexture*>::iterator p = m_mapPathToTexture.find(sTexturePath); std::map<CString, RageTexture*>::iterator p = m_mapPathToTexture.find(sTexturePath);
if(p == m_mapPathToTexture.end()) if(p == m_mapPathToTexture.end())
throw RageException( "Tried to Unload texture '%s' that wasn't loaded.", sTexturePath.GetString() ); RageException::Throw( "Tried to Unload texture '%s' that wasn't loaded.", sTexturePath.GetString() );
RageTexture* pTexture = p->second; RageTexture* pTexture = p->second;
pTexture->m_iRefCount--; pTexture->m_iRefCount--;
+1 -1
View File
@@ -230,7 +230,7 @@ Screen* ScreenManager::MakeNewScreen( CString sClassName )
else if( 0==stricmp(sClassName, "ScreenTitleMenu") ) ret = new ScreenTitleMenu; else if( 0==stricmp(sClassName, "ScreenTitleMenu") ) ret = new ScreenTitleMenu;
else if( 0==stricmp(sClassName, "ScreenEz2SelectMusic") ) ret = new ScreenEz2SelectMusic; else if( 0==stricmp(sClassName, "ScreenEz2SelectMusic") ) ret = new ScreenEz2SelectMusic;
else else
throw RageException( "Invalid Screen class name '%s'", sClassName.GetString() ); RageException::Throw( "Invalid Screen class name '%s'", sClassName.GetString() );
/* That probably took a little while. Let's reset stats. This prevents us /* That probably took a little while. Let's reset stats. This prevents us
* from displaying an unnaturally low FPS value, and the next FPS value we * from displaying an unnaturally low FPS value, and the next FPS value we
+1 -1
View File
@@ -78,7 +78,7 @@ void SongManager::SanityCheckGroupDir( CString sDir ) const
GetDirListing( sDir + "\\*.ogg", arrayFiles ); GetDirListing( sDir + "\\*.ogg", arrayFiles );
GetDirListing( sDir + "\\*.wav", arrayFiles ); GetDirListing( sDir + "\\*.wav", arrayFiles );
if( !arrayFiles.empty() ) if( !arrayFiles.empty() )
throw RageException( RageException::Throw(
"The folder '%s' contains music files.\n\n" "The folder '%s' contains music files.\n\n"
"This means that you have a music outside of a song folder.\n" "This means that you have a music outside of a song folder.\n"
"All song folders must reside in a group folder. For example, 'Songs\\DDR 4th Mix\\B4U'.\n" "All song folders must reside in a group folder. For example, 'Songs\\DDR 4th Mix\\B4U'.\n"
+4 -4
View File
@@ -73,17 +73,17 @@ bool Sprite::LoadFromSpriteFile( CString sSpritePath, RageTexturePrefs prefs )
IniFile ini; IniFile ini;
ini.SetPath( m_sSpritePath ); ini.SetPath( m_sSpritePath );
if( !ini.ReadFile() ) if( !ini.ReadFile() )
throw RageException( "Error opening Sprite file '%s'.", m_sSpritePath.GetString() ); RageException::Throw( "Error opening Sprite file '%s'.", m_sSpritePath.GetString() );
CString sTextureFile; CString sTextureFile;
ini.GetValue( "Sprite", "Texture", sTextureFile ); ini.GetValue( "Sprite", "Texture", sTextureFile );
if( sTextureFile == "" ) if( sTextureFile == "" )
throw RageException( "Error reading value 'Texture' from %s.", m_sSpritePath.GetString() ); RageException::Throw( "Error reading value 'Texture' from %s.", m_sSpritePath.GetString() );
CString sTexturePath = sFontDir + sTextureFile; // save the path of the new texture CString sTexturePath = sFontDir + sTextureFile; // save the path of the new texture
if( !DoesFileExist(sTexturePath) ) if( !DoesFileExist(sTexturePath) )
throw RageException( "The sprite file '%s' points to a texture '%s' which doesn't exist.", m_sSpritePath.GetString(), sTexturePath.GetString() ); RageException::Throw( "The sprite file '%s' points to a texture '%s' which doesn't exist.", m_sSpritePath.GetString(), sTexturePath.GetString() );
// Load the texture // Load the texture
@@ -100,7 +100,7 @@ bool Sprite::LoadFromSpriteFile( CString sSpritePath, RageTexturePrefs prefs )
if( !ini.GetValueI( "Sprite", sFrameKey, m_iStateToFrame[i] ) ) if( !ini.GetValueI( "Sprite", sFrameKey, m_iStateToFrame[i] ) )
break; break;
if( m_iStateToFrame[i] >= m_pTexture->GetNumFrames() ) if( m_iStateToFrame[i] >= m_pTexture->GetNumFrames() )
throw RageException( "In '%s', %s is %d, but the texture %s only has %d frames.", RageException::Throw( "In '%s', %s is %d, but the texture %s only has %d frames.",
m_sSpritePath.GetString(), sFrameKey.GetString(), m_iStateToFrame[i], sTexturePath.GetString(), m_pTexture->GetNumFrames() ); m_sSpritePath.GetString(), sFrameKey.GetString(), m_iStateToFrame[i], sTexturePath.GetString(), m_pTexture->GetNumFrames() );
m_fDelay[i] = 0.2f; m_fDelay[i] = 0.2f;
if( !ini.GetValueF( "Sprite", sDelayKey, m_fDelay[i] ) ) if( !ini.GetValueF( "Sprite", sDelayKey, m_fDelay[i] ) )
+3 -3
View File
@@ -176,7 +176,7 @@ int main(int argc, char* argv[])
/* Initialize the SDL library. */ /* Initialize the SDL library. */
if( SDL_InitSubSystem(SDL_INIT_VIDEO) < 0 ) if( SDL_InitSubSystem(SDL_INIT_VIDEO) < 0 )
throw RageException( "Couldn't initialize SDL: %s\n", SDL_GetError() ); RageException::Throw( "Couldn't initialize SDL: %s\n", SDL_GetError() );
SetIcon(); SetIcon();
@@ -227,7 +227,7 @@ int main(int argc, char* argv[])
SDL_SysWMinfo info; SDL_SysWMinfo info;
SDL_VERSION(&info.version); SDL_VERSION(&info.version);
if ( SDL_GetWMInfo(&info) < 0 ) if ( SDL_GetWMInfo(&info) < 0 )
throw RageException( "SDL_GetWMInfo failed" ); RageException::Throw( "SDL_GetWMInfo failed" );
#ifdef WIN32 #ifdef WIN32
g_hWndMain = info.window; g_hWndMain = info.window;
@@ -247,7 +247,7 @@ int main(int argc, char* argv[])
// immediately try to connect to server // immediately try to connect to server
GAMESTATE->m_pCurSong = SONGMAN->GetSongFromDir( g_sSongPath ); GAMESTATE->m_pCurSong = SONGMAN->GetSongFromDir( g_sSongPath );
if( GAMESTATE->m_pCurSong == NULL ) if( GAMESTATE->m_pCurSong == NULL )
throw RageException( "The song '%s' is required to play this network game.", g_sSongPath.GetString() ); RageException::Throw( "The song '%s' is required to play this network game.", g_sSongPath.GetString() );
CLIENT->Connect( (const char*)g_sServerIP, SM_PORT ); CLIENT->Connect( (const char*)g_sServerIP, SM_PORT );
SCREENMAN->SetNewScreen( "ScreenNetworkWaiting" ); SCREENMAN->SetNewScreen( "ScreenNetworkWaiting" );
} }
+3 -3
View File
@@ -176,7 +176,7 @@ try_element_again:
break; break;
case IDABORT: case IDABORT:
#endif #endif
throw RageException( "Theme element '%s/%s' could not be found in '%s' or '%s'.", RageException::Throw( "Theme element '%s/%s' could not be found in '%s' or '%s'.",
sAssetCategory.GetString(), sAssetCategory.GetString(),
sFileName.GetString(), sFileName.GetString(),
GetThemeDirFromName(m_sCurThemeName).GetString(), GetThemeDirFromName(m_sCurThemeName).GetString(),
@@ -217,7 +217,7 @@ try_element_again:
if( IDRETRY == MessageBox(NULL,"ThemeManager",ssprintf("The redirect '%s' points to the file '%s', which does not exist. Verify that this redirect is correct.", sRedirFilePath.GetString(), sNewFilePath.GetString()), MB_RETRYCANCEL ) ) if( IDRETRY == MessageBox(NULL,"ThemeManager",ssprintf("The redirect '%s' points to the file '%s', which does not exist. Verify that this redirect is correct.", sRedirFilePath.GetString(), sNewFilePath.GetString()), MB_RETRYCANCEL ) )
goto try_element_again; goto try_element_again;
#endif #endif
throw RageException( "The redirect '%s' points to the file '%s', which does not exist. Verify that this redirect is correct.", sRedirFilePath.GetString(), sNewFilePath.GetString() ); RageException::Throw( "The redirect '%s' points to the file '%s', which does not exist. Verify that this redirect is correct.", sRedirFilePath.GetString(), sNewFilePath.GetString() );
} }
else else
return sNewFilePath; return sNewFilePath;
@@ -264,7 +264,7 @@ try_metric_again:
goto try_metric_again; goto try_metric_again;
#endif #endif
throw RageException( "Theme metric '%s : %s' could not be found in '%s' or '%s'.", RageException::Throw( "Theme metric '%s : %s' could not be found in '%s' or '%s'.",
sClassName.GetString(), sClassName.GetString(),
sValueName.GetString(), sValueName.GetString(),
sCurMetricPath.GetString(), sCurMetricPath.GetString(),