Date:2011-04-01 18:31:54 (12 years 11 months ago)
Author:Paul Cercueil
Commit:fe25cf341d327a0e80f50e3a960db244fa1b2560
Message:The skin images will now be loaded using SurfaceCollection::getSkinFilePath().

Files: src/surface.cpp (2 diffs)

Change Details

src/surface.cpp
2626#include "surface.h"
2727#include "utilities.h"
2828#include "debug.h"
29#include "surfacecollection.h"
2930
3031RGBAColor strtorgba(const string &strColor) {
3132    RGBAColor c = {0,0,0,255};
...... 
116117    free();
117118
118119    string skinpath;
119    if (!skin.empty() && !img.empty() && img[0]!='/') {
120        skinpath = "skins/"+skin+"/"+img;
121        if (!fileExists(skinpath))
122            skinpath = "skins/Default/"+img;
123    } else {
124        skinpath = img;
125    }
120    if (!skin.empty() && !img.empty() && img[0]!='/')
121      skinpath = SurfaceCollection::getSkinFilePath(skin, img);
122    else
123      skinpath = img;
126124
127125    SDL_Surface *buf = IMG_Load(skinpath.c_str());
128126    if (buf!=NULL) {

Archive Download the corresponding diff file



interactive