more iOS port fix

This commit is contained in:
Xawotihs
2010-11-23 23:35:40 +00:00
parent ba027c9f8e
commit 7e37e68755
3 changed files with 4 additions and 8 deletions
+1 -1
View File
@@ -62,7 +62,7 @@ void dumpStack();
// *** DEFINES *** // *** DEFINES ***
#if defined (WIN32) || defined (LINUX) #if defined (WIN32) || defined (LINUX) || defined (IOS)
#define RAM_BLOCK (100 * 1024 * 1024) #define RAM_BLOCK (100 * 1024 * 1024)
#else #else
#define RAM_BLOCK (1024 * 1024) #define RAM_BLOCK (1024 * 1024)
-4
View File
@@ -278,11 +278,7 @@ int GameStateMenu::nextDirectory(const char * root, const char * file)
int found = 0; int found = 0;
if (!mDip) if (!mDip)
{ {
#ifdef IOS
mDip = opendir(JGE_GET_RES(root).c_str());
#else
mDip = opendir(root); mDip = opendir(root);
#endif //IOS
} }
while (!found && (mDit = readdir(mDip))) while (!found && (mDit = readdir(mDip)))
+3 -3
View File
@@ -69,7 +69,7 @@ void WResourceManager::DebugRender()
textureWCache.cacheSize, textureWCache.maxCacheSize, man); textureWCache.cacheSize, textureWCache.maxCacheSize, man);
font->DrawString(buf, 10, 5); font->DrawString(buf, 10, 5);
#if defined (WIN32) || defined (LINUX) #if defined (WIN32) || defined (LINUX) || defined (IOS)
#else #else
int maxLinear = ramAvailableLineareMax(); int maxLinear = ramAvailableLineareMax();
int ram = ramAvailable(); int ram = ramAvailable();
@@ -950,7 +950,7 @@ void WResourceManager::RemoveWFonts()
void WResourceManager::ResetCacheLimits() void WResourceManager::ResetCacheLimits()
{ {
#if defined WIN32 || defined LINUX #if defined WIN32 || defined LINUX || defined (IOS)
#ifdef FORCE_LOW_CACHE_MEMORY #ifdef FORCE_LOW_CACHE_MEMORY
textureWCache.Resize(kConstrainedCacheLimit, MAX_CACHE_OBJECTS); textureWCache.Resize(kConstrainedCacheLimit, MAX_CACHE_OBJECTS);
#else #else
@@ -1383,7 +1383,7 @@ bool WCache<cacheItem, cacheActual>::Cleanup()
} }
while (cacheItems > MAX_CACHE_OBJECTS || cacheItems > maxCached || cacheSize > maxCacheSize while (cacheItems > MAX_CACHE_OBJECTS || cacheItems > maxCached || cacheSize > maxCacheSize
#if defined WIN32 || defined LINUX #if defined WIN32 || defined LINUX || defined (IOS)
#else #else
|| ramAvailableLineareMax() < MIN_LINEAR_RAM || ramAvailableLineareMax() < MIN_LINEAR_RAM
#endif #endif