Skip to content

Commit

Permalink
refactor: use MCUFRIEND_KBV_H_ macro to determine the functionality o…
Browse files Browse the repository at this point in the history
…f App::get_at method

Signed-off-by: Aditya Agarwal <[email protected]>
  • Loading branch information
Aditya-A-garwal committed Apr 29, 2024
1 parent 8ff5da0 commit 618fa04
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion lib/gui/include/widgets/app.h
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ class App : public BasicWidget, public DrawableWidget {

protected:

#ifdef READ_PIXEL_ENABLED
#ifdef MCUFRIEND_KBV_H_
using display_t = MCUFRIEND_kbv;
#else
using display_t = Adafruit_GFX;
Expand Down
2 changes: 1 addition & 1 deletion lib/gui/src/widgets/app.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -167,7 +167,7 @@ App *App::set_at(unsigned int x, unsigned int y, uint16_t color) {

uint16_t App::get_at(unsigned int x, unsigned int y) const {

#ifdef READ_PIXEL_ENABLED
#ifdef MCUFRIEND_KBV_H_
return display->readPixel(x, y);
#else
return 0;
Expand Down

0 comments on commit 618fa04

Please sign in to comment.