diff options
author | tobigun <tobigun@b956fd51-792f-4845-bead-9b4dfca2ff2c> | 2008-05-08 17:26:37 +0000 |
---|---|---|
committer | tobigun <tobigun@b956fd51-792f-4845-bead-9b4dfca2ff2c> | 2008-05-08 17:26:37 +0000 |
commit | 0dd7fd1b3a6276a39699a00e72289f264b7fdd4f (patch) | |
tree | a3336ed458e633bb63e38a8b3bbf3910b7974d7d /Game/Code/Classes | |
parent | d9f655090a307ecc8bb3ea4a74572744090bb2d7 (diff) | |
download | usdx-0dd7fd1b3a6276a39699a00e72289f264b7fdd4f.tar.gz usdx-0dd7fd1b3a6276a39699a00e72289f264b7fdd4f.tar.xz usdx-0dd7fd1b3a6276a39699a00e72289f264b7fdd4f.zip |
- removed a windows unit reference
- added a missing "result :=" in bass error message function
- set default log-level to warn
git-svn-id: svn://svn.code.sf.net/p/ultrastardx/svn/trunk@1068 b956fd51-792f-4845-bead-9b4dfca2ff2c
Diffstat (limited to 'Game/Code/Classes')
-rw-r--r-- | Game/Code/Classes/UAudioCore_Bass.pas | 86 | ||||
-rw-r--r-- | Game/Code/Classes/UCovers.pas | 3 | ||||
-rw-r--r-- | Game/Code/Classes/ULog.pas | 2 |
3 files changed, 44 insertions, 47 deletions
diff --git a/Game/Code/Classes/UAudioCore_Bass.pas b/Game/Code/Classes/UAudioCore_Bass.pas index 55148f95..9c13b461 100644 --- a/Game/Code/Classes/UAudioCore_Bass.pas +++ b/Game/Code/Classes/UAudioCore_Bass.pas @@ -1,42 +1,42 @@ unit UAudioCore_Bass;
- -interface - -{$IFDEF FPC} - {$MODE Delphi} -{$ENDIF} - -{$I switches.inc} - -uses - Classes, - SysUtils; - -type - TAudioCore_Bass = class - private - public - class function ErrorGetString(): string; overload; - class function ErrorGetString(errCode: integer): string; overload; - end; - - -implementation - -uses - UMain, - ULog, - bass; - -class function TAudioCore_Bass.ErrorGetString(): string; -begin - ErrorGetString(BASS_ErrorGetCode()); -end; - -class function TAudioCore_Bass.ErrorGetString(errCode: integer): string; -begin - case errCode of - BASS_OK: +
+interface
+
+{$IFDEF FPC}
+ {$MODE Delphi}
+{$ENDIF}
+
+{$I switches.inc}
+
+uses
+ Classes,
+ SysUtils;
+
+type
+ TAudioCore_Bass = class
+ private
+ public
+ class function ErrorGetString(): string; overload;
+ class function ErrorGetString(errCode: integer): string; overload;
+ end;
+
+
+implementation
+
+uses
+ UMain,
+ ULog,
+ bass;
+
+class function TAudioCore_Bass.ErrorGetString(): string;
+begin
+ Result := ErrorGetString(BASS_ErrorGetCode());
+end;
+
+class function TAudioCore_Bass.ErrorGetString(errCode: integer): string;
+begin
+ case errCode of
+ BASS_OK:
result := 'No error';
BASS_ERROR_MEM:
result := 'Insufficient memory';
@@ -107,10 +107,10 @@ begin BASS_ERROR_CODEC:
result := 'Codec not available/supported';
BASS_ERROR_UNKNOWN:
- result := 'Unknown error'; - else - result := 'Unknown error'; - end; -end; + result := 'Unknown error';
+ else
+ result := 'Unknown error';
+ end;
+end;
end.
\ No newline at end of file diff --git a/Game/Code/Classes/UCovers.pas b/Game/Code/Classes/UCovers.pas index 478264b9..9cd7af10 100644 --- a/Game/Code/Classes/UCovers.pas +++ b/Game/Code/Classes/UCovers.pas @@ -9,9 +9,6 @@ interface {$I switches.inc} uses gl, - {$IFDEF win32} - windows, - {$ENDIF} Math, Classes, SysUtils, diff --git a/Game/Code/Classes/ULog.pas b/Game/Code/Classes/ULog.pas index ca488e7e..1d710387 100644 --- a/Game/Code/Classes/ULog.pas +++ b/Game/Code/Classes/ULog.pas @@ -37,7 +37,7 @@ const LOG_LEVEL_NONE = -1;
// define level that Log(File)Level is initialized with
- LOG_LEVEL_DEFAULT = LOG_LEVEL_INFO;
+ LOG_LEVEL_DEFAULT = LOG_LEVEL_WARN;
LOG_FILE_LEVEL_DEFAULT = LOG_LEVEL_ERROR;
type
|