ActorUtil::ResolvePath updated for error reporting. Changed BitmapText to work with either a font name or a path. ThemeManager::GetPathInfoRaw fixed to use correct error dialog. ThemeManager::GetPathInfo fixed to report correct error for missing theme elements.

This commit is contained in:
Kyzentun
2014-07-14 18:02:28 -06:00
parent 6cf23c4dc3
commit 273b76d3c7
3 changed files with 23 additions and 20 deletions
+6 -5
View File
@@ -722,7 +722,7 @@ bool ThemeManager::GetPathInfoToRaw( PathInfo &out, const RString &sThemeName_,
"Verify that this redirect is correct.",
sPath.c_str(), sNewFileName.c_str());
switch( LuaHelpers::ReportScriptError(sMessage) )
switch(LuaHelpers::ReportScriptError(sMessage, "", true))
{
case Dialog::retry:
ReloadMetrics();
@@ -815,11 +815,12 @@ try_element_again:
goto try_element_again;
case Dialog::ignore:
{
RString error= ssprintf(sCategory + '/' + sFileName,
"could not be found in \"%s\" or \"%s\".",
GetThemeDirFromName(m_sCurThemeName).c_str(),
GetThemeDirFromName(SpecialFiles::BASE_THEME_NAME).c_str() );
RString error= sCategory + '/' + sFileName +
" could not be found in \"" +
GetThemeDirFromName(m_sCurThemeName).c_str() + "\" or \"" +
GetThemeDirFromName(SpecialFiles::BASE_THEME_NAME).c_str() + "\".";
LOG->UserLog("Theme element", "%s", error.c_str());
LOG->Warn(error.c_str());
LuaHelpers::ScriptErrorMessage(error);
}