diff options
| author | Kieran Cawthray <kieranc@gmail.com> | 2021-06-25 06:48:16 (GMT) |
|---|---|---|
| committer | Kieran Cawthray <kieranc@gmail.com> | 2021-06-25 06:48:16 (GMT) |
| commit | d5d8438b60dfd34b2399caab67e0efe34c677f54 (patch) | |
| tree | b9a40f4d02ce0d7a2784f65dc9c37e286645a559 /src/drivers/St7789.cpp | |
| parent | 8f16574992b1bb0f49b884f95cf9b7f5d709c6b6 (diff) | |
| parent | 883700fca13a45b6cb0af4d74e3ef276a2d69283 (diff) | |
Merge remote-tracking branch 'upstream/develop' into pinetimestyle-colorpicker
Diffstat (limited to 'src/drivers/St7789.cpp')
| -rw-r--r-- | src/drivers/St7789.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/drivers/St7789.cpp b/src/drivers/St7789.cpp index 39218e7..0f1dc02 100644 --- a/src/drivers/St7789.cpp +++ b/src/drivers/St7789.cpp @@ -140,8 +140,9 @@ void St7789::Uninit() { } void St7789::DrawPixel(uint16_t x, uint16_t y, uint32_t color) { - if ((x < 0) || (x >= Width) || (y < 0) || (y >= Height)) + if (x >= Width || y >= Height) { return; + } SetAddrWindow(x, y, x + 1, y + 1); |
