Changeset 404
- Timestamp:
- May 22, 2016, 2:31:05 PM (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Library/DebugUnit.pas
r393 r404 29 29 LogViewStub, 30 30 LogObjConstDest, 31 LogMem, 31 32 LogDebug 32 33 ); 33 34 LogAspects = SET OF LogAspect; 34 35 36 Function IsLogAspectsEnabled(const aLogAspect: LogAspect) : boolean; 35 37 Procedure LogEvent(const aLogAspect: LogAspect; const anEventDescription: String); 36 38 … … 144 146 LogViewStub : result := 'ViewStub'; 145 147 LogObjConstDest : result := 'ObjConstDest'; 148 LogMem : result := 'Mem'; 146 149 LogDebug : result := 'Debug'; 147 150 else result := 'Unknown'; … … 170 173 if tmpAspects[i] = 'LogViewStub' then activeLogAspects := activeLogAspects + [ LogViewStub ]; 171 174 if tmpAspects[i] = 'LogObjConstDest' then activeLogAspects := activeLogAspects + [ LogObjConstDest ]; 175 if tmpAspects[i] = 'LogMem' then activeLogAspects := activeLogAspects + [ LogMem ]; 172 176 if tmpAspects[i] = 'LogDebug' then activeLogAspects := activeLogAspects + [ LogDebug ]; 173 177 end; … … 177 181 178 182 183 Function IsLogAspectsEnabled(const aLogAspect: LogAspect) : boolean; 184 Begin 185 result := aLogAspect IN activeLogAspects; 186 End; 187 188 179 189 Procedure LogEvent(const aLogAspect: LogAspect; const anEventDescription: String); 180 190 Var 181 191 tmpMessage : String; 182 192 Begin 183 if (aLogAspect IN activeLogAspects) then193 if IsLogAspectsEnabled(aLogAspect) then 184 194 begin 185 195 tmpMessage := 'Log[' + GetAspectPrefix(aLogAspect) + '] ' + anEventDescription;
Note:
See TracChangeset
for help on using the changeset viewer.