Merge commit '40829d4cc85394513ca631cff23254344e29786c' of https://github.com/kmatch98/circuitpython into bitmap-dirty-improvements

This commit is contained in:
Jeff Epler 2021-03-19 20:40:30 -05:00
commit 39500cdeab

View File

@ -321,12 +321,12 @@ bool displayio_area_empty(const displayio_area_t *a) {
} }
void displayio_area_canon(displayio_area_t *a) { void displayio_area_canon(displayio_area_t *a) {
if (a->x1 < a->x2) { if (a->x1 > a->x2) {
int16_t t = a->x1; int16_t t = a->x1;
a->x1 = a->x2; a->x1 = a->x2;
a->x2 = t; a->x2 = t;
} }
if (a->y1 < a->y2) { if (a->y1 > a->y2) {
int16_t t = a->y1; int16_t t = a->y1;
a->y1 = a->y2; a->y1 = a->y2;
a->y2 = t; a->y2 = t;