New debug messages.

svn-id: r26832
This commit is contained in:
Nicola Mettifogo 2007-05-13 12:41:42 +00:00
parent 7c79fe5bce
commit 09c816e695
5 changed files with 15 additions and 6 deletions

View File

@ -465,7 +465,7 @@ void jobRunScripts(void *parm, Job *j) {
while (((*inst)->_index != INST_SHOW) && (a->_flags & kFlagsActing)) {
debugC(1, kDebugJobs, "Animation: %s, instruction: %s", a->_label._text, (*inst)->_index == INST_END ? "end" : _instructionNamesRes[(*inst)->_index - 1]);
debugC(9, kDebugJobs, "Animation: %s, instruction: %s", a->_label._text, (*inst)->_index == INST_END ? "end" : _instructionNamesRes[(*inst)->_index - 1]);
switch ((*inst)->_index) {
case INST_ENDLOOP: // endloop

View File

@ -412,7 +412,7 @@ void Gfx::blit(const Common::Rect& r, uint16 z, byte *data, Gfx::Buffers buffer)
void jobDisplayLabel(void *parm, Job *j) {
Label *label = (Label*)parm;
debugC(1, kDebugJobs, "jobDisplayLabel (%p)", (const void*) label);
debugC(9, kDebugJobs, "jobDisplayLabel (%p)", (const void*) label);
if (label->_cnv._width == 0)
return;
@ -424,7 +424,7 @@ void jobDisplayLabel(void *parm, Job *j) {
void jobEraseLabel(void *parm, Job *j) {
Label *label = (Label*)parm;
debugC(1, kDebugJobs, "jobEraseLabel (%p)", (const void*) label);
debugC(9, kDebugJobs, "jobEraseLabel (%p)", (const void*) label);
int16 _si, _di;

View File

@ -294,6 +294,7 @@ uint16 Menu::selectGame() {
// character selection and protection
//
void Menu::selectCharacter() {
debugC(1, kDebugMenu, "Menu::selectCharacter()");
uint16 _di = 0;
bool askPassword = true;

View File

@ -121,7 +121,7 @@ Parallaction::Parallaction(OSystem *syst) :
Common::addSpecialDebugLevel(kDebugJobs, "jobs", "Jobs debug level");
Common::addSpecialDebugLevel(kDebugInput, "input", "Input debug level");
Common::addSpecialDebugLevel(kDebugAudio, "audio", "Audio debug level");
Common::addSpecialDebugLevel(kDebugMenu, "menu", "Menu debug level");
}
@ -788,6 +788,7 @@ int compareJobPriority(const JobPointer &j1, const JobPointer &j2) {
}
Job *Parallaction::addJob(JobFn fn, void *parm, uint16 tag) {
debugC(3, kDebugJobs, "addJob(%i)", tag);
Job *v8 = new Job;
@ -803,16 +804,22 @@ Job *Parallaction::addJob(JobFn fn, void *parm, uint16 tag) {
}
void Parallaction::removeJob(Job *j) {
debugC(3, kDebugJobs, "addJob(%i)", j->_tag);
j->_finished = 1;
return;
}
void Parallaction::pauseJobs() {
debugC(3, kDebugJobs, "pausing jobs execution");
_engineFlags |= kEnginePauseJobs;
return;
}
void Parallaction::resumeJobs() {
debugC(3, kDebugJobs, "resuming jobs execution");
_engineFlags &= ~kEnginePauseJobs;
return;
}
@ -831,7 +838,7 @@ void Parallaction::runJobs() {
it = _jobs.begin();
while (it != _jobs.end()) {
debugC(3, kDebugJobs, "runJobs: %i", (*it)->_tag);
debugC(9, kDebugJobs, "runJobs: %i", (*it)->_tag);
(*(*it)->_fn)((*it)->_parm, (*it));
it++;
}

View File

@ -52,7 +52,8 @@ enum {
kDebugGraphics = 1 << 4,
kDebugJobs = 1 << 5,
kDebugInput = 1 << 6,
kDebugAudio = 1 << 7
kDebugAudio = 1 << 7,
kDebugMenu = 1 << 8
};
enum {