LCD LIB
Fork of RA8875 by
Diff: GraphicsDisplay.cpp
- Revision:
- 142:6e9bff59878a
- Parent:
- 136:224e03d5c31f
- Child:
- 146:373d59f08357
--- a/GraphicsDisplay.cpp Thu Dec 29 20:06:00 2016 +0000 +++ b/GraphicsDisplay.cpp Sun Mar 19 21:41:24 2017 +0000 @@ -150,7 +150,17 @@ RetCode_t GraphicsDisplay::cls(uint16_t layers) { - return fill(0, 0, width(), height(), _background); + int restore = GetDrawingLayer(); + if (layers & 1) { + SelectDrawingLayer(0); + fill(0, 0, width(), height(), _background); + } + if (layers & 2) { + SelectDrawingLayer(1); + fill(0, 0, width(), height(), _background); + } + SelectDrawingLayer(restore); + return noerror; } RetCode_t GraphicsDisplay::blit(loc_t x, loc_t y, dim_t w, dim_t h, const int * color)