Skip to content

Commit 2d6a1d8

Browse files
authored
Merge pull request #104 from squix78/loadingDrawFunction-fix
Implement setLoadingDrawFunction. Fixes #102
2 parents da94d3e + 7126cd0 commit 2d6a1d8

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

OLEDDisplayUi.cpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -116,6 +116,10 @@ void OLEDDisplayUi::setOverlays(OverlayCallback* overlayFunctions, uint8_t overl
116116

117117
// -/----- Loading Process -----\-
118118

119+
void OLEDDisplayUi::setLoadingDrawFunction(LoadingDrawFunction loadingDrawFunction) {
120+
this->loadingDrawFunction = loadingDrawFunction;
121+
}
122+
119123
void OLEDDisplayUi::runLoadingProcess(LoadingStage* stages, uint8_t stagesCount) {
120124
uint8_t progress = 0;
121125
uint8_t increment = 100 / stagesCount;

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -322,7 +322,7 @@ void setOverlays(OverlayCallback* overlayFunctions, uint8_t overlayCount);
322322
* Set the function that will draw each step
323323
* in the loading animation
324324
*/
325-
void setLoadingDrawFunction(LoadingDrawFunction stage);
325+
void setLoadingDrawFunction(LoadingDrawFunction loadingDrawFunction);
326326
327327
/**
328328
* Run the loading process

0 commit comments

Comments
 (0)