svn-id: r32814
This commit is contained in:
Vicent Marti 2008-06-26 23:15:34 +00:00
parent 5534ce68a1
commit 8d696760b3
3 changed files with 15 additions and 4 deletions

View File

@ -257,7 +257,8 @@ void InterfaceManager::drawScrollbar(const Common::Rect &r, int sliderY, int sli
int InterfaceManager::runGUI() {
Common::EventManager *eventMan = _system->getEventManager();
loadTheme("modern_theme.xml");
if (!loadTheme("modern_theme.xml"))
return 0;
_system->showOverlay();

View File

@ -43,14 +43,20 @@ bool InterfaceManager::loadDefaultXML() {
"<color name = 'green' rgb = '0, 255, 0' />"
"<color name = 'blue' rgb = '0, 0, 255' />"
"</palette>"
"<default fill = 'gradient' fg_color = '255, 255, 255' />"
"<drawdata id = 'mainmenu_bg' cache = false>"
"<drawstep func = 'fill' fill = 'gradient' gradient_start = '214, 113, 8' gradient_end = '240, 200, 25' />"
"</drawdata>"
"<drawdata id = 'button_idle' cache = false>"
"<drawstep func = 'roundedsq' radius = '8' fill = 'gradient' gradient_start = '206, 121, 99' gradient_end = '173, 40, 8' size = 'auto' />"
"</drawdata>"
"</render_info>";
"</render_info>"
"<layout_info>"
"</layout_info>";
if (!parser()->loadBuffer(defaultXML, true))
return false;

View File

@ -233,8 +233,12 @@ bool ThemeParser::parserCallback_DRAWDATA() {
if (id == -1)
return parserError("%s is not a valid DrawData set identifier.", drawdataNode->values["id"].c_str());
if (drawdataNode->values.contains("cached") && drawdataNode->values["cached"] == "true") {
cached = true;
if (drawdataNode->values.contains("cache")) {
if (drawdataNode->values["cache"] == "true")
cached = true;
else if (drawdataNode->values["cache"] == "false")
cached = false;
else return parserError("'Parsed' value must be either true or false.");
}
// Both Max and Johannes suggest using a non-platform specfic approach based on available