Move the diagram in Y direction if screen saver mode is turned on

This commit is contained in:
Thomas Basler 2023-12-24 15:08:10 +01:00
parent 2259b1b525
commit 06b8fb65a1

View File

@ -63,7 +63,7 @@ void DisplayGraphicDiagramClass::updatePeriod()
void DisplayGraphicDiagramClass::redraw(uint8_t screenSaverOffsetX)
{
const uint8_t graphPosX = DIAG_POSX + ((screenSaverOffsetX > 3) ? 1 : 0); // screenSaverOffsetX expected to be in range 0..6
const uint8_t graphPosY = DIAG_POSY;
const uint8_t graphPosY = DIAG_POSY + ((screenSaverOffsetX > 3) ? 1 : 0);
// draw diagram axis
_display->drawVLine(graphPosX, graphPosY, CHART_HEIGHT);