Skip to content

Commit

Permalink
PEGASUS: Cleanup doFadeOutSync/doFadeInSync calls
Browse files Browse the repository at this point in the history
  • Loading branch information
Matthew Hoops committed Jul 6, 2012
1 parent 3860f34 commit b625df1
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 9 deletions.
8 changes: 4 additions & 4 deletions engines/pegasus/graphics.cpp
Expand Up @@ -204,13 +204,13 @@ DisplayElement *GraphicsManager::findDisplayElement(const DisplayElementID id) {
return 0;
}

void GraphicsManager::doFadeOutSync(const TimeValue time, const TimeScale scale, uint32 color) {
void GraphicsManager::doFadeOutSync(const TimeValue time, const TimeScale scale, bool isBlack) {
_updatesEnabled = false;
_screenFader->doFadeOutSync(time, scale, color == 0);
_screenFader->doFadeOutSync(time, scale, isBlack);
}

void GraphicsManager::doFadeInSync(const TimeValue time, const TimeScale scale, uint32 color) {
_screenFader->doFadeInSync(time, scale, color == 0);
void GraphicsManager::doFadeInSync(const TimeValue time, const TimeScale scale, bool isBlack) {
_screenFader->doFadeInSync(time, scale, isBlack);
_updatesEnabled = true;
}

Expand Down
4 changes: 2 additions & 2 deletions engines/pegasus/graphics.h
Expand Up @@ -66,8 +66,8 @@ friend class Cursor;
void disableUpdates();

// These default to black
void doFadeOutSync(const TimeValue = kOneSecondPerThirtyTicks, const TimeScale = kThirtyTicksPerSecond, uint32 color = 0);
void doFadeInSync(const TimeValue = kOneSecondPerThirtyTicks, const TimeScale = kThirtyTicksPerSecond, uint32 color = 0);
void doFadeOutSync(const TimeValue = kOneSecondPerThirtyTicks, const TimeScale = kThirtyTicksPerSecond, bool isBlack = true);
void doFadeInSync(const TimeValue = kOneSecondPerThirtyTicks, const TimeScale = kThirtyTicksPerSecond, bool isBlack = true);

protected:
void markCursorAsDirty();
Expand Down
5 changes: 2 additions & 3 deletions engines/pegasus/neighborhood/caldoria/caldoria.cpp
Expand Up @@ -249,15 +249,14 @@ void Caldoria::start() {
ExtraTable::Entry entry;

if (!skipped) {
uint32 white = g_system->getScreenFormat().RGBToColor(0xff, 0xff, 0xff);
_vm->_gfx->doFadeOutSync(kThreeSeconds * kFifteenTicksPerSecond, kFifteenTicksPerSecond, white);
_vm->_gfx->doFadeOutSync(kThreeSeconds * kFifteenTicksPerSecond, kFifteenTicksPerSecond, false);
g_system->delayMillis(3 * 1000 / 2);
getExtraEntry(kCaldoria00WakeUp1, entry);
_navMovie.setTime(entry.movieStart);
_navMovie.redrawMovieWorld();
_navMovie.show();
_vm->refreshDisplay();
_vm->_gfx->doFadeInSync(kOneSecond * kFifteenTicksPerSecond, kFifteenTicksPerSecond, white);
_vm->_gfx->doFadeInSync(kOneSecond * kFifteenTicksPerSecond, kFifteenTicksPerSecond, false);
} else {
getExtraEntry(kCaldoria00WakeUp1, entry);
_navMovie.setTime(entry.movieStart);
Expand Down

0 comments on commit b625df1

Please sign in to comment.