diff options
| author | Einar Johan Trøan Sømåen | 2012-07-29 14:56:39 +0200 | 
|---|---|---|
| committer | Einar Johan Trøan Sømåen | 2012-07-29 14:56:39 +0200 | 
| commit | da0ba41903bf50c3a6cb2923ca943386cd984f8c (patch) | |
| tree | 53a9a692329b0c1fae9a664c1e6e2b435c8d9a5c /engines | |
| parent | 3a218180017e97e4b9dceca3bf25a232f271c6b9 (diff) | |
| download | scummvm-rg350-da0ba41903bf50c3a6cb2923ca943386cd984f8c.tar.gz scummvm-rg350-da0ba41903bf50c3a6cb2923ca943386cd984f8c.tar.bz2 scummvm-rg350-da0ba41903bf50c3a6cb2923ca943386cd984f8c.zip  | |
WINTERMUTE: Remove more unused utils.
Diffstat (limited to 'engines')
| -rw-r--r-- | engines/wintermute/utils/utils.cpp | 72 | ||||
| -rw-r--r-- | engines/wintermute/utils/utils.h | 3 | 
2 files changed, 0 insertions, 75 deletions
diff --git a/engines/wintermute/utils/utils.cpp b/engines/wintermute/utils/utils.cpp index 05aa34f95f..6571147a80 100644 --- a/engines/wintermute/utils/utils.cpp +++ b/engines/wintermute/utils/utils.cpp @@ -92,18 +92,6 @@ char *BaseUtils::setString(char **string, const char *value) {  }
  //////////////////////////////////////////////////////////////////////////
 -int BaseUtils::strNumEntries(const char *str, const char delim) {
 -	int numEntries = 1;
 -	for (uint32 i = 0; i < strlen(str); i++) {
 -		if (str[i] == delim) {
 -			numEntries++;
 -		}
 -	}
 -	return numEntries;
 -}
 -
 -
 -//////////////////////////////////////////////////////////////////////////
  char *BaseUtils::strEntry(int entry, const char *str, const char delim) {
  	int numEntries = 0;
 @@ -158,66 +146,6 @@ float BaseUtils::randomAngle(float from, float to) {  }
  //////////////////////////////////////////////////////////////////////////
 -bool BaseUtils::matchesPattern(const char *pattern, const char *string) {
 -	char stringc, patternc;
 -
 -	for (;; ++string) {
 -		stringc = toupper(*string);
 -		patternc = toupper(*pattern++);
 -
 -		switch (patternc) {
 -		case 0:
 -			return (stringc == 0);
 -
 -		case '?':
 -			if (stringc == 0) {
 -				return false;
 -			}
 -			break;
 -
 -		case '*':
 -			if (!*pattern) {
 -				return true;
 -			}
 -
 -			if (*pattern == '.') {
 -				char *dot;
 -				if (pattern[1] == '*' && pattern[2] == 0) {
 -					return true;
 -				}
 -				dot = (char *)strchr(string, '.');
 -				if (pattern[1] == 0) {
 -					return (dot == NULL || dot[1] == 0);
 -				}
 -				if (dot != NULL) {
 -					string = dot;
 -					if (strpbrk(pattern, "*?[") == NULL && strchr(string + 1, '.') == NULL) {
 -						return(scumm_stricmp(pattern + 1, string + 1) == 0);
 -					}
 -				}
 -			}
 -
 -			while (*string)
 -				if (BaseUtils::matchesPattern(pattern, string++)) {
 -					return true;
 -				}
 -			return false;
 -
 -		default:
 -			if (patternc != stringc) {
 -				if (patternc == '.' && stringc == 0) {
 -					return(BaseUtils::matchesPattern(pattern, string));
 -				} else {
 -					return false;
 -				}
 -			}
 -			break;
 -		}
 -	}
 -}
 -
 -
 -//////////////////////////////////////////////////////////////////////////
  void BaseUtils::RGBtoHSL(uint32 rgbColor, byte *outH, byte *outS, byte *outL) {
  	float varR = (RGBCOLGetR(rgbColor) / 255.0f);
  	float varG = (RGBCOLGetG(rgbColor) / 255.0f);
 diff --git a/engines/wintermute/utils/utils.h b/engines/wintermute/utils/utils.h index 5b3ce65470..36a7398869 100644 --- a/engines/wintermute/utils/utils.h +++ b/engines/wintermute/utils/utils.h @@ -46,15 +46,12 @@ public:  	static void debugMessage(const char *text);
  	static char *setString(char **string, const char *value);
 -	static int strNumEntries(const char *str, const char delim = ',');
  	static char *strEntry(int entry, const char *str, const char delim = ',');
  	static int randomInt(int from, int to);
  	static float randomFloat(float from, float to);
  	static float randomAngle(float from, float to);
 -	static bool matchesPattern(const char *pattern, const char *string);
 -
  	static void RGBtoHSL(uint32 rgbColor, byte *outH, byte *outS, byte *outL);
  	static uint32 HSLtoRGB(byte H, byte S, byte L);
  | 
