Skip to content

Commit

Permalink
o Make sure the actual active frame is set after SwapOnVSync().
Browse files Browse the repository at this point in the history
  • Loading branch information
hzeller committed Aug 4, 2015
1 parent 9e7256f commit 55ff266
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion lib/led-matrix.cc
Original file line number Diff line number Diff line change
Expand Up @@ -159,7 +159,9 @@ FrameCanvas *RGBMatrix::CreateFrameCanvas() {
}

FrameCanvas *RGBMatrix::SwapOnVSync(FrameCanvas *other) {
return updater_->SwapOnVSync(other);
FrameCanvas *const previous = updater_->SwapOnVSync(other);
if (other) active_ = other;
return previous;
}

void RGBMatrix::SetTransformer(CanvasTransformer *transformer) {
Expand Down

0 comments on commit 55ff266

Please sign in to comment.