Minor code clarification.

Clarifies usage of a non-intuitive SDL error code in CVideo::fill.
This commit is contained in:
Tommy 2022-05-08 16:20:50 +12:00
parent e681ef3a32
commit 603006f0ed

View file

@ -178,10 +178,10 @@ int CVideo::fill(
uint8_t r, uint8_t g, uint8_t b, uint8_t a)
{
int e = SDL_SetRenderDrawColor(*window, r, g, b, a);
if (e) {
return e;
} else {
if (e == 0) {
return SDL_RenderFillRect(*window, &area);
} else {
return e;
}
}