integrated searchpath system

git-svn-id: https://clonekeenplus.svn.sourceforge.net/svnroot/clonekeenplus/cgenius/trunk@149 4df4b0f3-56ce-47cb-b001-ed939b7d65a6
This commit is contained in:
albertzeyer
2009-07-24 15:22:28 +00:00
parent 60bce8a456
commit 742176416b
18 changed files with 68 additions and 42 deletions

View File

@@ -7,7 +7,8 @@
#include "CHQBitmap.h"
#include "../CLogFile.h"
#include <stdlib.h>
#include "../FindFile.h"
#include <cstdlib>
CHQBitmap::CHQBitmap(SDL_Rect screenrect) {
m_scrimg = NULL;
@@ -24,10 +25,14 @@ CHQBitmap::~CHQBitmap() {
bool CHQBitmap::loadImage(const std::string& pFilename, int wsize, int hsize)
{
SDL_Surface *BitmapSurface = SDL_LoadBMP(pFilename.c_str());
m_active = false;
std::string fullfname = GetFullFileName(pFilename);
if(fullfname.size() == 0)
return false;
SDL_Surface *BitmapSurface = SDL_LoadBMP(Utf8ToSystemNative(fullfname).c_str());
if(BitmapSurface)
{
if((m_scrimg = SDL_DisplayFormat(BitmapSurface)))